Re: Date of a FreeBSD installation

2011-01-27 Thread Alexandr Sushko

On 01/13/2011 11:28 PM, David Demelier wrote:

Hello folks,

I'm just guessing if there is a way to know a FreeBSD installation 
date. We can't look after the uname -a ident since an update of the 
FreeBSD kernel is possible.


I think searching a file absolutely not touched ever in the system can 
helps but which one?


markand@Melon ~ $ ls -l /root/.cshrc
-rw-r--r--  2 root  wheel  798 19 Jul 04:17 /root/.cshrc

It seems that this file has the FreeBSD dist access time so can't 
refers to neither.


Do you have any clue?

Cheers,



Try to use not ls -l, but ls -lc. It will show you file creation time.

ls -lcd /bin/, for example

drwxr-xr-x  2 root  wheel  1024 Dec 10 00:31 /bin/

--
Best regards,
Alexandr Sushko

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-27 Thread Chris Brennan
On Thu, Jan 27, 2011 at 3:56 AM, Alexandr Sushko
alexandrsus...@gmail.comwrote:

 Try to use not ls -l, but ls -lc. It will show you file creation time.


 ls -lcd /bin/, for example

 drwxr-xr-x  2 root  wheel  1024 Dec 10 00:31 /bin/


I ran this and the earliest date I found was Oct 12, 2008 which seems to be
around when I migrated from 7.2 to 7.3 and this box has been alive since
6.0-RELEASE, it's a good 5-6 yrs old
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-27 Thread Chad Perrin
On Thu, Jan 13, 2011 at 01:57:38PM -0800, Devin Teske wrote:
 
 You're going to have to resort to things that aren't touched during a
 system upgrade if you want to find out the `true' answer as to when the
 box was first ... what? partitioned? newfs'd? clue me in here.
 
 What _is_ the definition of built ??? When the hardware pieces were
 coalesced into a single chassis? If that's the case, I'd be looking at
 model numbers of internal parts.

I suspect that at this point you are just being pedantic, and that you
know what the question actually means; you just want to dismiss the
question as immaterial.

-- 
Chad Perrin [ original content licensed OWL: http://owl.apotheon.org ]


pgpm7c8n9oyYt.pgp
Description: PGP signature


Re: Date of a FreeBSD installation

2011-01-27 Thread Devin Teske
On Thu, 2011-01-27 at 13:39 -0700, Chad Perrin wrote:

 On Thu, Jan 13, 2011 at 01:57:38PM -0800, Devin Teske wrote:
  
  You're going to have to resort to things that aren't touched during a
  system upgrade if you want to find out the `true' answer as to when the
  box was first ... what? partitioned? newfs'd? clue me in here.
  
  What _is_ the definition of built ??? When the hardware pieces were
  coalesced into a single chassis? If that's the case, I'd be looking at
  model numbers of internal parts.
 
 I suspect that at this point you are just being pedantic,


Correct. I get paid to be pedantic. It's a staple of my tenure-track
position.



  and that you
 know what the question actually means


Correct. Going back to the OP's e-mail, he indeed clarified that he was
only interested in the install-date of FreeBSD.


 ; you just want to dismiss the
 question as immaterial.


Incorrect and perceptually [unrightly] indignent.

The above statements (which you've taken out of context) were not to the
OP but a reply-thread between Chuck Swiger and myself.
--
Devin
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-27 Thread Chad Perrin
On Thu, Jan 27, 2011 at 09:09:52PM +, Devin Teske wrote:
 On Thu, 2011-01-27 at 13:39 -0700, Chad Perrin wrote:
 
  On Thu, Jan 13, 2011 at 01:57:38PM -0800, Devin Teske wrote:
   
   You're going to have to resort to things that aren't touched during a
   system upgrade if you want to find out the `true' answer as to when the
   box was first ... what? partitioned? newfs'd? clue me in here.
   
   What _is_ the definition of built ??? When the hardware pieces were
   coalesced into a single chassis? If that's the case, I'd be looking at
   model numbers of internal parts.
  
  I suspect that at this point you are just being pedantic,
 
 Correct. I get paid to be pedantic. It's a staple of my tenure-track
 position.

Do you get paid to read carefully?  I did not simply say you're being
pedantic.  I said you're *just* being pedantic, which is considerably
less useful or respectable.


 
   and that you
  know what the question actually means
 
 Correct. Going back to the OP's e-mail, he indeed clarified that he was
 only interested in the install-date of FreeBSD.
 
  ; you just want to dismiss the
 
 Incorrect and perceptually [unrightly] indignent.

s/indignent/indignant/

(just being pedantic; pardon me)

If that is not your intent, please enlighten me, because it *still* seems
to be your intended meaning, and this only looks like backpedaling in the
absence of any clarification of intended meaning.


 
 The above statements (which you've taken out of context) were not to the
 OP but a reply-thread between Chuck Swiger and myself.

. . . and yet, they're on the public list, so (it seems) there must be
some desire for them to be consumed by the general readership.  If that
desire is not rooted in an interest in publicly humiliating someone, the
next most likely reason seems to be to make comments in the general
context of the discussion thread hearkening back to the OP.  A third most
likely does not immediately spring to mind.

-- 
Chad Perrin [ original content licensed OWL: http://owl.apotheon.org ]


pgpKGh1GgY762.pgp
Description: PGP signature


Re: Date of a FreeBSD installation

2011-01-27 Thread Chad Perrin
I tried responding to an off-list message.  Delivery failed for some
reason.

I just don't want the sender of the message to which I tried to reply to
think I'm ignoring him, so I elected to send this to the list.

Thanks for your patience.

-- 
Chad Perrin [ original content licensed OWL: http://owl.apotheon.org ]


pgpaCnpR0jeSm.pgp
Description: PGP signature


Re: Date of a FreeBSD installation

2011-01-26 Thread David Demelier

On 14/01/2011 19:46, Carl Johnson wrote:

Chip Camdensterl...@camdensoftware.com  writes:


Quoth Carl Chave on Friday, 14 January 2011:

I'd suggest looking at the Btimes of top level directories

stat -f %SB %N /*


Or how about just / as this ~15 minutes earlier than most of the
remaining top level directories


sodserve# stat -f %SB %N /*
Jan  9 04:54:21 2011 /COPYRIGHT
Jan  9 04:54:21 2011 /bin
Jan  9 04:54:21 2011 /boot
Dec 31 18:59:59 1969 /dev
Jan  9 04:54:21 2011 /etc
Jan  9 04:54:21 2011 /lib
Jan  9 04:54:21 2011 /libexec
Jan  9 04:54:21 2011 /media
Jan  9 04:54:21 2011 /mnt
Jan  9 04:54:21 2011 /proc
Jan  9 04:54:21 2011 /rescue
Jan  9 04:54:21 2011 /root
Jan  9 04:54:21 2011 /sbin
Jan  9 04:54:21 2011 /sys
Jan  9 04:48:39 2011 /tmp
Jan  9 04:48:45 2011 /usr
Jan  9 04:49:39 2011 /var

sodserve# stat -f %SB %N /
Jan  9 04:39:59 2011 /


For me, that gets the Nov 21 2009 date, which is earlier than my
install date.

So far, /etc/hostid and the /home symlink seem to be the winners.


On my system /etc/hostid is several days later than my actual install
date, so that isn't always reliable.  You might want to create a file
with the timestamp you want.  The most likely time appears to me to be
the 'Created' time in /etc/rc.conf, as someone suggested earlier.  The
following code will extract that and create a file with that timestamp.
I have checked it on my system, but use at your own risk.

file=/etc/install_date
date=$(grep '^# Created: ' /etc/rc.conf | cut -c 12-80)
tdate=$(date -j -f %a %b %d %H:%M:%S %Y $date +%Y%m%d%H%M.%S)
echo $date  $file
touch -t $tdate $file
chmod -w $file
chflags schange $file



I finally agreed for /home symlink. I've made a mistake. To be sure the 
link and not the directory /usr/home is touched the best to do is :


# chflags -h uchg /home

-h means not following links

--
David Demelier
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-14 Thread David DEMELIER
2011/1/13 Chip Camden sterl...@camdensoftware.com:
 Quoth David Demelier on Thursday, 13 January 2011:
 Hello folks,

 I'm just guessing if there is a way to know a FreeBSD installation date.
 We can't look after the uname -a ident since an update of the FreeBSD
 kernel is possible.

 I think searching a file absolutely not touched ever in the system can
 helps but which one?

 markand@Melon ~ $ ls -l /root/.cshrc
 -rw-r--r--  2 root  wheel  798 19 Jul 04:17 /root/.cshrc

 It seems that this file has the FreeBSD dist access time so can't refers
 to neither.

 Do you have any clue?

 Cheers,

 --
 David Demelier
 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org

 The date on the /home symlink reflects my install date.  I don't think
 anything would touch that.

 --
 Sterling (Chip) Camden    | sterl...@camdensoftware.com | 2048D/3A978E4F
 http://camdensoftware.com | http://chipsquips.com       | http://chipstips.com


And to be sure that anything can touch it you can add the the `uchf'
flag to the symlink :

markand@Melon ~ $ ls -l /home
lrwxr-xr-x  1 root  wheel  8 11 Jan 2011 /home - usr/home
markand@Melon ~ $ sudo chflags uchg /home
markand@Melon ~ $ sudo touch /home
touch: /home: Operation not permitted

But be careful, apply `uchg' flag on /home and not /home/.

-- 
Demelier David
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-14 Thread n j
 I'm just guessing if there is a way to know a FreeBSD installation date.
 We can't look after the uname -a ident since an update of the FreeBSD
 kernel is possible.

How about looking at /proc or /mnt?

On a couple of my boxes that I checked, those files came up being the
oldest and probably match the installation date.

-- 
Nino
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-14 Thread krad
On 13 January 2011 20:34, Matthias Apitz g...@unixarea.de wrote:

 El día Thursday, January 13, 2011 a las 09:28:29PM +0100, David Demelier
 escribió:

  Hello folks,
 
  I'm just guessing if there is a way to know a FreeBSD installation date.
  We can't look after the uname -a ident since an update of the FreeBSD
  kernel is possible.
 
  I think searching a file absolutely not touched ever in the system can
  helps but which one?
 
  markand@Melon ~ $ ls -l /root/.cshrc
  -rw-r--r--  2 root  wheel  798 19 Jul 04:17 /root/.cshrc
 
  It seems that this file has the FreeBSD dist access time so can't refers
  to neither.
 
  Do you have any clue?

 I always use for this the oldest installed pkg:

 $ ls -lt /var/db/pkg

 HIH

matthias
 --
 Matthias Apitz
 t +49-89-61308 351 - f +49-89-61308 399 - m +49-170-4527211
 e g...@unixarea.de - w http://www.unixarea.de/
 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to 
 freebsd-questions-unsubscr...@freebsd.org


no good if packages have been updated
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-14 Thread Chip Camden
Quoth Carl Chave on Friday, 14 January 2011:
  I'd suggest looking at the Btimes of top level directories
 
  stat -f %SB %N /*
 
 Or how about just / as this ~15 minutes earlier than most of the
 remaining top level directories
 
 
 sodserve# stat -f %SB %N /*
 Jan  9 04:54:21 2011 /COPYRIGHT
 Jan  9 04:54:21 2011 /bin
 Jan  9 04:54:21 2011 /boot
 Dec 31 18:59:59 1969 /dev
 Jan  9 04:54:21 2011 /etc
 Jan  9 04:54:21 2011 /lib
 Jan  9 04:54:21 2011 /libexec
 Jan  9 04:54:21 2011 /media
 Jan  9 04:54:21 2011 /mnt
 Jan  9 04:54:21 2011 /proc
 Jan  9 04:54:21 2011 /rescue
 Jan  9 04:54:21 2011 /root
 Jan  9 04:54:21 2011 /sbin
 Jan  9 04:54:21 2011 /sys
 Jan  9 04:48:39 2011 /tmp
 Jan  9 04:48:45 2011 /usr
 Jan  9 04:49:39 2011 /var
 
 sodserve# stat -f %SB %N /
 Jan  9 04:39:59 2011 /

For me, that gets the Nov 21 2009 date, which is earlier than my
install date.

So far, /etc/hostid and the /home symlink seem to be the winners.

-- 
Sterling (Chip) Camden| sterl...@camdensoftware.com | 2048D/3A978E4F
http://camdensoftware.com | http://chipsquips.com   | http://chipstips.com


pgpXt05mhKVRS.pgp
Description: PGP signature


Re: Date of a FreeBSD installation

2011-01-14 Thread Chip Camden
Quoth David DEMELIER on Friday, 14 January 2011:
 2011/1/13 Chip Camden sterl...@camdensoftware.com:
 
  The date on the /home symlink reflects my install date.  I don't think
  anything would touch that.
 
  --
  Sterling (Chip) Camden    | sterl...@camdensoftware.com | 2048D/3A978E4F
  http://camdensoftware.com | http://chipsquips.com       | 
  http://chipstips.com
 
 
 And to be sure that anything can touch it you can add the the `uchf'
 flag to the symlink :
 
 markand@Melon ~ $ ls -l /home
 lrwxr-xr-x  1 root  wheel  8 11 Jan 2011 /home - usr/home
 markand@Melon ~ $ sudo chflags uchg /home
 markand@Melon ~ $ sudo touch /home
 touch: /home: Operation not permitted
 
 But be careful, apply `uchg' flag on /home and not /home/.
 
 -- 
 Demelier David

Touché.

-- 
Sterling (Chip) Camden| sterl...@camdensoftware.com | 2048D/3A978E4F
http://camdensoftware.com | http://chipsquips.com   | http://chipstips.com


pgpDRk8dkfyJb.pgp
Description: PGP signature


Re: Date of a FreeBSD installation

2011-01-14 Thread Chris Brennan
On Thu, Jan 13, 2011 at 6:01 PM, Carl Johnson ca...@peak.org wrote:

  How about /var/empty:

 % ls -ldo /var/empty/
 dr-xr-xr-x  2 root  wheel  schg 512 Jul 18 19:16 /var/empty/

 It can be changed, but doesn't look likely.


Ivan's e-mail I think might be a little more accurate

ch...@ziggy.xaerolimit.net [~]# grep delta /etc/rc.conf  lsl /etc/hostid
#-- sysinstall generated deltas -- # Sun Mar  8 19:10:02 2009
# -- sysinstall generated deltas -- # Tue Oct 26 02:15:25 2010
2 -rw-r--r--  1 root  wheel37B Mar  9  2009 /etc/hostid
ch...@ziggy.xaerolimit.net [~]#

whereas, your's gives me a date prior to that.

ch...@ziggy.xaerolimit.net [~]#
ls -ldo /var/empty/
dr-xr-xr-x  2 root  wheel  schg 512 Jan  1  2009 /var/empty/
ch...@ziggy.xaerolimit.net [~]#
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-14 Thread Chip Camden
Quoth n j on Friday, 14 January 2011:
  I'm just guessing if there is a way to know a FreeBSD installation date.
  We can't look after the uname -a ident since an update of the FreeBSD
  kernel is possible.
 
 How about looking at /proc or /mnt?
 
 On a couple of my boxes that I checked, those files came up being the
 oldest and probably match the installation date.
 
 -- 
 Nino

For me, /proc is older, /mnt is newer, than the install date.

-- 
Sterling (Chip) Camden| sterl...@camdensoftware.com | 2048D/3A978E4F
http://camdensoftware.com | http://chipsquips.com   | http://chipstips.com


pgppQhu3EGJFK.pgp
Description: PGP signature


Re: Date of a FreeBSD installation

2011-01-14 Thread krad
On 14 January 2011 15:37, Chip Camden sterl...@camdensoftware.com wrote:

 Quoth n j on Friday, 14 January 2011:
   I'm just guessing if there is a way to know a FreeBSD installation
 date.
   We can't look after the uname -a ident since an update of the FreeBSD
   kernel is possible.
 
  How about looking at /proc or /mnt?
 
  On a couple of my boxes that I checked, those files came up being the
  oldest and probably match the installation date.
 
  --
  Nino

 For me, /proc is older, /mnt is newer, than the install date.

 --
 Sterling (Chip) Camden| sterl...@camdensoftware.com | 2048D/3A978E4F
 http://camdensoftware.com | http://chipsquips.com   |
 http://chipstips.com



its nice to know the installation date, but im not sure what it gains you
technically.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-14 Thread RW
On Fri, 14 Jan 2011 07:32:13 -0800
Chip Camden sterl...@camdensoftware.com wrote:

  sodserve# stat -f %SB %N /*
  Jan  9 04:54:21 2011 /COPYRIGHT
  Jan  9 04:54:21 2011 /bin
  Jan  9 04:54:21 2011 /boot
  Dec 31 18:59:59 1969 /dev
  Jan  9 04:54:21 2011 /etc
  Jan  9 04:54:21 2011 /lib
  Jan  9 04:54:21 2011 /libexec

  
  sodserve# stat -f %SB %N /
  Jan  9 04:39:59 2011 /
 
 For me, that gets the Nov 21 2009 date, which is earlier than my
 install date.
 
 So far, /etc/hostid and the /home symlink seem to be the winners.
 
I think you'd have to look at a few dates. hostid hasn't been around
all that long, so it could have the date of the first boot after the
change was picked-up. There are legitimate reasons for modifying or
creating a /home symlink.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-14 Thread Carl Johnson
Chip Camden sterl...@camdensoftware.com writes:

 Quoth Carl Chave on Friday, 14 January 2011:
  I'd suggest looking at the Btimes of top level directories
 
  stat -f %SB %N /*
 
 Or how about just / as this ~15 minutes earlier than most of the
 remaining top level directories
 
 
 sodserve# stat -f %SB %N /*
 Jan  9 04:54:21 2011 /COPYRIGHT
 Jan  9 04:54:21 2011 /bin
 Jan  9 04:54:21 2011 /boot
 Dec 31 18:59:59 1969 /dev
 Jan  9 04:54:21 2011 /etc
 Jan  9 04:54:21 2011 /lib
 Jan  9 04:54:21 2011 /libexec
 Jan  9 04:54:21 2011 /media
 Jan  9 04:54:21 2011 /mnt
 Jan  9 04:54:21 2011 /proc
 Jan  9 04:54:21 2011 /rescue
 Jan  9 04:54:21 2011 /root
 Jan  9 04:54:21 2011 /sbin
 Jan  9 04:54:21 2011 /sys
 Jan  9 04:48:39 2011 /tmp
 Jan  9 04:48:45 2011 /usr
 Jan  9 04:49:39 2011 /var
 
 sodserve# stat -f %SB %N /
 Jan  9 04:39:59 2011 /

 For me, that gets the Nov 21 2009 date, which is earlier than my
 install date.

 So far, /etc/hostid and the /home symlink seem to be the winners.

On my system /etc/hostid is several days later than my actual install
date, so that isn't always reliable.  You might want to create a file
with the timestamp you want.  The most likely time appears to me to be
the 'Created' time in /etc/rc.conf, as someone suggested earlier.  The
following code will extract that and create a file with that timestamp.
I have checked it on my system, but use at your own risk.

file=/etc/install_date
date=$(grep '^# Created: ' /etc/rc.conf | cut -c 12-80)
tdate=$(date -j -f %a %b %d %H:%M:%S %Y $date +%Y%m%d%H%M.%S)
echo $date  $file
touch -t $tdate $file
chmod -w $file
chflags schange $file

-- 
Carl Johnsonca...@peak.org

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-13 Thread Matthias Apitz
El día Thursday, January 13, 2011 a las 09:28:29PM +0100, David Demelier 
escribió:

 Hello folks,
 
 I'm just guessing if there is a way to know a FreeBSD installation date. 
 We can't look after the uname -a ident since an update of the FreeBSD 
 kernel is possible.
 
 I think searching a file absolutely not touched ever in the system can 
 helps but which one?
 
 markand@Melon ~ $ ls -l /root/.cshrc
 -rw-r--r--  2 root  wheel  798 19 Jul 04:17 /root/.cshrc
 
 It seems that this file has the FreeBSD dist access time so can't refers 
 to neither.
 
 Do you have any clue?

I always use for this the oldest installed pkg:

$ ls -lt /var/db/pkg

HIH

matthias
-- 
Matthias Apitz
t +49-89-61308 351 - f +49-89-61308 399 - m +49-170-4527211
e g...@unixarea.de - w http://www.unixarea.de/
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-13 Thread Chuck Swiger
On Jan 13, 2011, at 12:28 PM, David Demelier wrote:
 I'm just guessing if there is a way to know a FreeBSD installation date. We 
 can't look after the uname -a ident since an update of the FreeBSD kernel is 
 possible.
 
 I think searching a file absolutely not touched ever in the system can helps 
 but which one?


Symlinks under /etc are a good choice:

# cd /etc ; ls -ltr | head
total 1242
lrwxrwxrwx  1 root  wheel 23 May 26  2001 termcap@ - 
/usr/share/misc/termcap
lrwxrwxrwx  1 root  wheel 13 May 26  2001 rmt@ - /usr/sbin/rmt

Regards,
-- 
-Chuck

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-13 Thread Chip Camden
Quoth David Demelier on Thursday, 13 January 2011:
 Hello folks,
 
 I'm just guessing if there is a way to know a FreeBSD installation date. 
 We can't look after the uname -a ident since an update of the FreeBSD 
 kernel is possible.
 
 I think searching a file absolutely not touched ever in the system can 
 helps but which one?
 
 markand@Melon ~ $ ls -l /root/.cshrc
 -rw-r--r--  2 root  wheel  798 19 Jul 04:17 /root/.cshrc
 
 It seems that this file has the FreeBSD dist access time so can't refers 
 to neither.
 
 Do you have any clue?
 
 Cheers,
 
 -- 
 David Demelier
 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org

The date on the /home symlink reflects my install date.  I don't think
anything would touch that.

-- 
Sterling (Chip) Camden| sterl...@camdensoftware.com | 2048D/3A978E4F
http://camdensoftware.com | http://chipsquips.com   | http://chipstips.com


pgpsDq2vwbc7R.pgp
Description: PGP signature


Re: Date of a FreeBSD installation

2011-01-13 Thread Chip Camden
Quoth Chuck Swiger on Thursday, 13 January 2011:
 On Jan 13, 2011, at 12:28 PM, David Demelier wrote:
  I'm just guessing if there is a way to know a FreeBSD installation date. We 
  can't look after the uname -a ident since an update of the FreeBSD kernel 
  is possible.
  
  I think searching a file absolutely not touched ever in the system can 
  helps but which one?
 
 
 Symlinks under /etc are a good choice:
 
 # cd /etc ; ls -ltr | head
 total 1242
 lrwxrwxrwx  1 root  wheel 23 May 26  2001 termcap@ - 
 /usr/share/misc/termcap
 lrwxrwxrwx  1 root  wheel 13 May 26  2001 rmt@ - /usr/sbin/rmt
 
 Regards,
 -- 
 -Chuck
 
 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org

On my system, /etc/termcap has the date well after my installation
(Jun 28 2010) and /etc/rmt dates to well before (Nov 21 2009).  I first
installed FreeBSD on this system on Apr 1 2010.

-- 
Sterling (Chip) Camden| sterl...@camdensoftware.com | 2048D/3A978E4F
http://camdensoftware.com | http://chipsquips.com   | http://chipstips.com


pgpd4KqKCYv80.pgp
Description: PGP signature


Re: Date of a FreeBSD installation

2011-01-13 Thread David DEMELIER
2011/1/13 Chuck Swiger cswi...@mac.com:
 On Jan 13, 2011, at 12:28 PM, David Demelier wrote:
 I'm just guessing if there is a way to know a FreeBSD installation date. We 
 can't look after the uname -a ident since an update of the FreeBSD kernel is 
 possible.

 I think searching a file absolutely not touched ever in the system can helps 
 but which one?


 Symlinks under /etc are a good choice:

 # cd /etc ; ls -ltr | head
 total 1242
 lrwxrwxrwx  1 root  wheel         23 May 26  2001 termcap@ - 
 /usr/share/misc/termcap
 lrwxrwxrwx  1 root  wheel         13 May 26  2001 rmt@ - /usr/sbin/rmt

 Regards,
 --
 -Chuck

 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


markand@Melon ~ $ cd /etc ; ls -ltr | head
total 612
drwxr-xr-x  2 root  wheel   512 19 Jul 04:16 zfs
drwxr-xr-x  2 root  wheel   512 19 Jul 04:16 skel

Same that my original post. I have not installed FreeBSD on July but
as Chip says the /home symlink is a pretty good choice :-)

Thanks

-- 
Demelier David
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-13 Thread Chuck Swiger
On Jan 13, 2011, at 12:45 PM, Chip Camden wrote:
 On my system, /etc/termcap has the date well after my installation
 (Jun 28 2010) and /etc/rmt dates to well before (Nov 21 2009).  I first
 installed FreeBSD on this system on Apr 1 2010.

Certainly the target of the link would change; my /etc/termcap points to:

-r--r--r--  1 root  wheel  206901 Dec 14 21:03 /usr/share/misc/termcap

This particular box I'm looking at had been updated from FreeBSD-4.x through 
7-STABLE, so a 2001 timestamp for the original installs seems about right.

I wonder, are you folks using something other than UFS for / 
filesystem...perhaps ZFS or whatever handles the dates on symlinks differently?

Regards,
-- 
-Chuck

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-13 Thread Chip Camden
Quoth Chuck Swiger on Thursday, 13 January 2011:
 On Jan 13, 2011, at 12:45 PM, Chip Camden wrote:
  On my system, /etc/termcap has the date well after my installation
  (Jun 28 2010) and /etc/rmt dates to well before (Nov 21 2009).  I first
  installed FreeBSD on this system on Apr 1 2010.
 
 Certainly the target of the link would change; my /etc/termcap points to:
 
 -r--r--r--  1 root  wheel  206901 Dec 14 21:03 /usr/share/misc/termcap
 
 This particular box I'm looking at had been updated from FreeBSD-4.x through 
 7-STABLE, so a 2001 timestamp for the original installs seems about right.
 
 I wonder, are you folks using something other than UFS for / 
 filesystem...perhaps ZFS or whatever handles the dates on symlinks 
 differently?
 
 Regards,
 -- 
 -Chuck

I'm all UFS.  My first installation was 8.0-RELEASE.  At that time, I
don't think termcap was even a symlink, but I could be mistaken.

I'm looking at the date on the symlink itself, not its target.

-- 
Sterling (Chip) Camden| sterl...@camdensoftware.com | 2048D/3A978E4F
http://camdensoftware.com | http://chipsquips.com   | http://chipstips.com


pgplVikbzxCvp.pgp
Description: PGP signature


Re: Date of a FreeBSD installation

2011-01-13 Thread Devin Teske
On Thu, 2011-01-13 at 13:03 -0800, Chip Camden wrote:
 Quoth Chuck Swiger on Thursday, 13 January 2011:
  On Jan 13, 2011, at 12:45 PM, Chip Camden wrote:
   On my system, /etc/termcap has the date well after my installation
   (Jun 28 2010) and /etc/rmt dates to well before (Nov 21 2009).  I first
   installed FreeBSD on this system on Apr 1 2010.
  
  Certainly the target of the link would change; my /etc/termcap points to:
  
  -r--r--r--  1 root  wheel  206901 Dec 14 21:03 /usr/share/misc/termcap
  
  This particular box I'm looking at had been updated from FreeBSD-4.x 
  through 7-STABLE, so a 2001 timestamp for the original installs seems about 
  right.
  
  I wonder, are you folks using something other than UFS for / 
  filesystem...perhaps ZFS or whatever handles the dates on symlinks 
  differently?
  
  Regards,
  -- 
  -Chuck
 
 I'm all UFS.  My first installation was 8.0-RELEASE.  At that time, I
 don't think termcap was even a symlink, but I could be mistaken.
 
 I'm looking at the date on the symlink itself, not its target.

This is nearly always accurate on any FreeBSD system (when wanting to
query the date the machine was built):

ls -l /etc/defaults/rc.conf

But again... not always. Though for all situations where the answer is
_NOT_ the correct answer... there's usually a damned-good explanation
why (the machine was rsync'd etc.), in which case I still consider the
date returned to be accurate (for any time /etc/defaults/rc.conf -- or
perhaps even better... /etc/rc -- is touched, I'd consider the system to
be rebuilt since those files should be somewhat golden on a system
-- read: never touched except during system upgrade or rsync etc.).
-- 
Cheers,
Devin Teske

- CONTACT INFORMATION -
Business Solutions Consultant II
FIS - fisglobal.com
510-735-5650 Mobile
510-621-2038 Office
510-621-2020 Office Fax
909-477-4578 Home/Fax
devin.te...@fisglobal.com

- LEGAL DISCLAIMER -
This message  contains confidential  and proprietary  information
of the sender,  and is intended only for the person(s) to whom it
is addressed. Any use, distribution, copying or disclosure by any
other person  is strictly prohibited.  If you have  received this
message in error,  please notify  the e-mail sender  immediately,
and delete the original message without making a copy.

- END TRANSMISSION -

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-13 Thread Chuck Swiger
On Jan 13, 2011, at 1:46 PM, Devin Teske wrote:
 This is nearly always accurate on any FreeBSD system (when wanting to
 query the date the machine was built):
 
   ls -l /etc/defaults/rc.conf

I gather that you don't ever run mergemaster, which would update this file?
My machine installed in 2001 has a Dec 2010 date for that file:

-r--r--r--  1 root  wheel  36037 Dec  1 14:13 /etc/defaults/rc.conf

Regards,
-- 
-Chuck

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-13 Thread Devin Teske
On Thu, 2011-01-13 at 13:50 -0800, Chuck Swiger wrote:
 On Jan 13, 2011, at 1:46 PM, Devin Teske wrote:
  This is nearly always accurate on any FreeBSD system (when wanting to
  query the date the machine was built):
  
  ls -l /etc/defaults/rc.conf
 
 I gather that you don't ever run mergemaster, which would update this file?
 My machine installed in 2001 has a Dec 2010 date for that file:

I view the running of mergemaster as part of a system upgrade which at
that point... I'm saying that the system is undergoing a rebuild in
which case, `ls -ltr /etc/defaults/rc.conf' is accurate (but, yes... I
agree with you that this is dependent upon the definition of accurate
-- entirely subjective to the definition of when did I build this
machine?; not everybody considers built to be inception).

That being said... because mergemaster _can_ touch every file on the
system, you really can't get an accurate answer from _any_ file's
timestamp.

You're going to have to resort to things that aren't touched during a
system upgrade if you want to find out the `true' answer as to when the
box was first ... what? partitioned? newfs'd? clue me in here.

What _is_ the definition of built ??? When the hardware pieces were
coalesced into a single chassis? If that's the case, I'd be looking at
model numbers of internal parts.

 
 -r--r--r--  1 root  wheel  36037 Dec  1 14:13 /etc/defaults/rc.conf
 
 Regards,
-- 
Cheers,
Devin Teske

- CONTACT INFORMATION -
Business Solutions Consultant II
FIS - fisglobal.com
510-735-5650 Mobile
510-621-2038 Office
510-621-2020 Office Fax
909-477-4578 Home/Fax
devin.te...@fisglobal.com

- LEGAL DISCLAIMER -
This message  contains confidential  and proprietary  information
of the sender,  and is intended only for the person(s) to whom it
is addressed. Any use, distribution, copying or disclosure by any
other person  is strictly prohibited.  If you have  received this
message in error,  please notify  the e-mail sender  immediately,
and delete the original message without making a copy.

- END TRANSMISSION -

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-13 Thread Polytropon
On Thu, 13 Jan 2011 13:50:27 -0800, Chuck Swiger cswi...@mac.com wrote:
 On Jan 13, 2011, at 1:46 PM, Devin Teske wrote:
  This is nearly always accurate on any FreeBSD system (when wanting to
  query the date the machine was built):
  
  ls -l /etc/defaults/rc.conf
 
 I gather that you don't ever run mergemaster, which would update this file?
 My machine installed in 2001 has a Dec 2010 date for that file:
 
 -r--r--r--  1 root  wheel  36037 Dec  1 14:13 /etc/defaults/rc.conf

Exactly that was my thought. Maybe a file that is NOT subject
to one of the system upgrade procedures would be better? Maybe
something in /boot?

% ls -l /etc/defaults/rc.conf
-r--r--r--  1 root  wheel  34300 Aug 24  2008 /etc/defaults/rc.conf
% ls -l /boot/defaults/loader.conf
-r--r--r--  1 root  wheel  19426 Aug 24  2008 /boot/defaults/loader.conf

No, forget about that, also nonsense, looks to new...




-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-13 Thread Ivan Voras

On 13/01/2011 21:28, David Demelier wrote:

Hello folks,

I'm just guessing if there is a way to know a FreeBSD installation date.
We can't look after the uname -a ident since an update of the FreeBSD
kernel is possible.


If you haven't removed it, a line in /etc/rc.conf should be written by 
sysinstall at system install time:


# -- sysinstall generated deltas -- # Sun Sep 14 16:13:22 2008

On a newer system (7+?), the timestamp of /etc/hostid would be from the 
first boot.


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-13 Thread Carl Johnson
Polytropon free...@edvax.de writes:

 On Thu, 13 Jan 2011 13:50:27 -0800, Chuck Swiger cswi...@mac.com wrote:
 On Jan 13, 2011, at 1:46 PM, Devin Teske wrote:
  This is nearly always accurate on any FreeBSD system (when wanting to
  query the date the machine was built):
  
 ls -l /etc/defaults/rc.conf
 
 I gather that you don't ever run mergemaster, which would update this file?
 My machine installed in 2001 has a Dec 2010 date for that file:
 
 -r--r--r--  1 root  wheel  36037 Dec  1 14:13 /etc/defaults/rc.conf

 Exactly that was my thought. Maybe a file that is NOT subject
 to one of the system upgrade procedures would be better? Maybe
 something in /boot?

 % ls -l /etc/defaults/rc.conf
 -r--r--r--  1 root  wheel  34300 Aug 24  2008 /etc/defaults/rc.conf
 % ls -l /boot/defaults/loader.conf
 -r--r--r--  1 root  wheel  19426 Aug 24  2008 /boot/defaults/loader.conf

 No, forget about that, also nonsense, looks to new...

How about /var/empty:

% ls -ldo /var/empty/
dr-xr-xr-x  2 root  wheel  schg 512 Jul 18 19:16 /var/empty/

It can be changed, but doesn't look likely.

-- 
Carl Johnsonca...@peak.org

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-13 Thread Chip Camden
Quoth Ivan Voras on Friday, 14 January 2011:
 On 13/01/2011 21:28, David Demelier wrote:
 Hello folks,
 
 I'm just guessing if there is a way to know a FreeBSD installation date.
 We can't look after the uname -a ident since an update of the FreeBSD
 kernel is possible.
 
 If you haven't removed it, a line in /etc/rc.conf should be written by 
 sysinstall at system install time:
 
 # -- sysinstall generated deltas -- # Sun Sep 14 16:13:22 2008
 
 On a newer system (7+?), the timestamp of /etc/hostid would be from the 
 first boot.
 
 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org

/etc/hostid has the right date for me.

-- 
Sterling (Chip) Camden| sterl...@camdensoftware.com | 2048D/3A978E4F
http://camdensoftware.com | http://chipsquips.com   | http://chipstips.com


pgprYENDxM96I.pgp
Description: PGP signature


Re: Date of a FreeBSD installation

2011-01-13 Thread Chip Camden
Quoth Carl Johnson on Thursday, 13 January 2011:
 Polytropon free...@edvax.de writes:
 
  On Thu, 13 Jan 2011 13:50:27 -0800, Chuck Swiger cswi...@mac.com wrote:
  On Jan 13, 2011, at 1:46 PM, Devin Teske wrote:
   This is nearly always accurate on any FreeBSD system (when wanting to
   query the date the machine was built):
   
ls -l /etc/defaults/rc.conf
  
  I gather that you don't ever run mergemaster, which would update this file?
  My machine installed in 2001 has a Dec 2010 date for that file:
  
  -r--r--r--  1 root  wheel  36037 Dec  1 14:13 /etc/defaults/rc.conf
 
  Exactly that was my thought. Maybe a file that is NOT subject
  to one of the system upgrade procedures would be better? Maybe
  something in /boot?
 
  % ls -l /etc/defaults/rc.conf
  -r--r--r--  1 root  wheel  34300 Aug 24  2008 /etc/defaults/rc.conf
  % ls -l /boot/defaults/loader.conf
  -r--r--r--  1 root  wheel  19426 Aug 24  2008 /boot/defaults/loader.conf
 
  No, forget about that, also nonsense, looks to new...
 
 How about /var/empty:
 
 % ls -ldo /var/empty/
 dr-xr-xr-x  2 root  wheel  schg 512 Jul 18 19:16 /var/empty/
 
 It can be changed, but doesn't look likely.
 
 -- 
 Carl Johnson  ca...@peak.org
 
 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org

On my system, it gives a date several months in advance of my install
date (Nov 21 2009).

-- 
Sterling (Chip) Camden| sterl...@camdensoftware.com | 2048D/3A978E4F
http://camdensoftware.com | http://chipsquips.com   | http://chipstips.com


pgpFDB7gtEbgU.pgp
Description: PGP signature


Re: Date of a FreeBSD installation

2011-01-13 Thread RW
On Thu, 13 Jan 2011 21:28:29 +0100
David Demelier demelier.da...@gmail.com wrote:

 Hello folks,
 
 I'm just guessing if there is a way to know a FreeBSD installation
 date. We can't look after the uname -a ident since an update of the
 FreeBSD kernel is possible.
 
 I think searching a file absolutely not touched ever in the system
 can helps but which one?
 
 markand@Melon ~ $ ls -l /root/.cshrc
 -rw-r--r--  2 root  wheel  798 19 Jul 04:17 /root/.cshrc
 
 It seems that this file has the FreeBSD dist access time so can't
 refers to neither.
 
 Do you have any clue?
 
 Cheers,
 

I'd suggest looking at the Btimes of top level directories

stat -f %SB %N /*
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-13 Thread Carl Johnson
Chip Camden sterl...@camdensoftware.com writes:

 Quoth Carl Johnson on Thursday, 13 January 2011:
 Polytropon free...@edvax.de writes:
 
  On Thu, 13 Jan 2011 13:50:27 -0800, Chuck Swiger cswi...@mac.com wrote:
  On Jan 13, 2011, at 1:46 PM, Devin Teske wrote:
   This is nearly always accurate on any FreeBSD system (when wanting to
   query the date the machine was built):
   
   ls -l /etc/defaults/rc.conf
  
  I gather that you don't ever run mergemaster, which would update this 
  file?
  My machine installed in 2001 has a Dec 2010 date for that file:
  
  -r--r--r--  1 root  wheel  36037 Dec  1 14:13 /etc/defaults/rc.conf
 
  Exactly that was my thought. Maybe a file that is NOT subject
  to one of the system upgrade procedures would be better? Maybe
  something in /boot?
 
  % ls -l /etc/defaults/rc.conf
  -r--r--r--  1 root  wheel  34300 Aug 24  2008 /etc/defaults/rc.conf
  % ls -l /boot/defaults/loader.conf
  -r--r--r--  1 root  wheel  19426 Aug 24  2008 /boot/defaults/loader.conf
 
  No, forget about that, also nonsense, looks to new...
 
 How about /var/empty:
 
 % ls -ldo /var/empty/
 dr-xr-xr-x  2 root  wheel  schg 512 Jul 18 19:16 /var/empty/
 
 It can be changed, but doesn't look likely.

 On my system, it gives a date several months in advance of my install
 date (Nov 21 2009).

Oops, you're right.  I just checked and it is a few days before I
actually installed mine, so that is probably when the ISO was built.

-- 
Carl Johnsonca...@peak.org

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Date of a FreeBSD installation

2011-01-13 Thread Carl Chave
 I'd suggest looking at the Btimes of top level directories

 stat -f %SB %N /*

Or how about just / as this ~15 minutes earlier than most of the
remaining top level directories


sodserve# stat -f %SB %N /*
Jan  9 04:54:21 2011 /COPYRIGHT
Jan  9 04:54:21 2011 /bin
Jan  9 04:54:21 2011 /boot
Dec 31 18:59:59 1969 /dev
Jan  9 04:54:21 2011 /etc
Jan  9 04:54:21 2011 /lib
Jan  9 04:54:21 2011 /libexec
Jan  9 04:54:21 2011 /media
Jan  9 04:54:21 2011 /mnt
Jan  9 04:54:21 2011 /proc
Jan  9 04:54:21 2011 /rescue
Jan  9 04:54:21 2011 /root
Jan  9 04:54:21 2011 /sbin
Jan  9 04:54:21 2011 /sys
Jan  9 04:48:39 2011 /tmp
Jan  9 04:48:45 2011 /usr
Jan  9 04:49:39 2011 /var

sodserve# stat -f %SB %N /
Jan  9 04:39:59 2011 /
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org