TestClientNagles is failing due to incorrect command being executed

Description

test_qdel_nagle_perf in TestClientNagles is failing due to a incorrect command being executed.

Analysis:

The command formed and executed is :

/usr/bin/time -f "%e" /opt/pbs/bin/qdel `qselect`

On further analysis, and running with DEBUG mode, following was observed:

2017-11-20 01:49:58,595 INFO submit to x53-c6p6 as pbsuser1: job 5042.x53-c6p6

2017-11-20 01:49:58,596 INFOCLI2 x53-c6p6: /tmp/PtlPbsHDIHvY

Contents of /tmp/PtlPbsHDIHvY:

----------------------------------------

#!/bin/bash

time -f "%e" /opt/pbs/bin/qdel `qselect`

----------------------------------------

2017-11-20 01:49:58,650 INFOCLI2 x53-c6p6: /opt/tools/wrappers/rm /tmp/PtlPbsHDIHvY

2017-11-20 01:49:58,661 DEBUG out: []

2017-11-20 01:49:58,662 DEBUG err: []

2017-11-20 01:49:58,662 DEBUG rc: 0

2017-11-20 01:49:58,662 DEBUG out: []

2017-11-20 01:49:58,662 DEBUG err: ['/tmp/PtlPbsHDIHvY: line 2: -f: command not found', '', 'real\t0m0.044s', 'user\t0m0.022s', 'sys\t0m0.014s']

2017-11-20 01:49:58,663 DEBUG rc: 127

2017-11-20 01:49:58,665 INFO FAILED

Also , running the same command on command line gives following error:

[root@x53-c6p6 performance]# time -f "%e" /opt/pbs/bin/qdel `qselect`
bash: -f: command not found

real 0m0.043s
user 0m0.022s
sys 0m0.014s
[root@x53-c6p6 performance]#

The return value of execution of this command is checked against -1, which causes it to fail as shown below

Attached logs of TH2 for reference:

2017-11-19 21:30:27,330 INFOCLI2 x55-s12: sudo -H -u pbsuser1 /tmp/PtlPbsljTvMY Contents of /tmp/PtlPbsljTvMY: ---------------------------------------- #!/bin/bash /usr/bin/time -f "%e" /opt/pbs/bin/qdel `qselect` ---------------------------------------- 2017-11-19 21:30:27,361 INFOCLI2 x55-s12: /opt/tools/wrappers/rm /tmp/PtlPbsljTvMY Traceback (most recent call last): File "/home/pbsroot/TEST/tmp/tests/performance/pbs_client_nagle_performance.py", line 126, in test_qdel_nagle_perf self.assertTrue((qdel_perf != -1), "qdel command failed") AssertionError: qdel command failed test duration: 0:00:20.938792

Attached Job ID for reference:

321443 PDO-924_run2 18.2.0.20171103014109 TestClientNagles vishrut x55-s12 0:06:54 FAIL 1 1 0 0 0 0

Acceptance Criteria

None

Status

Assignee

Dinesh Joshi

Reporter

Vishrut Arora

Severity

3-High

OS

None

Start Date

None

Pull Request URL

None

Story Points

4

Components

Priority

Low
Configure