(self, options, args)
| 1572 | return "\n".join(lines) |
| 1573 | |
| 1574 | def run(self, options, args): |
| 1575 | self.manager.kill_osd(self.osd) |
| 1576 | cmd = self.build_cmd(options, args, None) |
| 1577 | self.manager.log(cmd) |
| 1578 | try: |
| 1579 | proc = self.remote.run(args=['bash', '-e', '-x', '-c', cmd], |
| 1580 | check_status=False, |
| 1581 | stdout=BytesIO(), |
| 1582 | stderr=BytesIO()) |
| 1583 | proc.wait() |
| 1584 | if proc.exitstatus != 0: |
| 1585 | self.manager.log("failed with " + str(proc.exitstatus)) |
| 1586 | error = proc.stdout.getvalue().decode() + " " + \ |
| 1587 | proc.stderr.getvalue().decode() |
| 1588 | raise Exception(error) |
| 1589 | finally: |
| 1590 | if self.do_revive: |
| 1591 | self.manager.revive_osd(self.osd) |
| 1592 | self.manager.wait_till_osd_is_up(self.osd, 300) |
| 1593 | |
| 1594 | |
| 1595 | # XXX: this class has nothing to do with the Ceph daemon (ceph-mgr) of |
no test coverage detected