Kristian Rink
2004-Jan-10 14:41 UTC
[Samba] syncing file dates between windows nt4 and samba 3.0
Hi all,... ... currently I am trying to get hold of a strange error which is successfully keeping me from sleeping the last week. Basically, I am running a DebianGNU/Linux based machine with samba 3.0.0 as a backup server for an amount of Windows NT4 workstations. There is an old backup "framework" around here, basically a collection of .bat files on the workstations which at night run xcopy /d to copy files from the workstation to the backup server (which used to be an NT4 server before, as well). This procedure by now was intented to only copy modified files from workstation to backup, which worked pretty well... This is not the case with Samba, however. Basically, the Samba server is part of the local NT domain, access permissions are fine so far, yet xcopy each and every time is copying _all_ files to the backup server instead of just those which didn't change. And, by now, no matter which files or directories I am copying there - if they already exist on the samba machine, they're obviously updated, but their timestamp doesn't change while doing this. After playing around with dos filetime and fake directory create filetimes without any success: Can anyone enlighten me in this topic? TIA, have a fine weekend everyone! Kris
Holger Krull
2004-Jan-10 18:19 UTC
[Samba] syncing file dates between windows nt4 and samba 3.0
Kristian Rink schrieb:> workstations which at night run xcopy /d to copy files from the> files or directories I am copying there - if they already exist on the > samba machine, they're obviously updated, but their timestamp doesn't> After playing around with dos filetime and fake directory create > filetimes without any success: Can anyone enlighten me in this topic?Hmm, no real solution but the update stops if you make a touch on the samba server on all files. And a system with disabled ntfslastAccess doesn't update every time with xcopy /d. Looks as if this behaviour comes from differences in creation, access and changed times. (touch sets all of them to current time) And robocopy only picks the real changes, maybe you can use that. Holger
Dan Shadix
2004-Jan-10 18:32 UTC
[Samba] syncing file dates between windows nt4 and samba 3.0
If you are just trying to backup the files from NT to SAMBA, I'd use xcopy /m instead. /m copies files with the archive attribute set, and then turns off the archive attribute. That way you don't have to worry about the dates. Dan>Kristian Rink schrieb: > >> workstations which at night run xcopy /d to copyfiles from the> >> files or directories I am copying there - ifthey already exist on the>> samba machine, they're obviously updated, buttheir timestamp doesn't> >> After playing around with dos filetime and fakedirectory create>> filetimes without any success: Can anyoneenlighten me in this topic?>
Daniel Johnson
2004-Jan-11 04:13 UTC
[Samba] syncing file dates between windows nt4 and samba 3.0
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 10 Jan 2004 at 19:15, Holger Krull wrote:> Kristian Rink schrieb: > > workstations which at night run xcopy /d to copy files from the > > > files or directories I am copying there - if they already existon the> > samba machine, they're obviously updated, but their timestampdoesn't> > > After playing around with dos filetime and fake directory create > > filetimes without any success: Can anyone enlighten me in thistopic? <Sorry for posting here, I subscribed after the first message> What systems are in use? I ask because I had a similar always-updating problem when mirroring a website onto a FAT32 partition. FAT's timestamps are only kept to 2-second precision (IIRC), but the website was on EXT2. The FAT system appeared to round the timestamps *down*, so every time wget compared them it thought my copy was old. I found that putting a 'touch *' at the end of that script took care of the problem. If that really is the cause of your problem, you could put an extra command in those BAT files ("copy C:\something .\update.now") to signal a cron job that it needs to touch everything. It would be nice to have a "--plus-one-minute" option in touch... - -- Through the modem, off the server, over the T1, past the frame-relay, < < NOTHIN' BUT NET > > Daniel Johnson Progman2000@usa.net http://dannyj.come.to/ Public PGP Keys & other info: http://dannyj.come.to/pgp/ -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.3 (MingW32) - GPGshell v2.95 iD8DBQFAAM1F6vGcUBY+ge8RAoYwAKCco5UJaDsBcSH0RvaQ2otD43hm+QCg/bof xyL3DdtJGBnkFKDuigBUfo8=6y8f -----END PGP SIGNATURE-----