I have two Mac laptops connected to my home router. My machine is at IP whereas the 2nd machine is at IP I'm trying to scp a file from my machine (*.11) to the other machine (*.13):

scp ~/files/somefile.txt user2@

When I run this I get:

ssh: connect to host port 22: Connection refused
lost connection

I try to see if there's even a plausible connection between the two machines:

telnet 22

Figuring SSH would be running for sure. This gives me:

telnet: connect to address Connection refused
telnet: Unable to connect to remote host

How can I troubleshoot this and get scp working?

  • Two things to check: is SSH even running on What is the firewall config?
    – Attie
    Mar 24, 2017 at 12:25

2 Answers 2


You can follow following step in the remote MAC and enable SSH services. After you can try copy via scp command.

System Preferences pane → Sharing applet → check the Remote Login checkbox. This will enable SSH, and in turn, SCP.


You can start the service using the following command in the remote MAC laptop after you can try copy via scp command.

sudo launchctl load /System/Library/LaunchDaemons/ssh.plist

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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