* Tramp default method
@ 2006-10-29 13:18 Lars Hansen
2006-11-05 17:06 ` Michael Albinus
0 siblings, 1 reply; 13+ messages in thread
From: Lars Hansen @ 2006-10-29 13:18 UTC (permalink / raw)
Cc: emacs-devel
How come tramp-default-method is ssh and not scp?
In my setup, copying a 8 MB file takes 100 secs with ssh and 1.5 secs
withs scp. And I beleive scp should be installed if ssh is.
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Tramp default method
2006-11-05 17:06 ` Michael Albinus
@ 2006-11-05 16:52 ` Andreas Schwab
2006-11-05 19:34 ` Michael Albinus
2006-11-06 5:01 ` Richard Stallman
2006-11-06 14:47 ` Lars Hansen
2 siblings, 1 reply; 13+ messages in thread
From: Andreas Schwab @ 2006-11-05 16:52 UTC (permalink / raw)
Cc: emacs-devel
Michael Albinus <michael.albinus@gmx.de> writes:
> With smaller files, ssh seems to be faster than scp. scp needs always
> an additional process, which requires some initial handshaking.
That can be avoided by setting up a master connection where all ssh data
is routed through.
Andreas.
--
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
PGP key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Tramp default method
2006-10-29 13:18 Tramp default method Lars Hansen
@ 2006-11-05 17:06 ` Michael Albinus
2006-11-05 16:52 ` Andreas Schwab
` (2 more replies)
0 siblings, 3 replies; 13+ messages in thread
From: Michael Albinus @ 2006-11-05 17:06 UTC (permalink / raw)
Cc: emacs-devel
Lars Hansen <lists@soem.dk> writes:
> How come tramp-default-method is ssh and not scp?
> In my setup, copying a 8 MB file takes 100 secs with ssh and 1.5 secs
> withs scp. And I beleive scp should be installed if ssh is.
With smaller files, ssh seems to be faster than scp. scp needs always
an additional process, which requires some initial handshaking. See
the discussion in the Tramp info page "(tramp)Default Method".
Best regards, Michael.
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Tramp default method
2006-11-05 16:52 ` Andreas Schwab
@ 2006-11-05 19:34 ` Michael Albinus
2006-11-05 20:34 ` Andreas Schwab
0 siblings, 1 reply; 13+ messages in thread
From: Michael Albinus @ 2006-11-05 19:34 UTC (permalink / raw)
Cc: emacs-devel
Andreas Schwab <schwab@suse.de> writes:
>> With smaller files, ssh seems to be faster than scp. scp needs always
>> an additional process, which requires some initial handshaking.
>
> That can be avoided by setting up a master connection where all ssh data
> is routed through.
IIUC, you mean an ssh connection to the remote host, and afterwards
scp from the remote host back to the local host?
How does this work if there is no ssh daemon running on the local
host? And how does this work when you need multiple hops in order to
reach the remote host, passing a firewall or whatever?
> Andreas.
Best regards, Michael.
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Tramp default method
2006-11-05 19:34 ` Michael Albinus
@ 2006-11-05 20:34 ` Andreas Schwab
2006-11-05 20:53 ` Michael Albinus
0 siblings, 1 reply; 13+ messages in thread
From: Andreas Schwab @ 2006-11-05 20:34 UTC (permalink / raw)
Cc: emacs-devel
Michael Albinus <michael.albinus@gmx.de> writes:
> Andreas Schwab <schwab@suse.de> writes:
>
>>> With smaller files, ssh seems to be faster than scp. scp needs always
>>> an additional process, which requires some initial handshaking.
>>
>> That can be avoided by setting up a master connection where all ssh data
>> is routed through.
>
> IIUC, you mean an ssh connection to the remote host, and afterwards
> scp from the remote host back to the local host?
No. Open an ssh connection as the ControlMaster, then use ssh/scp as
usual. See ssh_config(5).
Andreas.
--
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
PGP key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Tramp default method
2006-11-05 20:34 ` Andreas Schwab
@ 2006-11-05 20:53 ` Michael Albinus
0 siblings, 0 replies; 13+ messages in thread
From: Michael Albinus @ 2006-11-05 20:53 UTC (permalink / raw)
Cc: emacs-devel
Andreas Schwab <schwab@suse.de> writes:
>> IIUC, you mean an ssh connection to the remote host, and afterwards
>> scp from the remote host back to the local host?
>
> No. Open an ssh connection as the ControlMaster, then use ssh/scp as
> usual. See ssh_config(5).
I see. I'll play with this option, looks promising.
> Andreas.
Thanks to nudge me, and best regards, Michael.
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Tramp default method
2006-11-05 17:06 ` Michael Albinus
2006-11-05 16:52 ` Andreas Schwab
@ 2006-11-06 5:01 ` Richard Stallman
2006-11-06 14:52 ` Lars Hansen
2006-11-06 22:31 ` Michael Albinus
2006-11-06 14:47 ` Lars Hansen
2 siblings, 2 replies; 13+ messages in thread
From: Richard Stallman @ 2006-11-06 5:01 UTC (permalink / raw)
Cc: emacs-devel
> How come tramp-default-method is ssh and not scp?
> In my setup, copying a 8 MB file takes 100 secs with ssh and 1.5 secs
> withs scp. And I beleive scp should be installed if ssh is.
With smaller files, ssh seems to be faster than scp. scp needs always
an additional process, which requires some initial handshaking. See
the discussion in the Tramp info page "(tramp)Default Method".
So how about making the default be "ssh for a file under 10k, scp for
larger files"?
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Tramp default method
2006-11-05 17:06 ` Michael Albinus
2006-11-05 16:52 ` Andreas Schwab
2006-11-06 5:01 ` Richard Stallman
@ 2006-11-06 14:47 ` Lars Hansen
2 siblings, 0 replies; 13+ messages in thread
From: Lars Hansen @ 2006-11-06 14:47 UTC (permalink / raw)
Cc: Richard Stallman, emacs-devel
Michael Albinus wrote:
>With smaller files, ssh seems to be faster than scp. scp needs always
>an additional process, which requires some initial handshaking. See
>the discussion in the Tramp info page "(tramp)Default Method".
>
>
IMO, the default value of tramp-default-method should give good results
for large as well as small files. I don't think a small improvement for
small files justify a very bad performance for large files. And even
though people don't normally _edit_ large files, the do _copy_ them
using dired (at least I do). Emacs is much more than an editor, you know :-)
To make it short: An unexperienced user should get good performance for
small and large files. Experienced users that never edit or copy large
files can easily customize tramp-default-method. IMHO.
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Tramp default method
2006-11-06 5:01 ` Richard Stallman
@ 2006-11-06 14:52 ` Lars Hansen
2006-11-06 21:00 ` Richard Stallman
2006-11-06 22:33 ` Michael Albinus
2006-11-06 22:31 ` Michael Albinus
1 sibling, 2 replies; 13+ messages in thread
From: Lars Hansen @ 2006-11-06 14:52 UTC (permalink / raw)
Cc: Michael Albinus, emacs-devel
Richard Stallman wrote:
>So how about making the default be "ssh for a file under 10k, scp for
>larger files"?
>
>
Checking the file size before copying is an extra overhead when the file
is remote.
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Tramp default method
2006-11-06 14:52 ` Lars Hansen
@ 2006-11-06 21:00 ` Richard Stallman
2006-11-06 22:45 ` Michael Albinus
2006-11-06 22:33 ` Michael Albinus
1 sibling, 1 reply; 13+ messages in thread
From: Richard Stallman @ 2006-11-06 21:00 UTC (permalink / raw)
Cc: michael.albinus, emacs-devel
Checking the file size before copying is an extra overhead when the file
is remote.
Alas, that is true when reading the file. However, when saving the file,
you can check the size painlessly.
For reading the file, perhaps the openssh developers could
perhaps provide a mode that does things one way or the other
depending on the file size. But that is not something we can do now.
For the short term, I think we should use scp as the default.
To eliminate a short delay for small files is not worth a painful
slowdown for large files.
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Tramp default method
2006-11-06 5:01 ` Richard Stallman
2006-11-06 14:52 ` Lars Hansen
@ 2006-11-06 22:31 ` Michael Albinus
1 sibling, 0 replies; 13+ messages in thread
From: Michael Albinus @ 2006-11-06 22:31 UTC (permalink / raw)
Cc: emacs-devel
Richard Stallman <rms@gnu.org> writes:
> So how about making the default be "ssh for a file under 10k, scp for
> larger files"?
That is already on the todo list for Tramp 2.1.
Best regards, Michael.
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Tramp default method
2006-11-06 14:52 ` Lars Hansen
2006-11-06 21:00 ` Richard Stallman
@ 2006-11-06 22:33 ` Michael Albinus
1 sibling, 0 replies; 13+ messages in thread
From: Michael Albinus @ 2006-11-06 22:33 UTC (permalink / raw)
Cc: rms, emacs-devel
Lars Hansen <lists@soem.dk> writes:
> Richard Stallman wrote:
>
>>So how about making the default be "ssh for a file under 10k, scp for
>>larger files"?
>>
>>
> Checking the file size before copying is an extra overhead when the file
> is remote.
Nope. Usually, file-attributes is called before copying a file, the
size is known therefore. And Tramp 2.1 caches/reuses such information
whenever possible.
Best regards, Michael.
^ permalink raw reply [flat|nested] 13+ messages in thread
* Re: Tramp default method
2006-11-06 21:00 ` Richard Stallman
@ 2006-11-06 22:45 ` Michael Albinus
0 siblings, 0 replies; 13+ messages in thread
From: Michael Albinus @ 2006-11-06 22:45 UTC (permalink / raw)
Cc: emacs-devel
Richard Stallman <rms@gnu.org> writes:
> For reading the file, perhaps the openssh developers could
> perhaps provide a mode that does things one way or the other
> depending on the file size. But that is not something we can do now.
Tramp's scp method is always escorted by an ordinary ssh connection in
order to gather file information. That is sufficient for today. When
Andreas' suggestion is added (use of ControlMaster), scp might be even
more efficient.
An extension of ssh is nothing I expect for next time. What could be
helpful is an own small server process on the remote side (via an ssh
connection), which provides the needed file information directly to
Tramp. The FISH server is such an approach, I'm playing with these
days. But I'm still not happy with performance.
> For the short term, I think we should use scp as the default.
> To eliminate a short delay for small files is not worth a painful
> slowdown for large files.
OK, I'll change the default.
Best regards, Michael.
^ permalink raw reply [flat|nested] 13+ messages in thread
end of thread, other threads:[~2006-11-06 22:45 UTC | newest]
Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-10-29 13:18 Tramp default method Lars Hansen
2006-11-05 17:06 ` Michael Albinus
2006-11-05 16:52 ` Andreas Schwab
2006-11-05 19:34 ` Michael Albinus
2006-11-05 20:34 ` Andreas Schwab
2006-11-05 20:53 ` Michael Albinus
2006-11-06 5:01 ` Richard Stallman
2006-11-06 14:52 ` Lars Hansen
2006-11-06 21:00 ` Richard Stallman
2006-11-06 22:45 ` Michael Albinus
2006-11-06 22:33 ` Michael Albinus
2006-11-06 22:31 ` Michael Albinus
2006-11-06 14:47 ` Lars Hansen
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).