Welcome to Linux command line for you and me!¶
- Shell commands
- Terminal emulators
- date command
- cal command
- whoami command
- id command
- pwd command
- cd command
- . directory and .. directory
- ls command
- mkdir command
- rm command
- Copying a file using cp command
- Renaming or moving a file
- tree command
- wc command
- less command
- echo command
- Redirecting the command output
- Using > to redirect output to a file
- Moving around in the command line
- man pages
- Counting files in a directory
- Editing longer commands
- File system
- Useful commands
- Creating soft link to a file
- Creating hard links
- Extracting a tar file
- Creating a tar file
- Vim editor
- :q to exit vim
- Open a new file or edit an existing file
- Different modes of vim
- :w to save a file
- :q! to quit without saving
- Becoming root user
- Using sudo command
- !! trick
- Setting up hostname
- Environment variables
- Setting up environment variable values
- locate command
- Finding date/time in different timezones
- Bash history
- Sort files by size
- Curl! For all your web needs
- Viewing a file
- Downloading the file
- Download with the same name
- Making a POST request using curl
- Following redirection
- Example: To view github’s pull request patch
- Viewing more details about the transfer
- Making multiple requests at once
- Inspecting HTTP headers
- Adding new HTTP headers
- Curl video/talk
- Curl book
- Users and Groups
- File permissions
- Processes in Linux
- How to view all running processes?
- How to find a particular process?
- How to kill/stop a particular process?
- Finding out list of open files
- Signals
- top command
- Load average
- htop tool
- More about Linux processes
- /proc directory
- /proc/cpuinfo
- /proc/cmdline
- /proc/meminfo
- /proc/uptime
- /proc/sys/ & sysctl command
- Enabling IP forward with sysctl
- Linux Services
- What is a service?
- What is a daemon?
- What is the init system?
- Units in systemd
- .service units in systemd
- How to find all the systemd units in the system?
- Working with a particular service
- Enabling or disabling a service
- Shutdown or reboot the system using systemctl
- journalctl
- Finding the logs of a service
- To view only the last N entries
- Continuous stream of logs
- Listing of previous boots
- Time-based log viewing
- Total size of the journal logs
- Writing your own service file
- Securing a service using systemd
- Installing verybad service
- Vulnerabilities in the application
- Directory traversal vulnerability/ LFI
- Arbitary file write vulnerability
- Remote code execution (RCE) vulnerability
- Remove access to system’s tmp directory
- Protecting home dirctories
- Fixing directory paths
- DynamicUser
- Allowed Executables
- What is next?
- Package management
- dnf command
- Searching for a package
- Finding more information about a package
- Installing a package
- To list the available updates
- To list all security updates
- Update the packages via dnf
- Find out the services & applications need restart after update in Fedora/CentOS/RHEL
- Automatic updates in dnf systems
- apt command
- apt update
- Installing a package via apt
- apt-cache search
- Listing upgrades
- Upgrading packages
- Figuring out which services/processes need restart after package upgrade in Debian
- Listing available security updates in Debian systems
- Unattended upgrades in Debian systems
- SELinux
- File system mounting
- Networking commands
- Finding the IP address
- Finding ARP table
- ping command
- Short note about DNS
- /etc/hosts
- /etc/resolv.conf
- systemd-resolved controlled name resolution
- resolvectl command
- host command
- dig command
- ss command
- traceroute command
- tracepath command
- Remote login to a computer using ssh tool
- ssh key generation
- ssh-copy-id
- Stop and disable the sshd service
- Disable password based login for ssh
- How to find active (open) network connections from your computer?
- To know about ports
- Linux Firewall
- Installation
- Tables, chains and rules
- filter table
- nat table
- iptables command
- View the existing rules
- Appending rules to INPUT chain
- Flushing all rules
- Example of a series of rules
- Delete a rule based on rule number
- Delete a rule directly
- Saving the rules
- A blog post from Major Hayden
- Debugging firewall rules
- Random things
- Whats next?
- Workbook
- Advanced section
- Containers
Team¶
- Jason Braganza (Editor in command)
- Kushal Das (Adds typos in every form)