{"id":1825,"date":"2014-08-06T08:09:53","date_gmt":"2014-08-06T08:09:53","guid":{"rendered":"http:\/\/www.msinterdev.org\/wp\/2014\/08\/06\/xnix-commands-list-2\/"},"modified":"2014-08-06T08:09:53","modified_gmt":"2014-08-06T08:09:53","slug":"xnix-commands-list-2","status":"publish","type":"post","link":"http:\/\/www.msinterdev.org\/wp\/2014\/08\/06\/xnix-commands-list-2\/","title":{"rendered":"xNIX commands list -2"},"content":{"rendered":"<p>dvdrecord -scanbus = lists dvd devices<\/p>\n<p>df -h = free hard drive space<br \/>\n<br \/>\ndf = free hard drive space<br \/>\n<br \/>\ndu -sh = disk usage<br \/>\n<br \/>\ndu -h = hard drive usage<\/p>\n<p>dialog \u2013msgbox \u201cHello\u201d 8 12 = create dialog box<br \/>\n<br \/>\ndialog \u2013title \u201cCheck me\u201d &#8211;checklist \u201cPick numbers\u201d 12 15 2 1 \u201cFirst\u201d \u201con\u201d 2 \u201cSecond\u201d \u201coff\u201d = create checklist<\/p>\n<p>echo $SHELL = prints the default shell name<br \/>\n<br \/>\necho $OSTYPE = prints the operating system name<br \/>\n<br \/>\necho &#8216;text&#8217; = prints what is held in the quotes<br \/>\n<br \/>\necho $HOME = prints home directory<br \/>\n<br \/>\necho $USER = who is currently using the system<br \/>\n<br \/>\necho $HISTFILE = location of history file<br \/>\n<br \/>\necho $HISTFILESIZE = history&#8217;s set size<br \/>\n<br \/>\necho $HISTSIZE = history&#8217;s set size<br \/>\n<br \/>\necho \u201ctest\u201d | mail -v -s test xyz@abc.com = sending e-mail from a terminal<\/p>\n<p>ethtool eth0 = info about ethernet connection<br \/>\n<br \/>\nethtool -i eth0 = driver for ethernet<br \/>\n<br \/>\nethtool -S eth0 = statictics for ethernet<br \/>\n<br \/>\nethtool l0 = info about local loop<\/p>\n<p>egrep \u201cone\/two\/three\u201d filename = looks for any of these 3 words in a file<br \/>\n<br \/>\nenv = prints all environment variables<br \/>\n<br \/>\nexpr 7 + 8 = simple command based calculator (mind the spaces in the equation)<\/p>\n<p>\/etc\/init.d\/httpd status = service status<br \/>\n<br \/>\n\/etc\/init.d\/mysqld start = starts mysql server<br \/>\n<br \/>\n\/etc\/init.d\/oracle-xe start = starts oracle server<\/p>\n<p>exec ls -l = runs ls command and closes the terminal<br \/>\n<br \/>\nexec uptime = runs uptime command and closes terminal<\/p>\n<p>fc -l = short command history<br \/>\n<br \/>\nfdisk -l = list of partitions on the hdd<br \/>\n<br \/>\nfdisk -l \/dev\/hda = partitions within a specific partition<br \/>\n<br \/>\nfdisk \/dev\/hda = master device on IDE channel 0<br \/>\n<br \/>\nfdisk \/dev\/hdb = slave device on IDE channel 0<br \/>\n<br \/>\nfdisk \/dev\/hdc = master device on IDE channel 1<br \/>\n<br \/>\nfdisk \/dev\/hdd = slave device on IDE channel 1<\/p>\n<p>find \/usr\/bin -amin -30 = finds files accessed in last 30 minutes in \/usr\/bin<br \/>\n<br \/>\nfind \/usr\/bin -atime +50 = finds files not accessed for than 50 days<br \/>\n<br \/>\nfind \/usr\/bin -perm 750 = finds files with permission 750<br \/>\n<br \/>\nfind \/usr\/bin -user root = finds files owned by root in \/usr\/bin<br \/>\n<br \/>\nfind \/usr\/bin -user root | wc -l = calculates total no of files owned by root<br \/>\n<br \/>\nfind ! \/usr\/bin -user root = finds files not owned by user root<br \/>\n<br \/>\nfind ! \/usr\/bin -user root | wc -l = calculates no of files not owned by root<br \/>\n<br \/>\nfind -iname filename.ext = finds a file by name<br \/>\n<br \/>\nfind . = lists all files and subdirectories in the current directory<br \/>\n<br \/>\nfind . -size +200M = finds files more than 200M in size<br \/>\n<br \/>\nfind . -size +200M -ls = more details<br \/>\n<br \/>\nfind . -name *.txt -size +40K = finds .txt file names of more than 40 k in size<br \/>\n<br \/>\nfind \/usr\/share\/docs | xargs grep -l &#8216;keyword&#8217; = finds files that contain the keyword from documents<br \/>\n<br \/>\nfinger = log in details<\/p>\n<p>free = memory usage in kb<br \/>\n<br \/>\nfree -b = memory usage in mb<br \/>\n<br \/>\nfree -m = memory usage in blocks<br \/>\n<br \/>\nfree -mt = memory usage in totals<br \/>\n<br \/>\nfree -g = memory usage in gigabytes<br \/>\n<br \/>\nfree -s 5 = update memory usage every 5 seconds<\/p>\n<p>fuser -amuv \/boot = shows processes with \/boot open (a = all, m = man, u = user, v = verbose)<br \/>\n<br \/>\nfuser \/boot = shows parent pids for processes opening \/boot<br \/>\n<br \/>\nfuser -m \/boot = shows pids for processes opening \/boot<br \/>\n<br \/>\nfuser -u \/boot = shows pids for user<br \/>\n<br \/>\nfuser -k \/boot = kills all processes with \/boot files open<br \/>\n<br \/>\nfuser -l = lists supported signals<br \/>\n<br \/>\nfuser -k -HUP \/boot = kills all processes running \/boot by sending HUP signal <\/p>\n<p>getenforce = status of selinux<br \/>\n<br \/>\ngdmsetup = display configuration client\/gui<br \/>\n<br \/>\nglxinfo = graphics card info<br \/>\n<br \/>\nglxinfo | direct = check if direct randering is on<\/p>\n<p>gnome-terminal -x alsamixer = stars terminal with alsamixer displayed<br \/>\n<br \/>\ngnome-terminal -tab -tab -tab = stars terminal with 3 open tabs<br \/>\n<br \/>\ngnome-terminal -geometry 80*20 = stars terminal 80 characters and 20 lines<br \/>\n<br \/>\ngnome-terminal -zoom=2 = stars terminal with larger fonts<\/p>\n<p>grep india \/usr\/share\/dict\/words = looks for the word &#8216;india&#8217; in dictionary<br \/>\n<br \/>\ngrep \u201cword\u201d filename.txt = prints lines with the \u201cword \u201d in them<br \/>\n<br \/>\ngrep \u2013color \u201cword\u201d filename.txt = prints lines with the word in color<br \/>\n<br \/>\ngrep 300 filename.txt = prints lines with 300 in them<br \/>\n<br \/>\ngrep -n \u201cword\u201d filename = line numbers with the word in them printed<br \/>\n<br \/>\ngrep -vn \u201cword\u201d filename = lines without the \u201cword\u201d in them<br \/>\n<br \/>\ngrep -c \u201cword\u201d filename = total no. of occurrences of \u201cword\u201d<br \/>\n<br \/>\ngrep -n \u201cword\u201d * = lists all lines from all files that contain \u201cword\u201d<br \/>\n<br \/>\ngrep -R myword \/etc\/bin* = lists lines with their file names in the directory containing myword<br \/>\n<br \/>\ngrep -h -R myword \/etc\/bin* = lists lines without their file names containing myword<br \/>\n<br \/>\ngrep -Rn myword \/etc\/bin* = lists lines containing myword with their numbers<br \/>\n<br \/>\ngrep \u2013color -R myword \/etc\/bin* = lists lines in the directory containing myword in color<br \/>\n<br \/>\ngrep -Rl myword \/etc\/bin* = lists file names in the directory containing myword<br \/>\n<br \/>\ngrep -x \u201cword\u201d * = only \u201cword\u201d a line<br \/>\n<br \/>\ngrep word filename.txt = searchers for the word in the file (case sensitive)<br \/>\n<br \/>\ngrep word -n filename.txt = lists lines containing word with their numbers<br \/>\n<br \/>\ngrep -i word filename = searchers for the word in the file (i = not case sensitive)<br \/>\n<br \/>\ngrep -i word1 word2 filename = searchers for the word in the file<br \/>\n<br \/>\ngroups = list of groups<\/p>\n<p>gzip = only zips, gunzip = unzips + untars, tar = zips + unzips with czvf, xzvf<br \/>\n<br \/>\ngzip abc.txt = zips a file<br \/>\n<br \/>\ngzip -1 abc.txt = fast compression but poor quality<br \/>\n<br \/>\ngzip -9 abc.txt = slow compression but good quality<br \/>\n<br \/>\ngzip -rv foldername = zips all files in the folder<br \/>\n<br \/>\ngzip -tv abc.txt.gz = checks integrity if gz file with verbose<br \/>\n<br \/>\ngzip -lv abc.txt.gz = gives info about gz file<br \/>\n<br \/>\ngunzip -v abc.txt.gz = unzips gz file with verbose<br \/>\n<br \/>\ngunzip -c abc.tar.gz | tar x = unzips and untars a file (two steps)<br \/>\n<br \/>\ngunzip abc.tar.gz; tar xf abc.tar = unzips then untars a file (two steps)<\/p>\n<p>hal-device-manager = opens a gui for hardware profiling<br \/>\n<br \/>\nhead -6 .bash_history = first 6 commands<br \/>\n<br \/>\nhead -5 filename.txt = prints first 5 lines of the file<br \/>\n<br \/>\nhead -n 5 filename.txt = prints first 5 lines of the file<\/p>\n<p>history 5 = last five commands<br \/>\n<br \/>\nhistory | wc -l = total history commands<br \/>\n<br \/>\nhistory | grep rpm = search through history for rpm commands<br \/>\n<br \/>\nhistory = list of all commands used so far<\/p>\n<p>hostname = name of the host<br \/>\n<br \/>\nhwclock \u2013show = prints today&#8217;s date and time<br \/>\n<br \/>\nhwclock \u2013set \u2013date =\u201d2\/22\/2008 12:25:30\u201d = reset new time and date<\/p>\n<p>identify imagename.jpg = gives image info<br \/>\n<br \/>\nidentify -verbose imangename.jpg | less = gives info about image<br \/>\n<br \/>\nidentify -verbose imangename.jpg | more = gives more info about image<br \/>\n<br \/>\nid = info about user\/root&#8217;s groupid\/uid etc<br \/>\n<br \/>\nifconfig = network card info, ipaddress etc.<br \/>\n<br \/>\nifconfig -a = available network cards<br \/>\n<br \/>\ninfo coreutils = info about core commands<br \/>\n<br \/>\niostat 3 = checks disk reads<br \/>\n<br \/>\niostat -c 3 = updates cpu usage<br \/>\n<br \/>\niostat -c -t = cpu usage with time<br \/>\n<br \/>\niostat -c -t 2 10 = repeat cpu usage info every 2 seconds 10 times<br \/>\n<br \/>\nip a = available network interfaces<br \/>\n<br \/>\nip addr = ip addresses by method of connection ie ppp0<br \/>\n<br \/>\nip addr show eth0 = ip address for ethernet connection<br \/>\n<br \/>\nip calc -bnm 192.168.0.1\/27 = displays netmast ip from CIDR<br \/>\n<br \/>\nip route = checks routing table<br \/>\n<br \/>\nisoinfo = info about iso<br \/>\n<br \/>\niwconfig = checks for wireless connection<br \/>\n<br \/>\niwlist = checks for a wireless access point<\/p>\n<p>kded \u2013version = kde version<br \/>\n<br \/>\nkde-config \u2013version = kde version<\/p>\n<p>kill 23456 = kills process with id 23456<br \/>\n<br \/>\nkill -9 1234 = sends SIGKILL to id 1234<br \/>\n<br \/>\nkill -SIGCONT 1234 = sends SIGCONT to id 1234<br \/>\n<br \/>\nkill 4% = kills the process represented by 4% job<br \/>\n<br \/>\nkill sttd = kills all sttd daemons running<\/p>\n<p>last = last log in details<br \/>\n<br \/>\nlastlog [-u root] = last log in time<br \/>\n<br \/>\nlast [root] = entire log in history, the feature needs to be activated first<br \/>\n<br \/>\nlastb [root] = prints failed login attempts <\/p>\n<p>less filename.txt = prints contents of the file, scroll bar fixed, Press q to quite and spacebar to go to  another page<br \/>\n<br \/>\nless filename.txt = prints contents of the file, scroll bar fixed, press spacebar<br \/>\n<br \/>\nless filename \/word = searches for word  <\/p>\n<p>ln -s originalfile newfile = creates a symbolic link to new file<br \/>\n<br \/>\nlocate xyz = locates file xyz case-sensitive<br \/>\n<br \/>\nlocate -i xyz = locates file xyz not case-sensitive<br \/>\n<br \/>\nlocate -r \/ls$ = locates files ending in \/ls<br \/>\n<br \/>\nlocate -r james*bond = locate files with james and bond in their names<br \/>\n<br \/>\nlocate -r ^ boot\/grub\/me = locate files beginning with boot\/grub\/me<br \/>\n<br \/>\nlocate *.jpg &gt; Desktop\/myjpgs.txt = stores results of search in a file named myjpgs.txt<br \/>\n<br \/>\nlsmod = lists kernel modules installed<br \/>\n<br \/>\nlsmod | sort -k 2,2n = sorts kernel modules in increasing size order<\/p>\n<p>ls \/var\/www\/html\/*.html = lists all html files<br \/>\n<br \/>\nls .??* = lists all directory names that start with a dot .<br \/>\n<br \/>\nls \/etc\/rc.d = prints all directories for all available run levels<br \/>\n<br \/>\nls \/etc\/rc.d\/init.d = list of system services&#8217; scripts<br \/>\n<br \/>\nls -l = lists files and folders in the current directory<br \/>\n<br \/>\nls -la = lists hidden files and folders in the current directory with a dot<br \/>\n<br \/>\nls li = files with their inodes<br \/>\n<br \/>\nls -lt = files recently modified<br \/>\n<br \/>\nls -lu = lists files by their accss time<br \/>\n<br \/>\nls -ln = user names and groups numerically displayed<br \/>\n<br \/>\nls -lh = human readable file sizes<br \/>\n<br \/>\nls -lR = displays all the files and their folders<br \/>\n<br \/>\nls -F = lists files by type<br \/>\n<br \/>\nls -c = lists files columnwise<br \/>\n<br \/>\nls \u2013color =always = shows filenames in colors<\/p>\n<p>ls -l \/var\/lib\/rpm = rpm database<br \/>\n<br \/>\nls = lists contents of a directory<br \/>\n<br \/>\nls . = lists contents of a directory<br \/>\n<br \/>\nls .. = lists contents of a directory<br \/>\n<br \/>\nls \/ = lists all system directories<br \/>\n<br \/>\nls = lists directories in current directory<br \/>\n<br \/>\nls \/var = lists all subdirectories under the \/var directory<br \/>\n<br \/>\nls \/proc | wc -l = number of subdirectories in \/proc directory<br \/>\n<br \/>\nls -ltr =<br \/>\n<br \/>\nls -l filename.ext = checks permissions for a file<br \/>\n<br \/>\nls -l \/etc = permission status of all subdirectories<br \/>\n<br \/>\nls -a = shows hidden . Dot directories. A kind of special configuration files not be messed with<br \/>\n<br \/>\nls tr | &#8216;\\n&#8217; &#8216; &#8216; = replaces all newline characters with spaces<br \/>\n<br \/>\nls tr | -d &#8216;\\n&#8217; = deletes newlines<br \/>\n<br \/>\nls \/var\/lib\/mysql = list of databases in blue color <\/p>\n<p>lsof = list of open directories and files<br \/>\n<br \/>\nlsof -c bash = list of files open by bash shells<br \/>\n<br \/>\nlsof -d cwd  = list of directories open as current working directory<br \/>\n<br \/>\nlsof -u james = list of files and directories open by user james<br \/>\n<br \/>\nlsof \/mnt\/sda1 = list of anything open on \/mnt\/sda1 file system<br \/>\n<br \/>\nlsof +d \/mnt\/sda1\/dx = list of anything open under \/mnt\/sda1\/dx directory<\/p>\n<p>lpadmin = Linux printer details<br \/>\n<br \/>\nlspci = info about pci devices\/ports<br \/>\n<br \/>\nlspci | grep VGA = graphics card info<br \/>\n<br \/>\nlspci | grep audio = audio card info<br \/>\n<br \/>\nlspci | grep -i modem = modem info<br \/>\n<br \/>\nlspci | grep -i usb = usb ports info<br \/>\n<br \/>\nlspci | grep -i ethernet = ethernet card info<\/p>\n<p>man -f php = info about php modules<br \/>\n<br \/>\nman -k php = info about php modules<br \/>\n<br \/>\nman php = php manual pages<br \/>\n<br \/>\nman man = info about manual pages and their format<br \/>\n<br \/>\nman 3 php = shows entries for php in 3rd section of the manual<br \/>\n<br \/>\nman php | grep word = searches for a particular word in php manual<br \/>\n<br \/>\nman hier = info about directories<br \/>\n<br \/>\nmd5sum xyz.iso = checksum verification<br \/>\n<br \/>\nmore filename.txt = shows contents of a file page by page (press spacebar)<br \/>\n<br \/>\nmount = files system type per device<br \/>\n<br \/>\nmount \/mnt\/cdrom = mounts cd rom<br \/>\n<br \/>\nmysql = launches mysql<br \/>\n<br \/>\nmysql -u root -p = asks for a password to launch mysql<br \/>\n<br \/>\nmy old.txt new.txt = renames a file<\/p>\n<p>netstat = info about active Internet connections<br \/>\n<br \/>\nnetstat -i = netstat statictics<br \/>\n<br \/>\nnetstat -tanp = shows active tcp connections<br \/>\n<br \/>\nnetstat -uanp = shows active udp connections<\/p>\n<p>od -c -t x1 filename.txt = list of newline characters in Linux<\/p>\n<p>ogg123 mysong.ogg  = plays ogg file<br \/>\n<br \/>\nogg123 http:\/\/xyz.com\/music\/audio.ogg = plays from web address<br \/>\n<br \/>\nogg123 -z *.ogg = play files in pseudo-random order<br \/>\n<br \/>\nogg123 -Z *.ogg = same -z, but repeats forever<br \/>\n<br \/>\nogg123 \/var\/music\/ = plays songs in \/var\/music and sub dirs<br \/>\n<br \/>\nogg123 -@myplaylist = plays songs from playlist<\/p>\n<p>pgrep httpd = gives process id for httpd<br \/>\n<br \/>\npgrep -l init = gives process id for processes containing init as string<br \/>\n<br \/>\nps -lu james = all processes owned by james<br \/>\n<br \/>\nphp &#8211;help = shows all php help pages in full<br \/>\n<br \/>\nphp &#8211;help | less = shows limited php help pages, scroll bar fixed, q to exit<br \/>\n<br \/>\nphp -v = php version<br \/>\n<br \/>\nphp &#8211;version = php version<br \/>\n<br \/>\npirut =<br \/>\n<br \/>\npasswd = asks for a new password for root<\/p>\n<p>play musicfilename.wav = plays music file<br \/>\n<br \/>\nplay *.wav = plays all wav files upto 32<br \/>\n<br \/>\nplay audio.au vol. 6 = plays audio file with volume level 6<br \/>\n<br \/>\nplay -r 12000 short.aiff = sampling rate of 12000<\/p>\n<p>ps ajfx = process hierarchy in BSD style<br \/>\n<br \/>\nps ax = lists all running processes<br \/>\n<br \/>\nps aux = lists all running processes with BSD cycle<br \/>\n<br \/>\nps auwx = running processes with wide format<br \/>\n<br \/>\nps auwwx = running processes with unlimited width<br \/>\n<br \/>\nps auwx | sort -r -k 4,4 = sort processes on descending memory usage<br \/>\n<br \/>\nps auwx | head -4 = prints first 4 lines of a process<br \/>\n<br \/>\nps auwx | head -n 4 = prints first 4 lines of a process<br \/>\n<br \/>\nps auwx | tail -4 = prints last 4 lines of a process<br \/>\n<br \/>\nps auwx | tail -n 4 = prints last 4 lines of a process<br \/>\n<br \/>\nps auwx | less = shows contents of a process, scroll bar fixed<br \/>\n<br \/>\nps auwx | more = shows contents of a process page by page (press spacebar)<br \/>\n<br \/>\nps auwx | grep init = shows lines containing init in them<br \/>\n<br \/>\nps auwx | grep \u201c\\[*\\]\u201d = shows bracketed comments<br \/>\n<br \/>\nps = list of processes by current user in current shell<br \/>\n<br \/>\nps -C httpd = process info for http<br \/>\n<br \/>\nps -p 5323 -o pid,ppid,bsdtime,args = process info for id 5323<br \/>\n<br \/>\nps -U james,john -o pid,ruser,tty,stat,args = process info for 2 users<br \/>\n<br \/>\nps -e = lists all running processes<br \/>\n<br \/>\nps -e | wc -l = number of all running processes<br \/>\n<br \/>\nps -ef = lists all running processes with format listing<br \/>\n<br \/>\nps -ef \u2013forest = process hierarchy in forest format<br \/>\n<br \/>\nps -eF = lists all running processes with full format listing<br \/>\n<br \/>\nps -ejH = process hierarchy<br \/>\n<br \/>\nps -el = lists all running processes with long listing<br \/>\n<br \/>\nps -eo ppid,user,%mem,size,vsize,comm \u2013sort=-size = multiple parameters<br \/>\n<br \/>\nps -eo ppid,user,bsdstart,bsdtime,%cpu,args \u2013sort=-%cpu = multiple parameters<br \/>\n<br \/>\nps -eo ppid,user,bsdstart,bsdtime,%cpu,args \u2013sort=-%cpu = multiple parameters<br \/>\n<br \/>\nps -eo ppid,user,stat,tname,sess,cputime,args \u2013sort=user = multiple parameters<br \/>\n<br \/>\npstree = processes in alphabetical order in tree format<br \/>\n<br \/>\nps -u root = list of processes run by user root<br \/>\n<br \/>\nps -u root u = list of processes run by root with cpu usage<br \/>\n<br \/>\nps -fu root = list of processes run by root with PPID<br \/>\n<br \/>\npwd = current working directory<br \/>\n<br \/>\npwd -P = one level up from current working directory<br \/>\n<br \/>\npwd -L = one level down from current working directory<\/p>\n<p>printenv | less = prints all environment variables<br \/>\n<br \/>\nps -ef | grep root = processed owned by root<\/p>\n<p>ramsize = info about ram<br \/>\n<br \/>\nreboot = reboots the pc<br \/>\n<br \/>\nredhat-logviewer = opens a GUI tool for log monitoring<br \/>\n<br \/>\nrepoquery -il tomcat5 = list of files in tomcat5 package in any repo<br \/>\n<br \/>\nrepoquery &#8211;provides php = info about php modules<\/p>\n<p>rm ~\/.bash_history = clears history of commands<br \/>\n<br \/>\nrm -f *.doc = removes\/deletes all files of .doc extension in a folder<\/p>\n<p>rpm2cpio xyz.rpm &gt; xyz.cpio = extracts cpio archive from rpm package<br \/>\n<br \/>\nrpm2cpio xyz.rpm | cpio -tv = lists the contents of archive<br \/>\n<br \/>\nrpm -e xyz = removes package xyz<br \/>\n<br \/>\nrpm -e \u2013nodeps xyz-5.6.fc5.i386 = removes 32+ bit version of package if more versions available<br \/>\n<br \/>\nrpm -ivh xyz.rpm = install package xyz  (i=install, v=verbose, h=hash)<br \/>\n<br \/>\nrpm -ivh http:\/\/ftp.abc.com\/xyz.rpm = install package xyz from the site<br \/>\n<br \/>\nrpm -Uvh xyz.rpm = update package xyz (U=update)<br \/>\n<br \/>\nrpm -q &#8211;scripts kernel |less = list of all preinstall &amp; post-install scripts<br \/>\n<br \/>\nrpm -q php = php version no.<br \/>\n<br \/>\nrpm -qi php = php install info<br \/>\n<br \/>\nrpm -qi fedora-release = Fedora installation info<br \/>\n<br \/>\nrpm -qi php\/per\/python\/ruby = version info for the package<br \/>\n<br \/>\nrpm -qa grun = prints grub version no.<br \/>\n<br \/>\nrpm -qa php = prints php version no.<br \/>\n<br \/>\nrpm -qa | sort | pr \u2013column=2 | less = shows installed packages in 2 columns per page<br \/>\n<br \/>\nrpm -qa | sort | pr \u2013column=2 &gt; abc.txt = saves output to a file<br \/>\n<br \/>\nrpm -qa | sort | pr \u2013column=2 | lpr = sends output to a printer<br \/>\n<br \/>\nrpm -qa | grep kernel | sort = sorts installed packages in alphanumeric order<br \/>\n<br \/>\nrpm -qa | grep kernel | sort -r = sorts in reverse alphanumeric order<br \/>\n<br \/>\nrpm -qa | grep php = prints version nos. of all php related packages<br \/>\n<br \/>\nrpm -qa | head = only 10 softwares listed<br \/>\n<br \/>\nrpm -qa | head -n5 = first 5 software listed<br \/>\n<br \/>\nrpm -qa | wc -l = total no of packages installed on the system<br \/>\n<br \/>\nrpm -ql php = lists all files in a particular package<br \/>\n<br \/>\nrpm -qal | grep php = find php in all installed packages<br \/>\n<br \/>\nrpm -ql php | wc -l = total no. of files in a particular package<br \/>\n<br \/>\nrpm -qa | grep php | wc -l = count the total number of php modules<br \/>\n<br \/>\nrpm -qf \/var\/lib\/php = what package a particular file belongs to<br \/>\n<br \/>\nrpm -q &#8211;scripts mysql = scripts of a package<br \/>\n<br \/>\nrpm -qa php | wc -l = total no. of php packages<br \/>\n<br \/>\nrpm -qi php = info about php<br \/>\n<br \/>\nrpm -q \u2013last php = installation date of php<br \/>\n<br \/>\nrpm -qi php | grep -i vendor = php vendor name<br \/>\n<br \/>\nrpm -qi fedora-release | grep -i vendor = prints vendor name from a file named fedora-release<br \/>\n<br \/>\nrpm -v = rpm version<\/p>\n<p>rpm -qa &#8211;queryformat &#8216;%{NAME}==%{VENDOR}\\n&#8217; | grep -v &#8220;Red Hat&#8221; | sort =<br \/>\n list of installed packages with their vendor names except Red Hat<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{VENDOR}\\n&#8217; | grep &#8220;Red Hat&#8221; | sort = list of installed packages with their vendor name as Red Hat<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{VENDOR}\\n&#8217; | sort = list of installed packages with their vendor names<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{VENDOR}\\n&#8217; | grep  &#8220;Red Hat&#8221; | wc -l = total number of installed packages with Red Hat as their vendor <\/p>\n<p>rpm -qa &#8211;qf &#8216;%{NAME}==%{LICENSE}\\n&#8217; | sort = list of all installed packages with their licence type sorted alphabetically<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{LICENSE}\\n&#8217; | wc -l = total number of installed packages with their licence type<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{LICENSE}\\n&#8217; | grep php | sort = list of all php packages with their licence types sorted alphabetically<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{LICENSE}\\n&#8217; | grep php | wc -l = total number of all php packages with their licence types<\/p>\n<p>rpm -qa &#8211;qf &#8216;%{NAME}==%{SIZE}\\n&#8217; | sort = list of all installed<br \/>\npackages with their names and sizes in bytes sorted alphabetically<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{SIZE}\\n&#8217; | grep php | sort = list of all php<br \/>\npackages with their names and sizes in bytes sorted alphabetically<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{SIZE}\\n&#8217; | grep php | wc -l = total number of<br \/>\ninstalled php packages with their names and sizes in bytes <\/p>\n<p>rpm -qa &#8211;qf &#8216;%{NAME}==%{SUMMARY}\\n&#8217; | sort = list of all installed<br \/>\npackages with their names and functions sorted alphabetically<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{SUMMARY}\\n&#8217; | grep php | sort = list of all php<br \/>\n packages with their names and functions sorted alphabetically<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{SUMMARY}\\n&#8217; | grep php | wc -l = total number of all php packages with their names and functions<\/p>\n<p>rpm -qa &#8211;qf &#8216;%{NAME}==%{BUILDHOST}\\n&#8217; | sort = list of all installed<br \/>\npackages with their names and buildhosts sorted alphabetically<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{BUILDHOST}\\n&#8217; | grep php | sort = list of all<br \/>\nphp packages with their names and buildhosts sorted alphabetically<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{BUILDHOST}\\n&#8217; | grep php | wc -l = total number of all php packages with their names and buildhosts<\/p>\n<p>rpm -qa &#8211;qf &#8216;%{NAME}==%{URL}\\n&#8217; | sort = list of all installed packages with their names and urls sorted alphabetically<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{URL}\\n&#8217; | grep php | sort = list of all php packages with their names and urls sorted alphabetically<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{URL}\\n&#8217; | grep php | wc -l = total number of all php packages with their names and urls<\/p>\n<p>rpm -qa &#8211;qf &#8216;%{NAME}==%{ARCH}\\n&#8217; | sort = list of all installed<br \/>\npackages with their names and architecture type sorted alphabetically<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{ARCH}\\n&#8217; | grep php | sort = list of all php<br \/>\npackages with their names and architecture type sorted alphabetically<br \/>\n<br \/>\nrpm -qa &#8211;qf &#8216;%{NAME}==%{ARCH}\\n&#8217; | grep php | wc -l = total number of all php packages with their names and  architecture type<\/p>\n<p>rpm \u2013querytags = list of all rpm query tags<br \/>\n<br \/>\nrpm \u2013querytags | wc -l = total number of rpm tags<br \/>\n<br \/>\nrpm -Va = verify all installed packages<br \/>\n<br \/>\nrpm -Va | grep php = verify php packages only<br \/>\n<br \/>\nrpm -Vv | grep php = check php packages only with verbose<\/p>\n<p>root = superuser, who has permission to do anything<br \/>\n<br \/>\n\/root = root account&#8217;s home directory<\/p>\n<p>sha1sum xyz.iso = checksum verification<br \/>\n<br \/>\nstat filename = prints access\/modification right to a file<br \/>\n<br \/>\nset = list of all enviornmental variables<br \/>\n<br \/>\nset | wc -l = total number of enviornmental variables<br \/>\n<br \/>\nset history = 60 = history of commands set to 60<br \/>\n<br \/>\nset | less = prints all shell variables, scroll bar fixed<\/p>\n<p>setserial -g \/dev\/ttys0 \/dev\/ttys1 \/dev\/ttys2 \/dev\/tty3 = info about serial ports<br \/>\n<br \/>\nsetserial -ga  \/dev\/ttys0 = info about one serial port<br \/>\n<br \/>\nstty -F \/dev\/ttys0 -a = info about serial port<\/p>\n<p>service httpd start = starts apache server<br \/>\n<br \/>\nservice mysqld start = starts mysql server<br \/>\n<br \/>\nservice &#8211;status-all = service status of all the services installed<\/p>\n<p>shutdown = shutdowns the pc<br \/>\n<br \/>\nshutdown -r = reboot<br \/>\n<br \/>\nshutdown -0 (Zero) = reboot<br \/>\n<br \/>\nshutdown \u2013 h = halt<br \/><\/p>\n","protected":false},"excerpt":{"rendered":"<p>dvdrecord -scanbus = lists dvd devices df -h = free hard drive space df = free hard drive space du -sh = disk usage du -h = hard drive usage dialog \u2013msgbox \u201cHello\u201d 8 12 = create dialog box dialog \u2013title \u201cCheck me\u201d &#8211;checklist \u201cPick numbers\u201d 12 15 2 1 \u201cFirst\u201d \u201con\u201d 2 \u201cSecond\u201d \u201coff\u201d [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[35],"tags":[],"class_list":["post-1825","post","type-post","status-publish","format-standard","hentry","category-about-knowledge-os_linux"],"_links":{"self":[{"href":"http:\/\/www.msinterdev.org\/wp\/wp-json\/wp\/v2\/posts\/1825","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.msinterdev.org\/wp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.msinterdev.org\/wp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.msinterdev.org\/wp\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.msinterdev.org\/wp\/wp-json\/wp\/v2\/comments?post=1825"}],"version-history":[{"count":0,"href":"http:\/\/www.msinterdev.org\/wp\/wp-json\/wp\/v2\/posts\/1825\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.msinterdev.org\/wp\/wp-json\/wp\/v2\/media?parent=1825"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.msinterdev.org\/wp\/wp-json\/wp\/v2\/categories?post=1825"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.msinterdev.org\/wp\/wp-json\/wp\/v2\/tags?post=1825"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}