Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 589586 - app-editors/emacs-24.5-r1: tramp (first load?) on "Find file: /su..." hangs
Summary: app-editors/emacs-24.5-r1: tramp (first load?) on "Find file: /su..." hangs
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: GNU Emacs project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-07-24 10:32 UTC by sphakka
Modified: 2016-07-24 18:33 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (emacs.emerge-info,6.96 KB, text/plain)
2016-07-24 10:32 UTC, sphakka
Details
tramp backtrace (emacs.tramp.backtrace2,13.13 KB, text/plain)
2016-07-24 10:32 UTC, sphakka
Details

Note You need to log in before you can comment on or make changes to this bug.
Description sphakka 2016-07-24 10:32:10 UTC
Created attachment 441442 [details]
emerge --info

I'm observing this annoying behaviour on the first use of tramp when trying to open a file via 'su[do]'

  1. Start emacs with

    $ emacs -Q -D -nw -nsl

  2. C-x C-f (Find file) and start typing

    /su

  3. then type ':'. Emacs hangs for some minutes -- C-g needed to abort. In graphical mode (i.e. no "-nw" option on the command line), several C-g are needed to resume, after which, sometimes tramps work correctly.

The same happens when typing "/sudo" then ":". 

Starting with extra option

  --eval "
  (setq debug-on-error t
      debug-on-signal t)
  "

spits out a backtrace (see attachment) exactly when typing ":".
Comment 1 sphakka 2016-07-24 10:32:46 UTC
Created attachment 441444 [details]
tramp backtrace
Comment 2 sphakka 2016-07-24 13:11:24 UTC
Mmh, it also happens on '/ssh:'... Might be network-related...
Comment 3 sphakka 2016-07-24 14:24:12 UTC
WTF! Indeed it's a stupid DNS issue: my ISP redirects resolution failures to a dumb address which breaks tramp as, AFAIK, it uses a fake host name to expand/test connections, grrr.

See:

  https://lists.gnu.org/archive/html/bug-gnu-emacs/2015-03/msg00203.html

  http://emacs.stackexchange.com/questions/18438/emacs-suspend-at-startup-ssh-connection-issue

Reconfiguring networking with good DNS servers solves the problem :-)

I don't know if there's anything that can be fixed on Emacs/tramp side up/downstream. Otherwise this bug would be invalid...
Comment 4 Ulrich Müller gentoo-dev 2016-07-24 18:33:30 UTC
Upstream had some plans for asynchronous DNS resolution:
https://lists.gnu.org/archive/html/emacs-devel/2015-02/msg00830.html

I fear that we cannot do much about this at the distro level, because any changes would be very intrusive. Therefore resolving as UPSTREAM.