GNU bug report logs -
#11526
du: hard-links counting with multiple arguments (commit
Previous Next
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 11526 in the body.
You can then email your comments to 11526 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-coreutils <at> gnu.org
:
bug#11526
; Package
coreutils
.
(Sun, 20 May 2012 16:57:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Chris Marusich <cmmarusich <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-coreutils <at> gnu.org
.
(Sun, 20 May 2012 16:57:01 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
BUG DESCRIPTION:
If you pass multiple arguments to du -s and the first of those argument is
. (the current directory), then du will only output the size of the first
argument. This bug is reproducible in version 8.13 on Ubuntu 12.04 LTS
(this is currently the latest version for Ubuntu 12.04 LTS) as follows.
However, it works properly in version 7.4 on Ubuntu 10.04.3 LTS. An
acquaintance has confirmed that the bug also occurs with du 8.16 and 8.17
(currently the latest coreutils version) on Arch Linux.
EXAMPLE, DU DOESN'T WORK:
chris <at> shmion:~/foo$ mkdir foo bar ; ls -al
total 16
drwxrwxr-x 4 chris chris 4096 May 19 23:24 .
drwxr-xr-x 42 chris chris 4096 May 19 22:04 ..
drwxrwxr-x 2 chris chris 4096 May 19 23:24 bar
drwxrwxr-x 2 chris chris 4096 May 19 23:24 foo
chris <at> shmion:~/foo$ strace -odu.log du -s . foo bar
20 .
chris <at> shmion:~/foo$ lsb_release -d
Description: Ubuntu 12.04 LTS
chris <at> shmion:~/foo$ du --version | head -n 1
du (GNU coreutils) 8.13
chris <at> shmion:~/foo$ cat du.log
execve("/usr/bin/du", ["du", "-s", ".", "foo", "bar"], [/* 51 vars */]) = 0
brk(0) = 0x17aa000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or
directory)
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f15215ed000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or
directory)
open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=82139, ...}) = 0
mmap(NULL, 82139, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f15215d8000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or
directory)
open("/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3,
"\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\200\30\2\0\0\0\0\0"...,
832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=1802936, ...}) = 0
mmap(NULL, 3917016, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0x7f1521010000
mprotect(0x7f15211c3000, 2093056, PROT_NONE) = 0
mmap(0x7f15213c2000, 24576, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1b2000) = 0x7f15213c2000
mmap(0x7f15213c8000, 17624, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f15213c8000
close(3) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f15215d7000
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f15215d6000
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f15215d5000
arch_prctl(ARCH_SET_FS, 0x7f15215d6700) = 0
mprotect(0x7f15213c2000, 16384, PROT_READ) = 0
mprotect(0x617000, 4096, PROT_READ) = 0
mprotect(0x7f15215ef000, 4096, PROT_READ) = 0
munmap(0x7f15215d8000, 82139) = 0
brk(0) = 0x17aa000
brk(0x17cb000) = 0x17cb000
open("/usr/lib/locale/locale-archive", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=3906928, ...}) = 0
mmap(NULL, 3906928, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f1520c56000
close(3) = 0
newfstatat(AT_FDCWD, ".", {st_mode=S_IFDIR|0775, st_size=4096, ...},
AT_SYMLINK_NOFOLLOW) = 0
openat(AT_FDCWD, ".", O_RDONLY|O_NOCTTY|O_NONBLOCK|O_DIRECTORY|O_NOFOLLOW)
= 3
fcntl(3, F_GETFD) = 0
fcntl(3, F_SETFD, FD_CLOEXEC) = 0
fstat(3, {st_mode=S_IFDIR|0775, st_size=4096, ...}) = 0
fcntl(3, F_GETFL) = 0x38800 (flags
O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY|O_NOFOLLOW)
fcntl(3, F_SETFD, FD_CLOEXEC) = 0
fcntl(3, F_DUPFD, 3) = 4
fcntl(4, F_GETFD) = 0
fcntl(4, F_SETFD, FD_CLOEXEC) = 0
getdents(3, /* 5 entries */, 32768) = 128
getdents(3, /* 0 entries */, 32768) = 0
close(3) = 0
newfstatat(4, "foo", {st_mode=S_IFDIR|0775, st_size=4096, ...},
AT_SYMLINK_NOFOLLOW) = 0
openat(4, "foo", O_RDONLY|O_NOCTTY|O_NONBLOCK|O_DIRECTORY|O_NOFOLLOW) = 3
fcntl(3, F_GETFD) = 0
fcntl(3, F_SETFD, FD_CLOEXEC) = 0
fstat(3, {st_mode=S_IFDIR|0775, st_size=4096, ...}) = 0
fcntl(3, F_GETFL) = 0x38800 (flags
O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY|O_NOFOLLOW)
fcntl(3, F_SETFD, FD_CLOEXEC) = 0
fcntl(3, F_DUPFD, 3) = 5
fcntl(5, F_GETFD) = 0
fcntl(5, F_SETFD, FD_CLOEXEC) = 0
getdents(3, /* 2 entries */, 32768) = 48
getdents(3, /* 0 entries */, 32768) = 0
close(3) = 0
close(5) = 0
newfstatat(4, "bar", {st_mode=S_IFDIR|0775, st_size=4096, ...},
AT_SYMLINK_NOFOLLOW) = 0
openat(4, "bar", O_RDONLY|O_NOCTTY|O_NONBLOCK|O_DIRECTORY|O_NOFOLLOW) = 3
fcntl(3, F_GETFD) = 0
fcntl(3, F_SETFD, FD_CLOEXEC) = 0
fstat(3, {st_mode=S_IFDIR|0775, st_size=4096, ...}) = 0
fcntl(3, F_GETFL) = 0x38800 (flags
O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY|O_NOFOLLOW)
fcntl(3, F_SETFD, FD_CLOEXEC) = 0
fcntl(3, F_DUPFD, 3) = 5
fcntl(5, F_GETFD) = 0
fcntl(5, F_SETFD, FD_CLOEXEC) = 0
getdents(3, /* 2 entries */, 32768) = 48
getdents(3, /* 0 entries */, 32768) = 0
close(3) = 0
close(5) = 0
newfstatat(4, "du.log", {st_mode=S_IFREG|0664, st_size=4441, ...},
AT_SYMLINK_NOFOLLOW) = 0
fstat(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 4), ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x7f15215ec000
write(1, "20\t.\n", 5) = 5
close(4) = 0
newfstatat(AT_FDCWD, "foo", {st_mode=S_IFDIR|0775, st_size=4096, ...},
AT_SYMLINK_NOFOLLOW) = 0
newfstatat(AT_FDCWD, "bar", {st_mode=S_IFDIR|0775, st_size=4096, ...},
AT_SYMLINK_NOFOLLOW) = 0
close(1) = 0
munmap(0x7f15215ec000, 4096) = 0
close(2) = 0
exit_group(0) = ?
chris <at> shmion:~/foo$
EXAMPLE, DU WORKS:
chris <at> rika:~/foo$ mkdir foo bar ; ls -al
total 16
drwxr-xr-x 4 chris chris 4096 2012-05-19 23:25 .
drwxr-xr-x 6 chris chris 4096 2012-05-19 22:36 ..
drwxr-xr-x 2 chris chris 4096 2012-05-19 23:25 bar
drwxr-xr-x 2 chris chris 4096 2012-05-19 23:25 foo
chris <at> rika:~/foo$ strace -odu.log du -s . foo bar
20 .
4 foo
4 bar
chris <at> rika:~/foo$ lsb_release -d
Description: Ubuntu 10.04.3 LTS
chris <at> rika:~/foo$ du --version | head -n 1
du (GNU coreutils) 7.4
chris <at> rika:~/foo$ cat du.log
execve("/usr/bin/du", ["du", "-s", ".", "foo", "bar"], [/* 21 vars */]) = 0
brk(0) = 0x9ea7000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or
directory)
mmap2(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0xb7794000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or
directory)
open("/etc/ld.so.cache", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=18207, ...}) = 0
mmap2(NULL, 18207, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb778f000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or
directory)
open("/lib/tls/i686/cmov/libc.so.6", O_RDONLY) = 3
read(3,
"\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0000m\1\0004\0\0\0"..., 512)
= 512
fstat64(3, {st_mode=S_IFREG|0755, st_size=1405508, ...}) = 0
mmap2(NULL, 1415592, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0)
= 0x49e000
mprotect(0x5f1000, 4096, PROT_NONE) = 0
mmap2(0x5f2000, 12288, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x153) = 0x5f2000
mmap2(0x5f5000, 10664, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x5f5000
close(3) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0xb778e000
set_thread_area({entry_number:-1 -> 6, base_addr:0xb778e8d0, limit:1048575,
seg_32bit:1, contents:0, read_exec_only:0, limit_in_pages:1,
seg_not_present:0, useable:1}) = 0
mprotect(0x5f2000, 8192, PROT_READ) = 0
mprotect(0x805e000, 4096, PROT_READ) = 0
mprotect(0x946000, 4096, PROT_READ) = 0
munmap(0xb778f000, 18207) = 0
brk(0) = 0x9ea7000
brk(0x9ec8000) = 0x9ec8000
open("/usr/lib/locale/locale-archive", O_RDONLY|O_LARGEFILE) = -1 ENOENT
(No such file or directory)
open("/usr/share/locale/locale.alias", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=2570, ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0xb7793000
read(3, "# Locale name alias data base.\n#"..., 4096) = 2570
read(3, "", 4096) = 0
close(3) = 0
munmap(0xb7793000, 4096) = 0
open("/usr/lib/locale/en_US.UTF-8/LC_IDENTIFICATION", O_RDONLY) = -1 ENOENT
(No such file or directory)
open("/usr/lib/locale/en_US.utf8/LC_IDENTIFICATION", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=373, ...}) = 0
mmap2(NULL, 373, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7793000
close(3) = 0
open("/usr/lib/gconv/gconv-modules.cache", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=26048, ...}) = 0
mmap2(NULL, 26048, PROT_READ, MAP_SHARED, 3, 0) = 0xb7787000
close(3) = 0
open("/usr/lib/locale/en_US.UTF-8/LC_MEASUREMENT", O_RDONLY) = -1 ENOENT
(No such file or directory)
open("/usr/lib/locale/en_US.utf8/LC_MEASUREMENT", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=23, ...}) = 0
mmap2(NULL, 23, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7792000
close(3) = 0
open("/usr/lib/locale/en_US.UTF-8/LC_TELEPHONE", O_RDONLY) = -1 ENOENT (No
such file or directory)
open("/usr/lib/locale/en_US.utf8/LC_TELEPHONE", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=59, ...}) = 0
mmap2(NULL, 59, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7791000
close(3) = 0
open("/usr/lib/locale/en_US.UTF-8/LC_ADDRESS", O_RDONLY) = -1 ENOENT (No
such file or directory)
open("/usr/lib/locale/en_US.utf8/LC_ADDRESS", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=155, ...}) = 0
mmap2(NULL, 155, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7790000
close(3) = 0
open("/usr/lib/locale/en_US.UTF-8/LC_NAME", O_RDONLY) = -1 ENOENT (No such
file or directory)
open("/usr/lib/locale/en_US.utf8/LC_NAME", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=77, ...}) = 0
mmap2(NULL, 77, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb778f000
close(3) = 0
open("/usr/lib/locale/en_US.UTF-8/LC_PAPER", O_RDONLY) = -1 ENOENT (No such
file or directory)
open("/usr/lib/locale/en_US.utf8/LC_PAPER", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=34, ...}) = 0
mmap2(NULL, 34, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7786000
close(3) = 0
open("/usr/lib/locale/en_US.UTF-8/LC_MESSAGES", O_RDONLY) = -1 ENOENT (No
such file or directory)
open("/usr/lib/locale/en_US.utf8/LC_MESSAGES", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
close(3) = 0
open("/usr/lib/locale/en_US.utf8/LC_MESSAGES/SYS_LC_MESSAGES", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=57, ...}) = 0
mmap2(NULL, 57, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7785000
close(3) = 0
open("/usr/lib/locale/en_US.UTF-8/LC_MONETARY", O_RDONLY) = -1 ENOENT (No
such file or directory)
open("/usr/lib/locale/en_US.utf8/LC_MONETARY", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=286, ...}) = 0
mmap2(NULL, 286, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7784000
close(3) = 0
open("/usr/lib/locale/en_US.UTF-8/LC_COLLATE", O_RDONLY) = -1 ENOENT (No
such file or directory)
open("/usr/lib/locale/en_US.utf8/LC_COLLATE", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=1170770, ...}) = 0
mmap2(NULL, 1170770, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7666000
close(3) = 0
open("/usr/lib/locale/en_US.UTF-8/LC_TIME", O_RDONLY) = -1 ENOENT (No such
file or directory)
open("/usr/lib/locale/en_US.utf8/LC_TIME", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=2454, ...}) = 0
mmap2(NULL, 2454, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7665000
close(3) = 0
open("/usr/lib/locale/en_US.UTF-8/LC_NUMERIC", O_RDONLY) = -1 ENOENT (No
such file or directory)
open("/usr/lib/locale/en_US.utf8/LC_NUMERIC", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=54, ...}) = 0
mmap2(NULL, 54, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7664000
close(3) = 0
open("/usr/lib/locale/en_US.UTF-8/LC_CTYPE", O_RDONLY) = -1 ENOENT (No such
file or directory)
open("/usr/lib/locale/en_US.utf8/LC_CTYPE", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=256324, ...}) = 0
mmap2(NULL, 256324, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7625000
close(3) = 0
fstatat64(AT_FDCWD, ".", {st_mode=S_IFDIR|0755, st_size=4096, ...},
AT_SYMLINK_NOFOLLOW) = 0
openat(AT_FDCWD, ".", O_RDONLY|O_LARGEFILE) = 3
fstat64(3, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
fcntl64(3, F_GETFL) = 0x8000 (flags
O_RDONLY|O_LARGEFILE)
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
fcntl64(3, F_DUPFD, 3) = 4
getdents64(3, /* 5 entries */, 32768) = 128
getdents64(3, /* 0 entries */, 32768) = 0
close(3) = 0
fstatat64(4, "foo", {st_mode=S_IFDIR|0755, st_size=4096, ...},
AT_SYMLINK_NOFOLLOW) = 0
openat(4, "foo", O_RDONLY|O_LARGEFILE) = 3
fstat64(3, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
fcntl64(3, F_GETFL) = 0x8000 (flags
O_RDONLY|O_LARGEFILE)
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
fcntl64(3, F_DUPFD, 3) = 5
getdents64(3, /* 2 entries */, 32768) = 48
getdents64(3, /* 0 entries */, 32768) = 0
close(3) = 0
close(5) = 0
fstatat64(4, "bar", {st_mode=S_IFDIR|0755, st_size=4096, ...},
AT_SYMLINK_NOFOLLOW) = 0
openat(4, "bar", O_RDONLY|O_LARGEFILE) = 3
fstat64(3, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
fcntl64(3, F_GETFL) = 0x8000 (flags
O_RDONLY|O_LARGEFILE)
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
fcntl64(3, F_DUPFD, 3) = 5
getdents64(3, /* 2 entries */, 32768) = 48
getdents64(3, /* 0 entries */, 32768) = 0
close(3) = 0
close(5) = 0
fstatat64(4, "du.log", {st_mode=S_IFREG|0644, st_size=8092, ...},
AT_SYMLINK_NOFOLLOW) = 0
fstat64(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 0), ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0xb7624000
write(1, "20\t.\n", 5) = 5
close(4) = 0
fstatat64(AT_FDCWD, "foo", {st_mode=S_IFDIR|0755, st_size=4096, ...},
AT_SYMLINK_NOFOLLOW) = 0
openat(AT_FDCWD, "foo", O_RDONLY|O_LARGEFILE) = 3
fstat64(3, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
fcntl64(3, F_GETFL) = 0x8000 (flags
O_RDONLY|O_LARGEFILE)
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
fcntl64(3, F_DUPFD, 3) = 4
getdents64(3, /* 2 entries */, 32768) = 48
getdents64(3, /* 0 entries */, 32768) = 0
close(3) = 0
write(1, "4\tfoo\n", 6) = 6
close(4) = 0
fstatat64(AT_FDCWD, "bar", {st_mode=S_IFDIR|0755, st_size=4096, ...},
AT_SYMLINK_NOFOLLOW) = 0
openat(AT_FDCWD, "bar", O_RDONLY|O_LARGEFILE) = 3
fstat64(3, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
fcntl64(3, F_GETFL) = 0x8000 (flags
O_RDONLY|O_LARGEFILE)
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
fcntl64(3, F_DUPFD, 3) = 4
getdents64(3, /* 2 entries */, 32768) = 48
getdents64(3, /* 0 entries */, 32768) = 0
close(3) = 0
write(1, "4\tbar\n", 6) = 6
close(4) = 0
close(1) = 0
munmap(0xb7624000, 4096) = 0
close(2) = 0
exit_group(0) = ?
chris <at> rika:~/foo$
[Message part 2 (text/html, inline)]
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#11526
; Package
coreutils
.
(Sun, 20 May 2012 21:19:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 11526 <at> debbugs.gnu.org (full text, mbox):
forcemerge 10282 11526
thanks
Thanks, but this behavior is expected and is not a bug.
We have been looking into ways of addressing the issue,
though there's nothing currently active in this area.
For more, please see <http://bugs.gnu.org/10282>.
Forcibly Merged 10281 10282 11526.
Request was from
Paul Eggert <eggert <at> cs.ucla.edu>
to
control <at> debbugs.gnu.org
.
(Sun, 20 May 2012 21:19:02 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#11526
; Package
coreutils
.
(Sun, 20 May 2012 22:20:02 GMT)
Full text and
rfc822 format available.
Message #13 received at 11526 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Thanks for your reply. I've read the thread and understand that the
intended behavior is not to double-count nodes so we can get an accurate
feel of the total size of the output of du -s by summing the sizes together.
However, the behavior contrasts with the description of -s ("display only a
total for each argument" on my system), so perhaps the documentation should
be updated? While it may be intuitive not to double-count a given
directory, I don't think the current description of -s makes it clear that
the size reported for a directory might be greater than 0 but less than the
actual size of the directory and all its contents (i.e. in the case where
one of its subdirectory was counted earlier). It should be made clear that
the numbers before each directory may in fact NOT be the actual size of
each directory, because that's what the description for -s seems to say now.
On Sun, May 20, 2012 at 2:17 PM, Paul Eggert <eggert <at> cs.ucla.edu> wrote:
> forcemerge 10282 11526
> thanks
>
> Thanks, but this behavior is expected and is not a bug.
> We have been looking into ways of addressing the issue,
> though there's nothing currently active in this area.
> For more, please see <http://bugs.gnu.org/10282>.
>
[Message part 2 (text/html, inline)]
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#11526
; Package
coreutils
.
(Mon, 21 May 2012 00:31:02 GMT)
Full text and
rfc822 format available.
Message #16 received at 11526 <at> debbugs.gnu.org (full text, mbox):
On 05/20/2012 03:18 PM, Chris Marusich wrote:
> the behavior contrasts with the description of -s
> ("display only a total for each argument" ...)
We could change that "total" to "summary".
The --help output (man page) currently doesn't discuss
this issue in detail, because it's not really set up for
long discussions. There is something in the manual about
this, if that helps.
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#11526
; Package
coreutils
.
(Mon, 21 May 2012 05:52:02 GMT)
Full text and
rfc822 format available.
Message #19 received at 11526 <at> debbugs.gnu.org (full text, mbox):
After reviewing the manual more closely, it seems I would have gotten
the behavior I expected with du -sl. What do you think about updating
the documentation to read as follows?
‘-s’
‘--summarize’
Display only a summary of the arguments. Unless -l is also
specified, not all arguments will necessarily appear in the output
(e.g., du -s foo foo/bar will not output a line for foo/bar), and not
every size printed next to a directory in the output will necessarily
reflect the total size of that directory including its contents (e.g.,
du -s foo/bar foo will output the total size of foo including its
contents minus the size of foo/bar). This behavior is POSIX-compliant
and allows us to use -c to get an idea of the total size of all the
arguments taken together.
The last line could perhaps be optional. I'd just like the docs to
have a clear explanation that helps prevent future confusion.
On Sun, May 20, 2012 at 5:29 PM, Paul Eggert <eggert <at> cs.ucla.edu> wrote:
>
> On 05/20/2012 03:18 PM, Chris Marusich wrote:
> > the behavior contrasts with the description of -s
> > ("display only a total for each argument" ...)
>
> We could change that "total" to "summary".
>
> The --help output (man page) currently doesn't discuss
> this issue in detail, because it's not really set up for
> long discussions. There is something in the manual about
> this, if that helps.
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#11526
; Package
coreutils
.
(Mon, 21 May 2012 07:25:01 GMT)
Full text and
rfc822 format available.
Message #22 received at 11526 <at> debbugs.gnu.org (full text, mbox):
On second thought, maybe this additional verbiage would be misleading
because (1) the same kind of thing can happen even when not using -s,
and (2) -c doesn't have to be used with -s to determine the total size
of the total disk usage of a given set of files or directories.
In any case, even though the varying output for -s is understandable,
behavior like the following seems counterintuitive:
$ mkdir foo foo/bar
$ du foo foo/bar
4 foo/bar
8 foo
$ du foo/bar foo
4 foo/bar
4 foo
Is this intended? Apologies if I'm asking something obvious.
On Sun, May 20, 2012 at 10:50 PM, Chris Marusich <cmmarusich <at> gmail.com> wrote:
> After reviewing the manual more closely, it seems I would have gotten
> the behavior I expected with du -sl. What do you think about updating
> the documentation to read as follows?
>
> ‘-s’
> ‘--summarize’
> Display only a summary of the arguments. Unless -l is also
> specified, not all arguments will necessarily appear in the output
> (e.g., du -s foo foo/bar will not output a line for foo/bar), and not
> every size printed next to a directory in the output will necessarily
> reflect the total size of that directory including its contents (e.g.,
> du -s foo/bar foo will output the total size of foo including its
> contents minus the size of foo/bar). This behavior is POSIX-compliant
> and allows us to use -c to get an idea of the total size of all the
> arguments taken together.
>
> The last line could perhaps be optional. I'd just like the docs to
> have a clear explanation that helps prevent future confusion.
>
> On Sun, May 20, 2012 at 5:29 PM, Paul Eggert <eggert <at> cs.ucla.edu> wrote:
>>
>> On 05/20/2012 03:18 PM, Chris Marusich wrote:
>> > the behavior contrasts with the description of -s
>> > ("display only a total for each argument" ...)
>>
>> We could change that "total" to "summary".
>>
>> The --help output (man page) currently doesn't discuss
>> this issue in detail, because it's not really set up for
>> long discussions. There is something in the manual about
>> this, if that helps.
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#11526
; Package
coreutils
.
(Mon, 21 May 2012 07:30:02 GMT)
Full text and
rfc822 format available.
Message #25 received at 11526 <at> debbugs.gnu.org (full text, mbox):
On 05/21/2012 12:24 AM, Chris Marusich wrote:
> $ mkdir foo foo/bar
> $ du foo foo/bar
> 4 foo/bar
> 8 foo
> $ du foo/bar foo
> 4 foo/bar
> 4 foo
>
> Is this intended?
Wow! That's a good one. Yes, the behavior is intended,
though, as I mentioned, there's been some consideration
to adding a flag or two that would generate different
output here.
Severity set to 'wishlist' from 'normal'
Request was from
Assaf Gordon <assafgordon <at> gmail.com>
to
control <at> debbugs.gnu.org
.
(Mon, 15 Oct 2018 15:04:02 GMT)
Full text and
rfc822 format available.
Added tag(s) wontfix.
Request was from
Assaf Gordon <assafgordon <at> gmail.com>
to
control <at> debbugs.gnu.org
.
(Mon, 15 Oct 2018 15:04:02 GMT)
Full text and
rfc822 format available.
Changed bug title to 'du: hard-links counting with multiple arguments (commit' from '"du -s . foo bar" only outputs size of first argument -- versions 8.13, 8.16, and 8.17 (latest)'
Request was from
Assaf Gordon <assafgordon <at> gmail.com>
to
control <at> debbugs.gnu.org
.
(Mon, 15 Oct 2018 15:04:02 GMT)
Full text and
rfc822 format available.
bug closed, send any further explanations to
10281 <at> debbugs.gnu.org and Paul Eggert <eggert <at> cs.ucla.edu>
Request was from
Assaf Gordon <assafgordon <at> gmail.com>
to
control <at> debbugs.gnu.org
.
(Mon, 15 Oct 2018 15:04:03 GMT)
Full text and
rfc822 format available.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Tue, 13 Nov 2018 12:24:05 GMT)
Full text and
rfc822 format available.
This bug report was last modified 6 years and 302 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.