Public bug reported:

Ubuntu releases : from 14.04 to 16.04 at least
Latest package version with the bug : 4.5.1-0ubuntu1.3

Use case :

 After changing the domU name in /etc/xen/auto/mydomU.cfg my editor creates a 
backup file /etc/xen/auto/mydomU.cfg~
 
 Then, when rebooting, xendomains starts the domU twice : once with the old 
name and once with the new name but using the same virtual block devices then 
corrupting the filesystem on them (btrfs in my case).

 Expected behavior :

 Only the domU configured in /etc/xen/auto/mydomU.cfg should start.

 Proposed solution :

 /etc/init.d/xendomains should enforce not only domU names but
extensions of files  in $XENDOMAINS_AUTO

in 
 do_start_auto()

I suggest changing :

  for file in $XENDOMAINS_AUTO/*; do

to

 for file in $XENDOMAINS_AUTO/*.cfg; do

And document the change (display a message when upgrading xen-utils-
common).


Other consistency checks may be useful like refusing to start a domU using  a 
VBD already in use (but this may be a needed feature of xen-hotplug).

** Affects: xen (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1572446

Title:
  /etc/init.d/xendomains does not filter out backups of domU's
  configuration files

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/xen/+bug/1572446/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to