New answers tagged

3

Indeed, pssh sounds like the better solution. If you must use parallel it should be fairly simple: pipe the hostnames one per line into a single command that uses {} as a placehold. Eg: consul members | ... awk {'print $2'} | cut -d ":" -f1 | parallel -j 10 sshpass -p "$PASSWORD" ssh -oStrictHostKeyChecking=no -q root@{} "hostname && yum clean all &...


2

Use pssh with ssh host key authentication it's better first, on the local box, as the user to connect with, do ssh-keygen to create a public key then use ssh-copy-id to copy that public key to all the remote servers. then do sometinhg like: pssh -h <(consul members | grep awk {'print $2'} | cut -d ":" -f1) -o /tmp/update-consul-servers -i "yum clean ...


1

If you can SSH to localhost, but you can't SSH from another machine, then either you changed the SSH configuration to forbid SSH from other machines, or there's a firewall that blocks incoming SSH connections. The firewall could be on the same machine, or on any hop between the client you're testing from and that server. If SSH works on the default port but ...


2

Server log says sshd: /etc/ssh/sshd_config: No such file or directory This means the the server is unable to open the file for some reason. Check if the file exists and if it has appropriate permissions (including SELinux labels) ls -lZ /etc/ssh/sshd_config should give you enough information to figure this out (restorecon /etc/ssh/sshd_config should ...


-1

It's because of ip conflict, I have same kind of issue, you should not use the same ip for other vm's. Even if you delete it, ip won't be released. try with another ip in the same network it should work.


-2

Once I faced some weird errors because commented lines were without space between the character # and the text. correct: # no default banner path incorrect: #no default banner path


0

The original question does not make much sense. But I can guess they wanted to ask about the servers A and C in private networks (so they do not "see" each other) and B visible to both of them. In this case, the answer is Remote Port Forwarding. With example: Create a tunnel B->C from C: C$ ssh -R 2222:localhost:22 B and then connecting from A to C like ...


0

@coffeMug I tried out your 1st solution, it will work only if B->C also is password less isn't ? here in my case A->B & C->B are password less. but not B-> C. Maybe, and only maybe C have a config allowing A, but does not communicate directly to A, requiring the middle server B only for the network communication. If that is true. iptables on ...


0

You are in server A: ssh user@serverB ssh user@serverC Or you can use proxy command (see here for more info Proxies and Jump Hosts) as follows: Create a config file under ~/.ssh in server A with following data: Host serverC HostName serverC User user ProxyCommand ssh -l user serverB -W %h:%p Then you can just user ssh serverC ...


2

Ok, apparently I do need openssh-server on Computer A, even though I am in the same network. I read that wrong somewhere else then.


0

The --with-ssl-dir option to the configure should not point directly to the openssl directory, but one level above (the includes are within openssl directory). Configure with --with-ssl-dir=/usr/local/ instead of --with-ssl-dir=/usr/local/openssl makes the cross-compilation work just fine.


3

Use the -N option -N Do not execute a remote command. This is useful for just for- warding ports (protocol version 2 only). Example ssh -fN -L 8999:localhost:6006 host



Top 50 recent answers are included