Topic D02 Introduction to Linux
- Linux is an operating system.
- An operating system is software that manages all of the hardware resources associated with a desktop or laptop.
- The OS manages the communication between your software and your hardware. Without the OS, the software would not function.
- To manage files, we can use two methods:
- Terminal (Command Line Interface - CLI)
- File manager (Graphical User Interface-GUI).
Some compelling uses of Command Line Interface (CLI):
- Commands offer more options and are flexible.
- Some configurations in GUI are 5 screens deep while in CLI it is just a single command.
- CLI loads fast and do not consume RAM as compared to GUI.
There are two ways to launch CLI on Ubuntu:
- Go to search and type terminal
- CTRL + ALT + T
$ sign suggests that you are working as a regular user in Linux.
"#" is displayed while working as a root user.
Present Working Directory
- Directory which is currently browsing is called the Present working directory.
- if we want to check the directory we are currently working on, we can use the command pwd.
- pwd stands for print working directory.
Changing Directories
- To change the current directory we are working on, we can use the "cd" command.
- To navigate to the home directory, we can just type in "cd" in the terminal and type enter.
- To move up one directory level, we can use the command "cd.."
Path
Path in computing can be defined as the address of a file or a folder.
There are two kinds of path:
- Relative path
- Absolute path
Absolute Path
- In absolute path, we need to type or specify the whole path to reach the file.
Relative Path
- It comes in handy when browsing another sub-directory within a given directory
- Saves us the effort from the effort to type complete paths all the time.
- Do no have to specify the complete path to reach a specific location within the same directory in the file system.
Accessing Hardware Information
- Disk Space Usage: <df -h> it displays the mounted filesystem disk usage.
- Memory : <free -h> displays the RAM and virtual memory information.
- CPU details : <lscpu> displays the PCI devices list and its information.
- Peripheral Component Interconnection (PCI) Devices: <ispci>, it displays the PCI devices list and its information.
Comments
Post a Comment