l3af-project/l3af-arch

Ubuntu version check fails.

Closed this issue · 7 comments

Ubuntu version check fails even with the correct version of ubuntu.
Here are the details:

./setup_linux_dev_env.sh

+ [[ 0 -ne 0 ]]
++ uname -v
++ cut -d. -f1
++ cut -d~ -f2
+ VER='#152-Ubuntu SMP Wed Nov 23 20:19:22 UTC 2022'
+ '[' '#152-Ubuntu SMP Wed Nov 23 20:19:22 UTC 2022' '!=' 20 ']'
+ echo 'The Ubuntu version #152-Ubuntu SMP Wed Nov 23 20:19:22 UTC 2022 is not supported by the script'
The Ubuntu version #152-Ubuntu SMP Wed Nov 23 20:19:22 UTC 2022 is not supported by the script
+ exit 1

My ubuntu details:

Distributor ID:	Ubuntu
Description:	Ubuntu 20.04.4 LTS
Release:	20.04
Codename:	focal

If this is a valid issue, I can submit a patch.
Thanks

Hi, can you please print the full output of your os version from "uname -v" command? This seems to work on the Ubuntu 20.04.4 version I am on.

sure:
uname -v

#64-Ubuntu SMP Thu Jan 5 11:43:13 UTC 2023

That string doesn't look valid and would explain the issue. It is missing the version info. What does the output of 'lsb_release -sr' show?

lsb_release -sr

20.04

I am thinking something probably something isn't correct with your system (coreutils + kernel). lsb_release and uname should really match. Does "cat /proc/version" show the same issue? I don't think this is a bug in script parsing code, but something got out of sync or not upgraded fully. Have you tried updating everything and rebooting?

Seems like this is an issue on newer release of coreutils. Please feel free to submit PR to add 'lsb_release -sr' as a fallback option for detection.

Yeah, sure
I'll create a PR soon.