From: Matan Breizman Date: Wed, 19 Nov 2025 13:49:36 +0000 (+0200) Subject: teuthology/task/pexec.py: add logs to command executed X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=69deb61c943d1091dc794aada3fc1e8accbd6996;p=teuthology.git teuthology/task/pexec.py: add logs to command executed The current output by pexec is: ``` INFO:teuthology.run_tasks:Running task pexec... INFO:teuthology.task.pexec:Executing custom commands... INFO:teuthology.task.pexec:Running commands on host ubuntu@smithi012.front.sepia.ceph.com DEBUG:teuthology.orchestra.run.smithi012:> TESTDIR=/home/ubuntu/cephtest bash -s ``` The output should include the acutal command executed, similar to exec.py: ``` INFO:teuthology.run_tasks:Running task exec... INFO:teuthology.task.exec:Executing custom commands... INFO:teuthology.task.exec:Running commands on role client.0 host ubuntu@smithi168.front.sepia.ceph.com DEBUG:teuthology.orchestra.run.smithi168:> sudo TESTDIR=/home/ubuntu/cephtest bash -c 'sudo ceph osd pool create low_tier 4' ``` Signed-off-by: Matan Breizman --- diff --git a/teuthology/task/pexec.py b/teuthology/task/pexec.py index 4d18d2719..d61979e9c 100644 --- a/teuthology/task/pexec.py +++ b/teuthology/task/pexec.py @@ -34,7 +34,6 @@ def _do_barrier(barrier, barrier_queue, remote): def _exec_host(barrier, barrier_queue, remote, sudo, testdir, ls): """Execute command remotely""" - log.info('Running commands on host %s', remote.name) args = [ 'TESTDIR={tdir}'.format(tdir=testdir), 'bash', @@ -57,6 +56,9 @@ def _exec_host(barrier, barrier_queue, remote, sudo, testdir, ls): r.stdin.writelines(['\n']) r.stdin.flush() r.stdin.close() + log.info('Running commands on host %s', remote.name) + for l in ls: + log.info('%s', l) tor.wait([r]) def _generate_remotes(ctx, config):