Terminal: Stored Remote Connection with non-standard Port?

Hi,

I am new to MacOS and I am amazed by the integrated terminal. However, I sometimes need to connect to servers which use a non-standard SSH port, for example, 2020. I know that I can manually connect, but for convinience, I'd like to have a saved remote connection including the non-standard port. Is this possible somehow?

Thanks,
Felicitus

MacBook, Mac OS X (10.6.2)

Posted on Mar 10, 2010 1:04 AM

Reply
4 replies

Mar 10, 2010 5:35 AM in response to Felicitus

It's actually ssh <ip> -p <port>, separating with spaces doesn't work as the SSH binary take the command after the space.

I know that it is possible to create shell script, but that's not what I wanted. I wish to keep all stored connections within the menu "remote connections".

If you open up the window "New Remote Connection", you see the actual SSH command at the bottom text field. Unfortunately it seems that the Terminal doesn't remember any changes to the text field, and I was asking if it is possible to have that saved somehow.

Mar 10, 2010 7:32 AM in response to Felicitus

I did some experimentation, using Terminal.

Terminal -> New Remote Connection -> Service -> [+]

now enter your own new service which includes

/usr/bin/ssh -p 50022

I found I had to enter a bonjour entry to get it to accept my new service, but once I did, I was able to use that new service with the custom -p 50022 port value.

Your mileage may vary. I still prefer iTerm.

Oh yea. In the future, Terminal and Unix oriented questions are better asked in the Mac OS X Technologies > Unix Forum
<http://discussions.apple.com/forum.jspa?forumID=735>

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Terminal: Stored Remote Connection with non-standard Port?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.