Hello again Sombrerero_loco
I noticed on the sample of your script that you are SSH to multiple nodes:
for my $vh(sort @hosts) {
This kind of processes will force sequential SSH sessions. I can not really test your code since you have provide us only a sample, so I can not replicate your problem.
Update: of course the author knows how to resolve the problem. Just take a look also on similar examples in case you find something useful.
But, in the past I had similar problems I tested any possible way of ssh, telnet modules that I could find. Take a look with working codes examples Best module to execute administrator commands on external operating systems (Linux).
Recently also another monk was asking for something similar (been able to SSH to multiple nodes). I created a working example for him with Net::OpenSSH::Parallel and the example is multiple machines disk space alert.
Similarly if you want to execute also SUDO commands, including example with working code Net::OpenSSH::Parallel with sudo commands.
Hope this helps, maybe to have another approach to your problem.
In reply to Re: Net::OpenSSH problem "controlpath is too long"
by thanos1983
in thread Net::OpenSSH problem "controlpath is too long"
by Sombrerero_loco
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |