Bug 1005432 - Wrong path for lxc global config
Summary: Wrong path for lxc global config
Keywords:
Status: CLOSED INSUFFICIENT_DATA
Alias: None
Product: Fedora
Classification: Fedora
Component: lxc
Version: rawhide
Hardware: All
OS: All
unspecified
high
Target Milestone: ---
Assignee: Thomas Moschny
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-09-06 22:32 UTC by Ranjib Dey
Modified: 2021-09-18 14:43 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-09-14 06:57:01 UTC
Type: Bug


Attachments (Terms of Use)

Description Ranjib Dey 2013-09-06 22:32:36 UTC
Description of problem:

/usr/share/lxc/lxc.functions uses /etc/lxc/lxc.conf (for grepping lxc template path) as global lxc config. It is sourced by lxc-clone bash script (which uses set -e). current lxc rpm ships the global template as /etc/lxc/default.conf. Which causes the grep inside lxc.functions to return non zero, failing the whole clone operation, without any error.

Version-Release number of selected component (if applicable): lxc0.9.0-1.fc21.x86_64

Comment 1 Thomas Moschny 2013-09-09 18:12:00 UTC
The two files serve a different purpose: /etc/lxc/default.conf is the
default configuration for a fresh container, while /etc/lxc/lxc.conf is
a configuration file with settings used by the scripts and binaries
directly.

However, LXC currently does not ship the latter. If lxc-clone fails due
to a non-existent /etc/lxc/lxc.conf that should be fixed: The
get_default_lxcpath() method probably needs an additional if [ -r
"$globalconf" ] ; then ...  fi construct.

Would you mind sending a patch fixing this to the lxc-devel list? The
patch should be against 0.9.0 though (and thus probably applied on a
branch for that version), as in the current staging branch lxc-clone has
been replaced by C code as far as I can see.

Comment 2 Michael H. Warfield 2014-06-04 21:02:51 UTC
Can this be verified against the 1.0.0 branch?  If not, it's going to be a "will not fix".  The fix will be to upgrade.  If it's still a problem, the 1.0.0 branch will be fixed and this will still be a "will not fix" against 0.9.0.

Comment 3 Thomas Moschny 2014-08-08 10:37:48 UTC
Please check whether the problem is still available with lxc-1.0.5-2.fc22.

Comment 4 Thomas Moschny 2014-09-14 06:57:01 UTC
Closing, please re-open if the problem persists.


Note You need to log in before you can comment on or make changes to this bug.