GNU bug report logs -
#16532
Test Fail: "tests/chown/separator"
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 16532 in the body.
You can then email your comments to 16532 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#16532
; Package
coreutils
.
(Thu, 23 Jan 2014 18:42:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Assaf Gordon <assafgordon <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-coreutils <at> gnu.org
.
(Thu, 23 Jan 2014 18:42:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
Hello,
Testing the latest coreutils (v8.22.16-be97f) on an old Ubuntu server,
results in a test failure "tests/chown/separator" (log + strace below).
System is:
====
$ uname -a
Linux club 2.6.32-24-server #43-Ubuntu SMP Thu Sep 16 16:05:42 UTC 2010
x86_64 GNU/Linux
$ cat /etc/issue
Ubuntu 10.04.4 LTS \n \l
## Failed on the following file-system
$ stat -f /data/gordon/projects/coreutils/
File: "/data/gordon/projects/coreutils/"
ID: 83000000000 Namelen: 255 Type: xfs
Block size: 4096 Fundamental block size: 4096
Blocks: Total: 1952592384 Free: 86807222 Available: 86807222
Inodes: Total: 1429327392 Free: 1388915606
====
strace (same command which failed in the log below):
=====
$ pwd
/data/gordon/projects/coreutils/
$ mkdir foo
$ cd foo
$ strace ../src/chown 34574:users . 2>&1 | grep -A 5 -B 5 chown
--
mmap(NULL, 895, PROT_READ, MAP_SHARED, 3, 0) = 0x7fb7ce753000
lseek(3, 895, SEEK_SET) = 895
munmap(0x7fb7ce753000, 895) = 0
close(3) = 0
newfstatat(AT_FDCWD, ".", {st_mode=S_IFDIR|0755, st_size=6, ...},
AT_SYMLINK_NOFOLLOW) = 0
fchownat(AT_FDCWD, ".", 34574, 100, 0) = -1 EPERM (Operation not permitted)
open("/usr/local/share/locale/en_US.UTF-8/LC_MESSAGES/coreutils.mo",
O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/share/locale/en_US.utf8/LC_MESSAGES/coreutils.mo",
O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/share/locale/en_US/LC_MESSAGES/coreutils.mo", O_RDONLY)
= -1 ENOENT (No such file or directory)
open("/usr/local/share/locale/en.UTF-8/LC_MESSAGES/coreutils.mo",
O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/local/share/locale/en.utf8/LC_MESSAGES/coreutils.mo",
O_RDONLY) = -1 ENOENT (No such file or directory)
--
=====
FAIL: tests/chown/separator
===========================
++ initial_cwd_=/data/gordon/projects/coreutils
++ fail=0
+++ testdir_prefix_
+++ printf gt
++ pfx_=gt
+++ mktempd_ /data/gordon/projects/coreutils gt-separator.sh.XXXX
+++ case $# in
+++ destdir_=/data/gordon/projects/coreutils
+++ template_=gt-separator.sh.XXXX
+++ MAX_TRIES_=4
+++ case $destdir_ in
+++ case $template_ in
++++ unset TMPDIR
+++ d=/data/gordon/projects/coreutils/gt-separator.sh.fh9P
+++ case $d in
+++ test -d /data/gordon/projects/coreutils/gt-separator.sh.fh9P
++++ ls -dgo /data/gordon/projects/coreutils/gt-separator.sh.fh9P
++++ tr S -
+++ perms='drwx------ 2 6 Jan 23 13:22
/data/gordon/projects/coreutils/gt-separator.sh.fh9P'
+++ case $perms in
+++ test 0 = 0
+++ echo /data/gordon/projects/coreutils/gt-separator.sh.fh9P
+++ return
++ test_dir_=/data/gordon/projects/coreutils/gt-separator.sh.fh9P
++ cd /data/gordon/projects/coreutils/gt-separator.sh.fh9P
++ gl_init_sh_nl_='
'
++ IFS='
'
++ for sig_ in 1 2 3 13 15
+++ expr 1 + 128
++ eval 'trap '\''Exit 129'\'' 1'
+++ trap 'Exit 129' 1
++ for sig_ in 1 2 3 13 15
+++ expr 2 + 128
++ eval 'trap '\''Exit 130'\'' 2'
+++ trap 'Exit 130' 2
++ for sig_ in 1 2 3 13 15
+++ expr 3 + 128
++ eval 'trap '\''Exit 131'\'' 3'
+++ trap 'Exit 131' 3
++ for sig_ in 1 2 3 13 15
+++ expr 13 + 128
++ eval 'trap '\''Exit 141'\'' 13'
+++ trap 'Exit 141' 13
++ for sig_ in 1 2 3 13 15
+++ expr 15 + 128
++ eval 'trap '\''Exit 143'\'' 15'
+++ trap 'Exit 143' 15
++ trap remove_tmp_ 0
+ path_prepend_ ./src
+ test 1 '!=' 0
+ path_dir_=./src
+ case $path_dir_ in
+ abs_path_dir_=/data/gordon/projects/coreutils/./src
+ case $abs_path_dir_ in
+
PATH=/data/gordon/projects/coreutils/./src:/data/gordon/projects/coreutils/src:/data/gordon/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
+ create_exe_shims_ /data/gordon/projects/coreutils/./src
+ case $EXEEXT in
+ return 0
+ shift
+ test 0 '!=' 0
+ export PATH
+ print_ver_ chown
+ test yes = yes
+ local i
+ for i in '$*'
+ env chown --version
chown (GNU coreutils) 8.22.16-be97f
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
<http://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Written by David MacKenzie and Jim Meyering.
++ id -u
+ id_u=34574
+ test -n 34574
++ id -un
+ id_un=agordon
+ test -n agordon
++ id -g
+ id_g=1000
+ test -n 1000
++ id -gn
+ id_gn=users
+ test -n users
+ case $host_triplet in
+ chown '' .
+ for u in '$id_u' '"$id_un"' ''\'''\'''
+ for g in '$id_g' '"$id_gn"' ''\'''\'''
+ case $u$g in
+ seps=': .'
+ for sep in '$seps'
+ case $u$sep$g in
+ chown 34574:1000 .
+ for sep in '$seps'
+ case $u$sep$g in
+ chown 34574.1000 .
+ for g in '$id_g' '"$id_gn"' ''\'''\'''
+ case $u$g in
+ seps=': .'
+ for sep in '$seps'
+ case $u$sep$g in
+ chown 34574:users .
chown: changing ownership of '.': Operation not permitted
+ fail=1
+ for sep in '$seps'
+ case $u$sep$g in
+ chown 34574.users .
chown: changing ownership of '.': Operation not permitted
+ fail=1
+ for g in '$id_g' '"$id_gn"' ''\'''\'''
+ case $u$g in
+ seps=': .'
+ for sep in '$seps'
+ case $u$sep$g in
+ chown 34574: .
+ for sep in '$seps'
+ case $u$sep$g in
+ chown 34574. .
+ for u in '$id_u' '"$id_un"' ''\'''\'''
+ for g in '$id_g' '"$id_gn"' ''\'''\'''
+ case $u$g in
+ seps=': .'
+ for sep in '$seps'
+ case $u$sep$g in
+ chown agordon:1000 .
+ for sep in '$seps'
+ case $u$sep$g in
+ chown agordon.1000 .
+ for g in '$id_g' '"$id_gn"' ''\'''\'''
+ case $u$g in
+ seps=': .'
+ for sep in '$seps'
+ case $u$sep$g in
+ chown agordon:users .
chown: changing ownership of '.': Operation not permitted
+ fail=1
+ for sep in '$seps'
+ case $u$sep$g in
+ chown agordon.users .
chown: changing ownership of '.': Operation not permitted
+ fail=1
+ for g in '$id_g' '"$id_gn"' ''\'''\'''
+ case $u$g in
+ seps=': .'
+ for sep in '$seps'
+ case $u$sep$g in
+ chown agordon: .
+ for sep in '$seps'
+ case $u$sep$g in
+ chown agordon. .
+ for u in '$id_u' '"$id_un"' ''\'''\'''
+ for g in '$id_g' '"$id_gn"' ''\'''\'''
+ case $u$g in
+ seps=': .'
+ for sep in '$seps'
+ case $u$sep$g in
+ chown :1000 .
+ for sep in '$seps'
+ case $u$sep$g in
+ chown .1000 .
+ for g in '$id_g' '"$id_gn"' ''\'''\'''
+ case $u$g in
+ seps=': .'
+ for sep in '$seps'
+ case $u$sep$g in
+ chown :users .
chown: changing group of '.': Operation not permitted
+ fail=1
+ for sep in '$seps'
+ case $u$sep$g in
+ chown .users .
chown: changing group of '.': Operation not permitted
+ fail=1
+ for g in '$id_g' '"$id_gn"' ''\'''\'''
+ case $u$g in
+ seps=': .'
+ for sep in '$seps'
+ case $u$sep$g in
+ chown : .
+ for sep in '$seps'
+ case $u$sep$g in
+ chown . .
+ Exit 1
+ set +e
+ exit 1
+ exit 1
+ remove_tmp_
+ __st=1
+ cleanup_
+ :
+ cd /data/gordon/projects/coreutils
+ chmod -R u+rwx /data/gordon/projects/coreutils/gt-separator.sh.fh9P
+ rm -rf /data/gordon/projects/coreutils/gt-separator.sh.fh9P
+ exit 1
===
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#16532
; Package
coreutils
.
(Thu, 23 Jan 2014 23:21:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 16532 <at> debbugs.gnu.org (full text, mbox):
tag 16532 + moreinfo
thanks
On 01/23/2014 07:41 PM, Assaf Gordon wrote:
> Hello,
welcome back!
> Testing the latest coreutils (v8.22.16-be97f) on an old Ubuntu server,
> results in a test failure "tests/chown/separator" (log + strace below).
> $ strace ../src/chown 34574:users . 2>&1 | grep -A 5 -B 5 chown
> fchownat(AT_FDCWD, ".", 34574, 100, 0) = -1 EPERM (Operation not permitted)
> ++ id -g
> + id_g=1000
> + chown 34574:users .
> chown: changing ownership of '.': Operation not permitted
> + fail=1
Ooops, something very strange is going on on your system:
chown resolves the group 'users' to gid 100 while 'id -g'
says 1000.
Can you find out why?
Are you using some strange Samba/Kerberos authentication against
an Active Directory or similar? (I've seen such issues with that
combination,)
Have a nice day,
Berny
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#16532
; Package
coreutils
.
(Thu, 23 Jan 2014 23:41:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 16532 <at> debbugs.gnu.org (full text, mbox):
On 01/23/2014 06:20 PM, Bernhard Voelker wrote:
> On 01/23/2014 07:41 PM, Assaf Gordon wrote:
>> $ strace ../src/chown 34574:users . 2>&1 | grep -A 5 -B 5 chown
>
>> fchownat(AT_FDCWD, ".", 34574, 100, 0) = -1 EPERM (Operation not permitted)
>
>> ++ id -g
>> + id_g=1000
>
>> + chown 34574:users .
>> chown: changing ownership of '.': Operation not permitted
>> + fail=1
>
> Ooops, something very strange is going on on your system:
> chown resolves the group 'users' to gid 100 while 'id -g'
> says 1000.
>
> Can you find out why?
> Are you using some strange Samba/Kerberos authentication against
> an Active Directory or similar? (I've seen such issues with that
> combination,)
>
Thanks for the quick reply - this is a strange old server (not my doing...).
Indeed it uses an external authentication, and has conflicting local and
global groups named "users".
==
$ grep users /etc/group
users:x:100:
$ getent group | grep ^users
users:x:100:
users:x:1000:
$ id -G
1000 1001 3432
==
So I guess this is not a bug, and can be closed.
I'll just ignore this failure on this system.
Thanks,
-gordon
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#16532
; Package
coreutils
.
(Fri, 24 Jan 2014 01:10:02 GMT)
Full text and
rfc822 format available.
Message #14 received at 16532 <at> debbugs.gnu.org (full text, mbox):
On 01/23/2014 11:41 PM, Assaf Gordon wrote:
> On 01/23/2014 06:20 PM, Bernhard Voelker wrote:
>> On 01/23/2014 07:41 PM, Assaf Gordon wrote:
>>> $ strace ../src/chown 34574:users . 2>&1 | grep -A 5 -B 5 chown
>>
>>> fchownat(AT_FDCWD, ".", 34574, 100, 0) = -1 EPERM (Operation not permitted)
>>
>>> ++ id -g
>>> + id_g=1000
>>
>>> + chown 34574:users .
>>> chown: changing ownership of '.': Operation not permitted
>>> + fail=1
>>
>> Ooops, something very strange is going on on your system:
>> chown resolves the group 'users' to gid 100 while 'id -g'
>> says 1000.
>>
>> Can you find out why?
>> Are you using some strange Samba/Kerberos authentication against
>> an Active Directory or similar? (I've seen such issues with that
>> combination,)
>>
>
> Thanks for the quick reply - this is a strange old server (not my doing...).
> Indeed it uses an external authentication, and has conflicting local and global groups named "users".
>
> ==
> $ grep users /etc/group
> users:x:100:
> $ getent group | grep ^users
> users:x:100:
> users:x:1000:
> $ id -G
> 1000 1001 3432
> ==
>
> So I guess this is not a bug, and can be closed.
> I'll just ignore this failure on this system.
It is a false failure though so would be worth avoiding.
It's important to have robust tests we and builders can rely on.
Would something along the following be possible?
test $(getent group $group | wc -l) != 1 || skip_ "multiple ids for group $group: $(getent group $group)"
welcome back!
Pádraig.
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#16532
; Package
coreutils
.
(Fri, 24 Jan 2014 01:39:02 GMT)
Full text and
rfc822 format available.
Message #17 received at 16532 <at> debbugs.gnu.org (full text, mbox):
This patch makes the test skip on my server (did not test it on other
systems).
On 01/23/2014 08:09 PM, Pádraig Brady wrote:
> On 01/23/2014 11:41 PM, Assaf Gordon wrote:
>> So I guess this is not a bug, and can be closed.
>> I'll just ignore this failure on this system.
>
> It is a false failure though so would be worth avoiding.
> It's important to have robust tests we and builders can rely on.
>
> Would something along the following be possible?
>
> test $(getent group $group | wc -l) != 1 || skip_ "multiple ids for group $group: $(getent group $group)"
>
From 3737105eacbb23cbe453a3d210359fea614b7154 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?P=C3=A1draig=20Brady?= <P <at> draigBrady.com>
Date: Thu, 23 Jan 2014 20:34:52 -0500
Subject: [PATCH] tests: skip chown/separator with duplicated groups
* tests/chwon/separator.sh: skip test if the user's group has
multiple entries.
Fixes http://bugs.gnu.org/16532
---
tests/chown/separator.sh | 3 +++
1 file changed, 3 insertions(+)
diff --git a/tests/chown/separator.sh b/tests/chown/separator.sh
index f64b738..ec33f4a 100755
--- a/tests/chown/separator.sh
+++ b/tests/chown/separator.sh
@@ -31,6 +31,9 @@ test -n "$id_g" || framework_failure_
id_gn=$(id -gn) || framework_failure_
test -n "$id_gn" || framework_failure_
+test $(getent group $id_gn | wc -l) != 1 ||
+ skip_ "multiple ids for group $id_gn: $(getent group $id_gn)"
+
# FreeBSD 6.x's getgrnam fails to look up a group name containing
# a space. On such a system, skip this test if the group name contains
# a byte not in the portable filename character set.
--
1.8.4.3
Reply sent
to
Pádraig Brady <P <at> draigBrady.com>
:
You have taken responsibility.
(Fri, 24 Jan 2014 01:45:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Assaf Gordon <assafgordon <at> gmail.com>
:
bug acknowledged by developer.
(Fri, 24 Jan 2014 01:45:03 GMT)
Full text and
rfc822 format available.
Message #22 received at 16532-done <at> debbugs.gnu.org (full text, mbox):
On 01/24/2014 01:38 AM, Assaf Gordon wrote:
> This patch makes the test skip on my server (did not test it on other systems).
>
> On 01/23/2014 08:09 PM, Pádraig Brady wrote:
>> On 01/23/2014 11:41 PM, Assaf Gordon wrote:
>
>>> So I guess this is not a bug, and can be closed.
>>> I'll just ignore this failure on this system.
>>
>> It is a false failure though so would be worth avoiding.
>> It's important to have robust tests we and builders can rely on.
>>
>> Would something along the following be possible?
>>
>> test $(getent group $group | wc -l) != 1 || skip_ "multiple ids for group $group: $(getent group $group)"
>>
>
>
> From 3737105eacbb23cbe453a3d210359fea614b7154 Mon Sep 17 00:00:00 2001
> From: =?UTF-8?q?P=C3=A1draig=20Brady?= <P <at> draigBrady.com>
> Date: Thu, 23 Jan 2014 20:34:52 -0500
> Subject: [PATCH] tests: skip chown/separator with duplicated groups
>
> * tests/chwon/separator.sh: skip test if the user's group has
s/chwon/chown/
> multiple entries.
> Fixes http://bugs.gnu.org/16532
> ---
> tests/chown/separator.sh | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/tests/chown/separator.sh b/tests/chown/separator.sh
> index f64b738..ec33f4a 100755
> --- a/tests/chown/separator.sh
> +++ b/tests/chown/separator.sh
> @@ -31,6 +31,9 @@ test -n "$id_g" || framework_failure_
> id_gn=$(id -gn) || framework_failure_
> test -n "$id_gn" || framework_failure_
>
> +test $(getent group $id_gn | wc -l) != 1 ||
> + skip_ "multiple ids for group $id_gn: $(getent group $id_gn)"
> +
> # FreeBSD 6.x's getgrnam fails to look up a group name containing
> # a space. On such a system, skip this test if the group name contains
> # a byte not in the portable filename character set.
Cool I'll push that in your name since you
did the hard work of tracking it down,
generating the patch and testing.
Marking this as done.
cheers,
Pádraig.
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#16532
; Package
coreutils
.
(Fri, 24 Jan 2014 02:33:02 GMT)
Full text and
rfc822 format available.
Message #25 received at 16532 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
On 01/24/2014 01:43 AM, Pádraig Brady wrote:
> On 01/24/2014 01:38 AM, Assaf Gordon wrote:
>> This patch makes the test skip on my server (did not test it on other systems).
>>
>> On 01/23/2014 08:09 PM, Pádraig Brady wrote:
>>> On 01/23/2014 11:41 PM, Assaf Gordon wrote:
>>
>>>> So I guess this is not a bug, and can be closed.
>>>> I'll just ignore this failure on this system.
>>>
>>> It is a false failure though so would be worth avoiding.
>>> It's important to have robust tests we and builders can rely on.
>>>
>>> Would something along the following be possible?
>>>
>>> test $(getent group $group | wc -l) != 1 || skip_ "multiple ids for group $group: $(getent group $group)"
>>>
>>
>>
>> From 3737105eacbb23cbe453a3d210359fea614b7154 Mon Sep 17 00:00:00 2001
>> From: =?UTF-8?q?P=C3=A1draig=20Brady?= <P <at> draigBrady.com>
>> Date: Thu, 23 Jan 2014 20:34:52 -0500
>> Subject: [PATCH] tests: skip chown/separator with duplicated groups
>>
>> * tests/chwon/separator.sh: skip test if the user's group has
>
> s/chwon/chown/
>
>> multiple entries.
>> Fixes http://bugs.gnu.org/16532
>> ---
>> tests/chown/separator.sh | 3 +++
>> 1 file changed, 3 insertions(+)
>>
>> diff --git a/tests/chown/separator.sh b/tests/chown/separator.sh
>> index f64b738..ec33f4a 100755
>> --- a/tests/chown/separator.sh
>> +++ b/tests/chown/separator.sh
>> @@ -31,6 +31,9 @@ test -n "$id_g" || framework_failure_
>> id_gn=$(id -gn) || framework_failure_
>> test -n "$id_gn" || framework_failure_
>>
>> +test $(getent group $id_gn | wc -l) != 1 ||
Actually I messed up the login in the suggestion.
I think the above should be s/!=/=/ which I've done
in the attached patch.
If you could confirm it was skipped on your system
it would be great.
I'll push soon anyway.
>> + skip_ "multiple ids for group $id_gn: $(getent group $id_gn)"
I also protected the $id_gn with quotes in case
there were spaces in the group name or something.
thanks,
Pádraig.
[tests-dupe-groups.patch (text/x-patch, attachment)]
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#16532
; Package
coreutils
.
(Fri, 24 Jan 2014 02:47:02 GMT)
Full text and
rfc822 format available.
Message #28 received at 16532 <at> debbugs.gnu.org (full text, mbox):
On 01/23/2014 09:32 PM, Pádraig Brady wrote:
>
> Actually I messed up the login in the suggestion.
> I think the above should be s/!=/=/ which I've done
> in the attached patch.
>
> If you could confirm it was skipped on your system
> it would be great.
>
> I'll push soon anyway.
>
Please don't push yet - it doesn't work, but for un-expected reason:
my previous patch was incorrect (The "=" vs "!=" as you pointed), but
also "getent groups" was incorrect - so two wrongs did make a right :)
The test fails, here's why:
On my strange system:
===
$ getent group users
users:x:100:
===
vs.
===
$ getent group | grep ^users
users:x:100:
users:x:1000:www-data,XXX,YYY
===
And so, the skip test didn't actual work to begin with.
Should we change it to "getent" + "grep" ?
-gordon
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#16532
; Package
coreutils
.
(Fri, 24 Jan 2014 02:58:01 GMT)
Full text and
rfc822 format available.
Message #31 received at 16532 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
On 01/23/2014 09:46 PM, Assaf Gordon wrote:
> On 01/23/2014 09:32 PM, Pádraig Brady wrote:
>>
>> If you could confirm it was skipped on your system
>> it would be great.
>>
>
> Please don't push yet - it doesn't work, but for un-expected reason:
> On my strange system
For completeness, attached is the test fail log.
Also, similar examples with other groups:
===
$ getent group | cut -f1 -d: | sort | uniq -d
adm
bin
daemon
lp
mail
root
sys
tty
users
uucp
$ getent group | grep ^mail:
mail:x:8:
mail:x:6:root
$ getent group mail
mail:x:8:
$ getent group | grep ^adm:
adm:x:4:
adm:x:4:root,adm,daemon
$ getent group adm
adm:x:4:
===
So yes, this is not an ideally-configured system.
-gordon
[chown-group-test-suite.log (text/x-log, attachment)]
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#16532
; Package
coreutils
.
(Fri, 24 Jan 2014 03:10:01 GMT)
Full text and
rfc822 format available.
Message #34 received at 16532 <at> debbugs.gnu.org (full text, mbox):
On 01/24/2014 02:46 AM, Assaf Gordon wrote:
> On 01/23/2014 09:32 PM, Pádraig Brady wrote:
>>
>> Actually I messed up the login in the suggestion.
>> I think the above should be s/!=/=/ which I've done
>> in the attached patch.
>>
>> If you could confirm it was skipped on your system
>> it would be great.
>>
>> I'll push soon anyway.
>>
>
> Please don't push yet - it doesn't work, but for un-expected reason:
>
> my previous patch was incorrect (The "=" vs "!=" as you pointed), but also "getent groups" was incorrect - so two wrongs did make a right :)
>
> The test fails, here's why:
>
> On my strange system:
>
> ===
> $ getent group users
> users:x:100:
> ===
> vs.
> ===
> $ getent group | grep ^users
> users:x:100:
> users:x:1000:www-data,XXX,YYY
> ===
Oh right, grep ^$id_gn: it is so.
Note we can't rely on getent(1) being available (as noted in bug 9987),
but the failure in that edge case is still a skip as the count will be 0 then.
thanks,
Pádraig.
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#16532
; Package
coreutils
.
(Fri, 24 Jan 2014 07:44:02 GMT)
Full text and
rfc822 format available.
Message #37 received at 16532 <at> debbugs.gnu.org (full text, mbox):
On 01/24/2014 04:09 AM, Pádraig Brady wrote:
> On 01/24/2014 02:46 AM, Assaf Gordon wrote:
>> $ getent group | grep ^users
>> users:x:100:
>> users:x:1000:www-data,XXX,YYY
>> ===
>
> Oh right, grep ^$id_gn: it is so.
>
> Note we can't rely on getent(1) being available (as noted in bug 9987),
> but the failure in that edge case is still a skip as the count will be 0 then.
I'm still not convinced that we should mask this misconfiguration
by skipping the test.
AFAIK it's totally valid to have several names for a gid,
but is it permitted the other way round?
I'd bet you run into other trouble on such a system, too.
Therefore, I see the failing test more as a heads-up to
fix the configuration.
Thanks & have a nice day,
Berny
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#16532
; Package
coreutils
.
(Fri, 24 Jan 2014 12:20:02 GMT)
Full text and
rfc822 format available.
Message #40 received at 16532 <at> debbugs.gnu.org (full text, mbox):
On 01/24/2014 07:43 AM, Bernhard Voelker wrote:
> On 01/24/2014 04:09 AM, Pádraig Brady wrote:
>> On 01/24/2014 02:46 AM, Assaf Gordon wrote:
>>> $ getent group | grep ^users
>>> users:x:100:
>>> users:x:1000:www-data,XXX,YYY
>>> ===
>>
>> Oh right, grep ^$id_gn: it is so.
>>
>> Note we can't rely on getent(1) being available (as noted in bug 9987),
>> but the failure in that edge case is still a skip as the count will be 0 then.
>
> I'm still not convinced that we should mask this misconfiguration
> by skipping the test.
>
> AFAIK it's totally valid to have several names for a gid,
> but is it permitted the other way round?
>
> I'd bet you run into other trouble on such a system, too.
> Therefore, I see the failing test more as a heads-up to
> fix the configuration.
>
> Thanks & have a nice day,
> Berny
>
Since it's an easy enough workaround it's worth adding IMHO.
As a general point there should never be any questions
about test failures. I've seen some test suites become
less than useful through attrition of little issues.
For me the tests take more time than the code and are more
awkward to write, but that's all fine and good as that's
were the real value is.
thanks,
Pádraig.
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#16532
; Package
coreutils
.
(Fri, 24 Jan 2014 12:47:01 GMT)
Full text and
rfc822 format available.
Message #43 received at 16532 <at> debbugs.gnu.org (full text, mbox):
On 01/24/2014 01:19 PM, Pádraig Brady wrote:
> On 01/24/2014 07:43 AM, Bernhard Voelker wrote:
>> On 01/24/2014 04:09 AM, Pádraig Brady wrote:
>>> Oh right, grep ^$id_gn: it is so.
>>>
>>> Note we can't rely on getent(1) being available (as noted in bug 9987),
>>> but the failure in that edge case is still a skip as the count will be 0 then.
>>
>> I'm still not convinced that we should mask this misconfiguration
>> by skipping the test.
>>
>> AFAIK it's totally valid to have several names for a gid,
>> but is it permitted the other way round?
>>
>> I'd bet you run into other trouble on such a system, too.
>> Therefore, I see the failing test more as a heads-up to
>> fix the configuration.
>>
>> Thanks & have a nice day,
>> Berny
>>
>
> Since it's an easy enough workaround it's worth adding IMHO.
> As a general point there should never be any questions
> about test failures. I've seen some test suites become
> less than useful through attrition of little issues.
> For me the tests take more time than the code and are more
> awkward to write, but that's all fine and good as that's
> were the real value is.
Okay, let's go with it then. Thanks.
BTW: I'd change the skip_ message to reflect the above mentioned
corner case where getent is not available, something like:
- skip_ "multiple IDs for group '$id_gn': $(getent group "$id_gn")"
+ skip_ "group '$id_gn' not biunique: $(getent group | grep "^$id_gn:")"
Have a nice day,
Berny
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#16532
; Package
coreutils
.
(Fri, 24 Jan 2014 16:59:01 GMT)
Full text and
rfc822 format available.
Message #46 received at 16532 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
On 01/24/2014 07:46 AM, Bernhard Voelker wrote:
>>> On 01/24/2014 04:09 AM, Pádraig Brady wrote:
>>>> Oh right, grep ^$id_gn: it is so.
>
> BTW: I'd change the skip_ message to reflect the above mentioned
> corner case where getent is not available, something like:
>
> - skip_ "multiple IDs for group '$id_gn': $(getent group "$id_gn")"
> + skip_ "group '$id_gn' not biunique: $(getent group | grep "^$id_gn:")"
>
Attached is an updated version, using grep and the suggested error message.
On addition is a "tr '\n' ','" - because "skip" only shows the first
line of the message, and so multiple groups and not displayed.
-gordon
[chown-dup-group.patch (text/x-patch, attachment)]
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#16532
; Package
coreutils
.
(Fri, 24 Jan 2014 17:51:01 GMT)
Full text and
rfc822 format available.
Message #49 received at 16532 <at> debbugs.gnu.org (full text, mbox):
On 01/24/2014 04:58 PM, Assaf Gordon wrote:
> On 01/24/2014 07:46 AM, Bernhard Voelker wrote:
>>>> On 01/24/2014 04:09 AM, Pádraig Brady wrote:
>>>>> Oh right, grep ^$id_gn: it is so.
>>
>> BTW: I'd change the skip_ message to reflect the above mentioned
>> corner case where getent is not available, something like:
>>
>> - skip_ "multiple IDs for group '$id_gn': $(getent group "$id_gn")"
>> + skip_ "group '$id_gn' not biunique: $(getent group | grep "^$id_gn:")"
>>
>
> Attached is an updated version, using grep and the suggested error message.
> On addition is a "tr '\n' ','" - because "skip" only shows the first line of the message, and so multiple groups and not displayed.
If you remove the "" from "$()" the '\n' would be changed to spaces
Your changing to ',' is neater though.
Note to avoid a trailing ',' one can use ... | paste -s -d,
Anyway pushed.
thanks!
Pádraig.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sat, 22 Feb 2014 12:24:03 GMT)
Full text and
rfc822 format available.
This bug report was last modified 10 years and 73 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.