[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

unremovable directory



I have a problem, I can't update my python-gtk2 because I get this error:

Setting up python-gtk2 (2.8.6-6) ...
Traceback (most recent call last):
  File "/usr/sbin/update-python-modules", line 281, in ?
    process(basedir,install_modules(py_installed))
  File "/usr/sbin/update-python-modules", line 154, in process
    func(basedir, dir, file)
  File "/usr/sbin/update-python-modules", line 125, in install_modules_func
    os.remove(destpath)
OSError: [Errno 1] Operation not permitted:
'/var/lib/python-support/python2.3/pygtk.pth'

I only get this far because I edited the old
/var/lib/dpkg/info/python-gtk2.prerm and commented out all
  update-python-modules -c -i /usr/share/python-support/python-gtk2
and
  update-python-modules -c -i python-gtk
but at the end the update still fails (see above).

If I perform as root

# ls -lad /var/lib/python-support/python2.3/pygtk.pth
dr-xrwsrwx 2 17996 34912 49152 1970-01-03 07:36
/var/lib/python-support/python2.3/pygtk.pth

(weired user, group, permissions, size and date)
and then

# rmdir /var/lib/python-support/python2.3/pygtk.pth
rmdir: /var/lib/python-support/python2.3/pygtk.pth: Operation not permitted

how's about a chown?

# chown -R root. /var/lib/python-support/python2.3/pygtk.pth
chown: changing ownership of
`/var/lib/python-support/python2.3/pygtk.pth': Operation not permitted

or a rm -r?

# rm -r /var/lib/python-support/python2.3/pygtk.pth
rm: remove write-protected directory
`/var/lib/python-support/python2.3/pygtk.pth'? y
rm: remove write-protected directory
`/var/lib/python-support/python2.3/pygtk.pth'? y
rm: cannot remove directory
`/var/lib/python-support/python2.3/pygtk.pth': Operation not permitted

or a chmod?

# chmod -R 755 /var/lib/python-support/python2.3/pygtk.pth
chmod: changing permissions of
`/var/lib/python-support/python2.3/pygtk.pth': Operation not permitted

I guess you get the idea, I'm not allowed to perform any operation on
that directory. An "fsck.ext3 -f .." did complete without errors but I
guess it's a relict of my last crash about two weeks ago (my CPU was the
reason not the OS). I also wasn't able to delete the directory from
within knoppix.

I'm very much clueless, any help is appreciated. How can I get rid of
the directory?



Maybe an strace can help:

# strace rmdir /var/lib/python-support/python2.3/pygtk.pth
execve("/bin/rmdir", ["rmdir", "/var/lib/python-support/python2."...],
[/* 19 vars */]) = 0
uname({sys="Linux", node="oaxaca", ...}) = 0
brk(0)                                  = 0x804c000
access("/etc/ld.so.nohwcap", F_OK)      = -1 ENOENT (No such file or
directory)
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1,
0) = 0xa7f84000
access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or
directory)
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1,
0) = 0xa7f83000
open("/etc/ld.so.cache", O_RDONLY)      = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=142048, ...}) = 0
mmap2(NULL, 142048, PROT_READ, MAP_PRIVATE, 3, 0) = 0xa7f60000
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\0\240O\1"...,
512) = 512
fstat64(3, {st_mode=S_IFREG|0755, st_size=1253868, ...}) = 0
mmap2(NULL, 1259676, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3,
0) = 0xa7e2c000
mmap2(0xa7f56000, 28672, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x12a) = 0xa7f56000
mmap2(0xa7f5d000, 10396, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0xa7f5d000
close(3)                                = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1,
0) = 0xa7e2b000
mprotect(0xa7f56000, 20480, PROT_READ)  = 0
set_thread_area({entry_number:-1 -> 6, base_addr:0xa7e2b6c0,
limit:1048575, seg_32bit:1, contents:0, read_exec_only:0,
limit_in_pages:1, seg_not_present:0, useable:1}) = 0
munmap(0xa7f60000, 142048)              = 0
open("/usr/lib/locale/locale-archive", O_RDONLY|O_LARGEFILE) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=802384, ...}) = 0
mmap2(NULL, 802384, PROT_READ, MAP_PRIVATE, 3, 0) = 0xa7d67000
close(3)                                = 0
brk(0)                                  = 0x804c000
brk(0x806d000)                          = 0x806d000
rmdir("/var/lib/python-support/python2.3/pygtk.pth") = -1 EPERM
(Operation not permitted)
write(2, "rmdir: ", 7rmdir: )                  = 7
write(2, "/var/lib/python-support/python2."...,
43/var/lib/python-support/python2.3/pygtk.pth) = 43
write(2, ": Operation not permitted", 25: Operation not permitted) = 25
write(2, "\n", 1
)                       = 1
close(1)                                = 0
exit_group(1)                           = ?
Process 19752 detached



Reply to: