Project

General

Profile

Actions

Bug #8936

closed

Teuthology: install purge_data remote command looks incorrect.

Added by Anonymous almost 10 years ago. Updated over 9 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
-
% Done:

0%

Source:
other
Tags:
Backport:
Regression:
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Crash signature (v1):
Crash signature (v2):

Description

Is it just me, or does anyone else here think that the extra
semi-colon in the umount line below is a mistake?

def _purge_data(remote):
    """ 
    Purge /var/lib/ceph on remote.

    :param remote: the teuthology.orchestra.remote.Remote object
    """ 
    log.info('Purging /var/lib/ceph on %s', remote)
    remote.run(args=[
        'sudo',
        'rm', '-rf', '--one-file-system', '--', '/var/lib/ceph',
        run.Raw('||'),
        'true',
        run.Raw(';'),
        'test', '-d', '/var/lib/ceph',
        run.Raw('&&'),
        'sudo',
        'find', '/var/lib/ceph',
        '-mindepth', '1',
        '-maxdepth', '2',
        '-type', 'd',
        '-exec', 'umount', '{}', ';',
        run.Raw(';'),
        'sudo',
        'rm', '-rf', '--one-file-system', '--', '/var/lib/ceph',
    ])
Actions #1

Updated by Anonymous over 9 years ago

  • Status changed from New to In Progress
  • Assignee set to Anonymous

I need to figure out if extra semi-colon needs to be escaped differently

Actions #2

Updated by Anonymous over 9 years ago

I now think that the bare ; needs to have escaped quotes around it.

Actions #3

Updated by Anonymous over 9 years ago

  • Status changed from In Progress to Resolved

Okay. The semi-colon is escaped correctly. I think that I got confused because a previous change that I was testing erroneously got here in the first place.

Actions

Also available in: Atom PDF