Multi-host ssh - how?



  • Hey

    I'm looking for a program lately (must run on linux) that would allow to make multiple ssh connections to different hosts and distribute key-presses to all of them at once. With up to 10 hosts, I'm quite happy with multixterm, but above that I'm starting to have some problems. Main issues are:

    • opening same set of connections another time
    • turning keyboard input on/off for a group hosts (not all that are open)
    • using special keys (home / end / ...)
    • logging in - some hosts will timeout if you have to input all passwords manually
    • delayed execution of some commands (sshd isn't happy with 20 hosts connecting to it at the same time when I do "cvs co ..." over ssh)

    Does anyone know a good solution for that?



  • @viraptor said:

    I'm looking for a program lately (must run on linux) that would allow to make multiple ssh connections to different hosts and distribute key-presses to all of them at once.
    With up to 10 hosts, I'm quite happy with multixterm, but above that I'm starting to have some problems. Main issues are:

    • opening same set of connections another time
    • turning keyboard input on/off for a group hosts (not all that are open)
    • using special keys (home / end / ...)
    • logging in - some hosts will timeout if you have to input all passwords manually
    • delayed execution of some commands (sshd isn't happy with 20 hosts connecting to it at the same time when I do "cvs co ..." over ssh)

    Does anyone know a good solution for that?

    You might be looking for clusterssh, but most likely you want to write a shell/perl script to automate whatever it is that you are doing - as you have noticed, just because you run the same command on each host doesn't mean they all respond in exactly the same way, so you normally need a bit more intelligence than a simple multiplexer. Most problems of this form are best handled by automating them out of existence.

    As for passwords, why the heck aren't you using ssh key authentication?



  • Forgot to mention - clusterssh & multixterm are closest to the thing I need, but not perfect. Clusterssh is just multixterm+specialkeys.

    Why no key auth? Because I'm logging in for the first time to set up those machines sometimes, or logging into system account to su to root and it shouldn't really hold my no-password key, or ... etc.

    Why not with a script? Because I'm basically creating new configuration, testing it, it may be different on some hosts - I don't know yet - only thing I know is they will be 90% the same and I'm waiting for results. I see results because I align all windows in a way that I see last couple of lines in each one - when you see them all, it's really easy to notice if one is different and fix it in just that one window.

    So far it seems the best idea would be to patch multixterm to my needs - just wanted to make sure there's nothing better out there already.


Log in to reply
 

Looks like your connection to What the Daily WTF? was lost, please wait while we try to reconnect.