Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm trying to SSH from one Mac running OS X 10.6 to another. Seems to work fine via a password, but I can't get it to use a RSA key instead. Where is the ssh configuration file on OS X and what is the command to reload SSH?

Update

What I'm asking is how to configured advanced options. For example, on Ubuntu there is a ssh config file at /etc/ssh/sshd_config and if you do something like change the port or disable password authentication for a particular user (PasswordAuthentication no) you need to run /etc/init.d/ssh reload to reload the config. I didn't see that file on OS X, so was just wondering where it was. I am aware of the ~/.ssh ~/.ssh/authorized_keys and `~/.ssh/config

share|improve this question
    
By ssh configuration file, do you mean ~/.ssh/authorized_keys, the same file as on any platform? –  Daniel Beck Dec 3 '11 at 20:10
1  
And why do you want to reload SSH? Doesn't it suffice to update the authorized_keys file for the user account you want to log in as? Please describe the problem you're facing in more detail. –  Daniel Beck Dec 3 '11 at 20:15
    
On Ubuntu there is a ssh config file at /etc/ssh/sshd_config and if you do something like change the port or disable password authentication for a particular user (PasswordAuthentication no) you need to run /etc/init.d/ssh reload to reload the config. I didn't see that file on OS X, so was just wondering where it was. I am aware of the ~/.ssh ~/.ssh/authorized_keys and ``~/.ssh/config` –  cwd Dec 4 '11 at 0:30
add comment

2 Answers 2

up vote 4 down vote accepted

The SSH configuration is stored in

/private/etc/sshd_config

To stop and start sshd:

launchctl stop com.openssh.sshd
launchctl start com.openssh.sshd
share|improve this answer
    
Not sure if this is just because of how my machine is setup or not, but as of OS X Mavericks the sshd service I needed to specify in launchctl is org.openbsd.ssh-agent –  Dan Herbert 15 hours ago
add comment

You can restart SSH somewhere in the sharing dialogs, but you don't have to. According to the man page on apple.com keys go to the ~/.ssh/authorized_keys file.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.