Day 2 of the 90DaysOfDevOps Challenge: Mastering Linux Basics

Introduction: Welcome back to my 90DaysOfDevOps Challenge journey! On Day 2, we're diving deep into the world of Linux, a fundamental skill for any DevOps enthusiast. Today, we'll explore some basic Linux commands that will serve as the building blocks of your DevOps journey.
Day 2 Task: Linux Command Basics
Checking Your Present Working Directory: The first step in navigating a Linux system is knowing where you are. You can use the pwd (present working directory) command to display the directory you're currently in. Simply open your terminal and type:
pwd
Press Enter, and you'll see the full path to your current directory.

Listing All Files and Directories (Including Hidden): To list all the files and directories in your current location, including hidden ones (those that start with a dot), you can use the ls command with the -a flag. Open your terminal and type:
ls -a
This command will provide a list of everything in your current directory, giving you a clear view of both visible and hidden files and directories.

Creating a Nested Directory A/B/C/D/E: Linux makes it easy to create nested directories. To create a nested directory structure like A/B/C/D/E, use the mkdir (make directory) command with the -p flag to ensure that any missing parent directories are also created. In your terminal, type:
mkdir -p A/B/C/D/E
This command will create the entire nested structure, even if some of the directories (A, B, C, D, E) did not exist before.

Linux Commands: Your Essential Toolkit
File and Directory Commands:
ls: List files and directories in the current directory.cd: Change directory.pwd: Print the working directory.mkdir: Create a new directory.touch: Create an empty file or update the access timestamp of a file.cp: Copy files or directories.mv: Move or rename files or directories.rm: Remove files or directories.cat: Concatenate and display the content of a file.grep: Search for a specific pattern in a file.find: Search for files and directories.chmod: Change file permissions.chown: Change file ownership.
System Information and Management Commands:
top: Display real-time system information and running processes.ps: Display information about running processes.kill: Terminate processes.df: Display disk space usage.free: Display memory usage.uname: Display system information.ifconfig(orip): Display network interface configuration.netstat: Display network statistics.systemctl: Control and manage system services (system-based systems).
Package Management Commands:
aptorapt-get: Package management commands for Debian/Ubuntu-based systems.
yum: Package management command for Red Hat/CentOS-based systems.
User and Group Management Commands:
useradd: Create a new user account.usermod: Modify user account properties.userdel: Delete a user account.groupadd: Create a new group.groupmod: Modify group properties.groupdel: Delete a group.passwd: Change user password.
File Transfer and Remote Access Commands:
scp: Securely copy files between local and remote hosts.ssh: Securely access a remote host.
Text File Manipulation:
echo: Display a message or value.grep: Search for a specific pattern in a file.sed: Stream editor for filtering and transforming text.awk: Text processing tool for pattern scanning and processing.
Version Control:
git: Version control system commands code management and collaboration.
Special Paths in Linux System
| Symbol | Represents path to |
~ | home directory |
/ | root directory |
. | present working directory |
.. | parent of a present working directory |
Conclusion: Day 2 of the 90DaysOfDevOps Challenge has been all about mastering basic Linux commands. These commands are essential tools in your DevOps toolbox, as Linux is a widely used operating system in the DevOps world. Understanding how to navigate, list files, and create directories is just the beginning of our journey.
Stay tuned for Day 3, where we'll explore more Linux commands and their applications in the world of DevOps. If you have any questions or topics you'd like me to cover during this challenge, feel free to leave a comment or reach out on social media. Let's keep learning and growing together!
#trainwithshubham #90DaysDevOps #DAY02-90DaysDevOps


