For When You Can't Have The Real Thing
[ start | index | login ]
start > wu-ftp > Times Displayed Incorrectly

Times Displayed Incorrectly

Created by dave. Last edited by dave, 10 years and 312 days ago. Viewed 3,370 times. #3
[diff] [history] [edit] [rdf]
labels
attachments

Problem

I'm running wu-ftpd on CentOS 4.x (see how to build on FC2 which works on CentOS 4.x). When I display file times through the ftp server, they are wrong. The >>FAQ on the subject doesn't help me.

Solution

On my system, there was no TZ environment variable set. wu-ftpd seemed to be reading the times on disk and displaying them in UTC instead of my local timezone.

The solution was to doctor the environment inherited by wu-ftpd from xinetd by modifying the file /etc/xinetd.d/wu-ftpd (see the env line):

# description: The wu-ftpd FTP server serves FTP connections. It uses 
#       normal, unencrypted usernames and passwords for authentication.
service ftp
{
        disable                 = no
        socket_type             = stream
        wait                    = no
        user                    = root
        server                  = /usr/sbin/in.ftpd
        server_args             = -l -a
        log_on_success          += DURATION
        nice                    = 10
        env                     = TZ='EST5EDT'
}
no comments | post comment
This is a collection of techical information, much of it learned the hard way. Consider it a lab book or a /info directory. I doubt much of it will be of use to anyone else.

Useful:


snipsnap.org | Copyright 2000-2002 Matthias L. Jugel and Stephan J. Schmidt