본문 바로가기
OldStory/리눅스

Folder의 크기를 알아내는 명령

by Alnilam 2009. 1. 22.

[kscho@devel0 api]$ du –help
사용법: du [<옵션>]… [<파일>]…
Summarize disk usage of each FILE, recursively for directories.

긴 옵션에서 꼭 필요한 인수는 짧은 옵션에도 꼭 필요합니다.
  -a, –all             write counts for all files, not just directories
  -B, –block-size=SIZE use SIZE-byte blocks
  -b, –bytes           print size in bytes
  -c, –total           produce a grand total
  -D, –dereference-args  dereference FILEs that are symbolic links
  -h, –human-readable  print sizes in human readable format (e.g., 1K 234M 2G)
  -H, –si              likewise, but use powers of 1000 not 1024
  -k                    like –block-size=1K
  -l, –count-links     count sizes many times if hard linked
  -L, –dereference     dereference all symbolic links
  -S, –separate-dirs   do not include size of subdirectories
  -s, –summarize       display only a total for each argument
  -x, –one-file-system  skip directories on different filesystems
  -X FILE, –exclude-from=FILE  Exclude files that match any pattern in FILE.
      –exclude=PATTERN Exclude files that match PATTERN.
      –max-depth=N     print the total for a directory (or file, with –all)
                          only if it is N or fewer levels below the command
                          line argument;  –max-depth=0 is the same as
                          –summarize
      –help     이 도움말을 표시하고 끝냅니다
      –version  버전 정보를 출력하고 끝냅니다

SIZE may be (or may be an integer optionally followed by) one of following:
kB 1000, K 1024, MB 1,000,000, M 1,048,576, and so on for G, T, P, E, Z, Y.

[kscho@devel0 workspace]$ du -hs temp/
14M     temp
[kscho@devel0 workspace]$

'OldStory > 리눅스' 카테고리의 다른 글

Change IP  (0) 2009.02.06
How To Find Your Ubuntu or Kernel Version  (0) 2009.02.05
Home – Embed Cooliris  (0) 2009.02.05
Top Menubar  (0) 2009.02.04
Home Linux 설치  (0) 2009.02.04