jsvc cannot find libcap.so on debian-based distributions
--------------------------------------------------------

                 Key: DAEMON-242
                 URL: https://issues.apache.org/jira/browse/DAEMON-242
             Project: Commons Daemon
          Issue Type: Bug
          Components: Jsvc
    Affects Versions: 1.0.9
         Environment: Debian 6.0.2
Ubuntu 11.04
            Reporter: Phil Clay


Debian-based distributions do not symlink the "main" shared object to the major 
version.

For example:

On RHEL4u4:
$ ls -l /lib/libcap.so*
lrwxrwxrwx  1 root root    11 Jun 13  2007 /lib/libcap.so -> libcap.so.1
lrwxrwxrwx  1 root root    14 Jun 12  2007 /lib/libcap.so.1 -> libcap.so.1.10
-rwxr-xr-x  1 root root 11784 Oct  7  2006 /lib/libcap.so.1.10

Notice libcap.so -> libcap.so.1


On Debian 6.02:
$ ls -l /lib/libcap.so*
lrwxrwxrwx 1 root root    14 Jan 25 10:19 /lib/libcap.so.2 -> libcap.so.2.19
-rw-r--r-- 1 root root 16640 Aug 16  2010 /lib/libcap.so.2.19


On Ubuntu 11.04:
$ ls -l /lib/libcap.so*
lrwxrwxrwx 1 root root    14 2011-07-16 09:52 /lib/libcap.so.2 -> libcap.so.2.20
-rw-r--r-- 1 root root 13816 2011-02-15 14:35 /lib/libcap.so.2.20

Notice there is no libcap.so -> libcap.so.2

Therefore, when jsvc attempts to load libcap.so, it fails...

I see this when running jsvc -debug ...

Attemtping to load library /lib/libcap.so
Attemtping to load library /usr/lib/libcap.so
failed loading capabilities library -- /usr/lib/libcap.so: cannot open shared 
object file: No such file or directory.
set_caps(CAPS) failed for user 'oncommand'
Service exit with a return value of 4


If I create the libcap.so -> libcap.so.2 symlink, it works.

I'm guessing the fix for this would be to load libcap.so, libcap.so.2, 
libcap.so.1 in progression to see if any work.

(Note that I have performed the workaround I mentioned in 
https://issues.apache.org/jira/browse/DAEMON-241 to get this far.)


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to