Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Tramp too slow to be usefull

66 views
Skip to first unread message

Thierry Leurent

unread,
Aug 4, 2017, 4:20:13 PM8/4/17
to help-gn...@gnu.org
Hello,

I'm trying to use tramp but it's very slow even I work with a local file owned
by root.
After asking to the "friend" Google, I don't find any solution.

I use emacs 25 on Linux Testing.

You can see my tramp configuration file.
(use-package tramp
:defer t
:config
(progn
(with-eval-after-load 'tramp-cache
(setq tramp-persistency-file-name "~/.emacs.d/backup_and_other_stuffs/
tramp$"))
(setq tramp-default-user-alist '(("\\`su\\(do\\)?\\'" nil "root"))
;; use the settings in ~/.ssh/config instead of Tramp's
tramp-verbose 9
tramp-default-method "ssh"
tramp-ssh-controlmaster-options
(concat "-o ControlPath=/tmp/tramp.%%r@%%h:%%p "
"-o ControlMaster=auto "
"-o ControlPersist=no")
tramp-use-ssh-controlmaster-options nil
backup-enable-predicate
(lambda (name)
(and (normal-backup-enable-predicate name)
(not (let ((method (file-remote-p name 'method)))
(when (stringp method)
(member method '("su" "sudo"))))))))

(use-package tramp-sh
:config
(progn
(add-to-list 'tramp-remote-path "/usr/local/sbin")
(add-to-list 'tramp-remote-path "/var/www/")
(add-to-list 'tramp-remote-path "~/bin")))))


Thnaks for your help.

Regards,

-----
Thierry Leurent

Michael Albinus

unread,
Aug 4, 2017, 4:20:30 PM8/4/17
to Thierry Leurent, help-gn...@gnu.org
Thierry Leurent <thierry...@asgardian.be> writes:

> Hello,

Hi Thierry,

> I'm trying to use tramp but it's very slow even I work with a local
> file owned by root.

Quoting from the Tramp manual, "Frequently Asked Questions":

• How could I speed up TRAMP?

In the backstage, TRAMP needs a lot of operations on the remote
host. The time for transferring data from and to the remote host
as well as the time needed to perform the operations there count.
In order to speed up TRAMP, one could either try to avoid some of
the operations, or one could try to improve their performance.

Use an external method, like ‘scp’.

Use caching. This is already enabled by default. Information
about the remote host as well as the remote files are cached for
reuse. The information about remote hosts is kept in the file
specified in ‘tramp-persistency-file-name’. Keep this file. If
you are confident that files on remote hosts are not changed out of
Emacs’ control, set ‘remote-file-name-inhibit-cache’ to ‘nil’. Set
also ‘tramp-completion-reread-directory-timeout’ to ‘nil’, *note
File name completion::.

Disable version control. If you access remote files which are not
under version control, a lot of check operations can be avoided by
disabling VC. This can be achieved by

(setq vc-ignore-dir-regexp
(format "\\(%s\\)\\|\\(%s\\)"
vc-ignore-dir-regexp
tramp-file-name-regexp))

Disable excessive traces. The default trace level of TRAMP,
defined in the variable ‘tramp-verbose’, is 3. You should increase
this level only temporarily, hunting bugs.

> Thnaks for your help.
>
> Regards,
>
> -----
> Thierry Leurent

Best regards, Michael.

Thierry Leurent

unread,
Aug 21, 2017, 4:44:50 PM8/21/17
to help-gn...@gnu.org
Thans fo your solution. It's work
On Wednesday, 2 August 2017 08:54:33 CEST Michael Albinus wrote:
> Thierry Leurent <thierry...@asgardian.be> writes:
> > Hello,
>
> Hi Thierry,
>
> > I'm trying to use tramp but it's very slow even I work with a local
> > file owned by root.
>
> Quoting from the Tramp manual, "Frequently Asked Questions":
>
> ? How could I speed up TRAMP?
>
> In the backstage, TRAMP needs a lot of operations on the remote
> host. The time for transferring data from and to the remote host
> as well as the time needed to perform the operations there count.
> In order to speed up TRAMP, one could either try to avoid some of
> the operations, or one could try to improve their performance.
>
> Use an external method, like ?scp?.
>
> Use caching. This is already enabled by default. Information
> about the remote host as well as the remote files are cached for
> reuse. The information about remote hosts is kept in the file
> specified in ?tramp-persistency-file-name?. Keep this file. If
> you are confident that files on remote hosts are not changed out of
> Emacs? control, set ?remote-file-name-inhibit-cache? to ?nil?. Set
> also ?tramp-completion-reread-directory-timeout? to ?nil?, *note
> File name completion::.
>
> Disable version control. If you access remote files which are not
> under version control, a lot of check operations can be avoided by
> disabling VC. This can be achieved by
>
> (setq vc-ignore-dir-regexp
> (format "\\(%s\\)\\|\\(%s\\)"
> vc-ignore-dir-regexp
> tramp-file-name-regexp))
>
> Disable excessive traces. The default trace level of TRAMP,
> defined in the variable ?tramp-verbose?, is 3. You should increase
> this level only temporarily, hunting bugs.
>
> > Thnaks for your help.
> >
> > Regards,
> >
> > -----
> > Thierry Leurent
>
> Best regards, Michael.


--

-----
Thierry Leurent

0 new messages