34
DT228-3 Computer Systems’ Architecture and Administration Ronan Bradley [email protected]

DT228-3 Computer Systems’ Architecture and Administration

  • Upload
    lada

  • View
    45

  • Download
    1

Embed Size (px)

DESCRIPTION

DT228-3 Computer Systems’ Architecture and Administration. Ronan Bradley [email protected]. Aims of the CSAA Course…. To introduce the student to the general principles of computer systems administration. - PowerPoint PPT Presentation

Citation preview

Page 1: DT228-3 Computer Systems’ Architecture and Administration

DT228-3Computer Systems’

Architecture and Administration

Ronan [email protected]

Page 2: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 2

Aims of the CSAA Course… To introduce the student to the general principles of

computer systems administration. To equip the student with a sufficient understanding

of the architecture of computer systems to support systems administration activities.

Page 3: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 3

…Aims of the CSAA Course To provide a complete coverage of the run-control

system used for UNIX system start-up and shutdown

To provide an introduction to user and group management techniques on Windows and UNIX systems.

To provide an introduction to systems issues relating to the integration of Windows and UNIX systems.

Page 4: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 4

Learning Outcomes On completion of the course the student will:

Describe the fundamental tasks of a UNIX or a Windows systems administrator.

Describe the user and group management mechanisms and tools on Windows and UNIX systems

Describe the system start-up and shutdown processes on a UNIX system.

Describe and modify the start-and shutdown order of services on a UNIX system.

Page 5: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 5

Learning Outcomes On completion of the course the student will:

Implement the installation, configuration and removal of software systems on a UNIX platform

Describe the configuration operation of basic file sharing mechanisms on the UNIX platform.

Describe the common mechanisms used for user and group management on UNIX and Windows platforms.

Describe the configuration operation of user and group sharing mechanisms on UNIX and Windows platforms

Design a systems integration plan to support file sharing, identity sharing and other resource sharing between UNIX and Windows systems.

Page 6: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 6

Examination Semester 1

Written Examination 60% Continuous Assessment 40%

Page 7: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 7

Reading List… Essential Reading

Marty Poniatowski, 2002, UNIX User’s Handbook, 2nd ed., Prentice Hall PTR ISBN: 0-13-065419-1

Steve Shah, Wale Soyinka. 2005, Linux Administration: A Beginner’s Guide. Osborne/McGraw-Hill ISBN: 0-07-226259-1

Page 8: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 8

CSAA Overview: System Admininstration User Management

on UNIX/Linux Systems on Windows Systems

UNIX/Linux System Start-up and Shutdown Run-Levels Changing the default start-up run-level Changing the run-level once the system has started Shutting down the System Designing custom run-levels

Managing System Resources CPU, memory, disk I/O, disk space

Security configuration Pluggable Authentication Modules (PAM)

Page 9: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 9

CSAA Overview: Networking Domain Naming System

using bind on a UNIX/Linux system FTP for file transfer between any systems DHCP for dynamic allocation of IP addresses NFS for transparent file sharing between UNIX/linux

systems SaMBa for file and printer sharing between

UNIX/Linux and Windows systems Network Information System (NIS) for sharing of user

names and passwords between systems

Page 10: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 10

File Sharing with FTP and NFS File Transfer Protocol

Basic transfer between Network File System (nfs)

Transparent file sharing between UNIX/Linux systems

Page 11: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 11

What is SaMBa? Client & Server for the Common Internet File

System (CIFS) Microsoft's name for its SMB protocol implementation

Provides a single integrated work-group spanning Windows and Linux machines Linux based resources look identical to Windows based

resources. Using Universal Naming conventions (UNC): //csaa/distrib

Page 12: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 12

What is Domain Name System? Internet system for associating human-friendly

names with machine-friendly IP addresses Resolution of a given hostname to an IP address

Supports the global domain naming hierarchy (i.e. comp.dit.ie.) Allows machines to be grouped logically, by domain

name The full name is referred to as the (FQDN) Fully Qualified

Domain Name (e.g. lugh.student.comp.dit.ie or lugh) Host names map to IP addresses in a one-to-many

relationship, each machine may have many IP addresses, and each IP address may be associated with many machines

Page 13: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 13

What is DHCP? Dynamic Host Configuration Protocol

DHCP/BOOTP Clients request and are granted IP addresses (and other information about themselves and the network)

Best to have only one machine on an Ethernet segment (VLAN) is designated a DHCP server

Page 14: DT228-3 Computer Systems’ Architecture and Administration

Some UNIX and Linux history

Ken Thompson and Dennis Ritchie

Page 15: DT228-3 Computer Systems’ Architecture and Administration

A Brief History of UNIX UNIX led to development of TCP/IP Numerous vendors sell different UNIX varieties Ken Thompson and Dennis Ritchie developed UNIX

at Bell Labs (part of AT&T) System V

UNIX source code was cheaply available from AT&T Quickly distributed to many organizations

Page 16: DT228-3 Computer Systems’ Architecture and Administration

A Brief History of UNIX (continued) Berkeley Software Distribution (BSD):

Berkeley versions of UNIX Added TCP/IP network subsystem to UNIX

AT&T sold rights to UNIX Now owned by two groups:

The SCO Group owns rights to UNIX source code The Open Group owns UNIX trademark

Page 17: DT228-3 Computer Systems’ Architecture and Administration

Varieties of UNIX All flavors of UNIX share many features:

Support multiple, simultaneously logged-on users Coordinate multiple, simultaneously running tasks Mount disk partitions on demand Apply permissions for file and directory access and

modification Uniform method of issuing data to or receiving data

from hardware devices, files, and running programs Start programs without interfering running programs

Page 18: DT228-3 Computer Systems’ Architecture and Administration

Varieties of UNIX (continued) All flavors of UNIX share the following

features (continued): Hundreds of subsystems, including dozens of

programming languages Source code portability Window interfaces (e.g., X Windows)

Page 19: DT228-3 Computer Systems’ Architecture and Administration

DT249/3 - CSAA - L01 19

Unix and Linux Linux an be considered as a full-featured Unix clone

It cannot legally be called Unix as ‘Unix’ is a registered trademark

Research and development of the kernel is undertaken by thousands of volunteers over the Internet Robust version 1 was released in 1994 Combination of Kernel, tools and Daemons make up the full

operating system Distributions of Linux from many sources

Kernel must be packaged with commands, daemons and other software to create a useable operating system

Page 20: DT228-3 Computer Systems’ Architecture and Administration

User Mode Linux

Page 21: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 21

User Mode Linux (UML) A virtualisation technology for Lunix

Vmware is a common virtualisation technology Allows many ‘instances’ of an operating system to run on a

single server Provides a sandbox environment

“User-Mode Linux is a safe, secure way of running Linux versions and Linux processes.”

“Run buggy software, experiment with new Linux kernels or distributions, and poke around in the internals of Linux, all without risking your main Linux setup.”

Page 22: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 22

User Mode Linux (UML) UML is a useful teaching tool, especially in courses

where students need a dedicated machine in order to get the most out of it

UML is being used to teach OS development, network administration, and more general system administration.

These are all cases where having a virtual machine to practice on is far more convenient for everyone than using physical boxes. http://user-mode-linux.sourceforge.net/

Page 23: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 23

Why UML? The UML kernel runs in a virtual machine that can be configured

in ways that your physical machine can't. It can have more memory, more devices, and, soon, more processors. So you can do development and testing of hardware capabilities even when you don't have the relevant hardware.

Poking around inside a running system Since you have a full OS running outside UML, it's pretty easy for

the terminally curious to find ways of looking inside this kernel that are impossible for a native kernel.

As a secure sandbox or jail Processes inside the user-mode kernel have no access to the hosting machine or to the outside world that's not explicitly provided. So, a malicious application running inside it can do no harm to anything that matters.

Page 24: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 24

Why UML? Virtual networking UML virtual machines are networkable, to each

other, to the host, and to other physical machines. So, UML can be used to set up a virtual network that allows setting up and testing of experimental services. See the networking tutorial and virtual network screenshot for more information

As a test environment Testing of some types of software requires booting up a machine. With UML, this can be very easily automated. There is a small test harness available , consisting of a small perl module implementing a UML object which provides methods to boot a virtual machine, log in to it, run commands, and shut it down.

Disaster recovery practice Do you know what you would do if your machine suddenly didn't boot one day? With UML, you can set up virtual disasters and practice recovering from them. This doesn't have to be serious business - it can also be fun. Ever wonder what happens when you run UML# rm -rf / but been afraid to try it? Now you can with impunity.

Page 25: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 25

UML at the School of Computing The School of Computing provides one

system specifically for hosting UML sessions wicklow.cs.dit.ie Upgraded in 2008

Page 26: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 26

Wicklow UML The binary executable on wicklow.cs.dit.ie which

loads the Linux kernel for the UML environment is /usr/bin/umllinux

This is a script which invokes /bin/linux.nfs

Page 27: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 27

Wicklow UML In UML, the entire file system is contained in

a single file By default the file used is root_fs in the

current directory If no command-line option is specified, the

executable linux kernel will look for a file called root_fs in the current directory

Page 28: DT228-3 Computer Systems’ Architecture and Administration

DT249/3 - CSAA - L03 28

Copy On Write

In UML, the entire file system is contained in a single file

By default the file used is root_fs in the current directory

If no command-line option is specified, the executable linux kernel will look for a file called root_fs in the /uml directory. The Copy On Write mechanism (COW) allows many users to use the same base root_fs yet still make their own changes

Page 29: DT228-3 Computer Systems’ Architecture and Administration

DT249/3 - CSAA - L03 29

UML File systems

This works by keeping a read-only copy of the root file system shared by all users and a copy-on-write file for each individual user

The copy-on-write (cow) file contains only those changes which an individual user has made to files

From the user’s point of view, their file system consists of two parts root_fs (read-only and shared) cow_fs (read/write and not shared)

To support the sharing of a single root file system among all UML users on wicklow, the master root file system is stored in /opt/uml/rootfs.debian

Page 30: DT228-3 Computer Systems’ Architecture and Administration

DT249/3 - CSAA - L03 30

Personal cow file

To allow UML users on wicklow to store their own modifications to the root_fs file, each student has their own cow file

This cow file is located in their home directory on wicklow and is called /uml/root_fs_cow_<your username>

Since this file reflects any changes you have made to the root_fs, if you delete this file all changes will be lost

Page 31: DT228-3 Computer Systems’ Architecture and Administration

DT249/3 - CSAA - L03 31

umllinux script

To start UML on wicklow, users use the umllinux script!/bin/sh/bin/linux.nfs ubd0=/uml/root_fs_cow_`whoami`,

/opt/uml/rootfs.debian eth0=mcast

This tells the executable linux kernel /bin/linux.nfs to use the root_fs (/opt/uml/rootfs.debian) and the cow file specified (/uml/root_fs_cow_<your username>)

It also tells linux to provide one ethernet card, eth0

Page 32: DT228-3 Computer Systems’ Architecture and Administration

DT249/3 - CSAA - L03 32

Backup your cow file

If the user were to create a backup copy of their cow file at the start of each wicklow session, then they would have the ability to roll-back any changes that were made during a given session

In this way users could experiment with settings and installing software in the knowledge that undoing their changes would be a simple matter

Page 33: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 33

host_fs How can you transfer files between the host

and the UML session? As a virtual network, there is no way to access

servers not on the network UML supports the use of a specialised file

system driver host_fs This allows us to mount the file system of the host

machine from within the UML instance There are a number of ways of doing this

Page 34: DT228-3 Computer Systems’ Architecture and Administration

22/04/23 34

host_fs The first mechanism for mounting the host file

system is to use the mount command as follows mount none /mnt/host –t hostfs

This will cause the root of the host’s file system to be mounted at the /mnt/host directory (which must exist)