In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/01 Report--
Today, I will talk to you about Linux to view the size of the hard disk command is what, many people may not know, in order to let you know more, Xiaobian summarized the following content for you, I hope you can harvest according to this article.
Command to view hard disk size
The df -hdf command can get information about how much space is being used on the hard disk, how much space is left, etc. It can also show how all file systems are using i nodes and disk blocks.
Df command is linux system to disk partition as a unit to view the file system, you can add parameters to view the remaining disk space information, command format: df -hl
Display format is:
File System Capacity Used Available % Mount Points Used
Filesystem Size Used Avail Use% Mounted on
/dev/hda2 45G 19G 24G 44% /
/dev/hda1 494M 19M 450M 4% /boot
/dev/hda6 4.9G 2.2G 2.5G 47% /home
/dev/hda5 9.7G 2.9G 6.4G 31% /opt
none 1009M 0 1009M 0% /dev/shm
/dev/hda3 9.7G 7.2G 2.1G 78% /usr/local
/dev/hdb2 75G 75G 0 100% /
/dev/hdb2 75G 75G 0 100% /
Take the output above as an example, which means:
The second hard disk (b) of the HD hard disk interface, the second partition (2), the capacity is 75 GB, the use of 75 GB, the availability is 0, so the utilization rate is 100%, mounted to the root partition directory (/).
Interpretation of relevant commands
df -hl View the remaining disk space df -h View the partition size of each root path du -sh [directory name] Return the size of the directory du -sm [folder] Return the total M number of folders du -h [directory name] View all file sizes under a specified folder (including subfolders) More features can be viewed by entering a command:
df --help``du --help Other functions
View partitions on hard disk #sudo fdisk -l
#sudo hdparm -i /dev/hda
#sudo hdparm -I /dev/sda or #sudo apt-get install blktool #sudo blktool /dev/sda id
View free hard drive space #df -h #df -H
View directory footprint #du -hs directory name
After reading the above, do you have any further understanding of what the Linux command to check the size of your hard drive is? If you still want to know more knowledge or related content, please pay attention to the industry information channel, thank you for your support.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.