Cheatography
https://cheatography.com
This cheat-sheet is for field worker and MNT team.
This is a draft cheat sheet. It is a work in progress and is not finished yet.
Directory Management
mkdir |
To create a Directory |
rmdir |
To remove a Directory |
cd |
To Change a Directory |
cd .. |
To go one Directory back |
pwd |
Print name of current/working directory |
cd Documents/ |
To change the directory to Documents |
ls (list files) Options
ls |
To see content of the current dir |
ls -al |
To see all files of the current dir |
ls -htl |
List content with human readable size formate and sort by modification time, newest first |
cp (Copy Command)
cp file1 /path/Destination |
To copy a content to another Directory |
cp -r file2/ /path/Destination |
To copy a Directory |
mv (Move Command)
mv [options] <source> <destination> |
Syntax |
mv Dir1 <../Destination> |
To move a file/Directory from one place to anothe place |
|
|
Compressing Commands
tar -cvzf Codebase.tar.gz |
To archive Codebase Dir to the Codebase.tar.gz formate |
tar -cvjf Codebase.tar.bz2 |
To archive Codebase Dir to the Codebase.tar.bz2 formate |
tar -xvf Codebase.tar.bz2 |
To extract the any formate of tar file. |
Networking Commands
netscan |
To see all IP's and MAC addresses on the Network |
ssh -X username@IP_address |
To remotely acess the another machine on the network |
scp Codebase.tar.bz2 username@IP_address:/home/rov/Downloads |
To copy a file local machine to remote machine. |
scp -r username@IP_address:/home/rov/Downloads |
To copy a Directory from remote machine to local machine |
Process Management
pidof <Process_Name> |
Syntax |
pidof node |
To know to the process id of the process name |
top |
To see real time process |
sudo kill -9 <PID> |
To kill the PID of the specified Process |
sudo killall process_name |
To kill all the process related to this name |
|