Subject: [156] Incorrect Time Zone

From: "Kurt Jansen ((303) 924-6975)" <[email-masked]>
Date: Tue, 12 Jul 1994 08:52:51 -0600 (MDT)

>I've just installed wu-ftpd-2.4. For some reason it's working
>in the GMT time zone, whereas everything else on my machine
>is (correctly) in British Summer Time (=GMT+1).
>
>Any ideas?

Phillip,
You don't say what operating system you are running on, but I had
the same problem with my RS/6000 running AIX 3.2.5.  Below is a
FAQ I put together on installing wu-ftpd on AIX.  Most of the
resolutions were from discussions on this mailing list.  Problem #1
in the list looks like the same one you are having.

PS:  If the developers of wu-ftpd are watching, perhaps they could
     incorporate some of these fixes in the product to make it
     easier to install on AIX systems.  Aside from these problems
     wu-ftpd is great!

- Kurt Jansen

***********************************************************************
Problem #1:
-----------
Timestamps in the logs are displayed in Greenwich Mean Time instead of
Local time.

Solution:                   (from Shane Castle [email-masked])
---------
Frequently, the SETPROCTITLE definition causes wu-ftpd to destroy all
environment variables, including the TZ environment variable.  If the
TZ environment variable is destroyed then all routines that display
time will use the actual recorded time (GMT) and never convert it to
local time.  Before you do the 'build aix' step, undefine SETPROCTITLE
by changing the following line in the src/config/config.aix file from:
     #define SETPROCTITLE
to:
     #undef  SETPROCTITLE

Problem #2:
-----------
The compile of ftpd.c fails with errors saying strunames, typenames,
modenames, ... are undefined.

Solution:
---------
This is documented in the INSTALL file, but it is easily missed.  To fix
this, you need to use the support/ftp.h file instead of the default
/usr/include/arpa/ftp.h.  The INSTALL file says you can replace the
/usr/include/arpa/ftp.h with the one in support/ftp.h.  However, I just
changed the #include in ftpd.c to reference the ftp.h file in the support
directory.  To do this, edit src/ftpd.c and comment out the old #include
for ftp.h and add a new one like so:
     /* #include <arpa/ftp.h>       */
     #include <../support/ftp.h>

Problem #3:
-----------
The 'build install' step does not work.  Install commands get syntax
errors.

Solution:                   (from Herald Milz  [email-masked])
---------
The install commands in the top Makefile are in BSD format.  The
default install program in AIX is /bin/install, and does not accept
this format, giving syntax errors on all the install commands.

The BSD-compatible install command in AIX is /usr/ucb/install.  You
can fix the Makefile by making INSTALL a variable in the Makefile
that points to /usr/ucb/install.  Edit the Makefile and make the
following changes.
Add the following line to the top of the Makefile:
     INSTALL=/usr/ucb/install

Then change all of the install commands to use ${INSTALL} instead.
For instance, change:
     install -o bin -g bin -m 755 bin/ftpd ${ETCDIR}/ftpd
to:
     ${INSTALL} -o bin -g bin -m 755 bin/ftpd ${ETCDIR}/ftpd

Problem #4:
-----------
Real users can not log on - get message:
   530 User xxxxxx access denied ...
   login failed

Solution:
---------
In step 5 of the INSTALL file it says:
  Make sure that you have a /etc/shells that lists all valid shells on
  your system.  Otherwise, those who have shells not listed there will
  not be able to log in.  �Yes, this is the expected behaivor.Ù

However, it does not say what the format is for the /etc/shells file is.
It turns out that most UNIX systems have a file called /etc/shells that
list all the valid shells on the system.  AIX does not have a file like
this, so you must create one.  Create an /etc/shells file that lists all
the valid shells on the system, one shell per line and starting in
column 1.  A sample /etc/shells file might have the following entries:

/bin/sh
/bin/csh
/bin/ksh

---

From: chuck <[email-masked]>
Date: Tue, 23 Jun 1998 10:00:44 -0400

> You don't say what operating system you are running on, but I had
[Yeah, I have to agree here.  You CAN"T report a problem without giving
 decent info to debug with.  wu-ftpd runs on about any unix, so let
 us know which one]

> * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
> Problem #1:

Would putting a localtime file help here?  In BSD4.4 it would go
in /etc/ (and is usually a link to, say, /usr/share/zoneinfo/US/Eastern).
Solaris and SunOS look in /usr/share/lib/zoneinfo/SOMETHING (I forget)
and making that file helps.

remember, it opens a connection to syslog, then chroots to ~ftp, then
starts talking.  It has no clue what zone it's in.

> default install program in AIX is /bin/install, and does not accept
[...]
> The BSD-compatible install command in AIX is /usr/ucb/install.

For sanity, you MAY want to build GNU's fileutils and things like
that.  I had to hop from machine to machine and found that with these,
I could type "du" or "df" and get a consistent output.  I just stuck
them in /usr/gnu/bin.  Made a multi-architecture life MUCH saner.
Worked on Ultrix, SunOS, Solaris, AIX, and about everything else
I tried.