GNU bug report logs -
#22432
owner,group and mode options are only applied to the deepest directory
Previous Next
Reported by: Hans Lambermont <hans <at> shapeways.com>
Date: Fri, 22 Jan 2016 15:53:02 UTC
Severity: normal
Tags: notabug
Found in version 8.21
Done: Eric Blake <eblake <at> redhat.com>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
Your bug report
#22432: owner,group and mode options are only applied to the deepest directory
which was filed against the coreutils package, has been closed.
The explanation is attached below, along with your original report.
If you require more details, please reply to 22432 <at> debbugs.gnu.org.
--
22432: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=22432
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
[Message part 3 (text/plain, inline)]
tag 22432 notabug
thanks
On 01/22/2016 04:42 AM, Hans Lambermont wrote:
> Package: coreutils
> Version: 8.21
>
> When 'install' creates nested directories the options for owner,group and mode
> are only applied to the deepest directory.
Thanks for the report, but this is documented. Per 'info install':
• If the ‘--directory’ (‘-d’) option is given, ‘install’ creates each
DIRECTORY and any missing parent directories. Parent directories
are created with mode ‘u=rwx,go=rx’ (755), regardless of the ‘-m’
option or the current umask. *Note Directory Setuid and Setgid::,
for how the set-user-ID and set-group-ID bits of parent directories
are inherited.
If you want to create parent directories with specific permissions, you
have to do multiple invocations.
As such, I'm closing this as not a bug, but feel free to add further
comments to this thread.
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
[signature.asc (application/pgp-signature, attachment)]
[Message part 5 (message/rfc822, inline)]
Package: coreutils
Version: 8.21
When 'install' creates nested directories the options for owner,group and mode
are only applied to the deepest directory.
Example, when I run as root :
install -o "www-data" -g "models" --mode=2775 -d /tmp/00/00/00/00
ls -la /tmp/00/00/00/00
drwxrwsr-x 2 www-data models 4096 Jan 21 16:38 .
drwxr-xr-x 3 root root 4096 Jan 21 16:38 ..
This shows that /tmp/00/00/00/ is owned by root:root and has 755 as permissions.
The same holds for the just created /tmp/00/00/ and /tmp/00/ .
Only /tmp/00/00/00/00/ is correct.
All created directories should get the given owner,group and mode options.
System: Ubuntu 12.04.5 LTS
GNU coreutils 8.21 (deb 8.21-1ubuntu5.3 amd64)
-- Hans Lambermont
This bug report was last modified 9 years and 124 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.