How do I know when my Ubuntu was installed?
Ralf Mardorf
silver.bullet at zoho.com
Mon Sep 5 01:17:16 UTC 2016
On Mon, 05 Sep 2016 00:48:11 +0200, Oliver Grawert wrote:
>sadly the ls command will only give you the last modification time
Hi,
indeed and even the hostname file could be completely deleted and
recreated, not only be modified. Your hint using /var/log/installer/ is
better, however, for /var/log/installer/ the "ls -l" command should
already do the job :).
It's mentioned by the link I posted...
"[snip]
You can check the installer logs and dates at:
/var/log/installer
A quick way to find the date through the command line would be by
running:
ls -l /var/log/installer
[snip]
If a heuristic is good enough, look at the date (mtime) of a file that
was created during the installation and is unlikely to have been
modified since. A good candidate is /etc/hostname; other candidates
are /etc/hosts, /etc/papersize, /etc/popularity-contest.conf.
[snip]" -
http://askubuntu.com/questions/1352/how-can-i-tell-what-date-ubuntu-was-installed
...but I didn't cared much about /var/log/installer/, IIRC I just run
"The command sudo grep ubiquity /var/log/installer/syslog | less
[snip]" -
http://askubuntu.com/questions/1352/how-can-i-tell-what-date-ubuntu-was-installed
[weremouse at moonstudio ~]$ sudo grep ubiquity /var/log/installer/syslog
[weremouse at moonstudio ~]$ echo $?
1
;)
In my case the date is mentioned by
/var/log/installer/media-info, too, perhaps because it was a
development release, that perhaps was downloaded on the same day I
installed Ubuntu.
[weremouse at moonstudio ~]$ ls -hAl /var/log/installer/
total 1.4M
drwxr-xr-x 2 root root 4.0K Jul 25 2015 cdebconf
-rw-r--r-- 1 root root 25K Jul 25 2015 hardware-summary
-rw-r--r-- 1 root root 127K Jul 25 2015 initial-status.gz
-rw-r--r-- 1 root root 126 Jul 25 2015 lsb-release
-rw-r--r-- 1 root root 60 Jul 25 2015 media-info
-rw------- 1 root root 618K Jul 25 2015 partman
-rw-r--r-- 1 root root 62K Jul 25 2015 status
-rw------- 1 root root 513K Jul 25 2015 syslog
[weremouse at moonstudio ~]$ echo $(cat /var/log/installer/media-info)
Ubuntu-Server 15.10 "Wily Werewolf" - Alpha amd64 (20150725)
[weremouse at moonstudio ~]$ sudo head -1 /var/log/installer/syslog
[sudo] password for weremouse:
Jul 25 20:20:41 syslogd started: BusyBox v1.22.1
[weremouse at moonstudio ~]$ cat /var/log/installer/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=15.10
DISTRIB_CODENAME=wily
DISTRIB_DESCRIPTION="Ubuntu Wily Werewolf (development branch)"
[weremouse at moonstudio ~]$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04.1 LTS
Release: 16.04
Codename: xenial
Regards,
Ralf
More information about the ubuntu-users
mailing list