Commands for Linux

Is still in progress!

.

ALLGEMEIN

[command] & The program is executed and the console can be used again gimp &
[Command] && [Command] Commands are executed one after the other apt-get install gimp && gimp
man [command] Shows a tutorial of the program man gimp
strg + c Cancels the shell operation strg + c
ORDERS, FILES
cd [directory] Changes to any directory cd /media/disk
cd .. Changes back a directory (/media/disk -> /media) cd ../
cd / Changes to the deepest directory cd /
cd – Changes to the last visited directory cd –
cp Copies a file to the specified directory cp /tmp/test.txt /media/disk
mv Moves a file and deletes the source file mv /tmp/bla.txt /media/disk
mv Renames files as well mv /tmp/x1.txt /tmp/x3.txt
rm Delete a file rm /tmp/bla.txt
rm -rf Delete everything in the directory rm -rf /tmp/
mkdir Creates a directory mkdir /media/disk/bla
rmdir Delete a directory rmdir /media/disk/bla
ls Displays all files in a folder ls /home/ubuntu
ls -l Shows a detailed list, with detailed rights to ls -l /home/ubuntu
ls -la Displays hidden files as well ls -la /home/ubuntu
pwd Shows the path to the current directory pwd
cat Displays the contents of a text file cat /home/test.txt
more Displays the contents of a file page by page more test.txt
touch Creates an empty file in any folder touch /ubuntu/123.txt
SYSTEM
top Gives an overview of all running processes and system load top
free Shows how much RAM is being used free
uptime This command displays how long the system has been online uptime
uname Shows some system information with the option -a e.g. the kernel version uname -a
shutdown -h now Drives the computer down shutdown -h now
whoami Shows the user logged in whoami
FIXED DISKS
df Displays the memory location df -h
du Shows the amount of memory used for directories du -h
mkfs.ext2 Format hard disk into ext2 format mkfs.ext2 /dev/sda1
mkfs.ext3 Format hard disk to ext3 format mkfs.ext3 /dev/sda1
mkreiserfs Format hard disk to reiserfs format mkreiserfs /dev/sda1
NETWORK
ifconfig Displays network information ifconfig
iwconfig Displays information about the Wlan network iwconfig
ping [IP/computer] Ping on a computer ping 127.0.0.1
ping6 [IP/computer] Ping a computer with ipv6 address to ping6 google.com
dig [domain] Shows information about the domain stored in the name server. dig meinubuntu.de
traceroute [IP/Domain] Tracks the path of a query “through the Internet” traceroute meinubuntu.de
INSTALLATE AND DEINSTALLATE
apt-get install Installs a package [root privileges required] apt-get install [package name]
apt-get remove Uninstall a package [root privileges required] apt-get remove [Packages