Linux commands

 0    26 informačný list    starakoza
stiahnuť mp3 vytlačiť hrať Skontrolujte sa
 
otázka Odpoveď
man
začať sa učiť
command for help
> man grep
ls
začať sa učiť
List directory contents
-l long listing (ls -l),-al (ls -al) Listing With Hidden Files
grep
začať sa učiť
Find text in a file
grep PATTERN [FILE], grep failed auth. log
cd
začať sa učiť
Change current directory
Forward slashes instead of backward, cd /var/log
shutdown
sudo shutdown -r 2
začať sa učiť
Safely turn off the computer in software
sudo shutdown 2 (turn off in 2min), -r restart, -c cancel or ctrl+c
pwd
začať sa učiť
Displays the current working directory path
Useful when changing directories often
passwd
začať sa učiť
Change a user account password
sudo passwd [username]
mv
mv SOURCE DEST
začať sa učiť
Move a file
mv first. txt second. txt
cp
cp first. txt second. txt
začať sa učiť
Copy a file
cp SOURCE DEST
rm
začať sa učiť
Remove files or directories
Does not remove directories by default, -r (removes directory)
mkdir
mkdir DIRECTORY
začať sa učiť
Make a directory
mkdir notes
chmod
r=read, w=write, x=execute
začať sa učiť
Change mode of a file system object
chmod mode FILE, chmod 744 script. sh
chown
začať sa učiť
Change file owner and group
sudo chown [OWNER: GROUP] file, sudo chown professor script. sh
iwconfig
začať sa učiť
View or change wireless network configuration
ifconfig
začať sa učiť
View or configure a network interface and IP
Slowly being replaced by ip (ip address)
ps
začať sa učiť
View the current processes
ps -e | more (View all processes)
su / sudo
začať sa učiť
Some command require elevated rights
There are some things normal users can’t do
su
začať sa učiť
Become super user
You continue to be that user until you exit
sudo
začať sa učiť
Execute a command as the super user
Only that command executes as the super user
apt-get
začať sa učiť
Advanced Packaging Tool (Install, update, remove)
sudo apt-get install wireshark
vi
začať sa učiť
Visual mode editor
Full screen editing with copy, paste, and more
dd
začať sa učiť
Backup and restore an entire partition
dd if=<source file name> of=<target file name> [Options]
Creating a disk image
začať sa učiť
dd if=/dev/sda of=/tmp/sda-image. img
Restoring from an image
začať sa učiť
dd if=/tmp/sda-image. img of=/dev/sda
killall / kill <pid>
začať sa učiť
Closing programs
sudo killall firefox
xkill
začať sa učiť
Graphical kill
kill an app with one click

Ak chcete pridať komentár, musíte byť prihlásený.