On 09/13/2012 10:20 PM, Dan Wendlandt wrote:
On Thu, Sep 13, 2012 at 5:47 AM, Gary Kotton<[email protected]> wrote:
Hi,
A little more information:
[root@(none) lib]# systemctl status quantum-dhcp-agent.service
quantum-dhcp-agent.service - OpenStack Quantum DHCP Agent
Loaded: loaded (/usr/lib/systemd/system/quantum-dhcp-agent.service;
disabled)
Active: failed (Result: exit-code) since Thu, 13 Sep 2012 08:45:12
-0400; 20s ago
Process: 1883 ExecStart=/usr/bin/quantum-dhcp-agent --config-file
/etc/quantum/quantum.conf --config-file /etc/quantum/dhcp_agent.ini
--log-file /var/log/quantum/dhcp_agent.log (code=exited, status=1/FAILURE)
CGroup: name=systemd:/system/quantum-dhcp-agent.service
Sep 13 08:45:12 Linux quantum-dhcp-agent[1883]: mgr.run()
Sep 13 08:45:12 Linux quantum-dhcp-agent[1883]: File
"/usr/lib/python2.7/site-packages/quantum/agent/dhcp_agent.py", line 84, in
run
Sep 13 08:45:12 Linux quantum-dhcp-agent[1883]: self.lease_relay.start()
Sep 13 08:45:12 Linux quantum-dhcp-agent[1883]: File
"/usr/lib/python2.7/site-packages/quantum/agent/dhcp_agent.py", line 557, in
start
Sep 13 08:45:12 Linux quantum-dhcp-agent[1883]: family=socket.AF_UNIX)
Sep 13 08:45:12 Linux quantum-dhcp-agent[1883]: File
"/usr/lib/python2.7/site-packages/eventlet/convenience.py", line 38, in
listen
Sep 13 08:45:12 Linux quantum-dhcp-agent[1883]: sock.bind(addr)
Sep 13 08:45:12 Linux quantum-dhcp-agent[1883]: File
"/usr/lib64/python2.7/socket.py", line 224, in meth
Sep 13 08:45:12 Linux quantum-dhcp-agent[1883]: return
getattr(self._sock,name)(*args)
Sep 13 08:45:12 Linux quantum-dhcp-agent[1883]: socket.error: [Errno 98]
Address already in use
[root@(none) lib]#
This type of error on a unix socket happens because the socket won't
bind if the file already exists. Therefore, it is standard to unlink
the file if it exists before trying to bind to it.
The DHCPLeaseRelay class seems to be doing this unlinking in the
__init__() method (quantum/agent/dhcp_agent.py). I might be useful to
see if there are differences in the behavior of this unlinking logic
between the scenario where it is working and not working.
Probably best to file a bug on this so we can track comments and such
there. I've filed: https://bugs.launchpad.net/quantum/+bug/1050568
and tagged it with folsom-rc-potential
Sorry, I forgot to update. The problem was when running the agent as a
service (by user Quantum), it was not able to write in a specific
directory where the lease file was maintained. This has been dealt with
on the sie of the packaging. I'll update the bug.
Thanks
Gary
dan
Thanks
Gary
On 09/13/2012 03:06 PM, Gary Kotton wrote:
Hi,
I have run into a problem with the DHCP agent. When it starts as a service
it terminates. I am trying to debug.
Thanks
Gary
--
Mailing list: https://launchpad.net/~quantum-core
Post to : [email protected]
Unsubscribe : https://launchpad.net/~quantum-core
More help : https://help.launchpad.net/ListHelp
--
Mailing list: https://launchpad.net/~quantum-core
Post to : [email protected]
Unsubscribe : https://launchpad.net/~quantum-core
More help : https://help.launchpad.net/ListHelp