getstatusoutput() headaches :(

B

Byrom, R (Rob)

hi,
I'm hoping someone can help me :)
I'm using the commands module (under linux) to do the following:
commands.getstatusoutput('/sbin/service network restart')
this is executed in a separate thread from the main executing thread.
However, the separate thread that executes the above hangs forever.
When I attempt to run the above without the thread it works ok. Am I doing
something stupid? I'm thinking the thread is unable to access the
stout/stderr stream which causes it to hang but I've tried running other
commands (such as 'ls' and it works ok).
any help gratefully appreciated,
Rob b
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,169
Messages
2,570,919
Members
47,459
Latest member
Vida00R129

Latest Threads

Top