-
Notifications
You must be signed in to change notification settings - Fork 105
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
After upgrading from WSL1 to WSL2, message of the day still displays "Running WSL version 1" #714
Comments
Hello @LBates2000 , Thanks for reporting this. It should set the WSL2 variable, so 00-pengwin.sh is failing for any reason. We will take a look. Manually setting the WSL2 variable to any value should work. Regards, |
Hello @LBates2000, The problem is that the WSL2 variable is not transferred through sudo. I mean.
but
Regards, |
This is the MOTD at startup:
And this is running run-parts /etc/update-motd.d/ without sudo:
|
It looks as though /etc/profile.d/00-pengwin.sh should be setting WSL2=3
but I still do not see the environment variable being set:
|
You are right. I'll recheck with Windows 11 |
I did this:
Launched Pengwin, now it's working. Weird. |
@LBates2000 could you please run this command and send me the result? id -Gn | grep -c "adm.*sudo\|sudo.*adm"` |
|
Did you remove your user from the sudo group? |
I did not, but I was having #715 before this occurred, which went away with a restart of Windows. |
@crramirez No, I'm in the sudo group:
|
@LBates2000 ok I can conclude that your user is not in the adm group. I can change the script to look for only the sudo group |
wsl.exe --terminate WLinux
wsl.exe --shutdown
sudo run-parts /etc/update-motd.d/
to redisplay the message of the day:echo ${WSL_INTEROP}
shows/run/WSL/2983_interop
echo ${WSL2}
shows that the environment variable is still unsetI could manually set the WSL2 environment variable, but I'm not sure what it should be set to:
I'm also concerned that other parts of my system configuration may not be set correctly.
PENGWIN_VERSION="21.9.0"
WSL Version: 2
Locale: en_US
Release Install Date: Tue Jun 29 12:26:44 PDT 2021
Branch: co_release
Build: 22000
Full Build: 22000.1.amd64fre.co_release.210604-1628
Display Scaling: 1
Windows Theme: dark
Windows Uptime: 1d 14h 44m
WSL Uptime: 0d 5h 50m
WSL Release: Pengwin
WSL Kernel: Linux 5.10.60.1-microsoft-standard-WSL2
Packages Count: 2566
The text was updated successfully, but these errors were encountered: