This isn’t a problem ‘per se’ - just something I noticed today…
I use the “stat /” command to get the install date for my Linux OS, works out of the box on
- Red Hat (8) x86_64
- Ubuntu 22.04 (x86_64)
- Ubuntu 22.04 arm64/aarch64 on a Pi 4 (8 GB model).
But - it doesn’t work on
- Ubuntu 16.04 on Orange Pi 2E+(via Armbian - yeah I know it’s EOL, but all it does is run transmission-daemon, and I won’t do anything with it until it breaks)
- Raspbian Stretch on RPi3B
(they both have a “Birth” field, but it’s unpopulated)
It “sorta/kinda” works on :
- MacOS
- FreeBSD (via FreeNAS)
i.e. it doesn’t have “Birth” field at the end, but, I can kinda glean from the output (MacOS and FreeBSD are, unsuprisingly, very similar) what day that “/” was first created…
Hmmm - just booted up an REL7 VM - and it too has an empty “Birth” field.
I don’t think its a kernel thing anyway? But why have it there, if it’s not going to be used? REL 7 is on kernel 3, REL 8 is on kernel 4, the other two that have “Birth” populated (Ubuntu 22.04 on x86_64 and arm64) are Kernel 5, but the Pi3 is running Kernel 4…
REL 7 :
[x@rel7 ~]$ uname -a
Linux rel7 3.10.0-1160.el7.x86_64 #1 SMP Tue Aug 18 14:50:17 EDT 2020 x86_64 x86_64 x86_64 GNU/Linux
[x@rel7 ~]$ sudo stat /
File: ‘/’
Size: 224 Blocks: 0 IO Block: 4096 directory
Device: fd00h/64768d Inode: 64 Links: 17
Access: (0555/dr-xr-xr-x) Uid: ( 0/ root) Gid: ( 0/ root)
Context: system_u:object_r:root_t:s0
Access: 2022-07-25 13:19:12.575000000 +0800
Modify: 2022-06-21 10:24:19.744000000 +0800
Change: 2022-06-21 10:24:19.744000000 +0800
Birth: -
REL 8 :
╭─x@fuglpige ~
╰─➤ uname -a
Linux fuglpige 4.18.0-372.9.1.el8.x86_64 #1 SMP Fri Apr 15 22:12:19 EDT 2022 x86_64 x86_64 x86_64 GNU/Linux
╭─x@fuglpige ~
╰─➤ sudo stat /
File: /
Size: 224 Blocks: 0 IO Block: 4096 directory
Device: fd00h/64768d Inode: 128 Links: 17
Access: (0555/dr-xr-xr-x) Uid: ( 0/ root) Gid: ( 0/ root)
Context: system_u:object_r:root_t:s0
Access: 2022-04-12 17:45:41.679323287 +0800
Modify: 2022-04-01 13:45:59.972594135 +0800
Change: 2022-04-01 13:45:59.972594135 +0800
Birth: 2022-04-01 13:20:21.929182000 +0800
Debian Stretch (armhf/arm7l) on Pi3B
╭─x@telesto ~
╰─➤ uname -a
Linux telesto 4.19.66-v7+ #1253 SMP Thu Aug 15 11:49:46 BST 2019 armv7l GNU/Linux
╭─x@telesto ~
╰─➤ sudo stat /
File: /
Size: 4096 Blocks: 8 IO Block: 4096 directory
Device: b302h/45826d Inode: 2 Links: 21
Access: (0755/drwxr-xr-x) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2021-07-14 01:16:47.761892113 +0800
Modify: 2019-04-08 18:25:39.399999997 +0800
Change: 2019-04-08 18:25:39.399999997 +0800
Birth: -
Was starting to think it might be something to do with “media” - the Pi3 and the OrangePi aren’t booting off a “hdd” in that sense, the Pi3 booting off SD-Card, the OrangePi on 16 GB onboard EMMC…
But the red herring is the REL 7 system… sure it aint exactly a “physical” HDD or SSD, but it is presented to REL 7 as one via VirtualBox…
Hmmm… Curious…
– just noticed - I installed that REL8 base system on April Fool’s Day! More fool me!