block.wipe_volume(mode='pvremove') fails on ubuntu precise

Bug #1592962 reported by Wesley Wiedenmeier
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
curtin
Fix Released
Undecided
Wesley Wiedenmeier

Bug Description

On versions of ubuntu trusty and up, lvmetad keeps a cache of pvscan results. In order to refresh this cache after pvremove has been run, block.wipe_volume therefore uses 'pvscan --cache'. However, on ubuntu precise, lvmetad is not yet present. The pvscan utility does not have a --cache flag. That results in block.wipe_volume stacktracing:

ubuntu@ubuntu:/curtin$ sudo python
Python 2.7.3 (default, Jun 22 2015, 19:33:41)
[GCC 4.6.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> from curtin import block
>>> block.wipe_volume('/dev/vdb5', mode='pvremove')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "curtin/block/__init__.py", line 666, in wipe_volume
    util.subp(cmd, rcs=[0, 5], capture=True)
  File "curtin/util.py", line 141, in subp
    return _subp(*args, **kwargs)
  File "curtin/util.py", line 91, in _subp
    cmd=args)
curtin.util.ProcessExecutionError: Unexpected error while running command.
Command: ['pvscan', '--cache']
Exit code: 3
Reason: -
Stdout: ''
Stderr: u"pvscan: unrecognized option '--cache'\n Error during parsing of comma
nd line.\n"

Related branches

Changed in curtin:
assignee: nobody → Wesley Wiedenmeier (wesley-wiedenmeier)
Changed in curtin:
status: New → Incomplete
status: Incomplete → Confirmed
Changed in curtin:
status: Confirmed → Fix Committed
Revision history for this message
Scott Moser (smoser) wrote : Fixed in Curtin 17.1

This bug is believed to be fixed in curtin in 17.1. If this is still a problem for you, please make a comment and set the state back to New

Thank you.

Changed in curtin:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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