国产 无码 综合区,色欲AV无码国产永久播放,无码天堂亚洲国产AV,国产日韩欧美女同一区二区

Linux查看磁盤、文件系統(tǒng)、文件夾、文件大小的命令(lsblk、df、du、ll)

這篇具有很好參考價(jià)值的文章主要介紹了Linux查看磁盤、文件系統(tǒng)、文件夾、文件大小的命令(lsblk、df、du、ll)。希望對(duì)大家有所幫助。如果存在錯(cuò)誤或未考慮完全的地方,請(qǐng)大家不吝賜教,您也可以點(diǎn)擊"舉報(bào)違法"按鈕提交疑問。

記錄:325

場(chǎng)景:在CentOS 7.9操作系統(tǒng)上,使用lsblk命令查看磁盤大小和磁盤掛載情況;使用df查看文件系統(tǒng)大小和掛載情況;使用du命令查看文件夾(目錄)大??;使用ll和ls查看文件大小。

版本:

操作系統(tǒng):CentOS 7.9

1.lsblk常用命令

(1)幫助命令

命令:lsblk --help

功能:查看lsblk支持全部命令和選項(xiàng),在實(shí)際工作中,查看這個(gè)手冊(cè)應(yīng)該是必備之選。

(2)查看磁盤大小

命令:lsblk

命令:lsblk -a

功能:查看掛載磁盤信息,磁盤名稱、大小、掛載目錄等。

Linux查看磁盤、文件系統(tǒng)、文件夾、文件大小的命令(lsblk、df、du、ll)

(2)查看磁盤文件系統(tǒng)信息

命令:lsblk -f

功能:查看掛載磁盤信息,磁盤名稱、文件系統(tǒng)類型、UUID、掛載目錄等。

Linux查看磁盤、文件系統(tǒng)、文件夾、文件大小的命令(lsblk、df、du、ll)

2.df常用命令

(1)幫助命令

命令:df --help

功能:查看df支持全部命令和選項(xiàng),在實(shí)際工作中,查看這個(gè)手冊(cè)應(yīng)該是必備之選。

(2)查看文件系統(tǒng)大小

命令:df -h

功能:查看文件系統(tǒng)信息,文件系統(tǒng)總?cè)萘?、已用容量、可用容量、掛載目錄等。

Linux查看磁盤、文件系統(tǒng)、文件夾、文件大小的命令(lsblk、df、du、ll)

3.du常用命令

(1)幫助命令

命令:du --help

功能:查看du支持全部命令和選項(xiàng),在實(shí)際工作中,查看這個(gè)手冊(cè)應(yīng)該是必備之選。

(2)查看文件夾(目錄)大小

命令:du -h

功能:查看文件夾(目錄)大小。

Linux查看磁盤、文件系統(tǒng)、文件夾、文件大小的命令(lsblk、df、du、ll)

4.ll常用命令

(1)幫助命令

命令:ll --help

功能:查看ll支持全部命令和選項(xiàng),在實(shí)際工作中,查看這個(gè)手冊(cè)應(yīng)該是必備之選。

(2)查看文件夾(目錄)大小

命令:ll -h

功能:查看文件大小。

Linux查看磁盤、文件系統(tǒng)、文件夾、文件大小的命令(lsblk、df、du、ll)

5.ls常用命令

(1)幫助命令

命令:ls --help

功能:查看ls支持全部命令和選項(xiàng),在實(shí)際工作中,查看這個(gè)手冊(cè)應(yīng)該是必備之選。

(2)查看文件夾(目錄)大小

命令:ls -lh

功能:查看文件大小。

Linux查看磁盤、文件系統(tǒng)、文件夾、文件大小的命令(lsblk、df、du、ll)

6.命令和選項(xiàng)

6.1 lsblk命令

執(zhí)行命令:lsblk --help,查看詳細(xì)幫助手冊(cè)。

Usage:
 lsblk [options] [<device> ...]

Options:
 -a, --all            print all devices
 -b, --bytes          print SIZE in bytes rather than in human readable format
 -d, --nodeps         don't print slaves or holders
 -D, --discard        print discard capabilities
 -e, --exclude <list> exclude devices by major number (default: RAM disks)
 -I, --include <list> show only devices with specified major numbers
 -f, --fs             output info about filesystems
 -h, --help           usage information (this)
 -i, --ascii          use ascii characters only
 -m, --perms          output info about permissions
 -l, --list           use list format output
 -n, --noheadings     don't print headings
 -o, --output <list>  output columns
 -p, --paths          print complate device path
 -P, --pairs          use key="value" output format
 -r, --raw            use raw output format
 -s, --inverse        inverse dependencies
 -t, --topology       output info about topology
 -S, --scsi           output info about SCSI devices

 -h, --help     display this help and exit
 -V, --version  output version information and exit

Available columns (for --output):
        NAME  device name
       KNAME  internal kernel device name
     MAJ:MIN  major:minor device number
      FSTYPE  filesystem type
  MOUNTPOINT  where the device is mounted
       LABEL  filesystem LABEL
        UUID  filesystem UUID
   PARTLABEL  partition LABEL
    PARTUUID  partition UUID
          RA  read-ahead of the device
          RO  read-only device
          RM  removable device
       MODEL  device identifier
      SERIAL  disk serial number
        SIZE  size of the device
       STATE  state of the device
       OWNER  user name
       GROUP  group name
        MODE  device node permissions
   ALIGNMENT  alignment offset
      MIN-IO  minimum I/O size
      OPT-IO  optimal I/O size
     PHY-SEC  physical sector size
     LOG-SEC  logical sector size
        ROTA  rotational device
       SCHED  I/O scheduler name
     RQ-SIZE  request queue size
        TYPE  device type
    DISC-ALN  discard alignment offset
   DISC-GRAN  discard granularity
    DISC-MAX  discard max bytes
   DISC-ZERO  discard zeroes data
       WSAME  write same max bytes
         WWN  unique storage identifier
        RAND  adds randomness
      PKNAME  internal parent kernel device name
        HCTL  Host:Channel:Target:Lun for SCSI
        TRAN  device transport type
         REV  device revision
      VENDOR  device vendor

For more details see lsblk(8).

6.2 df命令

執(zhí)行命令:df --help,查看詳細(xì)幫助手冊(cè)。

Usage: df [OPTION]... [FILE]...
Show information about the file system on which each FILE resides,
or all file systems by default.

Mandatory arguments to long options are mandatory for short options too.
  -a, --all             include pseudo, duplicate, inaccessible file systems
  -B, --block-size=SIZE  scale sizes by SIZE before printing them; e.g.,
                           '-BM' prints sizes in units of 1,048,576 bytes;
                           see SIZE format below
      --direct          show statistics for a file instead of mount point
      --total           produce a grand total
  -h, --human-readable  print sizes in human readable format (e.g., 1K 234M 2G)
  -H, --si              likewise, but use powers of 1000 not 1024
  -i, --inodes          list inode information instead of block usage
  -k                    like --block-size=1K
  -l, --local           limit listing to local file systems
      --no-sync         do not invoke sync before getting usage info (default)
      --output[=FIELD_LIST]  use the output format defined by FIELD_LIST,
                               or print all fields if FIELD_LIST is omitted.
  -P, --portability     use the POSIX output format
      --sync            invoke sync before getting usage info
  -t, --type=TYPE       limit listing to file systems of type TYPE
  -T, --print-type      print file system type
  -x, --exclude-type=TYPE   limit listing to file systems not of type TYPE
  -v                    (ignored)
      --help     display this help and exit
      --version  output version information and exit

Display values are in units of the first available SIZE from --block-size,
and the DF_BLOCK_SIZE, BLOCK_SIZE and BLOCKSIZE environment variables.
Otherwise, units default to 1024 bytes (or 512 if POSIXLY_CORRECT is set).

SIZE is an integer and optional unit (example: 10M is 10*1024*1024).  Units
are K, M, G, T, P, E, Z, Y (powers of 1024) or KB, MB, ... (powers of 1000).

FIELD_LIST is a comma-separated list of columns to be included.  Valid
field names are: 'source', 'fstype', 'itotal', 'iused', 'iavail', 'ipcent',
'size', 'used', 'avail', 'pcent', 'file' and 'target' (see info page).

GNU coreutils online help: <http://www.gnu.org/software/coreutils/>
For complete documentation, run: info coreutils 'df invocation'

6.3 du命令

執(zhí)行命令:du --help,查看詳細(xì)幫助手冊(cè)。

Usage: du [OPTION]... [FILE]...
  or:  du [OPTION]... --files0-from=F
Summarize disk usage of each FILE, recursively for directories.

Mandatory arguments to long options are mandatory for short options too.
  -0, --null            end each output line with 0 byte rather than newline
  -a, --all             write counts for all files, not just directories
      --apparent-size   print apparent sizes, rather than disk usage; although
                          the apparent size is usually smaller, it may be
                          larger due to holes in ('sparse') files, internal
                          fragmentation, indirect blocks, and the like
  -B, --block-size=SIZE  scale sizes by SIZE before printing them; e.g.,
                           '-BM' prints sizes in units of 1,048,576 bytes;
                           see SIZE format below
  -b, --bytes           equivalent to '--apparent-size --block-size=1'
  -c, --total           produce a grand total
  -D, --dereference-args  dereference only symlinks that are listed on the
                          command line
  -d, --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
      --files0-from=F   summarize disk usage of the
                          NUL-terminated file names specified in file F;
                          if F is -, then read names from standard input
  -H                    equivalent to --dereference-args (-D)
  -h, --human-readable  print sizes in human readable format (e.g., 1K 234M 2G)
      --inodes          list inode usage information instead of block usage
  -k                    like --block-size=1K
  -L, --dereference     dereference all symbolic links
  -l, --count-links     count sizes many times if hard linked
  -m                    like --block-size=1M
  -P, --no-dereference  don't follow any symbolic links (this is the default)
  -S, --separate-dirs   for directories do not include size of subdirectories
      --si              like -h, but use powers of 1000 not 1024
  -s, --summarize       display only a total for each argument
  -t, --threshold=SIZE  exclude entries smaller than SIZE if positive,
                          or entries greater than SIZE if negative
      --time            show time of the last modification of any file in the
                          directory, or any of its subdirectories
      --time=WORD       show time as WORD instead of modification time:
                          atime, access, use, ctime or status
      --time-style=STYLE  show times using STYLE, which can be:
                            full-iso, long-iso, iso, or +FORMAT;
                            FORMAT is interpreted like in 'date'
  -X, --exclude-from=FILE  exclude files that match any pattern in FILE
      --exclude=PATTERN    exclude files that match PATTERN
  -x, --one-file-system    skip directories on different file systems
      --help     display this help and exit
      --version  output version information and exit

Display values are in units of the first available SIZE from --block-size,
and the DU_BLOCK_SIZE, BLOCK_SIZE and BLOCKSIZE environment variables.
Otherwise, units default to 1024 bytes (or 512 if POSIXLY_CORRECT is set).

SIZE is an integer and optional unit (example: 10M is 10*1024*1024).  Units
are K, M, G, T, P, E, Z, Y (powers of 1024) or KB, MB, ... (powers of 1000).

GNU coreutils online help: <http://www.gnu.org/software/coreutils/>
For complete documentation, run: info coreutils 'du invocation'

6.4 ll命令

執(zhí)行命令:ll --help,查看詳細(xì)幫助手冊(cè)。

Usage: ls [OPTION]... [FILE]...
List information about the FILEs (the current directory by default).
Sort entries alphabetically if none of -cftuvSUX nor --sort is specified.

Mandatory arguments to long options are mandatory for short options too.
  -a, --all                  do not ignore entries starting with .
  -A, --almost-all           do not list implied . and ..
      --author               with -l, print the author of each file
  -b, --escape               print C-style escapes for nongraphic characters
      --block-size=SIZE      scale sizes by SIZE before printing them; e.g.,
                               '--block-size=M' prints sizes in units of
                               1,048,576 bytes; see SIZE format below
  -B, --ignore-backups       do not list implied entries ending with ~
  -c                         with -lt: sort by, and show, ctime (time of last
                               modification of file status information);
                               with -l: show ctime and sort by name;
                               otherwise: sort by ctime, newest first
  -C                         list entries by columns
      --color[=WHEN]         colorize the output; WHEN can be 'never', 'auto',
                               or 'always' (the default); more info below
  -d, --directory            list directories themselves, not their contents
  -D, --dired                generate output designed for Emacs' dired mode
  -f                         do not sort, enable -aU, disable -ls --color
  -F, --classify             append indicator (one of */=>@|) to entries
      --file-type            likewise, except do not append '*'
      --format=WORD          across -x, commas -m, horizontal -x, long -l,
                               single-column -1, verbose -l, vertical -C
      --full-time            like -l --time-style=full-iso
  -g                         like -l, but do not list owner
      --group-directories-first
                             group directories before files;
                               can be augmented with a --sort option, but any
                               use of --sort=none (-U) disables grouping
  -G, --no-group             in a long listing, don't print group names
  -h, --human-readable       with -l, print sizes in human readable format
                               (e.g., 1K 234M 2G)
      --si                   likewise, but use powers of 1000 not 1024
  -H, --dereference-command-line
                             follow symbolic links listed on the command line
      --dereference-command-line-symlink-to-dir
                             follow each command line symbolic link
                               that points to a directory
      --hide=PATTERN         do not list implied entries matching shell PATTERN
                               (overridden by -a or -A)
      --indicator-style=WORD  append indicator with style WORD to entry names:
                               none (default), slash (-p),
                               file-type (--file-type), classify (-F)
  -i, --inode                print the index number of each file
  -I, --ignore=PATTERN       do not list implied entries matching shell PATTERN
  -k, --kibibytes            default to 1024-byte blocks for disk usage
  -l                         use a long listing format
  -L, --dereference          when showing file information for a symbolic
                               link, show information for the file the link
                               references rather than for the link itself
  -m                         fill width with a comma separated list of entries
  -n, --numeric-uid-gid      like -l, but list numeric user and group IDs
  -N, --literal              print raw entry names (don't treat e.g. control
                               characters specially)
  -o                         like -l, but do not list group information
  -p, --indicator-style=slash
                             append / indicator to directories
  -q, --hide-control-chars   print ? instead of nongraphic characters
      --show-control-chars   show nongraphic characters as-is (the default,
                               unless program is 'ls' and output is a terminal)
  -Q, --quote-name           enclose entry names in double quotes
      --quoting-style=WORD   use quoting style WORD for entry names:
                               literal, locale, shell, shell-always, c, escape
  -r, --reverse              reverse order while sorting
  -R, --recursive            list subdirectories recursively
  -s, --size                 print the allocated size of each file, in blocks
  -S                         sort by file size
      --sort=WORD            sort by WORD instead of name: none (-U), size (-S),
                               time (-t), version (-v), extension (-X)
      --time=WORD            with -l, show time as WORD instead of default
                               modification time: atime or access or use (-u)
                               ctime or status (-c); also use specified time
                               as sort key if --sort=time
      --time-style=STYLE     with -l, show times using style STYLE:
                               full-iso, long-iso, iso, locale, or +FORMAT;
                               FORMAT is interpreted like in 'date'; if FORMAT
                               is FORMAT1<newline>FORMAT2, then FORMAT1 applies
                               to non-recent files and FORMAT2 to recent files;
                               if STYLE is prefixed with 'posix-', STYLE
                               takes effect only outside the POSIX locale
  -t                         sort by modification time, newest first
  -T, --tabsize=COLS         assume tab stops at each COLS instead of 8
  -u                         with -lt: sort by, and show, access time;
                               with -l: show access time and sort by name;
                               otherwise: sort by access time
  -U                         do not sort; list entries in directory order
  -v                         natural sort of (version) numbers within text
  -w, --width=COLS           assume screen width instead of current value
  -x                         list entries by lines instead of by columns
  -X                         sort alphabetically by entry extension
  -1                         list one file per line

SELinux options:

  --lcontext                 Display security context.   Enable -l. Lines
                             will probably be too wide for most displays.
  -Z, --context              Display security context so it fits on most
                             displays.  Displays only mode, user, group,
                             security context and file name.
  --scontext                 Display only security context and file name.
      --help     display this help and exit
      --version  output version information and exit

SIZE is an integer and optional unit (example: 10M is 10*1024*1024).  Units
are K, M, G, T, P, E, Z, Y (powers of 1024) or KB, MB, ... (powers of 1000).

Using color to distinguish file types is disabled both by default and
with --color=never.  With --color=auto, ls emits color codes only when
standard output is connected to a terminal.  The LS_COLORS environment
variable can change the settings.  Use the dircolors command to set it.

Exit status:
 0  if OK,
 1  if minor problems (e.g., cannot access subdirectory),
 2  if serious trouble (e.g., cannot access command-line argument).

GNU coreutils online help: <http://www.gnu.org/software/coreutils/>
For complete documentation, run: info coreutils 'ls invocation'

6.5 ls命令

執(zhí)行命令:ls --help,查看詳細(xì)幫助手冊(cè)。

Usage: ls [OPTION]... [FILE]...
List information about the FILEs (the current directory by default).
Sort entries alphabetically if none of -cftuvSUX nor --sort is specified.

Mandatory arguments to long options are mandatory for short options too.
  -a, --all                  do not ignore entries starting with .
  -A, --almost-all           do not list implied . and ..
      --author               with -l, print the author of each file
  -b, --escape               print C-style escapes for nongraphic characters
      --block-size=SIZE      scale sizes by SIZE before printing them; e.g.,
                               '--block-size=M' prints sizes in units of
                               1,048,576 bytes; see SIZE format below
  -B, --ignore-backups       do not list implied entries ending with ~
  -c                         with -lt: sort by, and show, ctime (time of last
                               modification of file status information);
                               with -l: show ctime and sort by name;
                               otherwise: sort by ctime, newest first
  -C                         list entries by columns
      --color[=WHEN]         colorize the output; WHEN can be 'never', 'auto',
                               or 'always' (the default); more info below
  -d, --directory            list directories themselves, not their contents
  -D, --dired                generate output designed for Emacs' dired mode
  -f                         do not sort, enable -aU, disable -ls --color
  -F, --classify             append indicator (one of */=>@|) to entries
      --file-type            likewise, except do not append '*'
      --format=WORD          across -x, commas -m, horizontal -x, long -l,
                               single-column -1, verbose -l, vertical -C
      --full-time            like -l --time-style=full-iso
  -g                         like -l, but do not list owner
      --group-directories-first
                             group directories before files;
                               can be augmented with a --sort option, but any
                               use of --sort=none (-U) disables grouping
  -G, --no-group             in a long listing, don't print group names
  -h, --human-readable       with -l, print sizes in human readable format
                               (e.g., 1K 234M 2G)
      --si                   likewise, but use powers of 1000 not 1024
  -H, --dereference-command-line
                             follow symbolic links listed on the command line
      --dereference-command-line-symlink-to-dir
                             follow each command line symbolic link
                               that points to a directory
      --hide=PATTERN         do not list implied entries matching shell PATTERN
                               (overridden by -a or -A)
      --indicator-style=WORD  append indicator with style WORD to entry names:
                               none (default), slash (-p),
                               file-type (--file-type), classify (-F)
  -i, --inode                print the index number of each file
  -I, --ignore=PATTERN       do not list implied entries matching shell PATTERN
  -k, --kibibytes            default to 1024-byte blocks for disk usage
  -l                         use a long listing format
  -L, --dereference          when showing file information for a symbolic
                               link, show information for the file the link
                               references rather than for the link itself
  -m                         fill width with a comma separated list of entries
  -n, --numeric-uid-gid      like -l, but list numeric user and group IDs
  -N, --literal              print raw entry names (don't treat e.g. control
                               characters specially)
  -o                         like -l, but do not list group information
  -p, --indicator-style=slash
                             append / indicator to directories
  -q, --hide-control-chars   print ? instead of nongraphic characters
      --show-control-chars   show nongraphic characters as-is (the default,
                               unless program is 'ls' and output is a terminal)
  -Q, --quote-name           enclose entry names in double quotes
      --quoting-style=WORD   use quoting style WORD for entry names:
                               literal, locale, shell, shell-always, c, escape
  -r, --reverse              reverse order while sorting
  -R, --recursive            list subdirectories recursively
  -s, --size                 print the allocated size of each file, in blocks
  -S                         sort by file size
      --sort=WORD            sort by WORD instead of name: none (-U), size (-S),
                               time (-t), version (-v), extension (-X)
      --time=WORD            with -l, show time as WORD instead of default
                               modification time: atime or access or use (-u)
                               ctime or status (-c); also use specified time
                               as sort key if --sort=time
      --time-style=STYLE     with -l, show times using style STYLE:
                               full-iso, long-iso, iso, locale, or +FORMAT;
                               FORMAT is interpreted like in 'date'; if FORMAT
                               is FORMAT1<newline>FORMAT2, then FORMAT1 applies
                               to non-recent files and FORMAT2 to recent files;
                               if STYLE is prefixed with 'posix-', STYLE
                               takes effect only outside the POSIX locale
  -t                         sort by modification time, newest first
  -T, --tabsize=COLS         assume tab stops at each COLS instead of 8
  -u                         with -lt: sort by, and show, access time;
                               with -l: show access time and sort by name;
                               otherwise: sort by access time
  -U                         do not sort; list entries in directory order
  -v                         natural sort of (version) numbers within text
  -w, --width=COLS           assume screen width instead of current value
  -x                         list entries by lines instead of by columns
  -X                         sort alphabetically by entry extension
  -1                         list one file per line

SELinux options:

  --lcontext                 Display security context.   Enable -l. Lines
                             will probably be too wide for most displays.
  -Z, --context              Display security context so it fits on most
                             displays.  Displays only mode, user, group,
                             security context and file name.
  --scontext                 Display only security context and file name.
      --help     display this help and exit
      --version  output version information and exit

SIZE is an integer and optional unit (example: 10M is 10*1024*1024).  Units
are K, M, G, T, P, E, Z, Y (powers of 1024) or KB, MB, ... (powers of 1000).

Using color to distinguish file types is disabled both by default and
with --color=never.  With --color=auto, ls emits color codes only when
standard output is connected to a terminal.  The LS_COLORS environment
variable can change the settings.  Use the dircolors command to set it.

Exit status:
 0  if OK,
 1  if minor problems (e.g., cannot access subdirectory),
 2  if serious trouble (e.g., cannot access command-line argument).

GNU coreutils online help: <http://www.gnu.org/software/coreutils/>
For complete documentation, run: info coreutils 'ls invocation'

以上,感謝。

2022年11月21日文章來源地址http://www.zghlxwxcb.cn/news/detail-468257.html

到了這里,關(guān)于Linux查看磁盤、文件系統(tǒng)、文件夾、文件大小的命令(lsblk、df、du、ll)的文章就介紹完了。如果您還想了解更多內(nèi)容,請(qǐng)?jiān)谟疑辖撬阉鱐OY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!

本文來自互聯(lián)網(wǎng)用戶投稿,該文觀點(diǎn)僅代表作者本人,不代表本站立場(chǎng)。本站僅提供信息存儲(chǔ)空間服務(wù),不擁有所有權(quán),不承擔(dān)相關(guān)法律責(zé)任。如若轉(zhuǎn)載,請(qǐng)注明出處: 如若內(nèi)容造成侵權(quán)/違法違規(guī)/事實(shí)不符,請(qǐng)點(diǎn)擊違法舉報(bào)進(jìn)行投訴反饋,一經(jīng)查實(shí),立即刪除!

領(lǐng)支付寶紅包贊助服務(wù)器費(fèi)用

相關(guān)文章

  • Linux查看當(dāng)前文件夾的大小

    在Linux中,可以使用 du (disk usage)命令來查看當(dāng)前文件夾的大小。以下是一些使用 du 的方法: 查看當(dāng)前文件夾的大小 : 為了查看當(dāng)前文件夾的總大小,可以在文件夾中運(yùn)行: 這里: -s 表示摘要模式,只顯示總計(jì)。 -h 表示人類可讀模式,使得輸出更容易閱讀,例如以KB、

    2024年02月06日
    瀏覽(93)
  • Hadoop 存儲(chǔ)占用分析命令,查看 Hdfs 文件夾占用大小

    兼職公司 Hadoop 運(yùn)維之后,經(jīng)常要解決 Hdfs 空間占用的問題,不知道哪天誰又在集群上留下一大堆緩存文件也不清掉,Hadoop 本身默認(rèn)就是三副本,人一多每個(gè)人留一點(diǎn)結(jié)果占用了一堆的存儲(chǔ)空間。 在 Linux 上游 du 這個(gè)指令可以很輕松的結(jié)合 sort 對(duì)文件夾的大小進(jìn)行排序,分析

    2024年02月15日
    瀏覽(91)
  • linux中查看某個(gè)文件夾下文件的個(gè)數(shù)和大小

    linux中查看某個(gè)文件夾下文件的個(gè)數(shù)和大小

    1、stat指令 stat命令 主要用于顯示文件或文件系統(tǒng)的詳細(xì)信息,該命令的語法格式如下: -f 不顯示文件本身的信息,顯示文件所在文件系統(tǒng)的信息 -L 顯示符號(hào)鏈接 -t 簡(jiǎn)潔模式,只顯示摘要信息 如: 2、wc命令 wc指令可以計(jì)算文件的列數(shù)、字?jǐn)?shù)和Byte數(shù)。 -c : Byte數(shù) -l : 文件行數(shù)

    2024年02月07日
    瀏覽(93)
  • Centos系統(tǒng)中如何查看文件夾的大小

    其中s代表統(tǒng)計(jì)匯總的意思,即只輸出一個(gè)總和大小 1、最簡(jiǎn)單的查看方法可以使用ls -ll、ls-lh命令進(jìn)行查看,使用ls -ll,會(huì)顯示成字節(jié)大小,而ls- lh會(huì)以KB、MB等為單位進(jìn)行顯示

    2024年02月06日
    瀏覽(91)
  • Linux 查看當(dāng)前路徑下所有文件夾大小的方法

    補(bǔ)充: du -sh 查看當(dāng)前目錄總共占的容量,而不單獨(dú)列出各子項(xiàng)占用的容量 du -ah --max-depth=1 a 表示顯示目錄下所有的文件和文件夾(不含子目錄) h 表示以人類能看懂的方式 max-depth 表示目錄的深度 du -lh --max-depth=1 查看當(dāng)前目錄下一級(jí)和子目錄占用的磁盤容量 整理完畢,完結(jié)

    2024年02月16日
    瀏覽(103)
  • Ubuntu查看文件大小或文件夾大小

    查看文件大小的命令: 會(huì)在終端輸出:-rw-r–r– 1 root root 2147483648 Mar 5 09:39 filetemp0606 其中數(shù)字2147483648 就是文件filename的大小單位是字節(jié)B 會(huì)在終端輸出當(dāng)前文件夾下的所有文件的權(quán)限大小信息。 注意:如果filename是一個(gè)目錄的話,執(zhí)行以上命令會(huì)把filename目錄下所有文件的大

    2024年02月14日
    瀏覽(95)
  • Linux磁盤空間與文件大小查看命令詳解

    ????????在Linux系統(tǒng)中,有多個(gè)命令可以用來查看磁盤空間的使用情況。最常用的命令是 df (disk free)。 df 命令的 -h 選項(xiàng)以人類可讀的方式顯示磁盤空間,該命令將顯示文件系統(tǒng)的使用情況、剩余空間等信息。 ????????為了查看特定文件夾的大小,我們可以使用 du (

    2024年01月20日
    瀏覽(140)
  • Qt 常用方法 獲取磁盤總大小、可用空間、文件夾大小 文件大小B KB M G轉(zhuǎn)換

    Qt 常用方法 獲取磁盤總大小、可用空間、文件夾大小 文件大小B KB M G轉(zhuǎn)換

    1.通過QFile獲取文件大小 注意:返回的是字節(jié)個(gè)數(shù) 通過QFileInfo獲取文件大小 2. 獲取磁盤空間 3 .獲取選擇路徑下總文件大小 4. 轉(zhuǎn)換大小單位 bit? === byte?? bit / 8 byte === KB byte / 1024 KB = MB KB / 1024 MB = GB MB / 1024 GB === TB GB / 1024

    2024年02月06日
    瀏覽(22)
  • 安卓adb命令查看系統(tǒng)文件大小及磁盤使用情況

    安卓adb命令查看系統(tǒng)文件大小及磁盤使用情況

    現(xiàn)象 今天測(cè)試端提出一個(gè)問題,桌面無法進(jìn)入,點(diǎn)HOME鍵做什么都沒用,就是不能進(jìn)去桌面,但是其他功能比如語音之類的可用。 分析 分析日志發(fā)現(xiàn)如下報(bào)錯(cuò): 提示設(shè)備存儲(chǔ)空間已滿,應(yīng)用在寫入日志和做一些文件存儲(chǔ)相關(guān)的操作異常,導(dǎo)致桌面無法進(jìn)入。 處理 需要先排查

    2024年02月05日
    瀏覽(29)
  • Ubuntu 使用 du 查看某個(gè)文件夾大小

    在 Ubuntu 系統(tǒng)中,你可以使用 du 命令來查看文件夾的大小。例如,如果你想查看文件夾 /var/log 的大小,你可以使用如下的命令: 其中,-s 選項(xiàng)表示只輸出總大小,-h 選項(xiàng)表示以人類可讀的格式輸出。 你也可以使用 du 命令來查看某個(gè)文件夾下所有文件和文件夾的大小,例如:

    2024年02月12日
    瀏覽(86)

覺得文章有用就打賞一下文章作者

支付寶掃一掃打賞

博客贊助

微信掃一掃打賞

請(qǐng)作者喝杯咖啡吧~博客贊助

支付寶掃一掃領(lǐng)取紅包,優(yōu)惠每天領(lǐng)

二維碼1

領(lǐng)取紅包

二維碼2

領(lǐng)紅包