my $socket = $ssh->socket; my $chan = $ssh->channel(); $chan->exec("/sbin/fwupdate -m\n"); close $socket; $ssh->disconnect; #### my $chan = $ssh->channel(); $ssh->blocking(0); $chan->exec("/sbin/fwupdate -m\n"); #### use Net::OpenSSH; my $ssh = Net::OpenSSH->new($host, timeout => 30); $ssh->scp_put($firmware[$antenna_type],'/tmp/fwupdate.bin'); $ssh->system("/sbin/fwupdate -m\n");