david_1234
Posts: 456
Joined: Mon Jan 01, 2018 2:14 pm

FTP server -vsftpd show wrong time +3 from my time

Tue Jul 07, 2020 9:57 am

Hello,
I have notice that when a file is creted on the ftp server the time is incorrect
when in my pi the time is 12:00:00
the file is 15:00:00

I have looked at the vsftpd .conf file , and it should use the system time

Code: Select all

# If enabled, vsftpd will display directory listings with the time
# in  your  local  time  zone.  The default is to display GMT. The
# times returned by the MDTM FTP command are also affected by this         
# option.
use_localtime=YES
do I need to change it to "no" ?

Thanks ,

knute
Posts: 664
Joined: Thu Oct 23, 2014 12:14 am
Location: Texas
Contact: Website

Re: FTP server -vsftpd show wrong time +3 from my time

Tue Jul 07, 2020 3:50 pm

I checked my installation of vsftpd running on a Pi3+. I tried sending a file to it from my Xubuntu desktop and the times are correct. You might check to make sure that there aren't timezone issues with either your client or server computer. Changing the use_localtime option to NO might help you to find your problem by displaying the file times in Zulu.

david_1234
Posts: 456
Joined: Mon Jan 01, 2018 2:14 pm

Re: FTP server -vsftpd show wrong time +3 from my time

Wed Jul 08, 2020 12:46 pm

I have an IP camera theat uplaod files to the pi .
the camera time & date are correct (the same as the pi +- a few seconds).

what else it could be ?

bjtheone
Posts: 1108
Joined: Mon May 20, 2019 11:28 pm
Location: The Frozen North (AKA Canada)

Re: FTP server -vsftpd show wrong time +3 from my time

Wed Jul 08, 2020 6:53 pm

What time zone are you in?

knute
Posts: 664
Joined: Thu Oct 23, 2014 12:14 am
Location: Texas
Contact: Website

Re: FTP server -vsftpd show wrong time +3 from my time

Wed Jul 08, 2020 6:56 pm

I think it has to be a timezone problem. What timezone are you in? What are the contents of /etc/timezone? What is the output of the date command?

pi@raspberrypi3B-1:~ $ cat /etc/timezone
America/Chicago

pi@raspberrypi3B-1:~ $ date
Wed 08 Jul 2020 01:56:40 PM CDT

Return to “Beginners”