E X C E E D I N G E X P E C T A T I O N S Basic LINUX Linux System Administration Dr. Hoganson Kennesaw State University Operating Systems Directory structure:

Slides:



Advertisements
Similar presentations
By: Tony Andrews.  Linux directory ordering system  Navigating and creating directories ◦ Listing directories and files ◦ Creating directories ◦ Changing.
Advertisements

Pre-Assessment Questions
5 Basic utilities When a user logs in to the Linux operating system the directory that they will start in is their home directory. Most users will have.
Linux File & Folder permissions. File Permissions In Ubuntu, files and folders can be set up so that only specific users can view, modify, or run them.
UNIX file systems Learning Objectives: 1. To understand the basics of file systems 2. To understand the hierarchical structure in Unix file system 3. To.
Exploring the UNIX File System and File Security
Lesson 22 – Introduction to Linux Systems Administration.
Linux+ Guide to Linux Certification, Second Edition
Linux Linux File System.
Linux Files. Files and directories As in Windows directories are structures which contain –Other directories –Files.
The UNIX File System.
Guide To UNIX Using Linux Third Edition
UNIX Files and Security Software Tools. Slide 2 File Systems l What is a file system? A means of organizing information on the computer. A file system.
Basic UNIX © McGraw Hill All rights reserved.
L INUX C OMMAND L INE I NTERFACE G UNAANBAN.G
Learning basic Unix command IT 325 operating system.
Guide To UNIX Using Linux Fourth Edition
File Systems Sources and Resources: 1. A Students Guide to UNIX, by Hahn 2. Paula Davidson’s Handout on UNIXHandout on UNIX.
1 THE UNIX FILE SYSTEM By Chokechai Chuensukanant ID COSC 513 Operating System.
The file structure and related utilities CS240 Computer Science II.
Unix Primer. Unix Shell The shell is a command programming language that provides an interface to the UNIX operating system. The shell is a “regular”
Manage Directories and Files in Linux
Chapter 9 Part II Linux Command Line Access to Linux Authenticated login using a Linux account is required to access a Linux system. The Linux prompt will.
CHAPTER 1 UNIX FOR NONPROGRAMMERS By U ğ ur Halıcı.
Linux Directory Navigation. File & Directory Commands This is a minimal list of Unix commands that you must know for file management: ls (list) mkdir.
1 Lecture 2 Working with Files and Directories COP 3344 Introduction to UNIX.
Essential Unix at ACEnet Joey Bernard, Computational Research Consultant.
Unix Basics Chapter 4.
Linux+ Guide to Linux Certification, Second Edition
Working with Linux Lab 1 1. Login and logout Account – username & password – Note: Linux is case-sensitive Administrator: username = root Logout: exit,
Chapter Two Exploring the UNIX File System and File Security.
INTRODUCTION TO LINUX Jacob Chan. GNU/Linux Consists of Linux kernel, GNU utilities, and open source and commercial applications Works like Unix –Multi-user.
Lesson 9-Setting and Using Permissions. Overview Describing file permissions. Using execute permissions with a file. Changing file permissions using mnemonics.
Guide to Linux Installation and Administration1 Chapter 4 Running a Linux System.
Linux file system "On a UNIX system, everything is a file; if something is not a file, it is a process." Sorts of files (on a Linux system) Directories:
BIF713 Basic Unix/Linux Commands Getting Help with Commands.
Chapter Two Exploring the UNIX File System and File Security.
Agenda Basic Unix Commands (Chapters 2 & 3) Miscellaneous Commands: whereis, which, whoami, finger, passwd, cal, date Working with Files: cat, more, less.
Chapter 4 The File Structure. Contents u The Hierarchical File Structure u Directory and Ordinary Files u Directories u Access Permissions u Links.
Linux+ Guide to Linux Certification, Third Edition
Linux+ Guide to Linux Certification, Third Edition
1 © 2001 John Urrutia. All rights reserved. Chapter 4 The LINUX Filesystem.
Λειτουργικά Συστήματα – Lab2 Γιάννης Πετράκης. Directory Navigation and Control  The Unix file system is set up like a tree branching out from the root.
Linux Commands C151 Multi-User Operating Systems.
File Systems, telnet and ftp Sources and Resources: 1. A Students Guide to UNIX, by Hahn 2. Paula Davidson’s Handout on UNIXHandout on UNIX.
2 Manual & Filestore Mauro Jaskelioff. Introduction Using the manual The UNIX filestore File permissions.
1 Lecture 2 Working with Files and Directories COP 3353 Introduction to UNIX.
BIF713 File and Directory Management. File System A File System is a structure used to organize programs and data on a computer ’ s storage device Files.
SUSE Linux Enterprise Desktop Administration Chapter 7 Manage Directories and Files.
UNIX filesystem CS 2204 Class meeting 2 *Notes by Doug Bowman and other members of the CS faculty at Virginia Tech. Copyright
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.
1 Introduction to Unix. 2 What is UNIX?  UNIX is an Operating System (OS).  An operating system is a control program that helps the user communicate.
CSCI 330 UNIX and Network Programming Unit II Basic UNIX Usage: File System.
UNIX file systems Learning Objectives: 1. To understand the basics of file systems 2. To understand the hierarchical structure in Unix file system 3. To.
Learning basic Unix command It 325 operating system.
BIF703 File Permissions. As you recall from our previous notes, that Unix/Linux recognizes everything as a file: Regular files to store data, programs,
LINUX Zhengli Zhu, School of Life Sciences. Outline 1. ABC of Linux 2. Basic orers of Linux 3. Bash Programming.
ORAFACT The Linux File System. ORAFACT Filesystem Support Support for dozens of filesystem types including: Minix, ext2, MS-DOS, UMSDOS, VFAT, NTFS, NFS,
Agenda The Linux File System (chapter 4 in text)
Commands Basic syntax of shell commands UNIX or shell commands have a basic structure command -options target command comes first (such as cd or ls) any.
Linux 101 Training Module Linux Basics.
Linux file system "On a UNIX system, everything is a file;
Lecture 2 Working with Files and Directories
C151 Multi-User Operating Systems
9 Linux on the Desktop.
UNIX Basics Internet Technology.
Exploring the UNIX File System and File Security
Web Programming Essentials:
Chapter 4: The Linux Filesystem
January 26th, 2004 Class Meeting 2
Presentation transcript:

E X C E E D I N G E X P E C T A T I O N S Basic LINUX Linux System Administration Dr. Hoganson Kennesaw State University Operating Systems Directory structure: /etc configuration files /var changing info like log files, , temp /home home directories for user accounts /bin executables (binary) /sbin executables for use by root /usr applications /tmp temporary files /root root user’s home directory /boot Linux boot files /dev device access points /lib system libraries

E X C E E D I N G E X P E C T A T I O N S Basic LINUX Linux System Administration Dr. Hoganson Kennesaw State University Command line interface: open terminal emulator window pwd – print working directory, current location ls –lists the files in the directory – numerous options ls –a : list all files ls –l : long (detailed) listing cd – change directory cd subdirectory cd path (files and directories) cd.. up one level Mkdir dirname : make directory rmdir dirname : remove directory (must be empty)

E X C E E D I N G E X P E C T A T I O N S Basic LINUX Linux System Administration Dr. Hoganson Kennesaw State University cp file1 file2 : copy a file rm file : remove a file mv file1 file2 : move (and/or rename) a file cat file : concatentate a file, also types or displays a file by concatenating a file to a device (file) zcat : cat for compressed files less : pauses display of file, page at a time more : similar to less file : describes type of file

E X C E E D I N G E X P E C T A T I O N S Basic LINUX Linux System Administration Dr. Hoganson Kennesaw State University File Properties Several properties are associated with each file in Linux. You can view other properties of a file or a directory using the ls -1 command. The output of this command for two sample files is shown here: -rwxr-xr-x 1 nwells users Nov 18 14:36 newprogram -rw-rw-rw- 1 nwells users 0 Nov 18 15:22 test Permissions, owner, group, size, date created, name

E X C E E D I N G E X P E C T A T I O N S Basic LINUX Linux System Administration Dr. Hoganson Kennesaw State University Depending on how your Linux distribution is configured, all of the regular user accounts on a Linux system might be members of the users group. The root user can execute the chosen command to change the ownership of a file or direc- tory. Chosen username.group filename The user and group that you assign to a file must already exist on the Linux system, as described in Chapter 8. The owner and group assigned to a file determine who can access the file. The term file permissions refers to the type of access that a user has to a file or directory on the Linux system. If you have used other operating systems, you may have heard terms such as file rights or access permissions. In Linux three different file permissions can be assigned: read write and execute. A Read permission allows a user to read the contents of a file or browse the files in a directory. This permission is designated in file listings by a letter r. Write permission allows a user to add or change information in a file or create files within a director-y. This permission is designated in file listings by a letter w. Execute permission allows a user to launch a file as a program or see files within a directory.This permission is designated in file listings by a letter x.

E X C E E D I N G E X P E C T A T I O N S Basic LINUX Linux System Administration Dr. Hoganson Kennesaw State University Each of these three possible permissions can be assigned in three different ways: User permissions always apply to the owner of a file or directory. Group permissions always apply to members of the group assigned to a file or directory. Other permissions always apply to all users on the Linux system who are not the owner of the file or directory in question and are not members of the group assigned to the file or directory. The three permissions assigned in three ways create a total of nine permissions that can be assigned to any file or directory in Linux. These nine permissions are shown on the left side of the output of the ls -1 conunand. Example ls -l command: -rwxr-xr-x 1 nwells users Nov 18 14:36 newprogram The far left character of the output (a hyphen in this example) indicates the type of item you are viewing. A hyphen indicates a regular file. The letter d indicates a directory. The next nine characters represent three permissions for the file's owner (user permissions), three permissions for members of the file's assigned group, and three permissions for all other users on the system. Example: the utility fdisk or less has the root user assigned as the file's owner and has file permissions that appear like this in a file listing using ls -1: rwxr-xr-x These indicate that the file's owner (root) can read, write to (alter) and execute the file, and that everyone else on the system (both group members and other users) can read the file and execute it as a command.

E X C E E D I N G E X P E C T A T I O N S Basic LINUX Linux System Administration Dr. Hoganson Kennesaw State University A common set of permissions assigned to files that a user might create is shown here: rw-r--r– You, as the owner of the file, can read and write to it. Others on the system can read the file's contents but cannot alter the file. You can use the chmod command to change the permissions assigned to any file or directory that you own. Or, if you are logged in as root, you can use chmod to change the permissions of any file or directory on the system. To use the chmod command, include the type of permissions you want to change (user, group, or other, entered as u, g, or o), followed by a plus or = minus sign to add or remove permissions, followed by the permissions you want to add or remove (r, w, or x for read, write, or execute). For example, to add the write permission for other users to the file test, use this command: chmod o+w test You can also set specific permissions using an equal sign. For example, to set the permissions for members of the group assigned to the file test to read and write, use this command: chmod g=rw test

E X C E E D I N G E X P E C T A T I O N S Basic LINUX Linux System Administration Dr. Hoganson Kennesaw State University Decimal representation of permissions as shorthand: rwx … r = 100 = 4 w = 010 = 2 x = 001 = 1 so, 3 = w,x 5 = r,x 7 = all Can be used with the chmod command: To assign user access to read and write, Group to read, No permissions for others, chmod 640 filename