📄 8gb
字号:
#!/bin/sh# Ensure that du does not rely on narrow types like size_t for# file sizes or sums.if test "$VERBOSE" = yes; then set -x du --versionfi. $srcdir/../envvar-checkpwd=`pwd`t0=`echo "$0"|sed 's,.*/,,'`.tmp; tmp=$t0/$$trap 'status=$?; cd $pwd; chmod -R u+rwx $t0; rm -rf $t0 && exit $status' 0trap '(exit $?); exit $?' 1 2 13 15framework_failure=0mkdir -p $tmp || framework_failure=1cd $tmp || framework_failure=1if test $framework_failure = 1; then echo "$0: failure in testing framework" 1>&2 (exit 1); exit 1fidd bs=1 seek=8G of=big < /dev/null 2> /dev/nullif test $? != 0; then echo "$0: cannot create a file large enough for this test; possibly" 1>&2 echo "$0: because file offsets are only 32 bits on this file system" 1>&2 (exit 77); exit 77fi# FIXME: this should be a test of dd.# On some systems (at least linux-2.4.18 + NFS to disks on a Solaris system)# the `dd' command above mistakenly creates a file of length `0', yet# doesn't fail. The root of that failure is that the ftruncate call# returns zero but doesn't do its job. Detect this failure.set x `ls -gG big`size=$4if test "$size" = 0; then echo "$0: cannot create a file large enough for this test;" 1>&2 echo "$0: possibly because this system's NFS support is buggy;" 1>&2 echo "$0: Consider rerunning this test on a different file system." 1>&2 (exit 77); exit 77fifail=0# This would print `0 big' with coreutils-4.5.8.du -ab big > out || fail=1cat <<\EOF > exp8589934592 bigEOFcmp out exp || fail=1test $fail = 1 && diff out exp 2> /dev/null(exit $fail); exit $fail
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -