1. Use the df command to view the overall disk usage The df command is used to view the mount point of the hard disk and the corresponding hard disk capacity information. Including the total size of the hard disk, the size already used, and the remaining size. And the percentage of space used, etc. The most commonly used command format is: df -h Or use: df -lh Output: Filesystem refers to the hardware device files on the system, and Size refers to the total size of the hard disk or partition. Used indicates the size that has been used, and Avail indicates the size that can be used. Use% indicates the percentage of used space. The final "mounted on" indicates the directory where the hard disk is mounted. Description: Parameters that can be added after the df command ● -a: List all file systems, including system-specific file systems such as /proc ● -k: Display the capacity of each file system in KB ● -m: Display the capacity of each file system in MB ● -h: Display in GB, MB, KB format which is easier for people to read ● -H: Replace M=1024K with M=1000K ● -T: Display the file system type ● -i: Display the number of inodes instead of the hard disk capacity ● -l: only display the file system of the local machine 2. Use the du command to view the usage of the specified directory Use the du command to view the directory or file information inside the hard disk. The du command usually needs to be executed with parameters at the end. The general format is: du option File/directory For example, if I want to check the capacity of the python3 directory in the current directory, the command is: du -sh python3 The result is shown in the figure below. You can intuitively see that the size of this directory is 206M. If there is no file name or directory name behind it, the size of the current directory will be displayed. You may also be interested in:
|
<<: CocosCreator ScrollView optimization series: frame loading
>>: Solution to the problem that the MySQL database cannot be accessed by other IP addresses
Preface Using Docker and VS Code can optimize the...
Server Information Management server: m01 172.16....
Table of contents What is MySQL NDB Cluster Preli...
1. Nginx status monitoring Nginx provides a built...
This technique comes from this article - How to a...
*Create a page: two input boxes and a button *Cod...
Jenkins configuration of user role permissions re...
Table of contents 1. Vue2 syntax 2. Use of Vue3 1...
When doing web development, you may encounter the...
Deleting a table is not very common, especially f...
Let me first introduce to you that the node proce...
background Temporary tablespaces are used to mana...
MySQL 5.7.27 detailed download, installation and ...
This article shares the installation and configur...
Configure Java environment variables Here, the en...