Hi.
today we start a fresh install to move our cloud to new machine.
we install CentOS7 using netinstall, and after using the rpm from centos7
at first all fine. service start, and run (opennebula.service opennebula-sunstone)
but… if we reboot the machine and launch the comand we retreived an error:
Dec 15 10:23:29 nebula systemd: Starting OpenNebula Cloud Controller Daemon... Dec 15 10:23:29 nebula systemd: Started OpenNebula Cloud Controller Daemon. Dec 15 10:23:29 nebula systemd: Starting OpenNebula Cloud Scheduler Daemon... Dec 15 10:23:29 nebula systemd: Started OpenNebula Cloud Scheduler Daemon. Dec 15 10:23:29 nebula oned: Error: Cannot start oned, opening lock file /var/lock/one/one Dec 15 10:23:30 nebula systemd: opennebula.service: main process exited, code=exited, status=255/n/a Dec 15 10:23:30 nebula systemd: Stopping OpenNebula Cloud Scheduler Daemon... Dec 15 10:23:30 nebula kill: Usage: Dec 15 10:23:30 nebula kill: kill [options] <pid|name> [...] Dec 15 10:23:30 nebula kill: Options: Dec 15 10:23:30 nebula kill: -a, --all do not restrict the name-to-pid conversion to processes Dec 15 10:23:30 nebula kill: with the same uid as the present process Dec 15 10:23:30 nebula kill: -s, --signal <sig> send specified signal Dec 15 10:23:30 nebula kill: -q, --queue <sig> use sigqueue(2) rather than kill(2) Dec 15 10:23:30 nebula kill: -p, --pid print pids without signaling them Dec 15 10:23:30 nebula kill: -l, --list [=<signal>] list signal names, or convert one to a name Dec 15 10:23:30 nebula kill: -L, --table list signal names and numbers Dec 15 10:23:30 nebula kill: -h, --help display this help and exit Dec 15 10:23:30 nebula kill: -V, --version output version information and exit Dec 15 10:23:30 nebula kill: For more details see kill(1). Dec 15 10:23:30 nebula systemd: opennebula.service: control process exited, code=exited status=1 Dec 15 10:23:30 nebula systemd: Stopped OpenNebula Cloud Controller Daemon. Dec 15 10:23:30 nebula systemd: Unit opennebula.service entered failed state. Dec 15 10:23:30 nebula systemd: Stopped OpenNebula Cloud Scheduler Daemon.
similar error
`[root@nebula ~]# systemctl status opennebula.service
opennebula.service - OpenNebula Cloud Controller Daemon
Loaded: loaded (/usr/lib/systemd/system/opennebula.service; disabled)
Active: failed (Result: exit-code) since mar 2015-12-15 10:23:30 CET; 6min ago
Process: 1133 ExecStop=/bin/kill -TERM $MAINPID (code=exited, status=1/FAILURE)
Process: 1129 ExecStart=/usr/bin/oned -f (code=exited, status=255)
Process: 1126 ExecStartPre=/bin/chown oneadmin:oneadmin /var/log/one (code=exited, status=0/SUCCESS)
Process: 1124 ExecStartPre=/bin/mkdir -p /var/log/one (code=exited, status=0/SUCCESS)
Main PID: 1129 (code=exited, status=255)
dic 15 10:23:30 nebula.cesga.es kill[1133]: -q, --queue use sigqueue(2) rather than kill(2)
dic 15 10:23:30 nebula.cesga.es kill[1133]: -p, --pid print pids without signaling them
dic 15 10:23:30 nebula.cesga.es kill[1133]: -l, --list [=] list signal names, or convert one to a name
dic 15 10:23:30 nebula.cesga.es kill[1133]: -L, --table list signal names and numbers
dic 15 10:23:30 nebula.cesga.es kill[1133]: -h, --help display this help and exit
dic 15 10:23:30 nebula.cesga.es kill[1133]: -V, --version output version information and exit
dic 15 10:23:30 nebula.cesga.es kill[1133]: For more details see kill(1).
dic 15 10:23:30 nebula.cesga.es systemd[1]: opennebula.service: control process exited, code=exited status=1
dic 15 10:23:30 nebula.cesga.es systemd[1]: Stopped OpenNebula Cloud Controller Daemon.
dic 15 10:23:30 nebula.cesga.es systemd[1]: Unit opennebula.service entered failed state.
`
the file instaled:
``[root@nebula ~]# cat /usr/lib/systemd/system/opennebula.service
[Unit]
Description=OpenNebula Cloud Controller Daemon
After=syslog.target
After=network.target
After=remote-fs.target
After=mariadb.service
Before=opennebula-scheduler.service
BindTo=opennebula-scheduler.service
[Service]
Type=simple
Group=oneadmin
User=oneadmin
# Start daemon in forground mode, when starting as forking process the
# daemon shuts down without obvious reason.
ExecStart=/usr/bin/oned -f
# Log file location must exist
ExecStartPre=/bin/mkdir -p /var/log/one
ExecStartPre=/bin/chown oneadmin:oneadmin /var/log/one
ExecStop=/bin/kill -TERM $MAINPID
PIDFile=/var/run/one/oned.pid
[Install]
WantedBy=multi-user.target
any idea? i think the kill not work with $MAINPID but not sure how fix.
Thanks in advance.