[SFTP] wierdness
Hi everyone, On my debian box ( Debian: 5.0.10/openssh-server: 1:5.1p1-5) I see the wierd behavior: sftp ls -l old -rw-r--r--1 user 100 9798 Jul 16 07:56 20120716_full_delhaizedirect_categories.zip -rw-r--r--1 user 100 9802 Jul 17 09:57 20120717_full_delhaizedirect_categories.zip sftp ls -l -h old -rw-r--r--0 1047 100 9.6K Jul 16 09:56 old/20120716_full_delhaizedirect_categories.zip -rw-r--r--0 1047 100 9.6K Jul 17 11:57 old/20120717_full_delhaizedirect_categories.zip As you can see there a date difference. # date vendredi 27 juillet 2012, 10:26:46 (UTC+0200) # cat /etc/default/rcS # # Defaults for the boot scripts in /etc/rcS.d # # Time files in /tmp are kept in days. TMPTIME=0 # Set to yes if you want sulogin to be spawned on bootup SULOGIN=no # Set to no if you want to be able to login over telnet/rlogin # before system startup is complete (as soon as inetd is started) DELAYLOGIN=yes # Set UTC=yes if your system clock is set to UTC (GMT), and UTC=no if not. UTC=no # Set VERBOSE to no if you would like a more quiet bootup. VERBOSE=yes # Set EDITMOTD to no if you don't want /etc/motd to be editted automatically EDITMOTD=yes # Set FSCKFIX to yes if you want to add -y to the fsck at startup. FSCKFIX=no Why do I see the difference with sftp and I don't see any difference when I am logging with ssh on the server # ls -l old/ total 29801 -rw-r--r-- 1 user users 9802 jui 17 11:57 20120717_full_delhaizedirect_categories.zip -rw-r--r-- 1 user users 9797 jui 18 08:22 20120718_full_delhaizedirect_categories.zip # ls -l -h old/ total 30M -rw-r--r-- 1 user users 9,6K jui 17 11:57 20120717_full_delhaizedirect_categories.zip -rw-r--r-- 1 user users 9,6K jui 18 08:22 20120718_full_delhaizedirect_categories.zip Any idea? -- Regards, JM PS: not able to find a suitable openssh mailing to send the question, sorry. -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/5012577c.7080...@antidot.net
Re: [SFTP] wierdness
Hello Jeremy, Jeremy MAURO jma...@antidot.net wrote: sftp ls -l old -rw-r--r--1 user 100 9798 Jul 16 07:56 20120716_full_delhaizedirect_categories.zip -rw-r--r--1 user 100 9802 Jul 17 09:57 20120717_full_delhaizedirect_categories.zip sftp ls -l -h old -rw-r--r--0 1047 100 9.6K Jul 16 09:56 old/20120716_full_delhaizedirect_categories.zip -rw-r--r--0 1047 100 9.6K Jul 17 11:57 old/20120717_full_delhaizedirect_categories.zip My first guess is that -h somehow translates the foreign time (probably UTC) to your local time (UTC+2), whereas using ssh, the server does not know your local time and hence can do no translation. Best regards, Claudius -- A board is the planck unit of boredom. http://chubig.net telnet nightfall.org 4242 signature.asc Description: PGP signature
Re: [SFTP] wierdness
On Fri, 27 Jul 2012 10:55:24 +0200, Jeremy MAURO wrote: On my debian box ( Debian: 5.0.10/openssh-server: 1:5.1p1-5) I see the wierd behavior: (...) sftp ls -l old -rw-r--r--1 user 100 9802 Jul 17 09:57 20120717_full_delhaizedirect_categories.zip (...) sftp ls -l -h old -rw-r--r--0 1047 100 9.6K Jul 17 11:57 old/20120717_full_delhaizedirect_categories.zip (...) As you can see there a date difference. (...) Yes, there's a shift of +0200 hours when using -h from sftp ls built-in command. In my lenny systems (clients and servers) there's not such a flag for sftp client: sftp ls -lh ls: Invalid flag -h Why do I see the difference with sftp and I don't see any difference when I am logging with ssh on the server (...) # ls -l old/ total 29801 -rw-r--r-- 1 user users 9802 jui 17 11:57 20120717_full_delhaizedirect_categories.zip (...) # ls -l -h old/ total 30M -rw-r--r-- 1 user users 9,6K jui 17 11:57 20120717_full_delhaizedirect_categories.zip (...) Different commands, different libraries, I guess. But I'm curious about the difference between ls -l and ls -lh when both are executed from sftp. Maybe is that the human readeable flag uses the local time of the host instead? :-? Greetings, -- Camaleón -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/juuahs$2bd$6...@dough.gmane.org