tramp hangs decoding local file (cygwin, emacs-w32)

classic Classic list List threaded Threaded
12 messages Options
Reply | Threaded
Open this post in threaded view
|

tramp hangs decoding local file (cygwin, emacs-w32)

delskorch
Using tramp/plink to open a remote file is hanging at
"Tramp: Decoding local file `/tmp/tramp.7048f_n' with `base64-decode-region'...done"

Other non-plink modes are working ok.

This is running on the latest cygwin, bash 4.3.33, emacs 24.5.1, tramp 2.2.11-24.5

The problem does not occur when using the previous cygwin emacs package: emacs 24.4.3, tramp 2.2.9-24.4
Reply | Threaded
Open this post in threaded view
|

Re: tramp hangs decoding local file (cygwin, emacs-w32)

Michael Albinus
delskorch <[hidden email]> writes:

Hi,

> Using tramp/plink to open a remote file is hanging at
> "Tramp: Decoding local file `/tmp/tramp.7048f_n' with
> `base64-decode-region'...done"

Could you please eval (setq tramp-verbose 10) and rerun the test? There
will be a Tramp debug buffer, please show its contents.

Best regards, Michael.

_______________________________________________
Tramp-devel mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/tramp-devel
Reply | Threaded
Open this post in threaded view
|

Re: tramp hangs decoding local file (cygwin, emacs-w32)

delskorch
Michael,

Debug output from the plink connection attempt:
debug_tramp_plink.gz

I also ran the test suite for the git master (but did not install). tramp-test30-make-auto-save-file-name is failing. The stdout+err of the test run is also attached. Let me know if you want to see more verbose test output and how to enable that.
make_test_output.make_test_output

Reply | Threaded
Open this post in threaded view
|

Re: tramp hangs decoding local file (cygwin, emacs-w32)

Michael Albinus
delskorch <[hidden email]> writes:

> Michael,

Hi,

> Debug output from the plink connection attempt:
> debug_tramp_plink.gz
> <http://emacs.1067599.n5.nabble.com/file/n359893/debug_tramp_plink.gz>  

Well, I cannot see an error in the traces. What I see is

2:36:26.392083 tramp-call-process (6) # `chown 1000:513 /tmp/tramp.9660Nxn' nil nil
12:36:46.303612 tramp-file-name-handler (1) # Interrupt received in operation (file-local-copy /plink:rclark4@localhost:/home/rclark4/.bashrc)

IOW, you (?) have pressed C-g, 20 seconds after the "chown ..." command
has been sent. Hmm, don't know what happened. Does

# touch /tmp/123
# chown 1000:513 /tmp/123

work on the remote host?

> I also ran the test suite for the git master (but did not install).
> tramp-test30-make-auto-save-file-name is failing. The stdout+err of the test
> run is also attached. Let me know if you want to see more verbose test
> output and how to enable that.
> make_test_output.make_test_output
> <http://emacs.1067599.n5.nabble.com/file/n359893/make_test_output.make_test_output>

The test case tramp-test30-make-auto-save-file-name was added some few
days ago, I couldn't test it on an MS Windows machine. Thanks for
reporting.

I have pushed a patch to the Tramp repository; could you please check
whether it works better now?

Best regards, Michael.

_______________________________________________
Tramp-devel mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/tramp-devel
Reply | Threaded
Open this post in threaded view
|

Re: tramp hangs decoding local file (cygwin, emacs-w32)

delskorch
Yes, I killed the process because it hangs indefinitely there. The last minibuffer msg is:
"Tramp: Decoding local file '/tmp....' with 'base64-decode-region'

Yes the chown operation is successful on the local cygwin host. (But not on the remote, if that matters.)

As mentioned, the other non-plink modes seem to work fine. Here's the debug output when using ssh mode to read the same file that fails using plink:
debug_tramp_ssh.gz

The 2.2.12-pre tests now look good on the latest Cygwin emacs.

    Ran 42 tests, 42 results as expected (2015-05-31 19:10:21-0400)
    2 expected failures
Reply | Threaded
Open this post in threaded view
|

Re: tramp hangs decoding local file (cygwin, emacs-w32)

Michael Albinus
delskorch <[hidden email]> writes:

> Yes, I killed the process because it hangs indefinitely there. The last
> minibuffer msg is:
> "Tramp: Decoding local file '/tmp....' with 'base64-decode-region'
>
> Yes the chown operation is successful on the local cygwin host. (But not on
> the remote, if that matters.)

... but it hangs when you are using the plink method. I have wrapped it
with a timeout of 5 seconds; could you please check whether it works
better now for you? (You must pull from the repo, again.)

> The 2.2.12-pre tests now look good on the latest Cygwin emacs.
>
>     Ran 42 tests, 42 results as expected (2015-05-31 19:10:21-0400)
>     2 expected failures

Thanks, so this is solved at least.

Best regards, Michael.

_______________________________________________
Tramp-devel mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/tramp-devel
Reply | Threaded
Open this post in threaded view
|

Re: tramp hangs decoding local file (cygwin, emacs-w32)

delskorch
Still hangs at "decoding local file" even with the timeout fix. But this is looking more like a cygwin problem.

My baseline, working setup is:
cygwin 1.7.35-1
emacs 24.4.1, tramp 2.2.9-24.4
plink 0.64

Changing only emacs and tramp to the latest available in the cygwin repo:
emacs 24.5.1, tramp 2.2.11-24.5 ... plink tramp sessions continue to work ok. And using your latest 2.2.12-pre with either setup works fine.

The trouble starts when the Cygwin system is updated. In my case, the cygwin engine goes from 1.7.35-1 to 2.0.2-1 .. and a bunch of other stuff comes with that which I haven't taken the time to A/B test. The point is, that something in that update that is not emacs/tramp/plink, corresponds to the trouble.  

Your 2.2.12-pre expected tests are passing on all my Cygwin setups. But the timeout code does not unstick the hanging process on cygwin 2.0.2-1.

Thanks for looking at this from the tramp side. Sorry I wasn't more thorough isolating the problem.
Reply | Threaded
Open this post in threaded view
|

Re: tramp hangs decoding local file (cygwin, emacs-w32)

Michael Albinus
delskorch <[hidden email]> writes:

Hi,

> My baseline, working setup is:
> cygwin 1.7.35-1
> emacs 24.4.1, tramp 2.2.9-24.4
> plink 0.64

Unfortunately, I cannot test this config. I don't use MS Windows machines.

> Your 2.2.12-pre expected tests are passing on all my Cygwin setups. But the
> timeout code does not unstick the hanging process on cygwin 2.0.2-1.

A very recent patch to Tramp 2.2.12-pre adds more traces in case you
cancel Tramp with C-g. Maybe you could pull it, and run your test with
tramp-verbose 10. There is a minor chance we get more information.

> Thanks for looking at this from the tramp side. Sorry I wasn't more thorough
> isolating the problem.

No problem, it's my daily fun to understand what Tramp users are doing :-)

Best regards, Michael.

_______________________________________________
Tramp-devel mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/tramp-devel
Reply | Threaded
Open this post in threaded view
|

Re: tramp hangs decoding local file (cygwin, emacs-w32)

delskorch
Another run with 2.2.12-pre pulled ~2015-06-03T02:00:00Z
debug_tramp_plink_cancel_trace.gz

I'll report the problem to the cygwin mail list sometime this week. Let me know if the debug output provides new insights.

Thanks.
Reply | Threaded
Open this post in threaded view
|

Re: tramp hangs decoding local file (cygwin, emacs-w32)

Michael Albinus
delskorch <[hidden email]> writes:

Hi,

> I'll report the problem to the cygwin mail list sometime this week. Let me
> know if the debug output provides new insights.

Unfortunately not. I made a small misthinking when adding the traces:
they report the status on the remote host when you interrupt Tramp; but
in your case we have a blocking call on the local host, sending the
chown command.

Well, I put this on hold. Let me know, if the cygwin maintainers need
more help for analyzing.

> Thanks.

Best regards, Michael.

_______________________________________________
Tramp-devel mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/tramp-devel
Reply | Threaded
Open this post in threaded view
|

Re: tramp hangs decoding local file (cygwin, emacs-w32)

delskorch
Cygwin 2.0.3-1 released yesterday includes a fix for hanging pty processes.
https://cygwin.com/ml/cygwin-announce/2015-06/msg00014.html

tramp/plink sessions are now working ok for me using this version of Cygwin.
Reply | Threaded
Open this post in threaded view
|

Re: tramp hangs decoding local file (cygwin, emacs-w32)

Michael Albinus
delskorch <[hidden email]> writes:

> Cygwin 2.0.3-1 released yesterday includes a fix for hanging pty processes.
> https://cygwin.com/ml/cygwin-announce/2015-06/msg00014.html
>
> tramp/plink sessions are now working ok for me using this version of Cygwin.

Wow! Thanks for keeping us informed.

Best regards, Michael.

_______________________________________________
Tramp-devel mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/tramp-devel