Course Notes 10-12-2019 Six Months Redhat Enterprise Linux 6
Total Page:16
File Type:pdf, Size:1020Kb
www.zmprotech.com 888-236-2620 Course Notes 10-12-2019 Six Months Redhat Enterprise Linux 6 and 7 (RHEL) Practice 2 hours daily 30 mins 45 mins 45 mins 10/12/2019 https://youtu.be/jU0kfERg5gU Virtual Box Setup Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Changing boot order 10-12-2019 https://youtu.be/jU0kfERg5gU - Push any key on the keyboard to stop the boot process Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - Push ‘e’ to Edit the GRUB menu Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - Highlight the second option and hit ‘e’ again Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - End of the line give space and hit 3 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - Now push ‘b’ to continue to boot the system Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - The system is in ‘Run Level 3’ Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 login using Login: root Password: redhat Change the boot run level permanent to run level 3 - vi /etc/inittab Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - arrow down to last line - push ‘I’ on the keyboard - you should see insert at the bottom of the screen Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - Change 5 to 3 as shown - Push ‘esc’ key Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - hold the Shift key and colon - Push ‘x’ and hit ‘enter’ - (this will save and exit) Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Change network settings - Settings> Network>Attached to> Host only adapter Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - Change settings as shown Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - Restart virtual machine - The system is successfully set to ‘Runlevel 3’ with network enabled Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 10-13-2019 https://youtu.be/BhDkHOXf7_k Putty Connection - Start the newly installed VM - Log in - ‘Ifconfig’ to see the ip address - Look for ethernet port - Example eth0 (this could be name differently on your VM) - If you don’t see ip address then - Go to - cd /etc/sysconfig/network-scripts/ Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - vi ifcfg-eth0 - change on boot to ‘yes’ - - - To Save and exit - Shift + : x - The above will save and exit - Reboot the system - After reboot and login - ‘Ifconfig’ - Example: 192.168.94.9 Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - - Make necessary changes and save in putty - - Click yes Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - 10-13-2019 https://youtu.be/BhDkHOXf7_k root Command Line Interface – CLI Most of Linux Admin time is spent here CLI root – Administrator – Super user - root user has highest level of access - don’t miss use the root access privileges Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 - you will have access to company data - never share your password with anyone even mangers and directors or ceo - don’t put password in emails, chats or text, don’t share it. /root - Default working directory for the Administrator ‘root’ - this is home directory of the user ‘root’ - this also known as landing directory - the profile of the user ‘root’ is sitting in this directory / - this is the top most directory or folder - also known as root directory - This is root of operating system - 10-19-2019 https://youtu.be/MSILbx8rPYY Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 Run Levels 0 – Shutdown - System is in shut down/ power off status - This will shutdown the system gracefully ‘init 0’ 1- Single user mode - This is used for troubleshooting the system - System bootup problems - Root password issues - It will boot automatically into root user – without prompting for password - Other troubleshooting issues - No networking is available in this mode - No other users can connect to the host ‘init 1’ 2 – Multiuser mode without NFS - Multiple users can connect - Network File System is not available ‘init 2’ 3 – Multiuser mode with NFS - This is default mode in most cases - Admins will be working in this mode - Example: DB team, Other admins, regular users etc., - NFS will be available ‘init 3’ 4 – undefined - No body is using this mode Copyright © 2018 ZMProTech www.zmprotech.com 888-236-2620 www.zmprotech.com 888-236-2620 5 – GUI mode – X11 Windows mode - Graphical User Interface. - Windows graphic are available - This will used by some web development team - NFS available - Everything in runlevel 3 – GUI ‘init 5’ 6 – reboot, restart - This will restart the system - When required must get approval from Application team, storage, etc., - Change Request – CR must be approved for reboot. - When the system is rebooted it will go into its default run level ‘init 6’ ** 0 – Shutdown 1- Single user mode 2 – Multiuser mode without NFS 3 – Multiuser mode with NFS 4 – undefined 5 – GUI mode – X11 Windows mode 6 – reboot, restart ** How do you check the run-level of the system? ‘runlevel’ ‘who -r’ ** Where is Default run-level is set in? /etc/inittab Change the run-level