05-30-2018 05:48 AM - edited 03-01-2019 06:27 AM
Hi,
i am executing a command python script over SSH on a remote Linux host and it is ending prematurely.
i'm issuing this:
python3 /path/to/script --vars ...
sleep 3
and i expect:
****
arguments: ....****
response: ....
there's a few seconds of delay between the 2 sections and for some reason, the arguments get printed in service request logs but the task finishes before the response shows up. i've tried longer sleep duration, i've tried adding constant output by the script, empty rows at the end of output... but nothing seems to keep the script from ending prematurely.
05-30-2018 08:44 AM
This ssh task does a new session with every line in your script. You may want in this case use a built in ssh task
05-30-2018 08:04 PM
Which ssh task are you using. There are a few built into UCSD and then I have one on the community site as well.
06-27-2018 04:29 AM
i ended up using the enhanced SSH command which has a delay between commands which makes sure the task doesn't end before the output is printed.
06-27-2018 04:54 AM
I usually use this
https://communities.cisco.com/docs/DOC-60468
to make sure certain things are done (install of ESXi and 443 is up) and test before I have the workflow move on.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide