Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#34803 - [python2] Incorrect permissions for some .pyc files

Attached to Project: Arch Linux
Opened by Peter Wu (Lekensteyn) - Tuesday, 16 April 2013, 07:23 GMT
Last edited by Stéphane Gaudreault (stephane) - Tuesday, 16 April 2013, 12:42 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To No-one
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Trying to md5sum my /usr, I found that some pyc files have incorrect permissions set. The files are known in the database though (pacman -Qo)

md5sum: /usr/lib/python2.7/sre_compile.pyc: Permission denied
md5sum: /usr/lib/python2.7/warnings.pyc: Permission denied
md5sum: /usr/lib/python2.7/string.pyc: Permission denied
md5sum: /usr/lib/python2.7/struct.pyc: Permission denied
md5sum: /usr/lib/python2.7/genericpath.pyc: Permission denied
md5sum: /usr/lib/python2.7/pickle.pyc: Permission denied
md5sum: /usr/lib/python2.7/locale.pyc: Permission denied
md5sum: /usr/lib/python2.7/site.pyc: Permission denied
md5sum: /usr/lib/python2.7/codecs.pyc: Permission denied
md5sum: /usr/lib/python2.7/sre_constants.pyc: Permission denied
md5sum: /usr/lib/python2.7/sre_parse.pyc: Permission denied
md5sum: /usr/lib/python2.7/subprocess.pyc: Permission denied
md5sum: /usr/lib/python2.7/abc.pyc: Permission denied
md5sum: /usr/lib/python2.7/gettext.pyc: Permission denied
md5sum: /usr/lib/python2.7/encodings/utf_8.pyc: Permission denied
md5sum: /usr/lib/python2.7/encodings/__init__.pyc: Permission denied
md5sum: /usr/lib/python2.7/encodings/aliases.pyc: Permission denied
md5sum: /usr/lib/python2.7/stat.pyc: Permission denied
md5sum: /usr/lib/python2.7/sysconfig.pyc: Permission denied
md5sum: /usr/lib/python2.7/curses/__init__.pyc: Permission denied
md5sum: /usr/lib/python2.7/curses/wrapper.pyc: Permission denied
md5sum: /usr/lib/python2.7/weakref.pyc: Permission denied
md5sum: /usr/lib/python2.7/types.pyc: Permission denied
md5sum: /usr/lib/python2.7/optparse.pyc: Permission denied
md5sum: /usr/lib/python2.7/_abcoll.pyc: Permission denied
md5sum: /usr/lib/python2.7/pprint.pyc: Permission denied
md5sum: /usr/lib/python2.7/copy.pyc: Permission denied
md5sum: /usr/lib/python2.7/functools.pyc: Permission denied
md5sum: /usr/lib/python2.7/os.pyc: Permission denied
md5sum: /usr/lib/python2.7/fnmatch.pyc: Permission denied
md5sum: /usr/lib/python2.7/linecache.pyc: Permission denied
md5sum: /usr/lib/python2.7/copy_reg.pyc: Permission denied
md5sum: /usr/lib/python2.7/posixpath.pyc: Permission denied
md5sum: /usr/lib/python2.7/UserDict.pyc: Permission denied
md5sum: /usr/lib/python2.7/traceback.pyc: Permission denied
md5sum: /usr/lib/python2.7/__future__.pyc: Permission denied
md5sum: /usr/lib/python2.7/platform.pyc: Permission denied
md5sum: /usr/lib/python2.7/textwrap.pyc: Permission denied
md5sum: /usr/lib/python2.7/socket.pyc: Permission denied
md5sum: /usr/lib/python2.7/ctypes/_endian.pyc: Permission denied
md5sum: /usr/lib/python2.7/ctypes/__init__.pyc: Permission denied
md5sum: /usr/lib/python2.7/_weakrefset.pyc: Permission denied
md5sum: /usr/lib/python2.7/re.pyc: Permission denied

Package version: 2.7.4-1
This task depends upon

Closed by  Stéphane Gaudreault (stephane)
Tuesday, 16 April 2013, 12:42 GMT
Reason for closing:  Works for me
Additional comments about closing:  Permissions are correct.
Comment by Stéphane Gaudreault (stephane) - Tuesday, 16 April 2013, 11:45 GMT
Permissions are correct here.

What are the permission for these files on your system ?

Also please check permissions on
/
/usr
/usr/lib
/usr/lib/python2.7
Comment by Peter Wu (Lekensteyn) - Tuesday, 16 April 2013, 12:30 GMT
The permissions of /usr/lib/python2.7 are fine. It seems that the files have been regenerated by some process.

$ ls -altr
...
drwxr-xr-x 60 root root 4096 Apr 12 22:03 site-packages
-rw-r----- 1 root root 19803 Apr 16 09:08 site.pyc
-rw-r----- 1 root root 11249 Apr 16 09:08 posixpath.pyc
-rw-r----- 1 root root 25451 Apr 16 09:08 os.pyc
-rw-r----- 1 root root 2731 Apr 16 09:08 stat.pyc
-rw-r----- 1 root root 3243 Apr 16 09:08 genericpath.pyc
-rw-r----- 1 root root 13094 Apr 16 09:08 warnings.pyc
-rw-r----- 1 root root 2494 Apr 16 09:08 types.pyc
...

I cannot remember what I was doing at that moment, no pacman upgrades at least. journald is broken again and does not show any logs. (fsck you journald, why can't you fscking be reliable? Restarting systemd-journald does not help, `logger 'Give my logs back!'` does not print anything, /dev/log does not exist if that matters.) [/end rant about journald failure]

Now I need to figure out why these files are regenerated in the first place, python shouldn't randomly place files over the filesystem.

Loading...