tramp-devel
[Top][All Lists]
Advanced

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

Re: tramp (2.1.17-pre); Nothing happens, waiting for something after "fo


From: Michael Albinus
Subject: Re: tramp (2.1.17-pre); Nothing happens, waiting for something after "found remote shell prompt"
Date: Fri, 05 Nov 2010 15:03:16 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux)

Fabrice Niessen <address@hidden> writes:

> Hello,

Hi,

> Here is what I see in the echo area.
>
> Tramp: Waiting 60s for local shell to come up...
> Tramp: Sending command `plink cauchy -l fni  -ssh && exit || exit'
> Tramp: Waiting for prompts from remote shell
> Tramp: Sending password
> Tramp: Found remote shell prompt on `cauchy'
>
> ... but it does not do anything else... and I have to stop waiting after more
> than a minute. Not connected, though...

Let's check the traces:

--8<---------------cut here---------------start------------->8---
10:35:36.911000 tramp-send-command (6) # plink cauchy -l fni  -ssh && exit || 
exit
10:35:47.986000 tramp-process-actions (6) # 
plink cauchy -l fni  -ssh && exit || exit
address@hidden's password: 
Last login: Fri Nov  5 10:12:39 2010 from 10.10.10.213

[?1034h/address@hidden:~ 0$ 
--8<---------------cut here---------------end--------------->8---

Connection to the remote host succeeds. There are some escape sequences
in the prompt, but they do not hurt.

--8<---------------cut here---------------start------------->8---
10:35:47.986000 tramp-send-command (6) # exec env ENV='' PROMPT_COMMAND='' 
PS1=\$\  PS2='' PS3='' /bin/sh
10:35:48.096000 tramp-wait-for-regexp (6) # 
exec env ENV='' PROMPT_COMMAND='' PS1=\$\  PS2='' PS3='' / 
bin/sh
[?1034h$ 
--8<---------------cut here---------------end--------------->8---

/bin/sh is called, and the prompt is set to "$ ".

--8<---------------cut here---------------start------------->8---
10:35:48.299000 tramp-send-command (6) # 
PS1=///77657d3502c121977584ac7ec5d40d3b\$
10:35:48.361000 tramp-wait-for-regexp (6) # 
///77657d3502c121977584ac7ec5d40d3b$
--8<---------------cut here---------------end--------------->8---

Prompt is changed to Tramp's default.

--8<---------------cut here---------------start------------->8---
10:35:49.033000 tramp-send-command (6) # echo ~root
10:35:49.095000 tramp-wait-for-regexp (6) # 
~root
///77657d3502c121977584ac7ec5d40d3b$
--8<---------------cut here---------------end--------------->8---

Tramp detects, that tilde (~) is not expanded in the current shell. It
calls bash, therefore.

--8<---------------cut here---------------start------------->8---
10:35:49.095000 tramp-send-command (6) # which \bash | wc -w
10:35:49.252000 tramp-wait-for-regexp (6) # 
1
///77657d3502c121977584ac7ec5d40d3b$
10:35:49.252000 tramp-send-command (6) # PROMPT_COMMAND='' PS1=\$\  PS2='' 
PS3='' exec \bash
10:35:50.204000 tramp-wait-for-regexp (6) # 

[?1034h/address@hidden:~ 0$ 
--8<---------------cut here---------------end--------------->8---

bash does not accept the PS1 setting in the exec call. However, Tramp
still detects the prompt.

--8<---------------cut here---------------start------------->8---
10:35:50.204000 tramp-send-command (6) # 
PS1=///77657d3502c121977584ac7ec5d40d3b\$
--8<---------------cut here---------------end--------------->8---

Now Tramp tries again to set the prompt to its preferred value. bash
does not accepts this, instead of we see in the connection buffer

--8<---------------cut here---------------start------------->8---
/address@hidden:~ 0$ 
--8<---------------cut here---------------end--------------->8---

And this confuses Tramp.

Could you, please, check your bash on the remote host? What does happen,
if you call interactively in a terminal

--8<---------------cut here---------------start------------->8---
# PROMPT_COMMAND='' PS1=\$\  PS2='' PS3='' exec \bash
--8<---------------cut here---------------end--------------->8---

And what happens, if you call

--8<---------------cut here---------------start------------->8---
# PS1=///77657d3502c121977584ac7ec5d40d3b\$
--8<---------------cut here---------------end--------------->8---

Best regards, Michael.



reply via email to

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