I have encountered an interesting difference in the way files are handled between using Windows as a client PC with either a Windows Server 2003 R2 as server or a Raspberry Pi with Raspbian Wheezy and Samba as a server. In both cases the client sees the data via mapped drives.
First, by way of background: I have several business and community websites hosted in the Linx centre (Canary Wharf). Although the webstatistics for the sites are available to be via Webalizer, I actually FTP the webstat log files down to my server daily, for more detailed analysis. Recently, I transferred responsibility for the management and processing of the daily files to one of my Raspberrys Pi which functions as a domain controller and fileserver.
The files are FTP'd to the server, and are then renamed as the date of retrieval as YYYYMMDD.txt. The Win2k3 server did this by a small C-compiled program, whereas the Raspberry Pi does it by a script. But the effect on the filename is absolutely identical in each case. All files have the same time, of 06:00am exactly.
Each month, I concatenate the 30 or 31 files into a single file. This is done at a Windows Command Window by navigation to the directory on the mapped drive, and typing the following command, for example, for January 2013:
Code: Select all
type 201301??.txt >> 201301.txt
When this process was managed at mapped drive on the Windows Server 2003 R2 server, the effect was to take the files in exact date order and write the contents into the new file for the month.
When the process is managed at a mapped drive on the Raspberry Pi, the files are NOT written into the new monthly file in exact date order: rather there is always one file which is written first, usually it is that from the 8th, 9th or 10th of the month. That file is then followed by the other files in the correct date order.
Does anyone have an explanation? Remember that the files are all named by the date, one file per day for the month, and that they all have the same time, exactly.
(Note that because of this little issue, the files are now concatenated into the monthly file at the time of retrieval, so they are put into the monthly file in the correct order!)
All the best,