buildroot icon indicating copy to clipboard operation
buildroot copied to clipboard

XAPI Startup Script Throws an Error in Ubuntu

Open GaoZu opened this issue 11 years ago • 3 comments

This script snippet throws an error:

    while [ ${RETRIES} -ne 0 ]; do
            xe host-shutdown-agent 2> /dev/null
            # Finish if all xapis have gone
            xapi_pids=$(pidof $prog)
            if [ -z "$xapi_pids" ]; then
                    logger "xapi stopped successfully"
                    rm -f $PIDFILE $lockfile
                    success $"xapi stopped successfully"
                    echo
                    return 0
            fi
            sleep 1
            echo -n .
            RETRIES=$(( ${RETRIES} - 1 ))
    done

There is not "success" primitive in Ubuntu, eg, " /etc/init.d/xapi: line 74: success: command not found"

Also, would need good 'HOWTO' once "xenserver-install-wizard && reboot" is performed as XAPI throws quite a few errors regarding prerequisite configurations.

Without XAPI running, cannot log into host with XenCenter for obvious reasons.

GaoZu avatar Sep 20 '14 21:09 GaoZu

Nevermind about the "HOWTO", my issue is fixed after running "xenserver-install-wizard.py". I can connect to the host with XenCenter.

Unless anyone else have something to add. I shall close this in a few days.

GaoZu avatar Sep 20 '14 22:09 GaoZu

I do have a problem that I can't seem to solve: Why is "<row key="host_disabled_until_reboot" value="true"/" always "true", even after I have manually edited "/var/lib/xcp/local.db" and set it to "false"?

With this set to "true", I cannot get the server out of maintenance mode.

GaoZu avatar Sep 20 '14 22:09 GaoZu

check what 'thread_zero' is up to in the logs - if your host is disabled, it's usually because this thread has got stuck doing something.

You can also try 'message-cli diagnostics' which can show messages that are waiting responses.

jonludlam avatar Sep 20 '14 23:09 jonludlam