Discussion:
[unison-users] Non Standard SSH port
jsmith@h2l.com [unison-users]
2018-03-21 15:11:33 UTC
Permalink
Hi,

New user and I've been doing some testing with the Unison, and think it's
great. I'm looking at using it between remote sites. I know it works
through SSH which is great ...

unison a.tmp ssh://remotehostname/a.tmp

but what if you're running SSH on something other that the default port of
22 (ex. Port 2222). In the Unison command that calls the synch through
ssh, can you specify which port to use for that protocol, or will it
always default to port 22?

Thanks,
Jeremy
Matt Zagrabelny mzagrabe@d.umn.edu [unison-users]
2018-03-21 15:43:40 UTC
Permalink
On Wed, Mar 21, 2018 at 10:11 AM, ***@h2l.com [unison-users] <
unison-users-***@yahoogroups.com> wrote:

>
>
> Hi,
>
> New user and I've been doing some testing with the Unison, and think it's
> great. I'm looking at using it between remote sites. I know it works
> through SSH which is great ...
>
> unison a.tmp ssh://remotehostname/a.tmp
>
> but what if you're running SSH on something other that the default port of
> 22 (ex. Port 2222). In the Unison command that calls the synch through
> ssh, can you specify which port to use for that protocol, or will it always
> default to port 22?
>

There are a few ways to skin this cat:

edit your .ssh/config file

Host remotehostname
Port 2222

man ssh_config

or

edit your .unison/profile.prf

sshargs = -p 2222

zless unison-manual.txt.gz

I'm sure there are other less standard ways, too.

-m
worley@alum.mit.edu [unison-users]
2018-03-22 02:17:20 UTC
Permalink
"Matt Zagrabelny ***@d.umn.edu [unison-users]"
<unison-users-***@yahoogroups.com> writes:
> There are a few ways to skin this cat:
>
> edit your .ssh/config file
>
> Host remotehostname
> Port 2222
>
> man ssh_config
>
> or
>
> edit your .unison/profile.prf
>
> sshargs = -p 2222

which turns into "-sshargs '-p 2222'" on the command line, I think.

Dale
sesc03@web.de [unison-users]
2018-03-22 21:47:56 UTC
Permalink
Yet another way is to say


unison a.tmp ssh://remotehostname:2222/a.tmp

(BTW, In a similar manner you can also specify a deviating user name: ssh://***@remotehost/)


/Sebastian




---In unison-***@yahoogroups.com, <***@...> wrote :

"Matt Zagrabelny ***@... mailto:***@... [unison-users]"
<unison-users-***@yahoogroups.com mailto:unison-users-***@yahoogroups.com> writes:
> There are a few ways to skin this cat:
>
> edit your .ssh/config file
>
> Host remotehostname
> Port 2222
>
> man ssh_config
>
> or
>
> edit your .unison/profile.prf
>
> sshargs = -p 2222

which turns into "-sshargs '-p 2222'" on the command line, I think.

Dale
Continue reading on narkive:
Loading...