You are on page 1of 2

#bash: sudo: super user do (root) apt-get: can't => sudo apt-get man: manual ex: man ping

q: quit (in man) tasksel: task select needs sudo sudo apt-get install ___bla (install) sudo apt-get remove ___bla (uninstall) sudo apt-get upgrade (update) sudo /etc/init.d/___bla start/stop/restart (start/stop/restart service) ex: sudo /etc/init.d/apache2 stop top: task manager needs sudo PID: process ID K xxxx: kill process ID # xxxx ex: K 1745323324 h: help help in top cd: change directory cd / .... /=root ls: list vim: file editor sudo vim ___bla (open file ___bla with vim) if ___bla doesn't exist, this will create it ex: sudo vim /etc/passwd sudo chown: change owner sudo chown ___bla___user file__blabla (change permission to ___bla___use r for file___blabla) clear: clear screen exit: log off a: insert mode in vim esc: quit insert mode in vim :/ ___bla: search for ___bla in file (down the file) :/ *___bla*: search for anything that contains ___bla in the middle :/? ___bla: search for ___bla in file (up the file) n: next thing that was found :e ___bla_file: open ___bla_file if already in vim :q == quit :q! == force quit :wq == save and quit (w=write) :w ___bla_file == save as ___bla_file important stuff: ls -l (many details) ls -m (few details) sudo find -iname ___BlA (find file, case insensitive because of -iname) sudo find -iname *_bl* sudo mkdir ___bla (make directory named __bla) sudo mkdir ___bla /etc/network (makes a folder ___bla in folder network) sudo rm ___bla (remove file ___bla) sudo rm ___bla -R (remove folder ___bla -recursive, everything inside of it and the folder itself) sudo mv old_bla (path...1) new_bla (path...2) (move old_bla from (path...1), mov e it in (path...2), and name it new_bla)

sudo cp ___bla ___bla.bak -R (make a copy of ___bla to ___bla.bak) mount: sudo mkdir/mnt/___bla (first, we came a folder where it will be mounted) fdisk -l (list all drives connected and many details) ex: sudo mount /dev/sda5 /mnt/___bla sudo umount /dev/sda5 (unmount) permissions: sudo adduser ___bla_user sudo userdel ___bla_user sudo groupadd ___bla sudo group del ___bla sudo adduser ___bla_user ___to_group sudo deluser ___bla_user ___from_group

You might also like