Linux Directory and disk usage related commands



1) Given below command gives a list of files and directories in a long listing (even hidden 
files will be displayed), human readable sizes, KB, MB. Also sorted by time (-t) and 
in reverse order (-r) i.e. Newest in the end of listing.


[root@badar /]# ls -l -h -a -t -r


2) Given below command captures lines showing directories only page by page, to check 
for files use ^f. (This ^ d or ^f is NOT ctrl-d or ctrl-f)


[root@badar /]# ls -l | grep “^d” | less 


3) To check for free space on your partitions:


[root@badar /]# df -h


4) To check for the used space by a particular directory:


[root@badar /]# du –c –h /home/shaheer
or 
[root@badar /]# du –s –h /home/shaheer



Comments

Popular posts from this blog

What is Oracle Integration Cloud Service - ICS?

How to Create Packages in Oracle Database using TOAD for Oracle

How to create a Simple Scheduler Job in Oracle Database using Toad