Hello archeman2,
Since you are using already Net::OpenSSH why don't you use Running remote commands with sudo (FAQ) which already implemented?
I had similar problem in the past and I have tried many modules trying to resolve it (Best module to execute administrator commands on external operating systems (Linux)).
I do not know if you are interested it can also be achieved with parallel ssh connections running ssh commands (Net::OpenSSH::Parallel with sudo commands).
From my point of view I would set up ssh-exchange as root so you do not need to provide password when you ssh and then apply the commands that you want as root. This is much much more safer than applying psw through ssh. Think about it.
Hope this helps.
In reply to Re: Expect OpenSSH sudo login is failing
by thanos1983
in thread Expect OpenSSH sudo login is failing
by archeman2
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |