lock_path config option seems to have no effect

Bug #1347915 reported by Alex Meade on 2014-07-23
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Valeriy Ponomaryov

Bug Description

It seems that manila always tries to create lock files in the current working directory for the manila service and ignores the 'lock_path' configuration option. This is a problem on systems where the manila service does not have permissions to write to the working directory and results in the following issue where the share service cannot start.

See: http://paste.openstack.org/show/87836/

Alex Meade (alex-meade) wrote :

This seems to be an issue with the current manila/openstack/common/lockutils.py which means this may affect other openstack projects as well.

1) There is no such option as 'lock_file' in configuration.
2) There are option 'lock_path', that has default value to env var 'MANILA_LOCK_PATH', see:

So, this can be changed in 2 (two) ways:

- set env var 'MANILA_LOCK_PATH' to some value, for example:
export MANILA_LOCK_PATH=/tmp/
It will use this dir as lock storage.

- set 'lock_path' opt in Manila's configuration.

In conclusion: there is no bug in Manila code, there is wrong configuration.

Changed in manila:
status: New → Invalid
Alex Meade (alex-meade) wrote :

Yeah i meant 'lock_path' and the bug is meant to say that specifying it in the config has no effect.

Changed in manila:
status: Invalid → New
description: updated
Changed in manila:
assignee: nobody → Valeriy Ponomaryov (vponomaryov)
status: New → In Progress

Reviewed: https://review.openstack.org/109562
Committed: https://git.openstack.org/cgit/stackforge/manila/commit/?id=fe675be8329a29674436f6e9bfcd5eac87989249
Submitter: Jenkins
Branch: master

commit fe675be8329a29674436f6e9bfcd5eac87989249
Author: Valeriy Ponomaryov <email address hidden>
Date: Fri Aug 22 06:05:55 2014 -0400

    Updated usage of locks

    - replaced direct usage of sychronized func from lockutils with local wrapper,
      that provides prefix;
    - 'lock_path' is not provided anymore as hardcode, defined 'lock_path'
      in config is expected;
    - added MANILA_LOCK_PATH to devstack plugin, to be able to set path
      before installation.

    Change-Id: I6518df0a6d32f1021b19a48f928f9ec8b00140b2
    Closes-Bug: #1347915

Changed in manila:
status: In Progress → Fix Committed
Changed in manila:
status: Fix Committed → Fix Released
Changed in manila:
milestone: none → juno-3
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers