Post a reply

Before posting, please read how to report bug or request support effectively.

Bug reports without an attached log file are usually useless.

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

Re: Using "screen" as shell (SFTP v2)

Thanks for coming back, your answer may help other users.
Greg

Re: Using "screen" as shell (SFTP v2)

I used PuTTY without virtual terminal, and that did reproduce the whole message. The message is "Must be connected to a terminal".

In short, screen doesn't like being used that way. I discovered that if I keep my shell as tcsh and simply run screen from the end of my .login by saying:
exec screen -RR

then I get all the benefits that I was looking for, and SFTP still works. Really the only reason to run screen as a shell is to ensure that it's always running to protect your terminal from disconnect probs. So this solution addresses both problems.

Thank you for your excellent debug suggestions, and thanks again for your devotion to making WinSCP such a great prog!

Greg
Guest

Re: Using "screen" as shell (SFTP v2)

martin wrote:

Greg wrote:

Is there a way I can read the rest of the "Must..." message, or do you have any ideas what might be causing this?

I have two ideas how to get the full message:
1) Using WinSCP: Select SCP protocol and enable logging. Login to the server and then check the log file. It may contain full message.
2) Using PuTTY: Check option "Don't allocate a pseudo-terminal" on SSH page of login dialog.

If the message is not shown in any of the above cases, then I suppose there is specific problem with SFTP protocol. It seems even probable, because I see in the log that the server closes connection. Are you sure your screen software is compatible with SFTP server?


I will try your suggestions, thanks. I am not 100% sure that screen can work with SFTP, but I am just trying to learn what the incompatibility might be (in case it is a setting or other thing I can fix).

I'll report my findings back here. Thanks!!
martin

Re: Using "screen" as shell (SFTP v2)

Greg wrote:

Is there a way I can read the rest of the "Must..." message, or do you have any ideas what might be causing this?

I have two ideas how to get the full message:
1) Using WinSCP: Select SCP protocol and enable logging. Login to the server and then check the log file. It may contain full message.
2) Using PuTTY: Check option "Don't allocate a pseudo-terminal" on SSH page of login dialog.

If the message is not shown in any of the above cases, then I suppose there is specific problem with SFTP protocol. It seems even probable, because I see in the log that the server closes connection. Are you sure your screen software is compatible with SFTP server?
Greg

Using "screen" as shell (SFTP v2)

Hi. First of all, thanks for the incredible program! Recently I have switched from tcsh to using Screen as my default shell (https://www.gnu.org/software/screen/). I.E. I have done a chsh to /usr/bin/screen (which is a supported use of the screen software).

Anyway this works fine with putty and plink, but WinSCP now gives the dreaded "Received too large SFTP packet" message. I have read the FAQ, and I know from your error message that the text it receives starts with "Must".

During normal logins no text is displayed. This leads me to wonder whether there is some failure that occurs between the shell and WinSCP, but does not occur in PuTTY. Is there a way I can read the rest of the "Must..." message, or do you have any ideas what might be causing this?

Below I have pasted in TWO log files. The first one is a successful WinSCP connect when "tcsh" is my shell. The second log is an attempt to connect to the same server using "screen" as my shell.

Thanks in advance for any assistance. Let me konw if you need any additional info!

Greg
. --------------------------------------------------------------------------
. WinSCP Version 3.7.1 (Build 257) (OS 5.1.2600 Service Pack 2)
. Login time: Tuesday, November 23, 2004 11:28:10 AM
. --------------------------------------------------------------------------
. Session name: 10forward - KEY
. Host name: 10forward.com (Port: 22)
. User name: gbell (Password: No, Key file: Yes)
. Transfer Protocol: SFTP
. SSH protocol version: 2; Compression: No
. Agent forwarding: No; TIS/CryptoCard: No; KI: Yes; GSSAPI: No
. Ciphers: aes,blowfish,3des,WARN,des; Ssh2DES: No
. Ping type: N, Ping interval: 60 sec; Timeout: 15 sec
. SSH Bugs: -,-,-,-,-,-,-,-,
. Proxy: none
. Return code variable: Autodetect; Lookup user groups: Yes
. Shell: default, EOL: 0
. Local directory: default, Remote directory: home, Update: No, Cache: Yes
. Cache directory changes: Yes, Permanent: Yes
. Clear aliases: Yes, Unset nat.vars: Yes, Resolve symlinks: Yes
. Alias LS: No, Ign LS warn: Yes, Scp1 Comp: No
. --------------------------------------------------------------------------
. Looking up host "10forward.com"
. Connecting to 66.92.208.232 port 22
. Server version: SSH-1.99-OpenSSH_3.6.1p2-pwexp22
. We claim version: SSH-2.0-WinSCP-release-3.7.1
. Using SSH protocol version 2
. Doing Diffie-Hellman group exchange
. Doing Diffie-Hellman key exchange
. Host key fingerprint is:
. ssh-rsa 1024 77:9b:bc:9e:de:e2:f6:3b:79:24:93:6b:7f:51:d4:a6
. Initialised AES-256 client->server encryption
. Initialised AES-256 server->client encryption
. Initialised HMAC-SHA1 client->server MAC algorithm
. Initialised HMAC-SHA1 server->client MAC algorithm
! Using username "gbell".
. Reading private key file "s:\data\priv-login.ppk"
. Offered public key
. Offer of public key accepted
! Authenticating with public key "rsa-key-20040418"
. Access granted
. Opened channel for session
. Started a shell/command
. --------------------------------------------------------------------------
. Using SFTP protocol.
. Doing startup conversation with host.
> Type: SSH_FXP_INIT, Size: 5, Number: -1
< Type: SSH_FXP_VERSION, Size: 5, Number: -1
. SFTP version 3 negotiated.
> Type: SSH_FXP_EXTENDED, Size: 38, Number: 200
< Type: SSH_FXP_STATUS, Size: 38, Number: 200
< Status/error code: 8
. Server does not recognise WinSCP.
. Getting current directory name.
. Getting real path for '.'
> Type: SSH_FXP_REALPATH, Size: 10, Number: 528
< Type: SSH_FXP_NAME, Size: 43, Number: 528
. Real path is '/home/gbell'
. Listing directory "/home/gbell".
> Type: SSH_FXP_OPENDIR, Size: 20, Number: 779
< Type: SSH_FXP_HANDLE, Size: 13, Number: 779
> Type: SSH_FXP_READDIR, Size: 13, Number: 1036
< Type: SSH_FXP_NAME, Size: 11971, Number: 1036
> Type: SSH_FXP_READDIR, Size: 13, Number: 1292
< Type: SSH_FXP_NAME, Size: 11936, Number: 1292
> Type: SSH_FXP_READDIR, Size: 13, Number: 1548
< Type: SSH_FXP_NAME, Size: 1040, Number: 1548
> Type: SSH_FXP_READDIR, Size: 13, Number: 1804
< Type: SSH_FXP_STATUS, Size: 28, Number: 1804
< Status/error code: 1
> Type: SSH_FXP_CLOSE, Size: 13, Number: 2052
< Type: SSH_FXP_STATUS, Size: 24, Number: 2052
< Status/error code: 0
. Startup conversation with host finished.
. Sending null packet to keep session alive.
. Sending special code: 15
. Sending null packet to keep session alive.
. Sending special code: 15
. Sending null packet to keep session alive.
. Sending special code: 15
. Sending null packet to keep session alive.
. Sending special code: 15
. Sending null packet to keep session alive.
. Sending special code: 15
. Sending null packet to keep session alive.
. Sending special code: 15
. Sending null packet to keep session alive.
. Sending special code: 15



. --------------------------------------------------------------------------
. WinSCP Version 3.7.1 (Build 257) (OS 5.1.2600 Service Pack 2)
. Login time: Tuesday, November 23, 2004 11:27:56 AM
. --------------------------------------------------------------------------
. Session name: 10forward - KEY
. Host name: 10forward.com (Port: 22)
. User name: gbell (Password: No, Key file: Yes)
. Transfer Protocol: SFTP
. SSH protocol version: 2; Compression: No
. Agent forwarding: No; TIS/CryptoCard: No; KI: Yes; GSSAPI: No
. Ciphers: aes,blowfish,3des,WARN,des; Ssh2DES: No
. Ping type: N, Ping interval: 60 sec; Timeout: 15 sec
. SSH Bugs: -,-,-,-,-,-,-,-,
. Proxy: none
. Return code variable: Autodetect; Lookup user groups: Yes
. Shell: default, EOL: 0
. Local directory: default, Remote directory: home, Update: No, Cache: Yes
. Cache directory changes: Yes, Permanent: Yes
. Clear aliases: Yes, Unset nat.vars: Yes, Resolve symlinks: Yes
. Alias LS: No, Ign LS warn: Yes, Scp1 Comp: No
. --------------------------------------------------------------------------
. Looking up host "10forward.com"
. Connecting to 66.92.208.232 port 22
. Server version: SSH-1.99-OpenSSH_3.6.1p2-pwexp22
. We claim version: SSH-2.0-WinSCP-release-3.7.1
. Using SSH protocol version 2
. Doing Diffie-Hellman group exchange
. Doing Diffie-Hellman key exchange
. Host key fingerprint is:
. ssh-rsa 1024 77:9b:bc:9e:de:e2:f6:3b:79:24:93:6b:7f:51:d4:a6
. Initialised AES-256 client->server encryption
. Initialised AES-256 server->client encryption
. Initialised HMAC-SHA1 client->server MAC algorithm
. Initialised HMAC-SHA1 server->client MAC algorithm
! Using username "gbell".
. Reading private key file "s:\data\priv-login.ppk"
. Offered public key
. Offer of public key accepted
! Authenticating with public key "rsa-key-20040418"
. Access granted
. Opened channel for session
. Started a shell/command
. --------------------------------------------------------------------------
. Using SFTP protocol.
. Doing startup conversation with host.
> Type: SSH_FXP_INIT, Size: 5, Number: -1
. Server sent command exit status 1
. All channels closed. Disconnecting
* (ESshFatal) Cannot initialize SFTP protocol. Is the host running a SFTP server?
* Received too large (1299542900 B) SFTP packet. Max supported packet size is 102400 B.
*
* The error is typically caused by message printed from startup script (like .profile). The message may start with "Must".