[Ukfreebsd] uname -r issue

Vsevolod Stakhov vsevolod at FreeBSD.org
Thu Jun 18 15:27:44 BST 2015


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On 18/06/2015 14:51, O'Connor, Kevin wrote:
> This is more of an annoyance than a technical issue but after a 
> freebsd-update fetch install and several reboots uname -a is still 
> reporting the previous build number on 10.1 release. According to
> the handbook uname -a gets it's information from 
> /usr/src/sys/conf/newvers.sh. I've checked the file and it does 
> indeed list it as RELEASE-p13 but uname -r is still showing p10
> 
> Anyone have an idea why the file is not getting read correctly, 
> permissions are fine, or where the incorrect information is coming 
> from?  Having to parse the file newvers.sh on every server would be
> a bit of a pain.

uname utility performs the following step to get information:

1) Check environment variables in form 'UNAME_s'/'UNAME_r' and so on
2) If there is no such a variable, then uname tries to resolve
information either via the corresponding sysctl (namely,
kern.osrelease for -r flag) or via some other ways, such as
getosreldate(3).

Hence, if you have no specific environment variables then you might
check your sysctl interface to query the kernel directly.

newvers.sh is used merely for building system from the sources. But
since you are using freebsd-update it doesn't seem like your case.

- -- 
Vsevolod Stakhov
-----BEGIN PGP SIGNATURE-----

iQIcBAEBCAAGBQJVgtVgAAoJEAdke2eQCBQ34ioQAMl4suGHS+10t4jEC5eHOrkw
TBZ/S6u8rGRKNKaljO2qsTzwEKCtEyej0yKwcbCasIUwkxirR6coYY8IiQtiFh86
lLVq4jKLUgZW/UlqpnoewXLBcdShK4ykv6Nm8XTDNgJSUkypvFZ7yWxeSnjtTlJL
uULs6hvL5Jh3n5I0r4hI3VELfLVjydr8PeT4BIqRzMLzIyOxi2W9E2ZRkpTidb0H
5LPcy1l8XhBFatstneBksPl5j7xQrzD1gaJsh/f5GNLqyCdRBrhyd04P4WmYdI4T
Sy/HcWN5ZJ08m3HjhVUtGegg4ENlVRZDRn7Jf0eExdVObF96jHP44qjK37V+/Pqg
3Qf7QhOixlcoM38MLp0p/tOXlxep1WsuL3d4mDfJ5ETc1LS2io4wWsqxHhJEl7nj
UmRM3SiS9RYtTJv4OwyqJNu61rOOp3z6c8CLV6BXWMN+NRiJlYutdDGJKT7+ezsh
yerLUI66DsXyPfyZYya0MsWtzS+r0oBEDgWjCy+9eCCuKrLeor4l+TVrkDgsfWqI
2+v/SYkC0y6FXa5zNOToF1VQFltjizJ710KlhAdckfWfffijl+SuNkC4SdYiymi6
LujMt3Ntmbk+f98bd008XXfzSrASORJuZG7HFMyTfFEc+NCifCqwl5lRzoWsTwxZ
E1o4gQZnXo5V85Gtkqe0
=n2Qi
-----END PGP SIGNATURE-----


More information about the Ukfreebsd mailing list