1 / 14

Linux Fundamentals

Linux Fundamentals. Linux Login. Need to have user id and password Every successful login is known as a user session. You can have multiple user sessions on the same host. User sessions can be graphical or text-based. For text-based user sessions. You can have a default of 7 sessions.

Download Presentation

Linux Fundamentals

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Linux Fundamentals IT2763 – Computer Operating Systems

  2. Linux Login IT2763 – Computer Operating Systems Need to have user id and password Every successful login is known as a user session. You can have multiple user sessions on the same host. User sessions can be graphical or text-based. For text-based user sessions. You can have a default of 7 sessions. To alternate between text-based user sessions, we use the keys sequences of ALT-F1 TO ALT-F6. These 6 keys will toggle between the 6 user sessions. ALT-F7 is a special key sequence to enter into the graphical user session if the X-server is started.

  3. IT2763 – Computer Operating Systems In Linux users have the ability to do remote text-based or graphical user sessions. Different users can be logged in at the same time. The host is shared between different users at the same time. To find out the list of currently logged in users, we use the ‘who’ command to find out.

  4. Linux Commands IT2763 – Computer Operating Systems • Linux commands are text-based. • They are enter using a text-based user session. • Be careful! Linux commands are case-sensitive. This means the following:- • If ‘who’ is the correct command. • ‘Who’, ‘WHO’, ‘wHo’, ‘wHO’, etc are all incorrect due to the case-sensitivity. • So if we indicate the command is ‘who’ it means ‘who’ literally!

  5. Log out/off IT2763 – Computer Operating Systems • If in graphical user session, choose log-off item from the System menu. • If in text-based user session, we can use the following commands:- • ‘exit’ • Key sequence of CTRL-D

  6. The Linux Kernel IT2763 – Computer Operating Systems The kernel is the basic core of the operating system. It provides all the fundamental services the operating system needs such as file input/output. It also contains a process scheduler. It is this scheduler that enables the Linux OS to multi-task. An executing program in Linux is known as a process. Every user session spawns or kickoff a process known as a user shell. Default shell for most Linux is usually ‘bash’.

  7. IT2763 – Computer Operating Systems • The shell provides a command-line to enter text-based commands. • Other shells that can be found in Linux distributions are:- • csh • ksh • To find out information about any process. We use the command ‘ps’. • The default ‘ps’ command without any options/arguments will show only the processes started from within the same user session. • To find out all the processes on a host we use ‘ps aux’ command.

  8. Linux File System IT2763 – Computer Operating Systems The Linux file system is different from that of Windows. There are no C: D: E: …. etc drives on Linux. The Linux file system has a common point. The point is always known as the root directory. It’s symbol is ‘/’. All other sub-directories and files are derived from this root. Linux documentation can refer to files or directories using absolute or relative references.

  9. Absolute References IT2763 – Computer Operating Systems • An absolute reference in Linux is the exact path starting from the root directory to the file or sub-directory. • Examples of absolute references. • /etc/fstab • /etc/sysconfig/network • /usr/home/student

  10. Relative references IT2763 – Computer Operating Systems • A relative reference is a path starting from the current working directory. • Examples of relative references. If the current working directory is ‘/usr’. And we need to refer to a file ‘/usr/home/student/fileA’. We can refer to it using the following relative references. • home/student/fileA • ./home/student/fileA • Special symbol ‘.’ in relative reference means the current working directory. • Special symbol ‘..’ in relative reference means the parent directory.

  11. Some common Linux commands IT2763 – Computer Operating Systems To obtain a file listing of the current working directory, we can use the ‘ls’ command. To examine the content of a file, we use the ‘cat’ command. To find out the absolute path leading to the command. We use the ‘which’ command.

  12. Command line switches/options IT2763 – Computer Operating Systems • Linux command behavior can be modified using command line switches. Example:- • ls –al • ls --size • ls --help • The command switches affects the output of the ls command. • All Linux command have command switches. • It is important to take note of the following. Command line switches can come in 2 forms. Short form or the long form. • -a • --all • Both short and long forms affects the command the same way. Choose which form that suits you best. • Short forms always have a single ‘-’ preceding the switch. • Long forms always have two ‘--’ preceding the switch.

  13. Linux Help IT2763 – Computer Operating Systems • Most Linux commands have mini help. • They are usually invoke using the --help switch. • ls --help • Items surrounded by ‘[‘ ‘]’ brackets are optional. • Items suffixed by ‘...’ means there can be one or more of the item.

  14. More Linux Help IT2763 – Computer Operating Systems • In addition to the command mini help, we can also refer to the following commands to obtain comprehensive help. • ‘man’ • ‘info’ • ‘whatis’

More Related