O GoConqr está de visual novo! Conte para nós o que você achou.

Notas

C2

Wen Xiang Ng Inglês 2 páginas

Conteúdo das notas (2)

Página 1

RESTRICTED 1 RESTRICTED CHAPTER 3 DESIGN CONCEPT OF CLIENT- SERVER ARCHITECTURE INTRODUCTION The Client-Server is a computing architecture based on distributed computing structure that partitions tasks or workloads between the providers of a resource or service, called servers, and service requesters, called clients. Although the Client-Server model can be used by programs within a single computer, it is more an important concept for networked computing, where the clients and servers communicate over a computer network on separate hardware. Distributed Computing A distributed system consists of multiple computer systems (also known as nodes) located either in the same physical location or dispersed within some geographical area that are interconnected over a communication network such as Local or Wide Area Network (LAN/WAN). Distributed computing is the use of more than one computer in a distributed system to perform the processing of a task and a computer program that runs in a distributed system is called a distributed program. In a distributed system, each computer system will has its own local memory and database system to perform independent data processing. Some of the advantages of distributed computing include: a. Improves system processing performance as the computational task is spread among different computers or nodes. b. Improves the system reliability as the distributed system can still continue to function if any one node fails (i.e. Redundancy). RESTRICTED 2 RESTRICTED c. Improves the system scalability as the number of nodes in a distributed system can be easily adjusted. d. Allows the sharing of data across multiple computers through the distributed database. While there are many advantages of distributed computing, there are also drawbacks as follows: a. Extra programming effort is needed to set up the complex management and control mechanism required of a distributed system. b. Higher cost due more components, additional communication devices and follow-on maintenance support required. c. Require added security control on all nodes and the communication network as well. d. Ensuring data integrity of the distributed database. CHARACTERISTICS OF CLIENT- SERVER ARCHITECTURE The client–server characteristic describes the relationship of cooperating programs in an application. The server component provides a function or service to one or many clients, which initiate requests for such services. Whether a computer is a client, a server, or both, is determined by the nature of the application that requires the service functions. In a Client-Server computing architecture, the client establishes a connection to the server over a local area network (LAN) or wide-area network (WAN), such as the internet for service. Once the server has fulfilled the client's request, the connection is terminated. A server host may run one or more server programs which share their resources with the clients. A client on the other hand, does not RESTRICTED 3 RESTRICTED share any of its resources, but requests a server's content or service. Clients therefore initiate communication sessions with servers which await incoming requests. Servers are classified by the services they provide. For instance, a web server serves web pages and a file server serves data files. A shared resource may be any of the server computer's software and hardware components, from programs and data to processors and storage devices. The sharing of resources of a server constitutes a service. For illustration, following Figure 1 shows how services are provided on the World Wide Web using through a Client-Server architecture: FIG 3.1 – CLIENT REQUESTING FOR A STATIC HTML FILE. In Figure 1, the client (browser) requests for an HTML file stored on the remote machine through the server software. The server locates this file and passes it to the client. The client then displays this file on the client machine. Other request may require the server to perform some data search before passing the processed information back to the client. For a C2 system, an example would be the display console running the client program that requests service for track information stored on the C2 Server. The service that the server provided is the delivery of the track information data over the LAN to the C2 console for display. RESTRICTED 4 RESTRICTED PRINCIPLES OF CLIENT- SERVER OPERATION In general, a service is refers to computer resources on a server and the client does not have to be concerned with how the server performs while fulfilling the request and delivering the response. The client only has to understand the response based on the well-known application protocol, i.e. the content and the formatting of the data for the requested service. A server may receive requests from many different clients in a very short period of time. Because the computer can perform a limited number of tasks at any moment, it then relies on a scheduling system to prioritise incoming requests from clients in order to accommodate them all in turn. To prevent abuse and maximise uptime, the server's software limits how a client can use the server's resources. Below figure 2 illustrates the message flow between client and server program: FIG 3.2 – MESSAGE FLOW OF CLIENT-SERVER PROGRAM. Acquire and process data Wait for Request Send data Send Request Process / display data Server Program Client Program RESTRICTED 5 RESTRICTED Following are some of the considerations in the server design: a. Is there more than one client? b. Are multiple clients served one-at-a-time or simultaneously? c. Are the different clients prioritised or treated differently? In the simplest application, only one remote client requests the service from the server computer. In this case the server waits for a request and returns the service to the requesting client. If multiple clients are serviced, the server continually monitors for service requests. The server queues each request as it is received, ensuring all the clients receive the service they request. The server application program queues each client and services it in a first-come-first-serve (First-In-First-Out or FIFO) manner. Once the queue is empty, the server continues to wait for new clients. The monitoring process is best broken into two components. One component detects the requests and queues up each client. The second component processes each queued client and performs the task requested one at a time as shown in Figure 2. Some applications require that you give different clients different priorities based on their importance and urgency to have the service timely. To do this, the server must have a method to identify, differentiate, and authenticate the clients of different priorities that are requesting the service. RESTRICTED 6 RESTRICTED Client-Server Exchange Messages To be serviced effectively, the client program must work with the interface or protocol defined by the server. The server defines the interface for communication between the client and server programs. A well designed interface only exposes how to send messages, what messages are supported, and what the response to each message is to the client. Clients and servers exchange messages in a request-response messaging pattern. The client sends a request, and the server returns a response. This exchange of messages is sometimes called inter-server or server-to-server communication and is an example of inter-process communication. To communicate, the computers must have a common language, and they must follow rules so that both the client and the server know what to expect. The language and rules of communication are defined in a communications protocol. All client-server protocols operate in the application layer. To formalise the data exchange even further, the server may implement an Application Program Interface (API) for the communication and service delivery. An API, in computer programming, specifies a set of functions or routines, inputs, outputs and data structures that accomplish a specific task or are allowed to interact with a specific software component. By restricting communication to a specific content format, it also facilitates cross-platform data exchange. The server and client software are also developed in a modular fashion, separating the message handling mechanism from the functional component processing the request itself. Therefore, you can update the functional component of the server without affecting any clients. This modular approach to a Client-Server application provides a distributed application that you can maintain and update without affecting each client and server component. RESTRICTED 7 RESTRICTED CLIENT-SERVER N-TIER ARCHITECTURAL STYLE The Client-Server architectural style describes distributed systems that involve the client system, server system and a connecting network. The simplest form of client-server system involves a server application that is accessed directly by multiple clients, and is referred to as a 2-Tier architectural style. In a 2-tier Client-Server architecture, the client communicates directly with the database server. The application or business logic either resides on the client or on the database server in the form of stored procedures. N-TIER / 3-TIER ARCHITECTURAL STYLE N-tier and 3-tier are architectural styles describe the separation of functionality into segments, but with each segment being a tier that can be located on a physically separate computer. N-tier architectures usually have at least three separate logical parts, each located on a separate physical server. Each part is responsible for specific functionality. In the case of a 3-tier or multi-tier environment, the client implements the presentation logic or user interface. The application or business logic (i.e. functional processing) is implemented on an application server and the data resides on database server. A Multi-tier architecture is thus defined by the following three component layers, see Figure 3 below: a. A front-end component, which is responsible for providing portable presentation logic or user interface. b. A middle-tier component, which allows users to share and control application or business logic by isolating it from the actual application. c. A back-end component, which provides access to dedicated services, such as a database server for data storage and assess. RESTRICTED 8 RESTRICTED FIG 3.3 – N-TIER / 3-TIER ARCHITECTURAL STYLE. N-tier application architecture is characterised by the functional decomposition of applications, service components, and their distributed deployment, providing improved scalability, availability, manageability, and resource utilisation. Each tier is completely independent from all other tiers, except for those immediately above and below it. The nth tier only has to know how to handle a request from the n+1th tier, how to forward that request on to the n-1th tier (if there is one), and how to handle the results of the request. Communication between tiers is typically asynchronous in order to support better scalability. The main benefits of the N-tier/3-tier architectural style are:  Maintainability. Because each tier is independent of the other tiers, updates or changes can be carried out without affecting the application as a whole.  Scalability. Because tiers are based on the deployment of layers, scaling out an application is reasonably straightforward. RESTRICTED 9 RESTRICTED  Flexibility. Because each tier can be managed or scaled independently, flexibility is increased.  Availability. Applications can exploit the modular architecture of enabling systems using easily scalable components, which increases availability. RESTRICTED 10 RESTRICTED MULTI-USER AND MULTI-TASKING OPERATING SYSTEMS An operating system (OS) is software that manages computer hardware and software resources and provides common services for computer programs. The operating system is an essential component of the system software in a computer system. Application programs usually require an operating system to function. Examples of popular modern operating systems include Windows from Microsoft, MAC OS from Apple Inc and Unix. The role of the operating system is to keep track of all the programs, allocating resources like disks, memory and printer queues as required. While both the client and server contains the OS software, the client computer usually contains more end-user software and the server usually contains more operating system components that will support multiple users log into the server at the same time. Thus, client OS are typically optimised for client programs for tasks such as word processing, graphic display and web browsing; while server OS are highly customised and optimised for multi-user connections, multi-task operations and hosting demanding web, mail, file, database and printing applications. Server OS usually also have a much greater focus on security. Generally, a client machine is simple and inexpensive whereas a server machine is more powerful and expensive. Multi-User Operating Systems Single-user operating systems have no means to distinguish users, but may allow multiple programs to run in tandem. A multi-user operating system, on the other hand, allows more than one user to share the same computer system at the same time. It does this by time-slicing the computer processor at regular intervals between the various users. For example, if there are five users, the multi-user operating system will share the processor hardware and main memory with the five users the on a time basis. The system starts off by giving the first user the processor hardware, and RESTRICTED 11 RESTRICTED run first user’s program for 1/5th of a second. When the time is up, the system operating system intervenes, saves the first user’s program state (program code and data) and then start running the second user program for 1/5th of a second. This process continues till it goes back the first user and the operating system restore the programs code and data and then run for 1/5th of a second. This switching between user programs is done by part of the kernel. In computing, the kernel is a computer program that manages I/O (input/output) requests from software, and translates them into data processing instructions for the central processing unit and other electronic components of a computer. The kernel is a fundamental part of the computer's operating system. To switch from one program to another requires:  A regular timed interrupt event (provided by a clock).  Saving the interrupted programs state and data.  Restoring the next programs state and data.  Running that program till the next timed interrupt occurs. The computer’s main system memory is divided into portions for the operating system and user programs. As you can see in the above diagram, the kernel space is kept separate from user programs. FIG 3.4 – MEMORY OF OPERATING SYSTEM AND USER PROGRAMS. RESTRICTED 12 RESTRICTED Multi-Tasking Operating Systems A single-tasking operating system can only run one program at a time. Multitasking operating systems permit the use of more than one program to run at once. It does this in the same way as a multi-user system, by rapidly switching the processor between the various programs. A multi-user system is also a multi-tasking system. This means that a user can run more than one program at once and using key selection to switch between the different programs. UNIX is an example of both a multi-tasking and multiuser operating system. Multi-tasking systems support foreground and background tasks. A foreground task is one that the user interacts directly with using the keyboard and screen. A background task is one that runs in the background. UNIX OPERATING SYSTEM Unix is a family of multi-tasking, multi-user computer operating systems that derive from the original AT&T Unix, developed in the 1970s by the company American Telephone & Telegraph (AT&T). From the power user's or programmer's perspective, Unix systems are characterised by a modular design that is sometimes called the “Unix philosophy”, meaning that the operating system provides a set of simple tools that each perform a limited, well-defined function, with a unified file system as the main means of communication and a shell scripting and command language to combine the tools to perform complex workflows. In computing, a shell is a user interface for access to an operating system’s services. In general, operating system shells use either a commandline interface (CLI) or graphical user interface (GUI), depending on a computer's role and particular operation. Unix was designed to be portable, multi-tasking and multi-user in a time-sharing configuration. Unix systems are characterised by various concepts: the use of plain text for storing data, a hierarchical file system, treating devices and certain types of inter-process communication (IPC) as files, and the use of a large RESTRICTED 13 RESTRICTED number of software tools, small programs that can be strung together through a command-line interpreter. These concepts are collectively known as the "Unix philosophy". The UNIX Software Components The Unix operating system consists of the following basic software components:  Kernel that schedules tasks manages data/file access and storage enforces security mechanisms performs all hardware access  Shell that presents each user with a prompt interprets commands types by a user executes user commands supports a custom environment for each user.  Utilities for File management, User management. Process management and Printing. Under Unix, the operating system consists of many utilities along with the master control program, the kernel. The kernel provides services to start and stop programs, handles the file system and other common "low-level" tasks that most programs share, and schedules access to avoid conflicts when programs try to access the same resource or device simultaneously. To mediate such access, the kernel has special rights, reflected in the division between user space and kernel space. A modern computer operating system usually makes use of virtual memory and segregates it into kernel space and user space. Virtual memory refers to the memory that the operating system use part of a computer's storage space as working memory, temporarily increasing available system resources and allowing large numbers of applications to run concurrently without experiencing a slowdown. This separation serves to protect data and functionality from faults (i.e. improving fault tolerance) and malicious behaviour (by providing computer security). Kernel space is strictly reserved for running a privileged operating RESTRICTED 14 RESTRICTED system kernel and most device drivers. In contrast, user space is the memory area where application software and some drivers execute. In UNIX systems, each user is presented with a shell. This is a program which displays the users prompt, handles user input and displays output on the terminal. The shell program provides a mechanism for customising each user's setup requirements, and storing this information for re-use (in a file called .profile). When the UNIX system starts up, it also starts a system process which monitors the state of each terminal input line. Whenever a user logs in and their password is validated the UNIX system associates the shell program with that terminal. Unix is designed to maximise performance through economical memory use. The operating system uses protected memory, a memory allocation system whereby a given block of memory can only be accessed by one application at a time, to enable full multitasking, allowing multiple users to run multiple applications without risking a system crash. In addition, Unix applications generally require a fairly small amount of physical memory to run due to the operating system's efficient use of virtual memory. Unix also enforces high security levels by requiring that all users authenticate to the system via a username and password. Furthermore, all files on the system must have an owner, who can set specific permissions as to which users can or cannot read or modify that file. This security system reduces the possibility that an unauthorised user could gain access or tamper with important files or documents on a Unix system. RESTRICTED 15 RESTRICTED Advantages and Disadvantages of Unix Operating System Some advantages of Unix are as follows:  Multi-user and Multi-tasking. More than one user can use the machine at a time supported via terminals (serial or network connection) and more than one program can be run at a time.  Hierarchical directory structure. To support the organisation and maintenance of files.  Flexibility. Unix is more flexible and can be installed on many different types of machines, including main-frame computers, supercomputers and micro-computers.  Stability. Unix is more stable and therefore requires less administration and maintenance.  Greater Security. Unix has greater built-in security and permissions features. Perhaps the primary disadvantage of Unix is the steep learning curve associated with using the software. Using the operating system to its full potential requires learning the Unix shell commands, a vast set of text-based system commands that vaguely resemble the commands used in Microsoft's DOS operating system. Learning these commands can take far longer than it is takes to use the graphical interface on an operating system such as Mac OS or Windows.

Página 2

CHAPTER 3 DESIGN CONCEPT OF CLIENT- SERVER ARCHITECTURE INTRODUCTION

The Client-Server is a computing architecture based on distributed computing structure that partitions tasks or workloads between the providers of a resource or service, called servers, and service requesters, called clients. Although the Client-Server model can be used by programs within a single computer, it is more an important concept for networked computing, where the clients and servers communicate over a computer network on separate hardware.

Distributed Computing

A distributed system consists of multiple computer systems (also known as nodes) located either in the same physical location or dispersed within some geographical area that are interconnected over a communication network such as Local or Wide Area Network (LAN/WAN). Distributed computing is the use of more than one computer in a distributed system to perform the processing of a task and a computer program that runs in a distributed system is called a distributed program. In a distributed system, each computer system will has its own local memory and database system to perform independent data processing.

Informações

Descrição
Notas sobre C2, criado por Wen Xiang Ng em 15-12-2019.
Criado por
Wen Xiang Ng · dez 2019
Atualizado
15 dez 2019
Visualizações
1
Avaliação

Fale Conosco

Sobre o que é sua mensagem?

O que você acha do novo visual?

Você gostou?