startup failure, Can't check status of PID <nnnn> from pidfile .../buildslave/twistd.pid: Operation not permitted

Bug #512708 reported by Erno Kuusela
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
twisted (Ubuntu)
New
Undecided
Unassigned

Bug Description

Binary package hint: python-twisted-core

After an unclean shutdown, I got an error message like this on "buildbot start ." in the buildslave dir:

Can't check status of PID <nnnn> from pidfile .../buildslave/twistd.pid: Operation not permitted

Interestingly the pid turned out to be a thread id beloning to another process and it seems kill(2) always returns EPERM for it, even when i tried it as root from the shell...

The relevant code is around lines 74-82 of /usr/share/pyshared/twisted/scripts/_twistd_unix.py:

        try:
            os.kill(pid, 0)
        except OSError, why:
            if why[0] == errno.ESRCH:
                # The pid doesnt exists.
                log.msg('Removing stale pidfile %s' % pidfile, isError=True)
                os.remove(pidfile)
            else:
                sys.exit("Can't check status of PID %s from pidfile %s: %s" %
                         (pid, pidfile, why[1]))

and the EPERM as shown by strace:

2702 kill(1403, SIG_0) = -1 EPERM (Operation not permitted)
2702 write(2, "Can't check status of PID 1403 f"..., 107) = 107

Details per guidelines:

> 1) The release of Ubuntu you are using, via 'lsb_release -rd' or System -> About Ubuntu.

Release: 9.10

> 2) The version of the package you are using, via 'apt-cache policy packagename' or by checking in Synaptic

Source: twisted
Version: 8.2.0-3

> 3) What you expected to happen

buildbot to start

> 4) What happened instead

buildbot didn't start

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.