6
2
From Mac OSX I login to a remote server that handles parallel computing jobs. I am not able to install anything on this server as it is administered by the university. I have multiple jobs running and want to monitor the log file in the following way:
tail -f logfile.log
Right now I have four jobs running, I open four terminal windows, SSH four times into the server, and do the tail
command four times for the different logfiles (which are in different folders on the server).
I have the feeling that I'm doing this in a sub-optimal way and am looking to just SSH once, then from one terminal window open all the four log files in separate windows (or tabs) with the tail
command.
Is this possible? Or is it mandatory to sign in four times?
I updated my answer under the assumption that you might want to actually have multiple osx windows instead of a terminal multiplexer. Is that a correct assumption? – dtmland – 2013-07-16T20:33:33.170
Your original answer did what I wanted. The only problem now is that I can't split vertically as the
screen
command is not patched (and I can't patch without the proper rights), but that's a minor nuisance. – Saaru Lindestøkke – 2013-07-16T20:35:56.920It's worth noting that both screen and tmux allow you to run a command automatically on each new window. So if you use SSH login with a public key, you can open an arbitrary number of SSH sessions, to one or more servers, with just one command, and already split as you wish (I did this often with tmux, never tried with screen). – Paulo Almeida – 2013-07-16T20:44:55.473