Basic Unix system administration

Slides:



Advertisements
Similar presentations
POS/420 Philip Robbins – March 19, 2013 (Week 2) University of Phoenix Mililani Campus Introduction to Unix.
Advertisements

Linux can be generally divided into four major components: 1. KERNEL – OS, ultimate boss The kernel is the core program that runs programs and manages.
A Guide to Unix Using Linux Fourth Edition
Introduction to Unix (CA263) File System
2000 Copyrights, Danielle S. Lahmani UNIX Tools G , Fall 2000 Danielle S. Lahmani Lecture 12.
File management in UNIX and windows 2000
GNU/Linux Filesystem 1 st AUT GNU/Linux Festival Computer Engineering & IT Department Bahador Bakhshi.
Linux+ Guide to Linux Certification, Second Edition
Operating Systems File Systems (Select parts of Ch 6)
Guide To UNIX Using Linux Third Edition
System Startup and Shutdown
7/15/2015B.RamamurthyPage 1 File System B. Ramamurthy.
Laksh mi.  fdisk is an interactive utility to manipulate disk partitions.  Use fdisk –l to review the disks and partitions on the system.  Use fdisk.
1. This presentation covers :  User Interface Administration  Files System and Services Management 2.
File System and Directory Structure in Linux. What is File System In a computer, a file system is the way in which files are named and where they are.
Guide To UNIX Using Linux Fourth Edition
Rensselaer Polytechnic Institute CSCI-4210 – Operating Systems David Goldschmidt, Ph.D.
Booting and boot levels
Filesystem Hierarchy Standard (FHS) –Standard of outlining the location of set files and directories on a Linux system –Gives Linux software developers.
Manage Directories and Files in Linux
Lesson 7-Creating and Changing Directories. Overview Using directories to create order. Managing files in directories. Using pathnames to manage files.
Guide to Linux Installation and Administration, 2e1 Chapter 3 Installing Linux.
Guide to Linux Installation and Administration, 2e1 Chapter 8 Basic Administration Tasks.
CT 320 Midterm Study Guide.
Disks, Filesystems 1.  sudo and PATH (environment)  disks  partitioning  formatting file systems: mkfs command  checking file system integrity: fsck.
Linux Operations and Administration
Linux+ Guide to Linux Certification, Second Edition
Chapter 6: Linux Filesystem Administration
Linux+ Guide to Linux Certification, Third Edition
Chapter Two Exploring the UNIX File System and File Security.
1 Interface Two most common types of interfaces –SCSI: Small Computer Systems Interface (servers and high-performance desktops) –IDE/ATA: Integrated Drive.
File Systems CSCI What is a file? A file is information that is stored on disks or other external media.
Linux Administration. Pre-Install Different distributions –Redhat, Caldera, mandrake, SuSE, FreeBSD Redhat Server Install –Check HCL –Significant issues.
Guide To UNIX Using Linux Third Edition Chapter 8: Exploring the UNIX/Linux Utilities.
Manage Directories and Files in Linux. 2 Objectives Understand the Filesystem Hierarchy Standard (FHS) Identify File Types in the Linux System Change.
Scis.regis.edu ● CS 468: Advanced UNIX Class 4 Dr. Jesús Borrego Regis University 1.
Chapter 3 & 6 Root Status and users File Ownership Every file has a owner and group –These give read,write, and execute priv’s to the owner, group, and.
Linux+ Guide to Linux Certification Chapter Eleven Managing Linux Processes.
Linux+ Guide to Linux Certification, Third Edition
Linux+ Guide to Linux Certification, Third Edition
Review Please hand in any homework and practicals Vim Scripting Inter-device communication.
System Administration – Part 2. Devices in UNIX are files: A device can be accessed with different file names All device files are stored in /dev or its.
Linux Commands C151 Multi-User Operating Systems.
1 File Processing : File Organization and File Systems 2015, Spring Pusan National University Ki-Joune Li.
Linux File system Implementations
The Unix File system (UFS) Presented by: Gurpreet Singh Assistant Professor Department of School of Computing and Engineering Galgotias University.
THE FILE SYSTEM Files long-term storage RAM short-term storage Programs, data, and text are all stored in files, which is stored on.
System Administration. Logging in as System Administrator System Admin login (aka superuser, aka root) –login id: root –Default PS1 prompt: # –Home directory:
File system In computing, a file system is a method of storing and organizing computer files and the data they contain to make it easy to find and access.
CSC414 “Introduction to UNIX/ Linux” Lecture 6. Schedule 1. Introduction to Unix/ Linux 2. Kernel Structure and Device Drivers. 3. System and Storage.
Lecture 02 File and File system. Topics Describe the layout of a Linux file system Display and set paths Describe the most important files, including.
Introduction to AFS IMSA Intersession 2003 Managing AFS Services Brian Sebby, IMSA ‘96 Copyright 2003 by Brian Sebby, Copies of these slides.
1 The File System. 2 Linux File System Linux supports 15 file systems –ext, ext2, xia, minix, umsdos, msdos, vfat, proc, smb, ncp, iso9660, sysv, hpfs,
Basic UNIX system administration CS 2204 Class meeting 14 *Notes by Doug Bowman and other members of the CS faculty at Virginia Tech. Copyright
Chapter 10 Periodic Processes Unix System Administration.
Linux Filesystem Administration
Filesystem Management and Backups
lctseng / Liang-Chi Tseng Edit: yench
Chapter 9 Periodic Processes
Chapter 6 File Systems CSNB113 SYSTEM ADMINISTRATION
Basic Commands ls cp ls –l (in detail format) echo ls –a
System Administration
Adding New Users, Storage, File System
Exploring the UNIX File System and File Security
Chapter 9 Periodic Processes
Periodic Processes Chapter 9.
Devices, Linux Filesystems,and the Filesystem Hirarchy standard
Linux Filesystem Management
January 26th, 2004 Class Meeting 2
Presentation transcript:

Basic Unix system administration System Programming Basic Unix system administration Basic Unix system administration Chapter Sixteen

System administration Thus far, we’ve only discussed: the use of UNIX from an end user point of view System programming - accesses the core OS but doesn’t change the way it operates System administration is another level: changing the way the system is set up and operates for end users Strongly related to security issues Basic Unix system administration Chapter Sixteen

Basic Unix system administration The superuser Most sys. admin. tasks can only be done by the superuser (also called the root user) Superuser has access to all files/ directories on the system can override permissions owner of most system files Shell command: su <username> Set current user to superuser or another user with proper password access Basic Unix system administration Chapter Sixteen

Administration through files As you would expect, system settings are stored in files Most of these are stored in /etc We’ll look at files related to: Users and groups File systems System initialization System upkeep In section 5 of the man pages Basic Unix system administration Chapter Sixteen

Basic Unix system administration /etc/passwd Information about system users bowman: x: 65: 20: D.Bowman:/home/bowman:/bin/ksh Command interpretter Home directory “real” name Group ID User ID [Encrypted password] Login name Basic Unix system administration Chapter Sixteen

Basic Unix system administration /etc/group Information about system groups faculty: x: 23: bowman, ribbens, mcquain List of group members Group ID [encrypted group password] Group name Basic Unix system administration Chapter Sixteen

Basic Unix system administration /etc/fstab Information about file systems /dev/cdrom /cdrom iso9660 defaults,ro,user,noauto 0 0 Mount options Other flags File system type Mount point File system(local device or remote dir.) Basic Unix system administration Chapter Sixteen

/etc/inittab and /etc/ init.d/ inittab: configuration file for the init process Defines “run levels” init.d: Directory containing system initialization scripts Script rc <n> is run at run level n Starts and stops various services Basic Unix system administration Chapter Sixteen

Configuring the system Often by directly editing files with a text editor In some cases there are programs that modify the files for you Many systems also have nice graphical user interfaces that let you manipulate these files indirectly Basic Unix system administration Chapter Sixteen

File System Implementation Entire disk Partition table Disk partition MBR Boot block Super block Free space mgmt I-nodes Root dir. Files and direc. A possible file system layout Basic Unix system administration Chapter Sixteen

Internal View of a File System Boot Block: The first block in a UNIX file system, contains the boot program and other initialization information or unused. Super Block Always the second block, contains the complete “catalog” of specific information about the file system, including lists of free memory Basic Unix system administration Chapter Sixteen

Internal View of a File System Inode list blocks List of inodes for the file system, contiguous and always follows the super block. The number of inodes is specified by the system administrator File access and type information, collectively known as the mode. File ownership information. Time stamps for last modification, last access and last mode modification. Link count. File size in bytes. Addresses of physical blocks. Basic Unix system administration Chapter Sixteen

Internal View of a File System Data blocks OS files, user data and program files etc. Basic Unix system administration Chapter Sixteen

Basic Unix system administration File system Commands mount mount a file system umount unmount a file system fsck check and repair a Linux file system sync flush filesystem buffers Basic Unix system administration Chapter Sixteen

Basic Unix system administration crontab Useful to have a script or command executed without human intervention a script to verify that the networks are working correctly cron daemon reads cron configuration files called “crontab” short for “cron table” parse crontabs find the soonest command to be run go to sleep until the command’s execution time has arrived Basic Unix system administration Chapter Sixteen

What’s cron and crontabs? Under UNIX, periodic execution is handled by the cron daemon read one or more configuration files containing as following command lines times at which they are to be invoked (on some systems)login names under which they are to run crontabs /etc/crontab Basic Unix system administration Chapter Sixteen

Format of Crontab files Seven or six fields minute hour day month weekday [username] command an asterisk matches all possible values, a single integer matches that exact value, a list of integers separated by commas (no spaces) used to match any one of the values two integers separated by a dash (a range) used to match any value within the range Basic Unix system administration Chapter Sixteen

Basic Unix system administration Example crontab SHELL=/ bin/ bash PATH=/ sbin:/ bin:/ usr/ sbin:/ usr/ bin MAILTO= root HOME=/ 01 * * * * root nice -n 19 run- parts /etc/ cron. hourly 02 4 * * * root nice -n 19 run- parts /etc/ cron. daily 22 4 * * 0 root nice -n 19 run- parts /etc/ cron. weekly 42 4 1 * * root nice -n 19 run- parts /etc/ cron. monthly Basic Unix system administration Chapter Sixteen