Monday, May 6, 2013

Quick Linux (3): Compressing/Locating/Users

Compressing Commands:

rm -rf #remove folder 

bzip2 file #compress (-v to report reduction size) (-k to keep original)
bunzip file.bz2 #decompress
bzcat file.bz2 #view compressed file

gzip file #compress (not to be confused with zip which archives files)
gunzip file #decompress

tar #packs and unpacks archives (-t view -x extract (overwrites files with same filenames) -c create, -v verbose, -f (read or write from file)

Locating Commands: 
whereis echo #location of a command using standard directories ind of search path
which echo #location using the search path
type echo #whether a command is a builtin
slocate file #searches for a file, needs to be installed


User/System Information: 
who #lists users 
who am i #
finger #lists users more info might be disabled
w #lists users
write user #sending msg to user

No comments:

Post a Comment