I found out that the particular FTP client that ships with a SuSE distribution 
is 'lukemftp' which contains this additional "preserve" command.  After 
uninstalling this and installing a different FTP client I was able to get the 
timestamp behavior that was desired without any additional fuss, but now I know 
about netrc.

Thanks,

Mike
 

-----Original Message-----
From: Linux on 390 Port [mailto:[email protected]] On Behalf Of Steffen 
Maier
Sent: Friday, September 16, 2011 5:23 PM
To: [email protected]
Subject: Re: FTP file timestamps

On 09/16/2011 08:48 PM, Frederick, Michael wrote:
> There is a subcommand/setting in (SLES9/10/11) FTP called "preserve",
> which says whether or not the timestamp on the file when you transfer
> it gets rewritten or not.  It is defaulted such that the timestamp on
> a 'get' remains the same.
>
> I have been asked if there is a way (other than issuing 'preserve
> off') to set this via some '.ftp_profile' or configuration file.  I
> know that I could download the FTP source, find the setting in there,
> change it, and recompile the program, but I would think there'd be an
> easier way.  Can anyone think of how you would do this?

I don't know anything about the particular preserve option. However,
the traditional ftp client reads ~/.netrc (man 5 netrc), where you can 
specify users and passwords to use with certain hosts, plus defining 
macros with "macdef", where the special macro named "init" gets executed 
automatically on successful login to an ftp host. Maybe you can use this 
to set the preserve thingy. With the lftp client, there's additionally 
~/.lftprc and ~/.lftp/rc and the system-wide /etc/lftp.conf and there 
seem to be options like ftp:use-mdtm 
[http://tools.ietf.org/html/rfc3659#section-3].

On the server side, things most probably depend on the specific ftpd 
implementation. E.g. I found an mdtm_write option with vsftpd with which 
you can disable the use of the MDTM ftp command to set file modification 
times (on the server side).

Apparently, things depend on the direction of transfer and are not 
straight-forward according to http://www.rjh.org.uk/ftp-report.html.

Steffen

Linux on System z Development

IBM Deutschland Research & Development GmbH
Vorsitzender des Aufsichtsrats: Martin Jetter
Geschäftsführung: Dirk Wittkopp
Sitz der Gesellschaft: Böblingen
Registergericht: Amtsgericht Stuttgart, HRB 243294

----------------------------------------------------------------------
For LINUX-390 subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO LINUX-390 or visit
http://www.marist.edu/htbin/wlvindex?LINUX-390
----------------------------------------------------------------------
For more information on Linux on System z, visit
http://wiki.linuxvm.org/

----------------------------------------------------------------------
For LINUX-390 subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO LINUX-390 or visit
http://www.marist.edu/htbin/wlvindex?LINUX-390
----------------------------------------------------------------------
For more information on Linux on System z, visit
http://wiki.linuxvm.org/

Reply via email to