[Bug 431114] [NEW] /var/run/eucalyptus is not being set with correct permissions on machine reboot

Daniel Nurmi dnurmi at gmail.com
Thu Sep 17 02:18:29 BST 2009


Public bug reported:

the eucalyptus init scripts create the:

/var/run/eucalyptus/*

directory(ies) on start, but do not correctly change the ownership of
the created directory(ies).  The init scripts (for example eucalyptus-
cc) call /usr/sbin/euca_conf -check cc on startup:

        if [ ! -d $EUCALYPTUS/var/run/eucalyptus ]; then
                if ! mkdir -p $EUCALYPTUS/var/run/eucalyptus ; then
                        # error should come from mkdir                                                                                                                   
                        exit 1
                fi
                if ! chown $EUCA_USER:$EUCA_GROUP $EUCALYPTUS/var/run/eucalyptus ; then
                        # error should come from chown                                                                                                                   
                        exit 1
                fi
        fi

        if [ "$CHECK" = "cc" ]; then
            if [ ! -d $EUCALYPTUS/var/run/eucalyptus/net ]; then
                if ! mkdir -p $EUCALYPTUS/var/run/eucalyptus/net ; then
                        # error should come from mkdir                                                                                                                   
                    exit 1
                fi
                if ! chown $EUCA_USER:$EUCA_GROUP $EUCALYPTUS/var/run/eucalyptus/net ; then
                        # error should come from chown                                                                                                                   
                    exit 1
                fi
            fi
        fi

it looks like, perhaps, the /var/run/eucalyptus directory has already
been created (by start-stop-daemon?) before this check is run, so the
chown part never gets hit.  The fix has been made upstream (>= r772),
but the fix is simply to move the 'chown' stuff from above outside the
check for whether the directory exists.

** Affects: eucalyptus (Ubuntu)
     Importance: Undecided
         Status: New

-- 
/var/run/eucalyptus is not being set with correct permissions on machine reboot
https://bugs.launchpad.net/bugs/431114
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to eucalyptus in ubuntu.



More information about the Ubuntu-server-bugs mailing list