LINUX DAY WISE SCHEDULE

Size: px
Start display at page:

Download "LINUX DAY WISE SCHEDULE"

Transcription

1 1

2 SYSTEM ADMINSITRATION LINUX DAY WISE SCHEDULE DAY 1 Introduction to Linux with Installation DAY 2 Basic Commands Part 1 DAY 3 DAY 4 DAY 5 DAY 6 DAY 7 DAY 8 DAY 9 DAY 10 DAY 11 DAY 12 DAY 13 Basic Commands Part II, Vi Editor User Administration Group Administration, Basic file permissions Partitions Part I Partitions Part II User, Group Quota & ACL RAID, Links LVM, Advance file permissions Backup, crontab, at Boot Process RPMS & YUM 2

3 NETWORK ADMINISTRATION DAY 14 DAY 15 DAY 16 DAY 17 DAY 18 DAY 19 DAY 20 DAY 21 DAY 22 DAY 23 DAY 24 DAY 25 DAY 26 Introduction to Networking NFS FTP SAMBA DNS Part I DNS Part II Web Server Part I Web Server Part II + Proxy MAIL NIS, DHCP Trouble Shooting Kickstart, Webmin, Virtualization, Iptables Selinux, Ldap, Live setup 3

4 Topics System Administration 1. Linux Installation Guide Basic Commands VI Users and Group Administration Permissions Partitions User and Group Quotas Access Control List Advanced file permissions Link RAID Logical Volume Manager Backups Boot Process Practicals Installation of packages through RPM and yum 53 4

5 Server Administration 1. Introduction to networking NFS FTP Samba DNS APACHE web Server Squid Proxy Server Mail Server NIS Server DHCP Server Troubleshooting Webmin Kickstart iptables SELinux Virtualization LDAP Comparision between Fedora and Ubuntu Comparision between Fedora and Suse Comparision between Fedora and Solaris Installation of Oracle 10g on linux 124 5

6 To Install linux follow following steps: - Linux Installation Guide To start the installation from DVD/CD set the BIOS to boot from CDROM This installation guide is to install Linux without any other o/s in the present Hard disk [ clean hard disk ] where the existing partitions will be overwritten. Installtion Can be done in to methods (1) Gui Mode (2) Text Mode Insert the first CD and restart the system Press Enter to Start Installation in GUI mode boot: press Enter Or Type linux text to start installation in text mode boot : linux text NEXT To do a media check select ok and press enter To skip it select skip and press enter NEXT Select Language English NEXT Select KeyBoard US English NEXT For Full installtion provide Installation Key Or Skip Note: If installation key is not selected then virtualization or Clustering will be not supported. 6

7 NEXT Create the Required Partition on this screen. Select Custom Layout and delete all partitions if any. Create 6 partitions. /boot = 100MB / = 2000MB /usr /var = 4000MB = 1000MB /home = 1000MB SWAP = 2 X RAM To check RAM size use Ctrl-Alt-F2 and use the free command # free To get back to the GUI interface use Ctrl-Alt-F6 NEXT Boot Loader Screen Simply select Next NEXT Select Network Devices go for Edit Select DHCP or manually provide IP Address For eg: / HostName: Station1.zoom.com Gateway DNS NEXT Select Time Zone 7

8 Asia/Calcutta NEXT Enter The Password for Root User Eg : abc123 NEXT Select the Softwares to be installed Desktop Environments GNOME Desktop Environment Application Editors Graphicle Internet Text based Internet Base Systems Select All Note : Remaining Packges can be selected even after Installation. Click Next to begin Installation NEXT After the completion of Installation Reboot After Reboot You will get Welcome Screen Select The License Agreement Check mark Yes, I agree to the License Agreement Forward Disable the Firewall. Click on Forward on confirmation click on Yes. Forward Disable the SELinux. Click on Forward on confirmation click on Yes Kdump Not Required simply uncheck Forward 8

9 Forward Set Date & time for system Asia/calcutta Forward Set Up Software updates Forward Finesh Updates Setup Forward Create Users Click on Continue to avoid creating normal users. Sound Card Forward Forward To Install additional Softwared Insert Installation CDs Forward Now the installation is comlpeted On the Login Screen provide => Username Password root abc123 Explore the Linux Operating System 9

10 Basic Commands 1. To check the present working directory ~]# pwd Example ~]# pwd /root 2. To show the contents of a directory (folder) [root@server ~]# ls Example [root@server ~]# ls anaconda-ks.cfg Desktop install.log install.log.syslog 3. To see more details including the permission regarding the contents of a directory (folder) [root@server ~]# ls -l Example [root@server ~]# ls -l total 76 -rw-r--r-- 1 root root 1049 Apr anaconda-ks.cfg drwxr-xr-x 2 root root 4096 Mar 14 20:13 Desktop -rw-r--r-- 1 root root Apr install.log -rw-r--r-- 1 root root 5175 Apr install.log.syslog [root@server ~]# ll total 76 -rw-r--r-- 1 root root 1049 Apr anaconda-ks.cfg drwxr-xr-x 2 root root 4096 Mar 14 20:13 Desktop -rw-r--r-- 1 root root Apr install.log -rw-r--r-- 1 root root 5175 Apr install.log.syslog 3. To see all contents including hidden files of a directory (folder) [root@server ~]# ls -a Example [root@server ~]# ls -a 10

11 ..camel_certs.esd_auth.gnome2_private.metacity.tcshrc...config.evolution.gstreamer-0.8.mozilla.thumbnails anaconda-ks.cfg.cshrc.fonts.cache-1.gtkrc.nautilus.trash.bash_history Desktop.gconf.gtkrc-1.2-gnome2.recentlyused.viminfo.bash_logout.dmrc.gconfd.ICEauthority.rhnapplet.conf.Xauthority.bash_profile.eggcups.gnome install.log.rnd.bashrc.elinks.gnome2 install.log.syslog.ssh 4. To see tree structure of nested directories ~]# ls -R /opt /opt: zoom /opt/zoom: zooma /opt/zoom/zooma: zoomb /opt/zoom/zooma/zoomb: zooms /opt/zoom/zooma/zoomb/zooms: To see a file starting from f [root@server ~]# ls f* To see a file have a middle string as disk [root@server ~]# ls /bin/*disk* To see a file whose length is 3 charaters [root@server ~]# ls??? To see a file which starts with single char & ends up with any number of character [root@server ~]# ls?edh* 5. To create a file [root@server ~]# cat > file1 hi how are you, how is your zoom 11

12 6. To see file content ~]# cat file1 hi how are you how is your zoom 7. To append a file [root@server ~]# cat >> file1 iam fine, it is very nice [root@server ~]# cat file1 file2 >> file3 [root@server ~]# cat file3 8. To create a file using touch command [root@server ~]# touch f1 f2 f3 f4 [root@server ~]# ls 9. Creating a single directory [root@server ~]# mkdir dir 10. Creating multiple directories [root@server ~]# mkdir dir1 dir2 dir3 dir4 [root@server ~]# ls anaconda-ks.cfg dir dir2 dir4 f2 f4 file2 install.log labmanual Desktop dir1 dir3 f1 f3 file1 file3 install.log.syslog 11. To create nested directories [root@server ~]# mkdir -p d1/d2/d3/d4 To see the tree structure [root@server ~]# ls -R d1 d1: d2 d1/d2: d3 d1/d2/d3: d4 d1/d2/d3/d4: [root@server ~]# 12

13 12. To change a directory [root@server ~]# cd dir1 [root@server dir1]# cd.. [root@server ~]# cd../.. [root@server /]# cd - /root [root@server ~]# pwd /root [root@server ~]# cd [root@server ~]# pwd /root [root@server ~]# 13. To remove files [root@server ~]# rm file1 rm: remove regular file `file1'? y 14. To remove an empty directory [root@server ~]# rmdir dir1 [root@server ~]# ls anaconda-ks.cfg Desktop dir2 dir4 f2 f4 file3 install.log.syslog d1 dir dir3 f1 f3 file2 install.log labmanual 15. To remove a directory [root@server ~]# rm -rf dir [root@server ~]# ls anaconda-ks.cfg Desktop dir3 f1 f3 file2 install.log labmanual d1 dir2 dir4 f2 f4 file3 install.log.syslog To copy files [root@server ~]# cp anaconda-ks.cfg file1 To copy folders [root@server ~]# cp -r dir2 Desktop To rename directories and files [root@server ~]# mv dir3 d4 13

14 ~]# ls anaconda-ks.cfg d4 dir2 f1 f3 file1 file3 install.log.syslog d1 Desktop dir4 f2 f4 file2 install.log labmanual To move directories and files ~]# mv dir2 /opt ~]# ls anaconda-ks.cfg d4 dir4 f2 f4 file2 install.log labmanual d1 Desktop f1 f3 file1 file3 install.log.syslog ~]# cd /opt opt]# ls dir2 zoom To search a word from single or multiple file s [root@server ~]# grep tom /etc/passwd /etc/group /etc/gshadow /etc/passwd:tom:x:500:500::/home/tom:/bin/bash /etc/group:tom:x:500: /etc/gshadow:tom:!:: [root@server ~]# cat /etc/passwd grep tom To see the type of file [root@server ~]# file * To view the date [root@server ~]# date [root@server ~]# date -s "07/15/ :06:00 " mm/dd/yyyy hh:mm:ss Tue Jul 15 00:06:00 EDT 2008 [root@server ~]# cal [root@server ~]# cal [root@server ~]# man mkdir [root@server ~]# man cal To see the content screen wise [root@server ~]# ls -l /bin less 14

15 Visual Interface Commands to Go into Insert mode To open a file use vi <filename> e.g. # vi test.txt i I a A o O r - inserts the text at current cursor position - inserts the text at beginning of line - appends the text after current cursor position - appends the text at end of line - inserts a line below current cursor position - inserts a line above current cursor position - replace a single char at current cursor position Commands at execute mode :q - quit without saving :q! - quit forcefully without saving :w - save :wq - save & quit :wq! - save & quit forcefully :x - save & quit :sh - Provides temporary shell :se nu - Setting line numbers :se nonu - Removing line numbers :84 - Press enter goes to line 84 To move the cursor, press the h,j,k,l keys as indicated. ^ k Hint: The h key is at the left and moves left. < h l > The l key is at the right and moves right. j The j key looks like a down arrow v w forward word to word b back side word to word Command's at command mode dd 2dd yy 2yy p u Ctrl+r G 5G - Deletes a line - Deletes 2 lines - Copy a line - Copies 2 lines - put (deleted or copied text) - Undo (can undo 1000 times) - Redo - Moves cursor to last line of file - Moves cursor to 5th line of file 15

16 Shift+ZZ - save & quit /<findword> - locate word To find and replace words :1,$s/<findword>/<replaceword>/gc e.g. :1,$s/world/universe/gc 1-- To start the search at from 1st line $ -> End of File s -> substitute g -> global c -> confirmation 16

17 User's & Group's Administration Scenario There are two groups : 1)salesgrp : salesgrp ID=2000 Sales users should exist in salesgrp 2)fingrp :fingrp ID=3000 Finance users should exist in fingrp tom joy Now create the users with following parameters: ali u tom c - "Mang of Sales Dept" ram d - /salesdept shyam s - /bin/ksh joy g - salesgrp/2000 Create user abdul with following parameters u c - "Director of Sales Dept" d - /salesdept s - /bin/csh g - salesgrp/2000 G - fingrp,mrkgrp Create a user ali whose user id is 2001 [root@server~]# useradd -u 2001 ali [root@server~]# grep ali /etc/passwd Create a user tom whose comment is "Mang of Sales Dept" [root@server~]# useradd -c "Mang of Sales Dept" tom [root@server~]# grep tom /etc/passwd Create a user ram whose home directory exist in /salesdept folder [root@server~]# mkdir /salesdept [root@server~]# useradd -d /salesdept/ram ram [root@server~]# grep ram /etc/passwd 17

18 Create a user shyam whose shell is ksh [root@server~]# cat /etc/shells [root@server~]# useradd -s /bin/ksh shyam [root@server~]# grep shyam /etc/passwd Create a user joy/jack whose primary group id is 2000/salesgrp [root@server~]# groupadd -g 2000 salesgrp [root@server~]# grep salesgrp /etc/group [root@server~]# useradd -g 2000 joy or [root@server~]# useradd -g salesgrp jack [root@server~]# grep 2000 /etc/passwd Create a user abdul with all parameters as in scenario [root@server~]# useradd -u g salesgrp -c "Director of Sales Dept" -d /salesdept/abdul -s /bin/csh abdul [root@server~]# grep abdul /etc/passwd abdul:x:2000:2000:director of Sales Dept:/salesdept/abdul:/bin/csh To Modify the parameter of existing user abdul [root@server ~]# usermod -u g fingrp -c "Mang of fin Dept" -d /findept/abdul -m -s /bin/ksh abdul [root@server ~]# grep abdul /etc/passwd abdul:x:3000:3000:mang of fin Dept:/findept/abdul:/bin/ksh [root@server ~]# useradd scott [root@server ~]# grep scott /etc/passwd scott:x:3001:3001::/home/scott:/bin/bash To change login name [root@server ~]# usermod -l tiger scott [root@server ~]# grep tiger /etc/passwd tiger:x:3001:3001::/home/scott:/bin/bash To lock the Account [root@server ~]# passwd tom [root@server ~]# usermod -L tom 18

19 login & check To Unlock the Account ~]# usermod -U tom login & check To delete only users account but not home directory & mail account. ~]# userdel tom ~]# ls /home To delete users account along with home directory & mail account. ~]# userdel -r tom ~]# ls /home Adding groups Adding a new group [root@server ~]# groupadd amerpetgrp [root@server ~]# grep amerpet /etc/group amerpetgrp:x:3002: adding a new group with gid 5000 [root@server ~]# groupadd -g 5000 banjaragrp [root@server ~]# grep banjaragrp /etc/group banjaragrp:x:5000: modifying group with gid [root@server ~]# groupmod -g 6000 banjaragrp [root@server ~]# grep banjaragrp /etc/group banjaragrp:x:6000: Changing the name of a existing group [root@server ~]# groupmod -n banjarahills banjaragrp [root@server ~]# grep banjarahills /etc/group banjarahills:x:6000: [root@server ~]# groupdel banjarahills 19

20 ~]# grep banjarahills /etc/group ~]# useradd jack ~]# useradd shyam ~]# useradd wiliam ~]# gpasswd -M jack,shyam,wiliam salesgrp ~]# grep salesgrp /etc/group salesgrp:x:2000:jack,shyam,wiliam Removing user wiliam from group salesgrp ~]# gpasswd -d wiliam salesgrp ~]# grep salesgrp /etc/group salesgrp:x:2000:jack,shyam Adding user wiliam to group salesgrp ~]# gpasswd -a wiliam salesgrp ~]# grep salesgrp /etc/group salesgrp:x:2000:jack,shyam,wiliam ~]# chage -l jack ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^OUTPUT^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Last password change : Jul 14, 2008 Password expires : never Password inactive : never Account expires : never Minimum number of days between password change : 0 Maximum number of days between password change : Number of days of warning before password expires : 7 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [root@server ~]# system-config-users & 20

21 ~]# mkdir /myfolder ~]# cd /myfolder/ myfolder]# ls myfolder]# whoami root Permissions myfolder]# touch test_file myfolder]# ls -ld test_file -rw-r--r-- 1 root root 0 Jul 13 00:06 test_file Set write permissions to the group only. [root@server myfolder]# chmod g+w test_file [root@server myfolder]# ls -ld test_file -rw-rw-r-- 1 root root 0 Jul 13 00:06 test_file Remove read permissions for others only. [root@server myfolder]# chmod o-r test_file [root@server myfolder]# ls -ld test_file -rw-rw root root 0 Jul 13 00:06 test_file Assign read, write, execute permissions to others only. [root@server myfolder]# chmod o=rwx test_file [root@server myfolder]# ls -ld test_file -rw-rw-rwx 1 root root 0 Jul 13 00:06 test_file Assign execute permissions to owner, group and others also. [root@server myfolder]# chmod +x test_file [root@server myfolder]# ls -ld test_file -rwxrwxrwx 1 root root 0 Jul 13 00:06 test_file Remove execute permissions from owner, group and others also. [root@server myfolder]# chmod -x test_file 21

22 myfolder]# ls -ld test_file -rw-rw-rw- 1 root root 0 Jul 13 00:06 test_file [root@server myfolder]# chmod 644 test_file [root@server myfolder]# ls -ld test_file -rw-r--r-- 1 root root 0 Jul 13 00:06 test_file [root@server myfolder]# pwd /myfolder [root@server myfolder]# whoami root [root@server myfolder]# mkdir dir1 [root@server myfolder]# ls -ld dir1 drwxr-xr-x 2 root root 4096 Jul 13 01:28 dir1 [root@server myfolder]# [root@server myfolder]# chmod 777 /myfolder [root@server ~]# su - tom [tom@server ~]$ whoami tom [tom@server ~]$ [tom@server ~]$ pwd /home/tom [tom@server ~]$ ls -l total 0 [tom@server ~]$ touch myfile [tom@server ~]$ ls -l total 0 -rw-rw-r-- 1 tom tom 0 Jul 12 20:20 myfile [tom@server ~]$ mkdir dir1 [tom@server ~]$ ls -ld dir1 drwxrwxr-x 2 tom tom 4096 Jul 12 20:22 dir1 [tom@server ~]$ 22

23 Step 1 ) To Create the partitions [root@client1 ~]# fdisk -l [root@client1 ~]# fdisk /dev/hda Partitions Command (m for help): m d delete a partition m print this menu n add a new partition p print the partition table q quit without saving changes w write table to disk and exit Command (m for help): Command (m for help): n First cylinder ( , default 1098): Using default value 1098 Last cylinder or +size or +sizem or +sizek ( , default 2434): +100M Command (m for help): p Command (m for help): n Command (m for help): p Command (m for help): n Command (m for help): p Command (m for help): d Command (m for help): 10 #write the number of partition Command (m for help): w [root@client1 ~]# To update the kernel without restarting [root@client1 ~]# partprobe /dev/hda [root@client1 ~]# fdisk -l Step 2 ) Make the filesystem ( i.e format the partition) ext2, ext3, vfat [root@client1 ~]# mkfs.ext2 /dev/hda8 [root@client1 ~]# mkfs.ext3 /dev/hda9 [root@client1 ~]# mkfs.vfat /dev/hda10 23

24 Step 3 ) Create a folder & Mount the partition to use [root@client1 ~]# mkdir /mnt/song /mnt/video /mnt/music [root@client1 ~]# mount /dev/hda8 /mnt/song [root@client1 ~]# mount /dev/hda9 /mnt/video [root@client1 ~]# mount /dev/hda10 /mnt/music [root@client1 ~]# mount Step 4 ) Write the data inside the partition [root@client1 ~]# cd /mnt/song [root@client1 song]# [root@client1 song]# touch myfile1 myfile2 myfile3 [root@client1 song]# mkdir hyd sec bhills ameerpet [root@client1 song]# ls ***************** This is the output ******************** ameerpet bhills hyd lost+found myfile1 myfile2 myfile3 sec [root@client1 myfolder]# Converting from ext3 to ext2 [root@client1 ~]# umount /dev/hda8 [root@client1 ~]# tune2fs -O ^has_journal /dev/hda8 [root@client1 ~]# mount /dev/hda8 /myfolder/ [root@client1 ~]# mount Convert from ext2 to ext3 [root@client1 ~]# umount /dev/hda8 [root@client1 ~]# tune2fs -j /dev/hda8 [root@client1 ~]# mount /dev/hda8 /myfolder [root@client1 ~]# mount 24

25 Creating a Swap Partition Step 1 ) Create the required partition (say 9 partition) [root@client1 ~]# fdisk -l [root@client1 ~]# fdisk /dev/hda :p :n :t { to change the partition ID} :82 { for swap partition } :w { save & exit } [root@client1 ~]# [root@client1 ~]# partprobe /dev/hda [root@client1 ~]# fdisk l Step 2 ) Make the partition as swap [root@client1 ~]# mkswap /dev/hda9 To see the status [root@client1 ~]# swapon s To on the swap partition [root@client1 ~]# swapon /dev/hda9 Again see the status [root@client1 ~]# swapon -s To put Off the swap partition [root@client1 ~]# swapoff /dev/hda9 [root@client1 ~]# swapon s 25

26 LABELS To check the label ~]# e2label /dev/hda8 To assign the labels ~]# e2label /dev/hda8 linux ~]# e2label /dev/hda8 linux Permanent Mounting Mounting the partition /dev/hda9 parmanently ~]# vi /etc/fstab LABEL=linux /myfolder ext3 defaults 0 0 :wq [root@client1 ~]# mount [root@client1 ~]# mount -a [root@client1 ~]# mount Mounting the cdrom [root@client1 ~]# mkdir /media/cdrom [root@client1 ~]# mount /dev/cdrom /media/cdrom To see the disk space [root@client1 ~]# df -h To see the block size. [root@client1 ~]# blockdev --getbsz /dev/hda [root@client1 ~]# blockdev --getbsz /dev/hda

27 Apply Quota on users & Group Create required users & Group ~]# useradd tom ~]# groupadd salesgrp ~]# groupadd fingrp ~]# mkdir /salesdept User and Group Quotas ~]# useradd -g salesgrp sai ~]# useradd -g salesgrp ram ~]# useradd -G fingrp tata ~]# useradd -G fingrp birla Step 1 ) Create a required partition [root@server ~]# fdisk -l [root@server ~]# fdisk /dev/hda :n :w [root@server ~]# partprobe /dev/hda [root@server ~]# mkdir /salesdept [root@server ~]# mkfs.ext3 /dev/hda9 Step 2) Mount the partition with user & group quota parameters. [root@server ~]# mount -o usrquota,grpquota /dev/hda9 /salesdept [root@server ~]# mount [root@server ~]# chmod 777 /salesdept/ Step 3 ) Create the Quota Database file [root@server ~]# quotacheck -cugv /salesdept/ [root@server ~]# ls /salesdept/ aquota.group aquota.user lost+found 27

28 Step 4) Check the quota Status ~]# quotaon -p /dev/hda9 group quota on /salesdept (/dev/hda9) is off user quota on /salesdept (/dev/hda9) is off Step 5 ) Enable the quota partition [root@server ~]# quotaon /dev/hda9 [root@server ~]# quotaon -p /dev/hda9 group quota on /salesdept (/dev/hda9) is on user quota on /salesdept (/dev/hda9) is on Step 6 ) Apply quota on a user tom [root@server ~]# edquota -u tom Disk quotas for user tom (uid 500): Filesystem blocks soft hard inodes soft hard /dev/hda :wq [root@server ~]# su - tom [tom@server ~]$ cd /salesdept/ [tom@server salesdept]$ ll [tom@server salesdept]$ touch tfa [tom@server salesdept]$ touch tfb [tom@server salesdept]$ touch tfc [tom@server salesdept]$ touch tfd hda9: warning, user file quota exceeded. [tom@server salesdept]$ mkdir tda [tom@server salesdept]$ mkdir tdb hda9: write failed, user file limit reached. mkdir: cannot create directory `tdb': Disk quota exceeded 28

29 Step 7 ) Apply quota on a group salesgrp who has primary members as sai & ram [root@server ~]# edquota -g salesgrp [root@server ~]# edquota -g salesgrp Disk quotas for group salesgrp (gid 501): Filesystem blocks soft hard inodes soft hard /dev/hda :wq! [root@server ~]# cd /salesdept/ [root@server salesdept]# su sai [sai@server salesdept]$ groups salesgrp [sai@server salesdept]$ touch sai1 sai2 sai3 [sai@server salesdept]$ exit exit [root@server salesdept]# su ram [ram@server salesdept]$ groups salesgrp [ram@server salesdept]$ touch ram1 hda9: warning, group file quota exceeded. [ram@server salesdept]$ touch ram3 [ram@server salesdept]$ touch ram4 hda9: write failed, group file limit reached. touch: cannot touch `ram4': Disk quota exceeded [ram@server salesdept]$ ll total 36 -rw root root -rw root root drwx root root -rw-r--r-- 1 ram salesgrp -rw-r--r-- 1 ram salesgrp -rw-r--r-- 1 sai salesgrp -rw-r--r-- 1 sai salesgrp -rw-r--r-- 1 sai salesgrp 7168 Jul 15 01:52 aquota.group 7168 Jul 15 01:53 aquota.user Jul 15 01:38 lost+found 0 Jul 15 01:53 ram1 0 Jul 15 01:53 ram3 0 Jul 15 01:53 sai1 0 Jul 15 01:53 sai2 0 Jul 15 01:53 sai3 [ram@server salesdept]$ Note : Quotas are not applicable on secondary group members 29

30 Access Control List Create required users & Group ~]# useradd tom ~]# groupadd salesgrp ~]# groupadd fingrp ~]# mkdir /salesdept ~]# useradd -g salesgrp sai ~]# useradd -g salesgrp ram ~]# useradd -G fingrp tata ~]# useradd -G fingrp birla Note: Acl's are applied on both primary & secondary members Step 1 ) Create a required partition [root@server ~]# fdisk -l [root@server ~]# fdisk /dev/hda :n :w [root@server ~]# partprobe /dev/hda [root@server ~]# mkdir /salesdept [root@server ~]# mkfs.ext3 /dev/hda9 Step 2) Mount the partition with ACLs parameters. [root@server ~]# mount -o acl /dev/hda9 /salesdept [root@server ~]# mount [root@server ~]# chmod 777 /salesdept/ Step 3) Apply ACLS on users & groups [root@server salesdept]# touch fabc.txt To apply acl's on users & groups [root@server salesdept]# setfacl -m u:tom:rwx,u:ram:rx,g:salesgrp:rx,g:fingrp:rw fabc.txt 30

31 To check acl list salesdept]# getfacl fabc.txt To modify permission for user tom salesdept]# setfacl -m u:tom:r fabc.txt salesdept]# getfacl fabc.txt To exclude user tom,group fingrp from ACL list salesdept]# setfacl -x u:tom,g:fingrp fabc.txt salesdept]# getfacl fabc.txt 31

32 Advanced file permissions To view the location of a command use which [root@client24 myfolder]# which cat /bin/cat [root@client24 myfolder]# ls -ld /bin/cat -rwxr-xr-x 1 root root Nov /bin/cat [root@client24 myfolder]# su - tom [tom@client24 ~]$ cat > myfile hello Open another terminal as root user root@client24 ~]# ps -aux USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND tom pts/1 S+ 22:01 0:00 cat [root@client24 myfolder]# ls -ld /bin/cat -rwxr-xr-x 1 root root Nov /bin/cat Set SUID on the file [root@client24 myfolder]# chmod 4755 /bin/cat [root@client24 myfolder]# ls -ld /bin/cat -rwsr-xr-x 1 root root Nov /bin/cat [root@client24 myfolder]# su - tom [tom@client24 ~]$ cat >> myfile Open another terminal as root user root@client24 ~]# ps -aux USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND root pts/1 S+ 22:05 0:00 cat [root@client24 ~]# mkdir /myfolder 32

33 ~]# cd /myfolder myfolder]# ls myfolder]# cat > test Learning Linux is a wise man's decesion. [root@client24 myfolder]# ls -ld test -rw-r--r-- 1 root root 41 Jul 13 21:22 test [root@client24 myfolder]# ls -ld /myfolder drwxrwxrwx 2 root root 4096 Jul 13 21:21 /myfolder Set SGID on the folder [root@client24 myfolder]# chmod 2777 /myfolder [root@client24 myfolder]# ls -ld /myfolder drwxrwsrwx 2 root root 4096 Jul 13 21:21 /myfolder [root@client24 myfolder]# ls test [root@client24 myfolder]# su - tom [tom@client24 ~]$ cd /myfolder [tom@client24 myfolder]$ ls -l total 4 -rw-r--r-- 1 root root 41 Jul 13 21:22 test [tom@client24 myfolder]$ cat > myfile file to test SGID [tom@client24 myfolder]$ ls -ld myfile -rw-r--r-- 1 tom root 18 Jul 13 22:14 myfile [root@client24 myfolder]# su - joy [joy@client24 ~]$ cd /myfolder [joy@client24 myfolder]$ ls -l total 8 -rw-r--r-- 1 tom root 18 Jul 13 22:14 myfile -rw-r--r-- 1 root root 41 Jul 13 21:22 test [joy@client24 myfolder]$ cat > joy_file 33

34 hello this file is created by joy but because of SGID bit set its group ownership will be root myfolder]$ ls -ld joy_file -rw-rw-r-- 1 joy root 95 Jul 13 22:15 joy_file joy and tom have the same primary group called joy [root@client24 ~]# mkdir /sticky [root@client24 ~]# chmod 777 /sticky [root@client24 ~]# su - tom [tom@client24 ~]$ cd /sticky [tom@client24 sticky]$ ls -l total 0 [tom@client24 sticky]$ cat > tom_file hello am tom, am going to set sticky bit on the /sticky folder. [tom@client24 sticky]$ ls -l total 4 -rw-r--r-- 1 tom joy 64 Jul 13 22:36 tom_file [tom@client24 sticky]$ chmod 664 tom_file [tom@client24 sticky]$ ls -ld tom_file -rw-rw-r-- 1 tom joy 64 Jul 13 22:36 tom_file [root@client24 sticky]# su - joy [joy@client24 ~]$ cd /sticky [joy@client24 sticky]$ ls -l total 4 -rw-rw-r-- 1 tom joy 64 Jul 13 22:37 tom_file [joy@client24 sticky]$ rm tom_file [joy@client24 sticky]$ ls To avoid joy to del the file owned by the user tom apply sticky bit on the folder. [root@client24 sticky]# ls -ld /sticky 34

35 drwxrwxrwx 2 root root 4096 Jul 13 22:38 /sticky Set Sticky Bit [root@client24 sticky]# chmod 1777 /sticky [root@client24 sticky]# ls -ld drwxrwxrwt 2 root root 4096 Jul 13 22:38. [root@client24 sticky]# su - tom [tom@client24 ~]$ cd /sticky/ [tom@client24 sticky]$ ls [tom@client24 sticky]$ cat > tom_file This file is created by tom whose primary group is joy, but joy cannot delete this file. [tom@client24 sticky]$ ls -ld /sticky/tom_file -rw-r--r-- 1 tom joy 89 Jul 13 22:41 /sticky/tom_file [root@client24 sticky]# su - joy [joy@client24 ~]$ cd /sticky/ [joy@client24 sticky]$ ls -l total 4 -rw-r--r-- 1 tom joy 89 Jul 13 22:41 tom_file [joy@client24 sticky]$ rm tom_file rm: remove write-protected regular file `tom_file'? y rm: cannot remove `tom_file': Operation not permitted [joy@client24 sticky]$ ls -l total 4 -rw-r--r-- 1 tom joy 89 Jul 13 22:41 tom_file 35

36 Links ~]# mount /dev/hda3 on / type ext3 (rw) proc on /proc type proc (rw) sysfs on /sys type sysfs (rw) devpts on /dev/pts type devpts (rw,gid=5,mode=620) /dev/hda1 on /boot type ext3 (rw) tmpfs on /dev/shm type tmpfs (rw) /dev/hda5 on /home type ext3 (rw) /dev/hda2 on /usr type ext3 (rw) /dev/hda6 on /var type ext3 (rw) /dev/hda8 on /myfolder type ext3 (rw) none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw) sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw) [root@client1 ~]# [root@client1 ~]# cd /myfolder [root@client1 myfolder]# ls [root@client1 myfolder]# cat > original_file This is the original file to test links [root@client1 myfolder]# ls -ld original_file -rw-r--r-- 1 root root 40 Jul 12 21:12 original_file [root@client1 myfolder]# cd Setting a soft link [root@client1 ~]# ln -s /myfolder/original_file softlink [root@client1 ~]# ls -ld softlink lrwxrwxrwx 1 root root 23 Jul 12 21:12 softlink -> /myfolder/original_file [root@client1 ~]# cat softlink This is the original file to test links [root@client1 ~]# cat >> softlink this line is appended by the softlink [root@client1 ~]# cat /myfolder/original_file This is the original file to test links this line is appended by the softlink 36

37 ~]# ls -ld /myfolder/original_file -rw-r--r-- 1 root root 78 Jul 12 21:13 /myfolder/original_file [root@client1 ~]# ls -ld softlink lrwxrwxrwx 1 root root 23 Jul 12 21:12 softlink -> /myfolder/original_file [root@client1 ~]# rm /myfolder/original_file rm: remove regular file `/myfolder/original_file'? y [root@client1 ~]# cat softlink cat: softlink: No such file or directory Setting a Hard Link [root@client1 ~]# ln /myfolder/original_file hardlink ln: creating hard link `hardlink' to `/myfolder/original_file': Invalid cross-device link [root@client1 ~]# cd / [root@client1 /]# cat > original This is the original file to test links. [root@client1 /]# cd [root@client1 ~]# ln /original /root/hardlink [root@client1 ~]# ls -ld /root/hardlink -rw-r--r-- 2 root root 41 Jul 12 21:16 /root/hardlink [root@client1 ~]# ls -ld /original -rw-r--r-- 2 root root 41 Jul 12 21:16 /original [root@client1 ~]# cd / [root@client1 /]# cat > original This is the original file to test links. [root@client1 /]# cd [root@client1 ~]# ln /original /root/hardlink [root@client1 ~]# ls -ld /root/hardlink -rw-r--r-- 2 root root 41 Jul 12 21:16 /root/hardlink 37

38 ~]# ls -ld /original -rw-r--r-- 2 root root 41 Jul 12 21:16 /original [root@client1 ~]# cat >> hardlink this is appended by the hardlink file [root@client1 ~]# ls -ld /root/hardlink -rw-r--r-- 2 root root 79 Jul 12 21:18 /root/hardlink [root@client1 ~]# ls -ld /original -rw-r--r-- 2 root root 79 Jul 12 21:18 /original [root@client1 ~]# rm /original rm: remove regular file `/original'? y [root@client1 ~]# cat hardlink This is the original file to test links. this is appended by the hardlink file 38

39 Example to Configure RAID 5 Install the required packages [root@client1 ~]# yum install mdadm* -y Create the required partition [root@client1 ~]# mdadm -C /dev/md0 -n3 /dev/hda11 /dev/hda12 /dev/hda13 -l5 mdadm: array /dev/md0 started. To see the detail information of /dev/md0 [root@client1 ~]# mdadm -D /dev/md0 Format the raid meta device [root@client1 ~]# mkfs.ext3 /dev/md0 Mount the partition [root@client1 ~]# mount /dev/md0 /raid_dir [root@client1 ~]# mount [root@client1 ~]# cd /raid_dir/ [root@client1 raid_dir]# ls lost+found Write some content inside the raid partition [root@client1 raid_dir]# cat > test hello this is a test file on raid 5 [root@client1 raid_dir]# ls -l To add a new device as spare [root@client1 ~]# mdadm -a /dev/md0 /dev/hda14 [root@client1 ~]# mdadm -D /dev/md0 [root@client1 ~]# mdadm /dev/md0 -f /dev/hda12 mdadm: set /dev/hda12 faulty in /dev/md0 To see the detail information of /dev/md0 [root@client1 ~]# mdadm -D /dev/md0 39

40 To remove the faulty device raid_dir]# mdadm /dev/md0 -r /dev/hda12 mdadm: hot removed /dev/hda12 raid_dir]# mdadm -D /dev/md0 raid_dir]# cd To stop the raid first unmount the meta device. ~]# umount /dev/md0 ~]# mdadm -S /dev/md0 mdadm: stopped /dev/md0 To activate or assemble the raid meta device ~]# mdadm -A /dev/md0 /dev/hda11 /dev/hda14 /dev/hda13 mdadm: /dev/md0 has been started with 3 drives. 40

41 Logical Volume Manager To view the Hard disk name and partition information ~]# fdisk -l Disk /dev/hda: 40.0 GB, bytes 255 heads, 63 sectors/track, 4865 cylinders Units = cylinders of * 512 = bytes Device Boot Start End Blocks Id System /dev/hda1 * Linux /dev/hda Linux /dev/hda Linux /dev/hda Extended /dev/hda Linux /dev/hda Linux /dev/hda Linux swap / Solaris /dev/hda Linux Create 3 partitions [root@client24 ~]# fdisk /dev/hda The number of cylinders for this disk is set to There is nothing wrong with that, but this is larger than 1024, and could in certain setups cause problems with: 1) software that runs at boot time (e.g., old versions of LILO) 2) booting and partitioning software from other OSs (e.g., DOS FDISK, OS/2 FDISK) Command (m for help): n First cylinder ( , default 2315): Using default value 2315 Last cylinder or +size or +sizem or +sizek ( , default 4865): +200M Command (m for help): n First cylinder ( , default 2340): Using default value 2340 Last cylinder or +size or +sizem or +sizek ( , default 4865): +200M Command (m for help): n First cylinder ( , default 2365): Using default value 2365 Last cylinder or +size or +sizem or +sizek ( , default 4865): +200M 41

42 Command (m for help): w The partition table has been altered! Calling ioctl() to re-read partition table. WARNING: Re-reading the partition table failed with error 16: Device or resource busy. The kernel still uses the old table. The new table will be used at the next reboot. Syncing disks. [root@client24 ~]# partprobe /dev/hda [root@client24 ~]# fdisk -l Disk /dev/hda: 40.0 GB, bytes 255 heads, 63 sectors/track, 4865 cylinders Units = cylinders of * 512 = bytes Device Boot Start End Blocks Id System /dev/hda1 * Linux /dev/hda Linux /dev/hda Linux /dev/hda Extended /dev/hda Linux /dev/hda Linux /dev/hda Linux swap / Solaris /dev/hda Linux /dev/hda Linux /dev/hda Linux /dev/hda Linux Create Physical Volumes [root@client24 ~]# pvcreate /dev/hda9 /dev/hda10 /dev/hda11 Physical volume "/dev/hda9" successfully created Physical volume "/dev/hda10" successfully created Physical volume "/dev/hda11" successfully created To view Physical Volumes [root@client24 ~]# pvdisplay --- Physical volume --- PV Name /dev/hda9 VG Name vg1 PV Size MB / not usable 4.08 MB Allocatable yes (but full) PE Size (KByte) 4096 Total PE 48 Free PE 0 Allocated PE 48 PV UUID 5r8qvn-GF0k-NAfo-Rhqc-I3Qn-ZWws-zLCvks --- Physical volume --- PV Name /dev/hda10 42

43 VG Name PV Size Allocatable PE Size (KByte) 4096 Total PE 48 Free PE 21 vg MB / not usable 4.08 MB yes Allocated PE 27 PV UUID ys5wd9-yiq5-mm7c-sjrt-mcwb-35of-8mfydw --- Physical volume --- PV Name /dev/hda11 VG Name vg1 PV Size MB / not usable 4.08 MB Allocatable yes PE Size (KByte) 4096 Total PE 48 Free PE 48 Allocated PE 0 PV UUID 5U81jh-Uddd-0giT-GYUT-pkvu-3MK3-KNkZJi To create Volume Group [root@client24 ~]# vgcreate vg1 /dev/hda9 /dev/hda10 /dev/hda11 Volume group "vg1" successfully created To display Volume Group Information. [root@client24 ~]# vgdisplay --- Volume group --- VG Name vg1 System ID Format lvm2 Metadata Areas 3 Metadata Sequence No 2 VG Access read/write VG Status resizable MAX LV 0 Cur LV 1 Open LV 0 Max PV 0 Cur PV 3 Act PV 3 VG Size MB PE Size 4.00 MB Total PE 144 Alloc PE / Size 75 / MB Free PE / Size 69 / MB VG UUID P1zXt6-yBWW-SoUq-ZeF1-K7pf-Z69D-GVz8Up To create logical Volume [root@client24 ~]# lvcreate vg1 -L +300M -n lv1 Logical volume "lv1" created 43

44 To view Logical Volume Information. ~]# lvdisplay --- Logical volume --- LV Name /dev/vg1/lv1 VG Name vg1 LV UUID ZvsfPh-Ve0c-y4Qa-VUYy-HbdR-lG3G-66703a LV Write Access read/write LV Status available # open 0 LV Size MB Current LE 75 Segments 2 Allocation inherit Read ahead sectors 0 Block device 253:0 [root@client24 ~]# Format the Logical Volume [root@client24 ~]# mkfs.ext3 /dev/vg1/lv1 mke2fs 1.39 (29-May-2006) Filesystem label= OS type: Linux Block size=1024 (log=0) Fragment size=1024 (log=0) inodes, blocks blocks (5.00%) reserved for the super user First data block=1 Maximum filesystem blocks= block groups 8192 blocks per group, 8192 fragments per group 2048 inodes per group Superblock backups stored on blocks: 8193, 24577, 40961, 57345, 73729, , , Writing inode tables: done Creating journal (8192 blocks): done Writing superblocks and filesystem accounting information: done This filesystem will be automatically checked every 20 mounts or 180 days, whichever comes first. Use tune2fs -c or -i to override. [root@client24 ~]# mkdir /mylvm [root@client24 ~]# mount /dev/vg1/lv1 /mylvm [root@client24 ~]# mount /dev/hda3 on / type ext3 (rw) proc on /proc type proc (rw) sysfs on /sys type sysfs (rw) devpts on /dev/pts type devpts (rw,gid=5,mode=620) /dev/hda1 on /boot type ext3 (rw) tmpfs on /dev/shm type tmpfs (rw) /dev/hda5 on /home type ext3 (rw) 44

45 /dev/hda2 on /usr type ext3 (rw) /dev/hda6 on /var type ext3 (rw) /dev/hda8 on /dada type ext3 (rw) none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw) sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw) /dev/mapper/vg1-lv1 on /mylvm type ext3 (rw) To resize the Logical Volume ~]# lvresize -L +100M /dev/vg1/lv1 Extending logical volume lv1 to MB Logical volume lv1 successfully resized ~]# lvdisplay --- Logical volume --- LV Name /dev/vg1/lv1 VG Name vg1 LV UUID ZvsfPh-Ve0c-y4Qa-VUYy-HbdR-lG3G-66703a LV Write Access read/write LV Status available # open 0 LV Size MB Current LE 100 Segments 3 Allocation inherit Read ahead sectors 0 Block device 253:0 [root@client24 ~]# cd /mylvm [root@client24 mylvm]# ls lost+found [root@client24 mylvm]# touch file1 file2 file3 [root@client24 mylvm]# mkdir hyd sec [root@client24 mylvm]# ls file1 file2 file3 hyd lost+found sec To remove logical Volume [root@client24 ~]# cd [root@client24 ~]# umount /mylvm [root@client24 ~]# lvremove /dev/vg1/lv1 Do you really want to remove active logical volume "lv1"? [y/n]: y Logical volume "lv1" successfully removed 45

46 ~]# fdisk /dev/hda The number of cylinders for this disk is set to There is nothing wrong with that, but this is larger than 1024, and could in certain setups cause problems with: 1) software that runs at boot time (e.g., old versions of LILO) 2) booting and partitioning software from other OSs (e.g., DOS FDISK, OS/2 FDISK) Command (m for help): n First cylinder ( , default 2390): +300M Value out of range. First cylinder ( , default 2390): w First cylinder ( , default 2390): Using default value 2390 Last cylinder or +size or +sizem or +sizek ( , default 4865): +300M Command (m for help): w The partition table has been altered! Calling ioctl() to re-read partition table. WARNING: Re-reading the partition table failed with error 16: Device or resource busy. The kernel still uses the old table. The new table will be used at the next reboot. Syncing disks. [root@client24 ~]# partprobe /dev/hda [root@client24 ~]# fdisk -l Disk /dev/hda: 40.0 GB, bytes 255 heads, 63 sectors/track, 4865 cylinders Units = cylinders of * 512 = bytes Device Boot Start End Blocks Id System /dev/hda1 * Linux /dev/hda Linux /dev/hda Linux /dev/hda Extended /dev/hda Linux /dev/hda Linux /dev/hda Linux swap / Solaris /dev/hda Linux /dev/hda Linux /dev/hda Linux /dev/hda Linux /dev/hda Linux 46

47 ~]# pvcreate /dev/hda12 Physical volume "/dev/hda12" successfully created To extend the volume group. ~]# vgextend vg1 /dev/hda12 Volume group "vg1" successfully extended ~]# vgdisplay --- Volume group --- VG Name vg1 System ID Format lvm2 Metadata Areas 4 Metadata Sequence No 5 VG Access read/write VG Status resizable MAX LV 0 Cur LV 0 Open LV 0 Max PV 0 Cur PV 4 Act PV 4 VG Size MB PE Size 4.00 MB Total PE 216 Alloc PE / Size 0 / 0 Free PE / Size 216 / MB VG UUID P1zXt6-yBWW-SoUq-ZeF1-K7pf-Z69D-GVz8Up 47

48 Backups Create a folder [root@client24 myfolder]# mkdir /myfolder [root@client24 ~]# cd /myfolder/ [root@client24 myfolder]# mkdir dir1 [root@client24 myfolder]#touch 1 test_file tom_file [root@client24 myfolder]# ls 1 dir1 test_file tom_file Use the tar command to tape archive the folder. [root@client24 ~]# tar -cvf myfolder.tar /myfolder tar: Removing leading `/' from member names /myfolder/ /myfolder/dir1/ /myfolder/tom_file /myfolder/test_file /myfolder/1 [root@client24 ~]# ls -ld myfolder.tar -rw-r--r-- 1 root root Jul 13 03:07 myfolder.tar To zip the tar file. [root@client24 ~]# gzip myfolder.tar [root@client24 ~]# ls -ld myfolder.tar.gz -rw-r--r-- 1 root root 264 Jul 13 03:07 myfolder.tar.gz To unzip the tar file [root@client24 ~]# gunzip myfolder.tar.gz [root@client24 ~]# ls -ld myfolder.tar -rw-r--r-- 1 root root Jul 13 03:07 myfolder.tar [root@client24 ~]# rm myfolder.tar rm: remove regular file `myfolder.tar'? y 48

49 To create a tar file with zip [root@client24 ~]# tar -cvzf myfolder.tar.gz /myfolder tar: Removing leading `/' from member names /myfolder/ /myfolder/dir1/ /myfolder/tom_file /myfolder/test_file /myfolder/1 [root@client24 ~]# ls -ld myfolder.tar.gz -rw-r--r-- 1 root root 251 Jul 13 03:09 myfolder.tar.gz To view the contents of the tar file without extracting. [root@client24 ~]# tar -tvzf myfolder.tar.gz drwxrwxrwx root/root drwxr-xr-x root/root -rw-r--r-- tom/joy -rw-rw-rw- root/root -rw-r--r-- tom/joy :31:34 myfolder/ :28:39 myfolder/dir1/ :29:51 myfolder/tom_file :06:35 myfolder/test_file :31:34 myfolder/1 [root@client24 ~]# rm -r /myfolder rm: descend into directory `/myfolder'? y rm: remove directory `/myfolder/dir1'? y rm: remove regular file `/myfolder/tom_file'? y rm: remove regular empty file `/myfolder/test_file'? y rm: remove regular empty file `/myfolder/1'? y rm: remove directory `/myfolder'? y [root@client24 ~]# cd / To extract the tar file. [root@client24 /]# tar -xvzf /root/myfolder.tar.gz myfolder/ myfolder/dir1/ myfolder/tom_file myfolder/test_file myfolder/1 [root@client24 /]# ls -ld myfolder drwxrwxrwx 3 root root 4096 Jul 13 01:31 myfolder [root@client24 /]# ls /myfolder/ 1 dir1 test_file tom_file [root@client24 ~]# cd /myfolder/ 49

50 To copy files to archive. myfolder]# ls cpio -ov > myfolder.cpio 1 dir1 myfolder.cpio test_file tom_file 1 block [root@client24 myfolder]# ls 1 dir1 myfolder.cpio test_file tom_file [root@client24 myfolder]# ls 1 dir1 myfolder.cpio test_file tom_file [root@client24 myfolder]# rm -r * rm: remove regular empty file `1'? y rm: remove directory `dir1'? y rm: remove regular file `myfolder.cpio'? n rm: remove regular empty file `test_file'? y rm: remove regular file `tom_file'? y To copy files from archive. [root@client24 myfolder]# cpio -iv < myfolder.cpio 1 dir1 cpio: myfolder.cpio not created: newer or same age version exists myfolder.cpio test_file tom_file 1 block [root@client24 myfolder]# ls 1 dir1 myfolder.cpio test_file tom_file [root@client24 ~]# cat > test test file for scp 50

51 Copy the test file to a remote systems /root directory [root@client24 ~]# scp -r test :/root/ root@ 's password: test 100% KB/s 00:00 [root@client24 ~]# rm test rm: remove regular file `test'? y Copy the file on a remote systems to the /root/test directory [root@client24 ~]# scp -r :/root/test. root@ 's password: test 100% KB/s 00:00 [root@client24 ~]# ls -ld test -rw-r--r-- 1 root root 18 Jul 13 03:27 test Scheduling using at command [root@client24 ~]# at 5:30 at> mkdir dir1 at> <EOT> job 2 at :30 To view the at queues [root@client24 ~]# atq :30 a root To remove the queue [root@client24 ~]# atrm 2 51

52 Boot Process Practical To view the default runlevel on boot ~]# vi /etc/inittab id:5:initdefault: line no 18 To view the present runlevel ~]# runlevel N 5 To switch to another runlevel [root@client24 ~]# init 3 [root@client24 ~]# init 0 [root@client24 ~]# init 1 [root@client24 ~]# init 6 To view the grub configuration file [root@client24 ~]# cat /boot/grub/grub.conf To view the status of the services in all runlevels. [root@client24 ~]# chkconfig --list [root@client24 ~]# chkconfig --list kudzu kudzu 0:off 1:off 2:off 3:on 4:on 5:on 6:off To set the status of a service [root@client24 ~]# chkconfig bluetooth on [root@client24 ~]# chkconfig --list bluetooth bluetooth 0:off 1:off 2:on 3:on 4:on 5:on 6:off [root@client24 ~]# chkconfig bluetooth off bluetooth 0:off 1:off 2:off 3:off 4:off 5:off 6:off [root@client24 ~]# service bluetooth restart 52

53 Installation of Packages through RPM or YUM If you want to install from CD or DVD go to packages location generally in /media/cdrom/server To install from NFS server where NFS server's IP is and share folder is /var/ftp/pub/server mount the share at client side. mnt]# mount :/var/ftp/pub/Server /mnt mnt]# mount mnt]# cd /mnt mnt]# ls To install packages mnt]# rpm -i mnt]# rpm -iv mnt]# rpm -iv samba* vsftpd* samba* vsftpd* samba* vsftpd* --force mnt]# rpm -ivh samba* vsftpd* --force To remove the packages mnt]# rpm -e vsftpd mnt]# rpm -e vsftpd mnt]# rpm -e samba --nodeps To query the packages mnt]# rpm -qa mnt]# rpm -qa sort less mnt]# rpm -q samba mnt]# rpm -qa samba* mnt]# mnt]# rpm -qi samba mnt]# rpm -ql samba mnt]# rpm -qd samba mnt]# rpm -qc samba mnt]# rpm -qs samba 53

54 Installing through yum Creating a repository at server side where all rpms are copied [root@client ~]# cd /var/ftp/pub/server [root@client Server]# rpm -ivh createrepo fc6.noarch.rpm -- force Remove the old repodata [root@client Server]# rm -rf repodata/ Create a new repodata [root@client Server]# createrepo -g /media/cdrom/server/repodata/compsrhel5-server-core.xml. [root@client Server]# cd [root@client ~]# At client side edit the yum configuration file, provide the path of repository [root@client ~]# vi /etc/yum.repos.d/rhel-debuginfo.repo [core] name= Linux $releasever - $basearch - Debug baseurl=ftp:// /pub/server enabled=1 gpgcheck=1 gpgkey=file:///etc/pki/rp :wq! Installing through yum [root@client ~]# yum list [root@client ~]# yum list installed [root@client ~]# yum list installed samba* [root@client ~]# yum install vsftpd* samba* [root@client ~]# yum remove vsftpd* samba* [root@client ~]# yum grouplist [root@client ~]# yum groupinstall "Mail Server" [root@client ~]# yum groupremove "Mail Server" [root@client ~]# cd /media/cdrom/server [root@client ~]# yum localinstall vsftpd* 54

55 Introduction to Networking To set the hostname temporarily ~]# hostname station9.example.com To view the hostname ~]# hostname station9.example.com Set hostname permanently ~]# vi /etc/sysconfig/network NETWORKING=yes HOSTNAME=station9.example.com :wq! Set ip address temporarily ~]# ifconfig eth netmask View the interfaces. ~]# ifconfig eth0 Link encap:ethernet HWaddr 00:13:20:B7:1D:44 inet addr: Bcast: Mask: inet6 addr: fe80::213:20ff:feb7:1d44/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:48153 errors:4 dropped:0 overruns:0 frame:4 TX packets:21992 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes: (37.6 MiB) TX bytes: (1.6 MiB) lo Link encap:local Loopback inet addr: Mask: inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:16436 Metric:1 RX packets:1249 errors:0 dropped:0 overruns:0 frame:0 TX packets:1249 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes: (1.2 MiB) TX bytes: (1.2 MiB) 55

56 Set permanent ip address ~]# netconfig Select yes and press the enter key Press tab and select the text box for IP address Enter the new IP address similarly enter the subnet mask, default gateway and primary nameserver. Select OK and press enter. Restart the service to activate the new ip address ~]# service network restart ~]# ifconfig eth0 Link encap:ethernet HWaddr 00:13:20:B7:1D:44 inet addr: Bcast: Mask: inet6 addr: fe80::213:20ff:feb7:1d44/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:48173 errors:4 dropped:0 overruns:0 frame:4 TX packets:22001 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes: (37.6 MiB) TX bytes: (1.6 MiB) lo Link encap:local Loopback inet addr: Mask: inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:16436 Metric:1 RX packets:1249 errors:0 dropped:0 overruns:0 frame:0 TX packets:1249 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes: (1.2 MiB) TX bytes: (1.2 MiB) ~]# netconfig --device eth0:1 ~]# service network restart ~]# ifconfig eth0 Link encap:ethernet HWaddr 00:13:20:B7:1D:44 inet addr: Bcast: Mask: inet6 addr: fe80::213:20ff:feb7:1d44/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:48749 errors:4 dropped:0 overruns:0 frame:4 TX packets:22678 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes: (38.0 MiB) TX bytes: (1.7 MiB) eth0:1 Link encap:ethernet HWaddr 00:13:20:B7:1D:44 inet addr: Bcast:

RG-MACC_2.0 Installation Manual

RG-MACC_2.0 Installation Manual RG-MACC_2.0 Installation Manual Ruijie Networks Co., Ltd all rights reserved 1 Copyright Clarify Copyright ownership belongs to Ruijie, shall not be reproduced, copied, or used in other ways without permission.

More information

EX200.redhat

EX200.redhat EX200.redhat Number: EX200 Passing Score: 800 Time Limit: 120 min Exam A QUESTION 1 Configure the verification mode of your host account and the password as LDAP. And it can login successfully through

More information

EX200.Lead2pass.Exam.24q. Exam Code: EX200. Exam Name: Red Hat Certified System Administrator RHCSA. Version 14.0

EX200.Lead2pass.Exam.24q. Exam Code: EX200. Exam Name: Red Hat Certified System Administrator RHCSA. Version 14.0 EX200.Lead2pass.Exam.24q Number: EX200 Passing Score: 800 Time Limit: 120 min File Version: 14.0 http://www.gratisexam.com/ Exam Code: EX200 Exam Name: Red Hat Certified System Administrator RHCSA Version

More information

Seltestengine EX200 24q

Seltestengine EX200 24q Seltestengine EX200 24q Number: EX200 Passing Score: 800 Time Limit: 120 min File Version: 22.5 http://www.gratisexam.com/ Red Hat EX200 Red Hat Certified System AdministratorRHCSA Nicely written Questions

More information

EX200.exam.35q. Number: EX200 Passing Score: 800 Time Limit: 120 min. EX200. Red Hat Certified System Administrator RHCSA

EX200.exam.35q. Number: EX200 Passing Score: 800 Time Limit: 120 min.   EX200. Red Hat Certified System Administrator RHCSA EX200.exam.35q Number: EX200 Passing Score: 800 Time Limit: 120 min EX200 Red Hat Certified System Administrator RHCSA Exam A QUESTION 1 Configure the verification mode of your host account and the password

More information

Exam Name: Red Hat Certified Engineer on Redhat

Exam Name: Red Hat Certified Engineer on Redhat Vendor: Red Hat Exam Code: RH302 Exam Name: Red Hat Certified Engineer on Redhat Version: DEMO QUESTION 1 One Logical Volume is created named as myvol under vo volume group and is mounted. The Initial

More information

Actual4Test. Actual4test - actual test exam dumps-pass for IT exams

Actual4Test.   Actual4test - actual test exam dumps-pass for IT exams Actual4Test http://www.actual4test.com Actual4test - actual test exam dumps-pass for IT exams Exam : RH-302 Title : Red Hat Certified Engineer on Redhat Enterprise Linux 5 (Labs) Vendors : RedHat Version

More information

Red Hat.Actualtests.EX200.v by.Dixon.22q. Exam Code: EX200. Exam Name: Red Hat Certified System Administrator (RHCSA) Exam

Red Hat.Actualtests.EX200.v by.Dixon.22q. Exam Code: EX200. Exam Name: Red Hat Certified System Administrator (RHCSA) Exam Red Hat.Actualtests.EX200.v2014-12-02.by.Dixon.22q Number: EX200 Passing Score: 800 Time Limit: 120 min File Version: 14.5 http://www.gratisexam.com/ Exam Code: EX200 Exam Name: Red Hat Certified System

More information

Vendor: RedHat. Exam Code: EX200. Exam Name: Red Hat Certified System Administrator - RHCSA. Version: Demo

Vendor: RedHat. Exam Code: EX200. Exam Name: Red Hat Certified System Administrator - RHCSA. Version: Demo Vendor: RedHat Exam Code: EX200 Exam Name: Red Hat Certified System Administrator - RHCSA Version: Demo EX200 Exam A QUESTION NO: 1 CRECT TEXT Configure your Host Name, IP Address, Gateway and DNS. Host

More information

EX200 EX200. Red Hat Certified System Administrator RHCSA

EX200 EX200. Red Hat Certified System Administrator RHCSA EX200 Number: EX200 Passing Score: 800 Time Limit: 120 min File Version: 14.0 http://www.gratisexam.com/ EX200 Red Hat Certified System Administrator RHCSA EX200 QUESTION 1 Configure your Host Name, IP

More information

Welcome to getting started with Ubuntu Server. This System Administrator Manual. guide to be simple to follow, with step by step instructions

Welcome to getting started with Ubuntu Server. This System Administrator Manual. guide to be simple to follow, with step by step instructions Welcome to getting started with Ubuntu 12.04 Server. This System Administrator Manual guide to be simple to follow, with step by step instructions with screenshots INDEX 1.Installation of Ubuntu 12.04

More information

Linux Administration

Linux Administration Linux Administration This course will cover all aspects of Linux Certification. At the end of the course delegates will have the skills required to administer a Linux System. It is designed for professionals

More information

RH202. Redhat Certified Technician on Redhat Enterprise Linux 4 (Labs) Exam.

RH202. Redhat Certified Technician on Redhat Enterprise Linux 4 (Labs) Exam. REDHAT RH202 Redhat Certified Technician on Redhat Enterprise Linux 4 (Labs) Exam TYPE: DEMO http://www.examskey.com/rh202.html Examskey REDHAT RH202 exam demo product is here for you to test the quality

More information

Testpassport.

Testpassport. Testpassport http://www.testpassport.cn Exam : RH-302 Title : Red Hat Certified Engineer on Redhat Enterprise Linux 5 (Labs) Version : Demo 1 / 12 1.CORRECT TEXT Change the root Password to redtophat Boot

More information

Back Up (And Restore) LVM Partitions With LVM Snapshots

Back Up (And Restore) LVM Partitions With LVM Snapshots By Falko Timme Published: 2007-04-15 13:24 Back Up (And Restore) LVM Partitions With LVM Snapshots Version 1.0 Author: Falko Timme Last edited 04/11/2007 This tutorial shows

More information

RG-MACC-BASE_v2.01. Installation Guide

RG-MACC-BASE_v2.01. Installation Guide RG-MACC-BASE_v2.01 Preface Thank you for using our products. Audience This manual is intended for: Network engineers Technical support and servicing engineers Network administrators Symbols Important information.

More information

example.com index.html # vim /etc/httpd/conf/httpd.conf NameVirtualHost :80 <VirtualHost :80> DocumentRoot /var/www/html/

example.com index.html # vim /etc/httpd/conf/httpd.conf NameVirtualHost :80 <VirtualHost :80> DocumentRoot /var/www/html/ example.com index.html # vim /etc/httpd/conf/httpd.conf NameVirtualHost 192.168.0.254:80 DocumentRoot /var/www/html/ ServerName station.domain40.example.com

More information

Braindumps EX200 15q

Braindumps EX200 15q Braindumps EX200 15q Number: EX200 Passing Score: 800 Time Limit: 120 min File Version: 22.5 http://www.gratisexam.com/ Red Hat EX200 Red Hat Certified System AdministratorRHCSA This is the best VCE I

More information

Embedded Linux Systems. Bin Li Assistant Professor Dept. of Electrical, Computer and Biomedical Engineering University of Rhode Island

Embedded Linux Systems. Bin Li Assistant Professor Dept. of Electrical, Computer and Biomedical Engineering University of Rhode Island Embedded Linux Systems Bin Li Assistant Professor Dept. of Electrical, Computer and Biomedical Engineering University of Rhode Island Generic Embedded Systems Structure User Sensors ADC microcontroller

More information

RH133. Red Hat Linux System Administration

RH133. Red Hat Linux System Administration RH133 Red Hat Linux System Administration Version 3.5 QUESTION NO: 1 RH133 John works as a Network Administrator for Perfect Solutions Inc. The company has a Linux-based network. He is working as a root

More information

NETW 110 Lab 5 Creating and Assigning Users and Groups Page 1

NETW 110 Lab 5 Creating and Assigning Users and Groups Page 1 NETW 110 Lab 5 Creating and Assigning Users and Groups Page 1 Objective At the conclusion of this lab, the student will be able to add and delete users, create and assign users to groups, and assign users

More information

Student Remote Login Procedure (see picture below): 1. Start SSH Secure Shell 2. Click the computer icon (4 th on the toolbar) 3.

Student Remote Login Procedure (see picture below): 1. Start SSH Secure Shell 2. Click the computer icon (4 th on the toolbar) 3. Student Remote Login Procedure (see picture below): 1. Start SSH Secure Shell 2. Click the computer icon (4 th on the toolbar) 3. Enter stargate.ncc.edu in the text field labeled Host Name: 4. Enter the

More information

Exam Questions RH202

Exam Questions RH202 Exam Questions RH202 Redhat Certified Technician on Redhat Enterprise Linux 5 (Labs) https://www.2passeasy.com/dumps/rh202/ 1.CORRECT TEXT Change the root Password to redtophat Boot the system in Single

More information

An introduction to Logical Volume Management

An introduction to Logical Volume Management An introduction to Logical Volume Management http://distrowatch.com/weekly.php?issue=20090309 For users new to Linux, the task of switching operating systems can be quite daunting. While it is quite similar

More information

Please choose the best answer. More than one answer might be true, but choose the one that is best.

Please choose the best answer. More than one answer might be true, but choose the one that is best. Introduction to Linux and Unix - endterm Please choose the best answer. More than one answer might be true, but choose the one that is best. SYSTEM STARTUP 1. A hard disk master boot record is located:

More information

Chapter 5: User Management. Chapter 5 User Management

Chapter 5: User Management. Chapter 5 User Management Chapter 5: User Management Chapter 5 User Management Last revised: 20/6/2004 Chapter 5 Outline In this chapter we will learn Where user and group account information is stored How to manage user accounts

More information

Changing user login password on templates

Changing user login password on templates Changing user login password on templates 1. Attach an ISO via the cloudstack interface and boot the VM to rescue mode. Click on attach iso icon highlighted below: A popup window appears from which select

More information

How to add additional disks to XenServer host

How to add additional disks to XenServer host How to add additional disks to XenServer host This article explains how to add physical disk drives to a XenServer host, so that more capacity is available for the XenServer guests. Create Linux LVM partition

More information

TestOut Linux Pro - English 4.0.x OBJECTIVE MAPPING: CompTIA Linux+ LX0-103

TestOut Linux Pro - English 4.0.x OBJECTIVE MAPPING: CompTIA Linux+ LX0-103 TestOut Linux Pro - English 4.0.x OBJECTIVE MAPPING: CompTIA Linux+ LX0-103 CompTIA Linux+ Powered by LPI LX0-103 Objectives The Linux+ Powered by LPI Exam: LX0-103 exam covers the following topics. #

More information

RH-202. RedHat. Redhat Certified Technician on Redhat Enterprise Linux 4 (Labs)

RH-202. RedHat. Redhat Certified Technician on Redhat Enterprise Linux 4 (Labs) RedHat RH-202 Redhat Certified Technician on Redhat Enterprise Linux 4 (Labs) Download Full Version : https://killexams.com/pass4sure/exam-detail/rh-202 QUESTION: 159 Install the dialog-* Questions asking

More information

Stop all processes and then reboot - same as above startx. Log in as superuser from current login exit

Stop all processes and then reboot - same as above startx. Log in as superuser from current login exit Starting & Stopping shutdown -h now Shutdown the system now and do not reboot shutdown -r 5 Shutdown the system in 5 minutes and reboot shutdown -r now Shutdown the system now and reboot reboot Stop all

More information

File systems and Filesystem quota

File systems and Filesystem quota File systems and Filesystem quota 8.1 Unit objectives After completing this unit, you should be able to: Describe what a file is Describe what a file system is List possible file systems Describe i-nodes

More information

Accurate study guides, High passing rate! IT TEST BOOK QUESTION & ANSWER. Ittestbook provides update free of charge in one year!

Accurate study guides, High passing rate! IT TEST BOOK QUESTION & ANSWER. Ittestbook provides update free of charge in one year! IT TEST BOOK QUESTION & ANSWER Ittestbook provides update free of charge in one year! Accurate study guides, High passing rate! Exam : RH133 Title : Red Hat Linux System Administration Version : Demo 1

More information

Manage your disk space... for free :)

Manage your disk space... for free :) Manage your disk space... for free :) Julien Wallior Plug Central Agenda Background RAID LVM Some basics Practice Booting on a raid device What is that? How it works Hardware raid... if you really want

More information

Cloning and Repartitioning sessionmgr Disks

Cloning and Repartitioning sessionmgr Disks This chapter describes the steps needed to repartition the sessionmgr disks so that the increased number of subscribers (> 10 million) can be accommodated. Cloning and Disk Repartitioning of Sessionmgr01

More information

Linux Essentials Objectives Topics:

Linux Essentials Objectives Topics: Linux Essentials Linux Essentials is a professional development certificate program that covers basic knowledge for those working and studying Open Source and various distributions of Linux. Exam Objectives

More information

How To Resize ext3 Partitions Without Losing Data

How To Resize ext3 Partitions Without Losing Data By Falko Timme Published: 2007-01-07 17:12 How To Resize ext3 Partitions Without Losing Data Version 1.0 Author: Falko Timme Last edited 12/31/2006 This article is about

More information

This section describes the procedures needed to add a new disk to a VM. vmkfstools -c 4g /vmfs/volumes/datastore_name/vmname/xxxx.

This section describes the procedures needed to add a new disk to a VM. vmkfstools -c 4g /vmfs/volumes/datastore_name/vmname/xxxx. Adding a New Disk, page 1 Mounting the Replication Set from Disk to tmpfs After Deployment, page 3 Manage Disks to Accommodate Increased Subscriber Load, page 5 Adding a New Disk This section describes

More information

Computer Systems and Architecture

Computer Systems and Architecture Computer Systems and Architecture Stephen Pauwels Computer Systems Academic Year 2018-2019 Overview of the Semester UNIX Introductie Regular Expressions Scripting Data Representation Integers, Fixed point,

More information

How to clone a Linux box using netcat

How to clone a Linux box using netcat How to clone a Linux box using netcat Dr. Emiliano Bruni info@ebruni.it Version 0.01 $Date: 2003/08/22 14:52:15 $ Many times it s necessary to have a clone of a linux box without modifying the original

More information

RedHat. Rh202. Redhat Certified Technician on Redhat Enterprise Linux 4 (Labs)

RedHat. Rh202. Redhat Certified Technician on Redhat Enterprise Linux 4 (Labs) RedHat Rh202 Redhat Certified Technician on Redhat Enterprise Linux 4 (Labs) http://killexams.com/exam-detail/rh202 QUESTION: 156 Who ever creates the files/directories on /data group owner should be automatically

More information

Chapter 6. Linux File System

Chapter 6. Linux File System Chapter 6 Linux File System 1 File System File System management how to store informations on storage devices The Hierarchical Structure Types of file Common File system Tasks 2 The Hierarchical Structure

More information

Exam Questions RH133

Exam Questions RH133 Exam Questions RH133 Red Hat Linux System Administration https://www.2passeasy.com/dumps/rh133/ 1.John works as a Network Administrator for Perfect Solutions Inc. The company has a Linux-based network.

More information

7. Try shrinking / -- what happens? Why? Cannot shrink the volume since we can not umount the / logical volume.

7. Try shrinking / -- what happens? Why? Cannot shrink the volume since we can not umount the / logical volume. OPS235 Lab 4 [1101] Sample/suggested Answers/notes (Please ask your professor if you need any clarification or more explanation on concepts you don't understand.) Investigation 1: How are LVMs managed

More information

GNU/Linux 101. Casey McLaughlin. Research Computing Center Spring Workshop Series 2018

GNU/Linux 101. Casey McLaughlin. Research Computing Center Spring Workshop Series 2018 GNU/Linux 101 Casey McLaughlin Research Computing Center Spring Workshop Series 2018 rccworkshop IC;3df4mu bash-2.1~# man workshop Linux101 RCC Workshop L101 OBJECTIVES - Operating system concepts - Linux

More information

Redhat Basic. Need. Your. What. Operation G U I D E. Technical Hand Note template version

Redhat Basic. Need. Your. What. Operation G U I D E. Technical Hand Note template version Redhat Basic Operation G U I D E What Need Your www.next-asia.com Readhat Basic Operation Guide, Prepared by Nazmul Khan Page 1 of 43 Redhat Basic Operation Guide RedHat Installation Guide... 2 Installation...

More information

Lab on User administration

Lab on User administration Lab on User administration To add user #useradd [options] -c Change the comment field. This is often the users full name. -d Change the home directory -e Set

More information

CIS UNIX System Administration

CIS UNIX System Administration Lab 11: Lab notes: - Lab 10 successful completion is a prerequisite for this lab - The sda8, sda9 partitions below may change based on current disk partition. See instructor for current # s. - After the

More information

Course 144 Supplementary Materials. UNIX Fundamentals

Course 144 Supplementary Materials. UNIX Fundamentals Course 144 Supplementary Materials UNIX Fundamentals 1 Background to UNIX Command Fundamentals This appendix provides a overview of critical commands and concepts Prerequisite knowledge attendees should

More information

"Charting the Course... MOC B: Linux System Administration. Course Summary

Charting the Course... MOC B: Linux System Administration. Course Summary Description Course Summary This four-day instructor-led course is designed to provide students with the necessary skills and abilities to work as a professional Linux system administrator. The course covers

More information

SA2 v6 Linux System Administration II Net Configuration, Software, Troubleshooting

SA2 v6 Linux System Administration II Net Configuration, Software, Troubleshooting SA2 v6 Linux System Administration II Net Configuration, Software, Troubleshooting Synopsis: This is the second System Administration class, a follow-on class for new administrators with limited networking

More information

Let us ping! First we will learn the Hello World of a networked machine.

Let us ping! First we will learn the Hello World of a networked machine. AN INTRODUCTION TO LINUX NETWORKING In this article, we ll explore networking under GNU/Linux. You ll find it interesting to manage the entire network through certain valid keystrokes known as commands.

More information

How to increase XenServer virtual machine root or swap partition

How to increase XenServer virtual machine root or swap partition How to increase XenServer virtual machine root or swap partition When doing a standard Linux installation on a XenServer virtual machine, installation process typically allocates all of available virtual

More information

Exam LFCS/Course 55187B Linux System Administration

Exam LFCS/Course 55187B Linux System Administration Exam LFCS/Course 55187B Linux System Administration About this course This four-day instructor-led course is designed to provide students with the necessary skills and abilities to work as a professional

More information

Computer Systems and Architecture

Computer Systems and Architecture Computer Systems and Architecture Introduction to UNIX Stephen Pauwels University of Antwerp October 2, 2015 Outline What is Unix? Getting started Streams Exercises UNIX Operating system Servers, desktops,

More information

LPIC-1 System Administrator

LPIC-1 System Administrator LPIC-1 System Administrator The world s largest and most recognized Linux Certification LPIC-1 is the first certification in LPI s multi-level Linux professional certification program. The LPIC-1 will

More information

At course completion. Overview. Audience profile. Course Outline. : 55187B: Linux System Administration. Course Outline :: 55187B::

At course completion. Overview. Audience profile. Course Outline. : 55187B: Linux System Administration. Course Outline :: 55187B:: Module Title Duration : 55187B: Linux System Administration : 4 days Overview This four-day instructor-led course is designed to provide students with the necessary skills and abilities to work as a professional

More information

Presented by Bill Genske Gary Jackson

Presented by Bill Genske Gary Jackson Quintessential School Systems Session C Linux Presented by Bill Genske Gary Jackson Copyright Quintessential School Systems, 2009 All Rights Reserved 867 American Street --- Second Floor --- San Carlos,

More information

Installation of RHEL/CentOS/ 6 updates for Servers & Desktops

Installation of RHEL/CentOS/ 6 updates for Servers & Desktops Installation of RHEL/CentOS/ 6 updates for Servers & Desktops 1. Set your computers BIOS to boot form CD / DVD 2. Insert the CentOS 6 CD or DVD 3. When presented with the following screen press enter on

More information

client X11 Linux workstation

client X11 Linux workstation LPIC1 LPIC Linux: System Administrator LPIC 1 LPI command line LPIC-1 Linux LPIC-1 client X11 Linux workstation Unix GNU Linux Fundamentals Unix and its Design Principles FSF and GNU GPL - General Public

More information

Course 55187B Linux System Administration

Course 55187B Linux System Administration Course Outline Module 1: System Startup and Shutdown This module explains how to manage startup and shutdown processes in Linux. Understanding the Boot Sequence The Grand Unified Boot Loader GRUB Configuration

More information

Linux Nuts and Bolts

Linux Nuts and Bolts Linux Nuts and Bolts David Morgan At the command line Cursor control type to insert del/ctrl-d to delete home/end for endpoints Filename completion tab after initial characters Command repetition uparrow

More information

Hands-on Keyboard: Cyber Experiments for Strategists and Policy Makers

Hands-on Keyboard: Cyber Experiments for Strategists and Policy Makers Hands-on Keyboard: Cyber Experiments for Strategists and Policy Makers Review of the Linux File System and Linux Commands 1. Introduction Becoming adept at using the Linux OS requires gaining familiarity

More information

Overview LEARN. History of Linux Linux Architecture Linux File System Linux Access Linux Commands File Permission Editors Conclusion and Questions

Overview LEARN. History of Linux Linux Architecture Linux File System Linux Access Linux Commands File Permission Editors Conclusion and Questions Lanka Education and Research Network Linux Architecture, Linux File System, Linux Basic Commands 28 th November 2016 Dilum Samarasinhe () Overview History of Linux Linux Architecture Linux File System

More information

SCSI RDMA Protocol. Introduction. Configuring SRP CHAPTER

SCSI RDMA Protocol. Introduction. Configuring SRP CHAPTER 4 CHAPTER This chapter describes SCSI RDMA protocol and includes the following sections: Introduction, page 4-1 Configuring SRP, page 4-1 Verifying SRP, page 4-7 See the Root and Non-root Conventions in

More information

Disks, Filesystems, Booting Todd Kelley CST8177 Todd Kelley 1

Disks, Filesystems, Booting Todd Kelley CST8177 Todd Kelley 1 Disks, Filesystems, Booting Todd Kelley kelleyt@algonquincollege.com CST8177 Todd Kelley 1 sudo and PATH (environment) disks partitioning formatting file systems: mkfs command checking file system integrity:

More information

CST8207: GNU/Linux Operating Systems I Lab Seven Linux User and Group Management. Linux User and Group Management

CST8207: GNU/Linux Operating Systems I Lab Seven Linux User and Group Management. Linux User and Group Management Student Name: YOUR NAME Lab Section: 011 012 013 or 014 Linux User and Group Management 1 Due Date - Upload to Blackboard by 8:30am Monday April 2, 2012 Submit the completed lab to Blackboard following

More information

Disks, Filesystems Todd Kelley CST8177 Todd Kelley 1

Disks, Filesystems Todd Kelley CST8177 Todd Kelley 1 Disks, Filesystems Todd Kelley kelleyt@algonquincollege.com CST8177 Todd Kelley 1 sudo and PATH (environment) disks partitioning formatting file systems: mkfs command checking file system integrity: fsck

More information

UNIX. Basic UNIX Command

UNIX. Basic UNIX Command UNIX Basic UNIX Command Command List ls mkdir mv chmod groupadd hostname kill head top compress/ uncompress pwd Cat find chown useradd id ioscan pdf sar cd more grep chgrp passwd mount dmesg netstat tar

More information

Linux Howtos. Fedora 9 Install (114) CIS Fall Fedora 9 Install (114) Fedora 9 installation with custom partitions.

Linux Howtos. Fedora 9 Install (114) CIS Fall Fedora 9 Install (114) Fedora 9 installation with custom partitions. Linux Howtos Fedora 9 Install (114) CIS 191 - Fall 2008 Fedora 9 Install (114) Fedora 9 installation with custom partitions. Requirements: Fedora 9 DVD ISO files http://iso.linuxquestions.org/ VMWare Server

More information

National University of Computer and Emerging Sciences Operating System Lab - 02 Lab Manual

National University of Computer and Emerging Sciences Operating System Lab - 02 Lab Manual National University of Computer and Emerging Sciences Operating System Lab - 02 Lab Manual Objective This lab is all about running commands in Ubuntu Terminal and compiling C program in Ubuntu Table of

More information

Linux Reference Card - Command Summary

Linux Reference Card - Command Summary Linux Reference Card - Command Summary adduser adduser dsoneil This command will automatically add a new user to the system The Bash script can be found in /usr/sbin if it needs to be changes alias alias

More information

UNIVERSITY OF BOLTON CREATIVE TECHNOLOGIES. BSc (Hons) COMPUTER NETWORKS AND SECURITY SEMESTER ONE EXAMINATION 2014/2015 UNIX MODULE NO: CPU5003

UNIVERSITY OF BOLTON CREATIVE TECHNOLOGIES. BSc (Hons) COMPUTER NETWORKS AND SECURITY SEMESTER ONE EXAMINATION 2014/2015 UNIX MODULE NO: CPU5003 [CRT09] UNIVERSITY OF BOLTON CREATIVE TECHNOLOGIES BSc (Hons) COMPUTER NETWORKS AND SECURITY SEMESTER ONE EXAMINATION 2014/2015 MODULE NO: CPU5003 Date: Wednesday 21 st January 2015 Time: 10:00 13:00 INSTRUCTIONS

More information

Outline. Structure of a UNIX command

Outline. Structure of a UNIX command Outline Structure of Unix Commands Command help (man) Log on (terminal vs. graphical) System information (utility) File and directory structure (path) Permission (owner, group, rwx) File and directory

More information

Linux Command Line Primer. By: Scott Marshall

Linux Command Line Primer. By: Scott Marshall Linux Command Line Primer By: Scott Marshall Draft: 10/21/2007 Table of Contents Topic Page(s) Preface 1 General Filesystem Background Information 2 General Filesystem Commands 2 Working with Files and

More information

FastTrack to Red Hat Linux System Administrator Course Overview

FastTrack to Red Hat Linux System Administrator Course Overview Course Overview This highly practical instructor led training course is designed to give experienced LINUX/UNIX administrators practical experience in the administration of a LINUX system to a level required

More information

Linux Essentials. Programming and Data Structures Lab M Tech CS First Year, First Semester

Linux Essentials. Programming and Data Structures Lab M Tech CS First Year, First Semester Linux Essentials Programming and Data Structures Lab M Tech CS First Year, First Semester Adapted from PDS Lab 2014 and 2015 Login, Logout, Password $ ssh mtc16xx@192.168.---.--- $ ssh X mtc16xx@192.168.---.---

More information

CompTIA Linux Course Overview. Prerequisites/Audience. Course Outline. Exam Code: XK0-002 Course Length: 5 Days

CompTIA Linux Course Overview. Prerequisites/Audience. Course Outline. Exam Code: XK0-002 Course Length: 5 Days CompTIA Linux+ 2009 Exam Code: XK0-002 Course Length: 5 Days Course Overview This instructor-led course will prepare students for the 2009 CompTIA Linux+ certification exam. It provides a comprehensive

More information

Linux System Administration, level 1. Lecture 4: Partitioning and Filesystems Part II: Tools & Methods

Linux System Administration, level 1. Lecture 4: Partitioning and Filesystems Part II: Tools & Methods Linux System Administration, level 1 Lecture 4: Partitioning and Filesystems Part II: Tools & Methods The sequence 1. Create one or more empty partitions 1a. (optional) Arrange them into a RAID or LVM

More information

Getting Started with Pentaho and Cloudera QuickStart VM

Getting Started with Pentaho and Cloudera QuickStart VM Getting Started with Pentaho and Cloudera QuickStart VM This page intentionally left blank. Contents Overview... 1 Before You Begin... 1 Prerequisites... 1 Use Case: Development Sandbox for Pentaho and

More information

Introduction to the UNIX command line

Introduction to the UNIX command line Introduction to the UNIX command line Steven Abreu Introduction to Computer Science (ICS) Tutorial Jacobs University s.abreu@jacobs-university.de September 19, 2017 Overview What is UNIX? UNIX Shell Commands

More information

These documents and software are covered under the terms and conditions of the fp Technologies, Inc. Program License Agreement

These documents and software are covered under the terms and conditions of the fp Technologies, Inc. Program License Agreement Copyright 2017, fp Technologies, Inc. All Rights Reserved These documents and software are covered under the terms and conditions of the fp Technologies, Inc. Program License Agreement You will need to

More information

Linux Systems Administration Getting Started with Linux

Linux Systems Administration Getting Started with Linux Linux Systems Administration Getting Started with Linux Network Startup Resource Center www.nsrc.org These materials are licensed under the Creative Commons Attribution-NonCommercial 4.0 International

More information

1. Set up the storage to allow access to the LD(s) by the server following the NEC storage user guides.

1. Set up the storage to allow access to the LD(s) by the server following the NEC storage user guides. Overview Server running Red Hat Enterprise Linux (RHEL) must be configured to recognize and work with NEC storage systems. The following procedure demonstrates the steps necessary to configure multipath

More information

Prerequisites: General computing knowledge and experience. No prior knowledge with Linux is required. Supported Distributions:

Prerequisites: General computing knowledge and experience. No prior knowledge with Linux is required. Supported Distributions: This course prepares students to take the 101 exam of the LPI level 1 certification. The Linux Professional Institute (LPI) is the go to certification body for vendor independent Linux certifications.

More information

Installing caos with Cinch on Floppy Disk

Installing caos with Cinch on Floppy Disk Installing caos with Cinch on Floppy Disk Troy Andrew Johnson May 21, 2004 Abstract cinch is the caos Linux (http://www.caosity.org/) installer. Prerequisites What you need: two floppy disks (at least)

More information

Linux Kung-Fu. James Droste UBNetDef Fall 2016

Linux Kung-Fu. James Droste UBNetDef Fall 2016 Linux Kung-Fu James Droste UBNetDef Fall 2016 $ init 1 GO TO https://apps.ubnetdef.org GO TO https://apps.ubnetdef.org GO TO https://apps.ubnetdef.org GO TO https://apps.ubnetdef.org GO TO https://apps.ubnetdef.org

More information

System Administration and Networking

System Administration and Networking System Administration and Networking Topics 1. System Administration 1 2. System Administration 2 3. Managing Directories & Files 4. Networking & Integrating Linux with the MS Infrastructure Samba Wireless

More information

User accounts and authorization

User accounts and authorization User accounts and authorization Authentication vs authorization Authentication: proving the identity of someone Authorization: allowing a user to access certain resources 1 Government authorization documents

More information

Exam Questions RH302

Exam Questions RH302 Exam Questions RH302 Red Hat Certified Engineer on Redhat Enterprise Linux 5 (Labs) https://www.2passeasy.com/dumps/rh302/ 1.. CORRECT TEXT We are working on /data initially the size is 2GB. The /dev/test0/lvtestvolume

More information

Topics. Installation Basics of Using GNU/ Linux Administration Tools

Topics. Installation Basics of Using GNU/ Linux Administration Tools GNU/ Linux Basics Topics Installation Basics of Using GNU/ Linux Administration Tools Installation Installing Using the GUI Disc Partitioning Allocation of swap space Selection of packages to install Configuring

More information

1.3 What does Ctrl-D, Ctrl-A, Ctrl-F and Ctrl-T do in terms of command line editing? (6)

1.3 What does Ctrl-D, Ctrl-A, Ctrl-F and Ctrl-T do in terms of command line editing? (6) Question 1 2 ICT2631 1.1 How do you switch between virtual consoles? (3) Hold down CTRL and ALT keys and press F1 through F7 to switch between consoles. 1.2 Give three reasons why you may opt to use a

More information

CSN09101 Networked Services. Module Leader: Dr Gordon Russell Lecturers: G. Russell

CSN09101 Networked Services. Module Leader: Dr Gordon Russell Lecturers: G. Russell CSN09101 Networked Services Week 3 : Users, Permissions, Processes, and Pipes Module Leader: Dr Gordon Russell Lecturers: G. Russell This lecture Users File permissions Processes Hard and soft links USERS

More information

Create Test Environment

Create Test Environment Create Test Environment Describes how to set up the Trafodion test environment used by developers and testers Prerequisites Python Passwordless ssh If you already have an existing set of ssh keys If you

More information

Linux Kung Fu. Stephen James UBNetDef, Spring 2017

Linux Kung Fu. Stephen James UBNetDef, Spring 2017 Linux Kung Fu Stephen James UBNetDef, Spring 2017 Introduction What is Linux? What is the difference between a client and a server? What is Linux? Linux generally refers to a group of Unix-like free and

More information

LAB #7 Linux Tutorial

LAB #7 Linux Tutorial Gathering information: LAB #7 Linux Tutorial Find the password file on a Linux box Scenario You have access to a Linux computer. You must find the password file on the computer. Objective Get a listing

More information

Introduction to Unix May 24, 2008

Introduction to Unix May 24, 2008 Introduction to Unix May 24, 2008 Exercises: Privileges REFERENCE Reference: Shah, Steve, "Linux Administration: A Beginner's Guide", 2nd. ed., Osborne press, New York, NY. If you look at files in a directory

More information

"Charting the Course... Enterprise Linux System Administration Course Summary

Charting the Course... Enterprise Linux System Administration Course Summary Course Summary Description This is an in-depth course that explores installation, configuration and maintenance of Linux systems. The course focuses on issues universal to every workstation and server.

More information

*nix Crash Course. Presented by: Virginia Tech Linux / Unix Users Group VTLUUG

*nix Crash Course. Presented by: Virginia Tech Linux / Unix Users Group VTLUUG *nix Crash Course Presented by: Virginia Tech Linux / Unix Users Group VTLUUG Ubuntu LiveCD No information on your hard-drive will be modified. Gives you a working Linux system without having to install

More information

Once your USB drive is formatted for the FAT32 file system it can be mounted and tested on the GESBC To do this, use the following command:

Once your USB drive is formatted for the FAT32 file system it can be mounted and tested on the GESBC To do this, use the following command: GESBC-9302 Development With a USB Drive Paul H. Muller - Documatrix www.documatrix-usa.com ulx@linuxmail.org Disclaimer: The programs and procedures described here have been tested and are thought to be

More information