You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am targeting a simple perl loop, in which I with ssh->cmd will execute a command on a remote host. This code should run in the back ground on the mother host.
The following simple code shows my observation.
use Net::SSH::Perl;
$host = Net::SSH::Perl->new("remotehost");
$host->login();
while (1) {
print `date`;
($out, $err, $exit) = $host->cmd("sleep 10");
}
Now, call the code test.pl and run "./test.pl". Command "top" running in another shell on the mother host does not show anything suspicious. Now I would like to have the code running in the background and thus I do "./test.pl </dev/null 1>/dev/null 2>/dev/null &". Now the "top" command shows my little program eating up one full processor. This puzzles me very much indeed and I am speculating, if this is a bug or a feature.
Thanks for any help in advance.
Best regards.
Thomas.
The text was updated successfully, but these errors were encountered:
This ticket was imported from rt.cpan.org 43780
Hi'
I am targeting a simple perl loop, in which I with ssh->cmd will execute a command on a remote host. This code should run in the back ground on the mother host.
The following simple code shows my observation.
Now, call the code test.pl and run "./test.pl". Command "top" running in another shell on the mother host does not show anything suspicious. Now I would like to have the code running in the background and thus I do "./test.pl </dev/null 1>/dev/null 2>/dev/null &". Now the "top" command shows my little program eating up one full processor. This puzzles me very much indeed and I am speculating, if this is a bug or a feature.
Thanks for any help in advance.
Best regards.
Thomas.
The text was updated successfully, but these errors were encountered: