I posted this a few days ago and got only marginally helpful responses, so 
here it is again with more detail:

1) I'm using reasonably recent versions of things:

# uname -a
FreeBSD acer.wb4jcm.org 7.0-RC1 FreeBSD 7.0-RC1 #0: Mon Dec 24 10:10:07 UTC 
2007     [EMAIL PROTECTED]:/usr/obj/usr/src/sys/GENERIC  amd64

# mkisofs -version
mkisofs 2.01.01a37 (amd64-unknown-freebsd7.0) Copyright (C) 1993-1997 Eric 
Youngdale (C) 1997-2007 Jörg Schilling

# pkg_info | grep cdrtools
cdrtools-devel-2.01.01a37,1 CD/DVD and ISO-9660 image creation and extraction 
tools

2) My system is set to US Eastern Standard Time:

# date
Wed Jan 23 21:45:27 EST 2008
# date -u
Thu Jan 24 02:45:49 UTC 2008
# TZ=EST date
Wed Jan 23 21:46:53 EST 2008
# TZ=GMT date
Thu Jan 24 02:46:58 GMT 2008
# echo $TZ

# 

This is a dual boot system (with MS Vista), so the hardware clock is set to 
local time, not to GMT. I suspect this is significant.


3) I have a test file (just a bunch of zeroes). It's big because I wanted to 
see how quickly this system could write out a GB of data, but I get the same 
results with small files). The time stamp displayed by "ls" is correct for 
local time, and shows correct GMT time if I ask for it:
# ls -l
total 1049104
-rw-r--r--  1 root  bobj  1073741824 Jan 23 21:28 test.file <--CORRECT
# TZ=GMT ls -l
total 1049104
-rw-r--r--  1 root  bobj  1073741824 Jan 24 02:28 test.file <--CORRECT
#      


4) I use mkisofs to create an ISO filesystem with this test file in it:

# mkisofs -R -J -o test.iso test.file
  0.95% done, estimate finish Wed Jan 23 21:55:59 2008
[...]
 99.15% done, estimate finish Wed Jan 23 21:54:46 2008
Total translation table size: 0
Total rockridge attributes bytes: 274
Total directory bytes: 0
Path table size(bytes): 10
Max brk space used 0
524469 extents written (1024 MB)

5) I use mdconfig to mount the ISO filesystem (I get the same results if I use 
burncd to burn a CD and then mount the CD):

# mdconfig -a -t vnode -f test.iso -u 4
# mount_cd9660 /dev/md4 /mnt
#                    

6) Now when I look at the dates on the ISO filesystem, they are wrong. They 
look like the correction for offset from GMT has been applied twice. Note 
that the correct local timestamp for the file on the ISO filesystem is  Jan 
23 21:28 and the correct GMT timestamp is Jan 24 02:28.

# ls -l /mnt
total 1048576
-rw-r--r--  1 root  bobj  1073741824 Jan 23 16:28 test.file <-- WRONG!
# TZ=EST ls -l /mnt
total 1048576
-rw-r--r--  1 root  bobj  1073741824 Jan 23 16:28 test.file <-- WRONG!
# TZ=GMT ls -l /mnt
total 1048576
-rw-r--r--  1 root  bobj  1073741824 Jan 23 21:28 test.file <-- WRONG!
#
# ls -lc /mnt
total 1048576
-rw-r--r--  1 root  bobj  1073741824 Jan 23 16:28 test.file <-- WRONG!
# ls -lt /mnt
total 1048576
-rw-r--r--  1 root  bobj  1073741824 Jan 23 16:28 test.file <-- WRONG!
# ls -lu /mnt
total 1048576
-rw-r--r--  1 root  bobj  1073741824 Jan 23 16:37 test.file <-- WRONG!
#       

So what is going on here? Is this a bug, or a misconfiguration, or a 
misunderstanding? 

And as a side issue, why is the incorrect last access time 16:37, rather than 
16:54, since I built the ISO filesystem at 21:54?

I have not yet tried moving a CD to a Windows system to see what the file 
timestamp shows there. I have tried this on two different FreeBSD systems 
(7.0-RC1 amd64, and 6.2-RELEASE-p9 i386) with both cdrtools and 
cdrtools-devel from ports, and get the same results.

- Bob
_______________________________________________
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Reply via email to