Topic "date: illegal option -- c"

Author Message
Guest




I am running version 3.7.1 build 257 of WinSCP3. The server to which I am trying to connect will only accept SCP, all SFTP attempts are refused. From the log file I show that a connection is accepted, but disconnects when trying to do something with the date. The interface is set to Norton Commander and every combination of date settings in the program have been set and unset resulting in the same error. The SCP shell is manually set to /bin/bash. I have also tried version 1 and 2 of the SCP protocol. Searching the message board I found one other post by the author [HEJ] with a similar problem with the -c titled "How to go thru interactive ssh gw." Below is the bottom of my log file. It seems like a "-c" is being sent somehow and is disturbing the connection.


Code:
.. Using stored password.
. Sent password
. Access granted
. Opened channel for session
. Started a shell/command
. --------------------------------------------------------------------------
. Using SCP protocol.
. Doing startup conversation with host.
. Skipping host startup message (if any).
> echo "WinSCP: this is end-of-file:0"
! date: illegal option -- c
! usage: date [-jnu] [-d dst] [-r seconds] [-t west] [-v[+|-]val[ymwdHMS]] ...
!             [-f fmt date | [[[[[cc]yy]mm]dd]HH]MM[.ss]] [+format]
. Server sent command exit status 1
. All channels closed. Disconnecting
* (ESshFatal) Error skipping startup message. Your shell is probably incompatible with the application (BASH is recommended).
* Connection has been unexpectedly closed. Server sent command exit status 1.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
WinSCP does not execute 'date' command. It is maybe executed from some startup script, like .profile. Check them. From the -c parameter it also looks like 'date' is treated like shell. So check shell box on SCP tab of login dialog whether the 'date' was not entered there by mistake. Also your account may have 'date' set as the default shell. In all cases try SFTP instead of SCP too.
_________________
Martin Prikryl
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License