in reply to Forking and Net::SSH::Perl

You can not share an Net::SSH::Perl connection between different processes. It just doesn't work.

You have to open a new connection from every child. If that slows down your script too much, reimplement it using a workers+queue aproach.

And BTW, you can get OpenSSH packed for Solaris from Sunfreeware. Net::OpenSSH does support sharing the SSH connection with child processes.

Replies are listed 'Best First'.
Re^2: Forking and Net::SSH::Perl
by eff_i_g (Curate) on Apr 05, 2011 at 14:34 UTC
      Thread::Queue may be a good choice as sharing data between threads is easier than between processes but you will have to check that Net::SSH::Perl and its dependencies are thread safe.

      In any case, I am not an expert in that area, you will probably get better answers if you post a new question.