| | |
Perl FTP Problem
Please support our Perl advertiser: Programming Forums - DaniWeb Sister Site
![]() |
•
•
Join Date: Mar 2007
Posts: 11
Reputation:
Solved Threads: 0
What I meant actually was that even if the timestamp of other files change ,it won't affect my application in any way.But the timestamp of the XML file should remain same.I tried copying a file to the remote host through Net::FTP and I did the same manually too.I tried to compare the two files through File::Compare and I got the result that both files weren't same.
•
•
Join Date: Mar 2007
Posts: 11
Reputation:
Solved Threads: 0
But the problem here is that I am using a windows 2003 server.So can you come up with any command which will revert back to the old timestamp?
•
•
Join Date: Dec 2007
Posts: 8
Reputation:
Solved Threads: 1
Unfortunately, ftp is not the problem. That's the way the file system operates. It takes makes the timestamps reflective of the time the file is put there. You won't be able to address it without doing some coding on the target node or modifying your application.
If you look at the other files you are sending you'll see that the timestamps are actually changing on those too, so the issue is not just ftp doing something weird or unexpected with just xml files.
Curious as to what you application is doing triggering of a timestamp. Do you have privs on the system where you are sending files?
If you look at the other files you are sending you'll see that the timestamps are actually changing on those too, so the issue is not just ftp doing something weird or unexpected with just xml files.
Curious as to what you application is doing triggering of a timestamp. Do you have privs on the system where you are sending files?
•
•
Join Date: Mar 2007
Posts: 11
Reputation:
Solved Threads: 0
•
•
•
•
Unfortunately, ftp is not the problem. That's the way the file system operates. It takes makes the timestamps reflective of the time the file is put there. You won't be able to address it without doing some coding on the target node or modifying your application.
If you look at the other files you are sending you'll see that the timestamps are actually changing on those too, so the issue is not just ftp doing something weird or unexpected with just xml files.
Curious as to what you application is doing triggering of a timestamp. Do you have privs on the system where you are sending files?
•
•
Join Date: Dec 2007
Posts: 8
Reputation:
Solved Threads: 1
Well, some ftp utilities allow using a 'preserve' option with MDTM, but my versions don't have it. So, check yours. If you don't find that workable, then, another option is to tar up the files, and extract them on the remote system. That should preserve the timestamps.
Honestly, though, in my work, I usually name files with a timestamp appended to the name of the file, rather than depend on the file system to give me that information accurately. Since, I move files from Linux, HPUX, OpenVMS, Windows, it is the only way I can deal with this type of issue. My applications that use these types of files parse the files based on the file names, not the timestamps.
Hope the above gives you some relief.
Cheers
Honestly, though, in my work, I usually name files with a timestamp appended to the name of the file, rather than depend on the file system to give me that information accurately. Since, I move files from Linux, HPUX, OpenVMS, Windows, it is the only way I can deal with this type of issue. My applications that use these types of files parse the files based on the file names, not the timestamps.
Hope the above gives you some relief.
Cheers
Last edited by tuxboy; Mar 5th, 2008 at 2:38 pm. Reason: left out something
use the perl command
utime( )
to change the timestamp of the file to be whatever you want.
http://www.perl.com/doc/manual/html/...unc/utime.html
utime( )
to change the timestamp of the file to be whatever you want.
http://www.perl.com/doc/manual/html/...unc/utime.html
![]() |
Similar Threads
- A Guide for Finding Printer Support (USB Devices and other Peripherals)
- WEB HOSTING - $4.99/MONTH For 1GB HD & 50GB BW! CPanel, PHP, MySQL & MORE! (Web Hosting Deals)
- RESELLER WEB HOSTING - $9.99/MONTH For 5GB HD & 75GB BW! CPanel, PHP, MySQL & MORE! (Web Hosting Deals)
- Cpanel 24Hr Support Premium Web Hosting E-gold/Paypal/Money Bookers Accepted (Web Hosting Deals)
- Internal Server Error (Perl)
- I am New In MySQL. Problem With MySQL Database Plz Help. (MySQL)
- I have a form problem (HTML and CSS)
- another newbie with alot of redhat and apache server Q'S (Linux Servers and Apache)
- cgi (HTML and CSS)
Other Threads in the Perl Forum
- Previous Thread: Perl SNMP Help
- Next Thread: images with perl
Views: 2204 | Replies: 9
| Thread Tools | Search this Thread |
Tag cloud for Perl






