Update linux.md
This commit is contained in:
parent
e21dcf1028
commit
caa337d5ea
21
linux.md
21
linux.md
|
@ -14,21 +14,18 @@ title: Linux
|
||||||
|
|
||||||
### Display the amount of available disk space
|
### Display the amount of available disk space
|
||||||
|
|
||||||
$ df
|
```sh
|
||||||
|
df
|
||||||
All File System:
|
df -h # human-readable format
|
||||||
|
df -a # all filesystems
|
||||||
$ df -a
|
```
|
||||||
|
|
||||||
Human Readable Format:
|
|
||||||
|
|
||||||
$ df -h
|
|
||||||
|
|
||||||
### Display disk usage
|
### Display disk usage
|
||||||
|
|
||||||
Largest 10 folder/file in the current directory:
|
```sh
|
||||||
|
du
|
||||||
$ du -hsx * | sort -rh | head -10
|
du -hsx * | sort -rh | head -10 # largest 10 folders
|
||||||
|
```
|
||||||
|
|
||||||
### Answer yes in a bash script
|
### Answer yes in a bash script
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue