]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
qa/cephfs: run nsenter commands with superuser privileges
authorRishabh Dave <ridave@redhat.com>
Wed, 29 Apr 2020 18:10:16 +0000 (23:40 +0530)
committerRishabh Dave <ridave@redhat.com>
Tue, 2 Jun 2020 11:37:49 +0000 (17:07 +0530)
commit04d501d6ff7b84378a6074ad6c6f2f0c1b91baa3
tree416293667022bd8dc99be2fc7b9ef18fdefa65eb
parentea1432810c18d15c405f3a4864db983ad5cca91d
qa/cephfs: run nsenter commands with superuser privileges

And add a method that sets self.fuse_daemon.subproc.pid to the PID of
the process that doesn't have sudo in its arguments. For example, when
"sudo ceph-fuse /mnt/cephfs" is run on the shell, it launches process
with arguments "ceph-fuse /mnt/cephfs". The added method gets PID of
latter/child process and sets that as the fuse daemon's PID. Not doing
so kills the former/parent process but the not the child process.

Also, since we are around cleanup this method a bit.

Fixes: https://tracker.ceph.com/issues/45339
Signed-off-by: Rishabh Dave <ridave@redhat.com>
qa/tasks/vstart_runner.py