create vm failed, RequiredOptError: value required for option lock_path in group

Bug #1812497 reported by Zhijiong Zhang
16
This bug affects 2 people
Affects Status Importance Assigned to Milestone
neutron
Fix Released
Low
Lajos Katona

Bug Description

when create vm failed, spawn as follow

2019-01-19 11:39:44.346 1161 INFO neutron.agent.securitygroups_rpc [req-5956adbc-f350-4109-bede-730ad7d9b302 - - - - -] Refresh firewall rules
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent [req-5956adbc-f350-4109-bede-730ad7d9b302 - - - - -] Error in agent loop. Devices info: {'current': set([]), 'timestamps': {}, 'removed': set(['tap8b65ae4f-56', 'tapd17a5148-f8', 'tapf04e93de-6e']), 'added': set([]), 'updated': set(['tapf04e93de-6e'])}: RequiredOptError: value required for option lock_path in group [DEFAULT]
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent Traceback (most recent call last):
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/neutron/plugins/ml2/drivers/agent/_common_agent.py", line 458, in daemon_loop
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent sync = self.process_network_devices(device_info)
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/osprofiler/profiler.py", line 158, in wrapper
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent result = f(*args, **kwargs)
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/neutron/plugins/ml2/drivers/agent/_common_agent.py", line 202, in process_network_devices
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent device_info.get('updated'))
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/neutron/agent/securitygroups_rpc.py", line 268, in setup_port_filters
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent self.refresh_firewall(updated_devices)
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/neutron/agent/securitygroups_rpc.py", line 122, in decorated_function
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent *args, **kwargs)
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/neutron/agent/securitygroups_rpc.py", line 221, in refresh_firewall
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent self._apply_port_filter(device_ids, update_filter=True)
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/neutron/agent/securitygroups_rpc.py", line 157, in _apply_port_filter
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent self.firewall.process_trusted_ports(trusted_devices)
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/contextlib.py", line 24, in __exit__
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent self.gen.next()
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/neutron/agent/firewall.py", line 140, in defer_apply
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent self.filter_defer_apply_off()
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/neutron/agent/linux/iptables_firewall.py", line 885, in filter_defer_apply_off
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent self.iptables.defer_apply_off()
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/neutron/agent/linux/iptables_manager.py", line 440, in defer_apply_off
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent self._apply()
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/neutron/agent/linux/iptables_manager.py", line 456, in _apply
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent with lockutils.lock(lock_name, runtime.SYNCHRONIZED_PREFIX, True):
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/contextlib.py", line 17, in __enter__
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent return self.gen.next()
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/oslo_concurrency/lockutils.py", line 215, in lock
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent ext_lock = external_lock(name, lock_file_prefix, lock_path)
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/oslo_concurrency/lockutils.py", line 146, in external_lock
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent lock_file_path = _get_lock_path(name, lock_file_prefix, lock_path)
2019-01-19 11:39:44.399 1161 ERROR neutron.plugins.ml2.drivers.agent._common_agent File "/usr/lib/python2.7/dist-packages/oslo_concurrency/lockutils.py", line 140, in _get_lock_path

solutions:

set /etc/neutron/neutron.conf

lock_path = /var/lock/neutron

This bug tracker is for errors with the documentation, use the following as a template and remove or add fields as you see fit. Convert [ ] into [x] to check boxes:

- [ ] This doc is inaccurate in this way: ______
- [ ] This is a doc addition request.
- [ ] I have a fix to the document that I can paste below including example: input and output.

If you have a troubleshooting or support issue, use the following resources:

 - Ask OpenStack: http://ask.openstack.org
 - The mailing list: http://lists.openstack.org
 - IRC: 'openstack' channel on Freenode

-----------------------------------
Release: 13.0.3.dev28 on 2019-01-11 04:05
SHA: cdcfce3b82e57cf66efe12bacef2992c95fb86d9
Source: https://git.openstack.org/cgit/openstack/neutron/tree/doc/source/install/compute-install-ubuntu.rst
URL: https://docs.openstack.org/neutron/rocky/install/compute-install-ubuntu.html

summary: - Install and configure compute node in neutron
+ create vm failed, RequiredOptError: value required for option lock_path
+ in group
Revision history for this message
Lajos Katona (lajos-katona) wrote :

Hi, Am I right that you feel that this should be documented?

lock_path is config option for oslo_concurency, the config help for the option:
"Directory to use for lock files. For security, the specified directory should only be writable by the user running the processes that need locking. Defaults to environment variable OSLO_LOCK_PATH. If external locks are used, a lock path must be set. (string value)"

Changed in neutron:
status: New → Confirmed
importance: Undecided → Low
Revision history for this message
Lajos Katona (lajos-katona) wrote :

From other perspective oslo.concurrency's lock_path config option should default to something like /var/lock instead of OSLO_LOCK_PATH environment variable

Revision history for this message
Brian Haley (brian-haley) wrote :

I think this has already been fixed in the latest doc:

https://docs.openstack.org/neutron/latest/install/compute-install-ubuntu.html

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (master)

Fix proposed to branch: master
Review: https://review.openstack.org/632316

Changed in neutron:
assignee: nobody → Lajos Katona (lajos-katona)
status: Confirmed → In Progress
Revision history for this message
Lajos Katona (lajos-katona) wrote :

I added the option for all related docs (Suse, rdo, Ubuntu compute/controller) so now I think it will be consistent for all:
https://review.openstack.org/632316

tags: added: pike queens-backport-potential rocky-backport-potential
tags: added: pike-backport-potential
removed: pike
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (master)

Reviewed: https://review.openstack.org/632316
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=534e85039271d91647173527cd4c4905b9532537
Submitter: Zuul
Branch: master

commit 534e85039271d91647173527cd4c4905b9532537
Author: Lajos Katona <email address hidden>
Date: Tue Jan 22 09:42:51 2019 +0100

    Add lock_path in installation guide

    Oslo_concurrency needs lock_path option, make it consistent in
    documentation for Suse, Redhat and Ubuntu installation guides.

    Change-Id: Ib675d7bf399f2aa7eba9d343fa0f06281d33089a
    Related-Bug: #1796976
    Closes-Bug: #1812497

Changed in neutron:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (stable/rocky)

Fix proposed to branch: stable/rocky
Review: https://review.openstack.org/633169

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (stable/rocky)

Reviewed: https://review.openstack.org/633169
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=573b0be3e86905853b104647ff237fae191eed0b
Submitter: Zuul
Branch: stable/rocky

commit 573b0be3e86905853b104647ff237fae191eed0b
Author: Lajos Katona <email address hidden>
Date: Tue Jan 22 09:42:51 2019 +0100

    Add lock_path in installation guide

    Oslo_concurrency needs lock_path option, make it consistent in
    documentation for Suse, Redhat and Ubuntu installation guides.

    Change-Id: Ib675d7bf399f2aa7eba9d343fa0f06281d33089a
    Related-Bug: #1796976
    Closes-Bug: #1812497
    (cherry picked from commit 534e85039271d91647173527cd4c4905b9532537)

tags: added: in-stable-rocky
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (stable/queens)

Fix proposed to branch: stable/queens
Review: https://review.openstack.org/634680

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (stable/queens)

Reviewed: https://review.openstack.org/634680
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=de9f813928d11b9048d0201caa3cbff60ccbf37b
Submitter: Zuul
Branch: stable/queens

commit de9f813928d11b9048d0201caa3cbff60ccbf37b
Author: Lajos Katona <email address hidden>
Date: Tue Jan 22 09:42:51 2019 +0100

    Add lock_path in installation guide

    Oslo_concurrency needs lock_path option, make it consistent in
    documentation for Suse, Redhat and Ubuntu installation guides.

    Change-Id: Ib675d7bf399f2aa7eba9d343fa0f06281d33089a
    Related-Bug: #1796976
    Closes-Bug: #1812497
    (cherry picked from commit 534e85039271d91647173527cd4c4905b9532537)
    (cherry picked from commit 573b0be3e86905853b104647ff237fae191eed0b)

tags: added: in-stable-queens
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (stable/pike)

Fix proposed to branch: stable/pike
Review: https://review.openstack.org/636295

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (stable/pike)

Reviewed: https://review.openstack.org/636295
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=6098f54722d849d1635436272a87146a273531ec
Submitter: Zuul
Branch: stable/pike

commit 6098f54722d849d1635436272a87146a273531ec
Author: Lajos Katona <email address hidden>
Date: Tue Jan 22 09:42:51 2019 +0100

    Add lock_path in installation guide

    Oslo_concurrency needs lock_path option, make it consistent in
    documentation for Suse, Redhat and Ubuntu installation guides.

    Change-Id: Ib675d7bf399f2aa7eba9d343fa0f06281d33089a
    Related-Bug: #1796976
    Closes-Bug: #1812497
    (cherry picked from commit 534e85039271d91647173527cd4c4905b9532537)
    (cherry picked from commit 573b0be3e86905853b104647ff237fae191eed0b)
    (cherry picked from commit de9f813928d11b9048d0201caa3cbff60ccbf37b)

tags: added: in-stable-pike
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron 14.0.0.0b2

This issue was fixed in the openstack/neutron 14.0.0.0b2 development milestone.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron 11.0.7

This issue was fixed in the openstack/neutron 11.0.7 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron 12.0.6

This issue was fixed in the openstack/neutron 12.0.6 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron 13.0.3

This issue was fixed in the openstack/neutron 13.0.3 release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.