[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Multi-hop: ssh, then sudo, then ssh

From: Michael Albinus
Subject: Re: Multi-hop: ssh, then sudo, then ssh
Date: Thu, 02 Dec 2010 21:38:21 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux)

Ole Laursen <address@hidden> writes:

> Hi!


> I've read the multiple-hops proxy page a couple of times and searched the
> interwebs, but still can't figure out how I setup this multihop. I need to 
> first
> ssh to server A, then sudo to root (to get access to a private key for B), 
> then 
> ssh to server B, i.e.
>   ssh A
>   sudo ssh B
> is sufficient to enable me to edit the files. Can Tramp help me here?

I assume, you use the same user on A and B, let's call him "ole".

(add-to-list 'tramp-default-proxies-alist
             "B" "ole" "/sudo:address@hidden:")
(add-to-list 'tramp-default-proxies-alist
             "A" "root" "/ssh:address@hidden:")

in this order. Afterwards, you could access 

> Ole

Best regards, Michael.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]