There are two general methods to use. One will not be discussed here fully
but rather mentioned in passing, which is that each user gets an
empty-passphrase key, which is then copied into their authorized_keys file.
We used this for several years, and while it certainly works, it is awfully
ugly to manage. Tip: use id_rsa_pbs as the key name so as not to interfere
with users who have their own ssh keys set up (for external connections).
Use something like this:
Hostbased ssh setup, with torque access control and minor performance tweaks:
On the SSHD Server side (which means everywhere, BUT!!! head node with
external logins should have more secure sshd_config):
NOTE: The above is involved in the pam_access.so line, which prevents root from
getting locked out even when root isn't listed in /etc/pbs_sshauth.
On the SSH Client side (everywhere):
Maintenance:
shosts.equiv needs to be updated when new nodes are added. You
could use netgroups for this, either NIS or a netgroup file (not tested by
myself, but I've read others doing so on Linux). Probably you want to add
something at bootup to clear out /etc/pbs_sshauth. Cipher/compression tweaks
as improvements come into existence, for performance gains.
NOTE: Entries are necessary for all users in /etc/shadow on the compute node. They can (and probably ought) to be locked (!! in the password field).
NOTE: If you have "UseDNS no" in your server config, make sure
your entries in /etc/ssh/shosts.equiv are IP addresses, not hostnames.
NOTE: For root to completely ignore the PBS authentication scheming we
have configured, you'll want to set up passphraseless keys just for root and
distributed the private and public keys, and authorized_keys file containing
said key, to all compute nodes and to the head node.