Date: Mon, 8 May 2017 09:55:14 +0100 From: Matthew Seaman <matthew@FreeBSD.org> To: freebsd-questions@freebsd.org Subject: Re: How to identify FreeBSD version on a different partition? Message-ID: <9429a0bd-69ef-89e4-7862-ba161d8109fc@freebsd.org> In-Reply-To: <55.A0.29375.E7010195@dnvrco-omsmta02> References: <55.A0.29375.E7010195@dnvrco-omsmta02>
next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --BxtprwrNqUJN8C4uiHJ82CS6p7aOAJP9a Content-Type: multipart/mixed; boundary="RHRfaKE4C78DOqHCR5p1uv9eCcS1bspU8"; protected-headers="v1" From: Matthew Seaman <matthew@freebsd.org> To: freebsd-questions@freebsd.org Message-ID: <9429a0bd-69ef-89e4-7862-ba161d8109fc@freebsd.org> Subject: Re: How to identify FreeBSD version on a different partition? References: <55.A0.29375.E7010195@dnvrco-omsmta02> In-Reply-To: <55.A0.29375.E7010195@dnvrco-omsmta02> --RHRfaKE4C78DOqHCR5p1uv9eCcS1bspU8 Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: quoted-printable On 05/08/17 07:29, Thomas Mueller wrote: > Is there any way to identify the version of a FreeBSD installation when= booted to a different FreeBSD or NetBSD installation? >=20 > With NetBSD, I can look under /<NetBSD-root-partition>/stand , always s= ee i386 or amd64, but I don't see anything so good or dependable with Fre= eBSD. >=20 > /etc/motd doesn't always show this information. >=20 > uname only shows the actively running version. >=20 > In my case, I use UFS and GPT, so FreeBSD and NetBSD can read each othe= r's partitions with no disklabel incompatibilities. /bin/freebsd-version is a shell script that contains the OS version hard-coded within it, which you can just read. Otherwise, you can run strings(1) on the kernel binary which is typically in /boot/kernel/kernel -- the version identification stuff appears near the end of quite a lot of output from that. Note that if you're using freebsd-update(8), the user land version from freebsd-version(1) may be a few patch levels ahead of the version from the kernel binary. It depends if the most resent security patches have affected the kernel or not. Cheers, Matthew --RHRfaKE4C78DOqHCR5p1uv9eCcS1bspU8-- --BxtprwrNqUJN8C4uiHJ82CS6p7aOAJP9a Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEGfFU7L8RLlBUTj8wAFE/EOCp5OcFAlkQMnkACgkQAFE/EOCp 5OdsWw/9HSUi/yXteNHD0CU5JoGSewjb5D50u8ArCrWeAehhKG2ixFGMCWpsUITw 5gU+l8s5zDt/Po04OnuzhHWsLWVZrWywQG4nOels08amBj6e7I64DZd+ff/jR0kk tn0Mx9Fz0pIUEZSAfbZxx/F0CRP2rjHVyrZdWEzQ66W+ioxg3d9fBx2TucT8/YOO 41hgw9+5f/sE8GptN71fWCTOX+NHH0l2VJ0iu/lyHcx3DUED+9016Som7Vp0n1F8 uPM+u5cS9EJtmkDIAAlt0YbSjKPs9UxRNATKQ/TwY4GsTHIffn6QKiHrDw8U8De0 bXC3jd6X7B7ZU5bszv4EULCGf2GExPi4n/ckaGpxhgyDTLDa7MeRPKfnMbwSJKFm yRmNRbA8mXUAeqhIv/XZCjM9hF3UtYamn3eT8eFd8Dt/iIXGpsbRkvXhqCqBooxH PFnNjGLqmjJHFq5SYxKqJ7oQtJBJaBlIQwN2FKffYaTET9k1XaU9G5fJiNpV0Ati zuXQhdWfrcIwM2GWkNyKNjjI6bEURYNG+YSnW/5gTkGSsvn30kgCdg2VFtdODRGO CgZSFvG5c8ab5eK14y1SBJr+S02XPKnTpWjT363UfTzEMAtAEqv7JJWeQ3hzEH2k Fa+CvwiGa+589EUwYjShrj1wuzFw7XuvKVHbdRrizd0F9KWG+uI= =HM2A -----END PGP SIGNATURE----- --BxtprwrNqUJN8C4uiHJ82CS6p7aOAJP9a--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?9429a0bd-69ef-89e4-7862-ba161d8109fc>