running MX on win10 using wsl
- mmikeinsantarosa
- Developer
- Posts: 2250
- Joined: Thu May 01, 2014 10:12 am
running MX on win10 using wsl
My work recently pulled all of our oracle virtualbox licenses. I have looked into running MX on hyper-V and nothing but problems. A Co-worker suggested trying wsl so I thought I'd give it a try. If the distro isn't in the MS store, you have to create a tar of the image and that's what i"m doing now.
Anybody ever spin up MX on wsl? If so, anything to beware of? Hyper-V had troubles booting the image after an install or if it did boot, I couldn't change display size. That's not all but after using Oracle VM's it seemed like an after thought more than a project app.
So send me your wsl stories.
I only run MX @ home.
Anybody ever spin up MX on wsl? If so, anything to beware of? Hyper-V had troubles booting the image after an install or if it did boot, I couldn't change display size. That's not all but after using Oracle VM's it seemed like an after thought more than a project app.
So send me your wsl stories.
I only run MX @ home.
LT: MX19.1 Quad Core model: Intel Core i7-6820HQ Kernel: 5.0.0-7.1-liquorix-amd64 x86_64
Re: running MX on win10 using wsl
Hey Mike, yes it's possible we have a user who posted a tutorial: viewtopic.php?t=75778
These are my notes:
1. isomount ISO
2. cd /mnt/iso/sq1/
3. sudo tar -zcvf ~/Downloads/distro.tar.gz .
4. Switch to Windows PS, create a mxlinux folder somewhere
5. wsl --import mxlinux ACTUAL_PATH\mxlinux distro.tar.gz
6. wsl --list -v (to check if it was added OK)
7. wsl -d mxlinux
8. upgrade, set password with passwd
9. apt install xrdp dbus-x11 xorgxrdp
10. /etc/init.d/xrdp start
Start "demo" automatically:
edit /etc/wsl.conf, add:
Once xrdp is started you can connect from Windows side with RDC, connect to "localhost"
There are some issues with sysvinit, for example I have to restart xrdp manually each time, it's possible to switch to systemd by editing that /etc/wsl.conf file and adding:
There might be some weird things and some stuff might not work as it should. Keep in mind that it will use the WSL kernel not the MX one. Also the networking will be the WSL one (I think future update of WSL will allow to use more of the Linux networking)
These are my notes:
1. isomount ISO
2. cd /mnt/iso/sq1/
3. sudo tar -zcvf ~/Downloads/distro.tar.gz .
4. Switch to Windows PS, create a mxlinux folder somewhere
5. wsl --import mxlinux ACTUAL_PATH\mxlinux distro.tar.gz
6. wsl --list -v (to check if it was added OK)
7. wsl -d mxlinux
8. upgrade, set password with passwd
9. apt install xrdp dbus-x11 xorgxrdp
10. /etc/init.d/xrdp start
Start "demo" automatically:
edit /etc/wsl.conf, add:
Code: Select all
[user]
default=demo
There are some issues with sysvinit, for example I have to restart xrdp manually each time, it's possible to switch to systemd by editing that /etc/wsl.conf file and adding:
Code: Select all
[boot]
systemd=true
- mmikeinsantarosa
- Developer
- Posts: 2250
- Joined: Thu May 01, 2014 10:12 am
Re: running MX on win10 using wsl
Thanks for the "notes", Santa. 

LT: MX19.1 Quad Core model: Intel Core i7-6820HQ Kernel: 5.0.0-7.1-liquorix-amd64 x86_64
- mmikeinsantarosa
- Developer
- Posts: 2250
- Joined: Thu May 01, 2014 10:12 am
Re: running MX on win10 using wsl
My first crack at getting mx installed broke wsl.
I was able to import a mx tar and list it once then I tried to upgrade wsl to version 2 and wsl broke. Any time I tried a wsl command I got
I tried removing wsl via programs & features but no go. Fortunately I created a restore point before I started so I am on round 2 now.
After the restore I have yet to enable wsl yet wsl.exe is already in windows\system32.- didn't expect that.
I'll follow up with any progress.
I was able to import a mx tar and list it once then I tried to upgrade wsl to version 2 and wsl broke. Any time I tried a wsl command I got
Code: Select all
%1 is not a valid Win32 application.
Error code: Wsl/CallMsi/0x800700c1.
After the restore I have yet to enable wsl yet wsl.exe is already in windows\system32.- didn't expect that.
I'll follow up with any progress.
LT: MX19.1 Quad Core model: Intel Core i7-6820HQ Kernel: 5.0.0-7.1-liquorix-amd64 x86_64
Re: running MX on win10 using wsl
You need WSL2, there's a big difference in technology, I haven't run WSL1 in years, didn't expect you'd still be on that.
- mmikeinsantarosa
- Developer
- Posts: 2250
- Joined: Thu May 01, 2014 10:12 am
Re: running MX on win10 using wsl
Thanks Adrian,
the instructions I've seen show several ways to get wsl installed. I'll look into starting with wsl2.
the instructions I've seen show several ways to get wsl installed. I'll look into starting with wsl2.
LT: MX19.1 Quad Core model: Intel Core i7-6820HQ Kernel: 5.0.0-7.1-liquorix-amd64 x86_64
- mmikeinsantarosa
- Developer
- Posts: 2250
- Joined: Thu May 01, 2014 10:12 am
Re: running MX on win10 using wsl
it seems that maybe the instructions to get wsl on win10 change often enough or the bits available on our build are out of sync with what's necessary.
Here's how to break wsl during an install (I've gotten really good at this):
-enable features:
windows subsytem for linux
windows hypervisor platform
virtual machine platform
-restart PC
-open cmd as admin
-type wsl --list --online
*wsl works so lets install ubuntu
-wsl --install -d Ubuntu
It fails because we're missing the latest kernel
"The WSL 2 kernel file is not found. To update or restore the kernel please run 'wsl --update'."
And if you do the update and afterwards try :
wsl --install -d Ubuntu
wsl is broken
BUT, if instead you go to https://aka.ms/wsl2kernel
and download the msi available there then install it, wsl is good at version2
**If you break wsl, you have to uninstall it from settings-apps and disable it in programs and features, restart and try again.
Here's how to break wsl during an install (I've gotten really good at this):
-enable features:
windows subsytem for linux
windows hypervisor platform
virtual machine platform
-restart PC
-open cmd as admin
-type wsl --list --online
*wsl works so lets install ubuntu
-wsl --install -d Ubuntu
It fails because we're missing the latest kernel
"The WSL 2 kernel file is not found. To update or restore the kernel please run 'wsl --update'."
And if you do the update and afterwards try :
wsl --install -d Ubuntu
wsl is broken
BUT, if instead you go to https://aka.ms/wsl2kernel
and download the msi available there then install it, wsl is good at version2
**If you break wsl, you have to uninstall it from settings-apps and disable it in programs and features, restart and try again.
LT: MX19.1 Quad Core model: Intel Core i7-6820HQ Kernel: 5.0.0-7.1-liquorix-amd64 x86_64
- mmikeinsantarosa
- Developer
- Posts: 2250
- Joined: Thu May 01, 2014 10:12 am
Re: running MX on win10 using wsl
Not sure what I'm missing but the install can't fin xrdpAdrian wrote: Mon Dec 11, 2023 3:36 pm Hey Mike, yes it's possible we have a user who posted a tutorial: viewtopic.php?t=75778
These are my notes:
1. isomount ISO
2. cd /mnt/iso/sq1/
3. sudo tar -zcvf ~/Downloads/distro.tar.gz .
4. Switch to Windows PS, create a mxlinux folder somewhere
5. wsl --import mxlinux ACTUAL_PATH\mxlinux distro.tar.gz
6. wsl --list -v (to check if it was added OK)
7. wsl -d mxlinux
8. upgrade, set password with passwd
9. apt install xrdp dbus-x11 xorgxrdp
10. /etc/init.d/xrdp start
Start "demo" automatically:
edit /etc/wsl.conf, add:Once xrdp is started you can connect from Windows side with RDC, connect to "localhost"Code: Select all
[user] default=demo
There are some issues with sysvinit, for example I have to restart xrdp manually each time, it's possible to switch to systemd by editing that /etc/wsl.conf file and adding:There might be some weird things and some stuff might not work as it should. Keep in mind that it will use the WSL kernel not the MX one. Also the networking will be the WSL one (I think future update of WSL will allow to use more of the Linux networking)Code: Select all
[boot] systemd=true
Code: Select all
apt-cache policy xrdp
N: Unable to locate package xrdp
Code: Select all
apt-cache policy dbus-x11
dbus-x11:
Installed: 1.14.10-1~deb12u1
Candidate: 1.14.10-1~deb12u1
Version table:
*** 1.14.10-1~deb12u1 100
100 /var/lib/dpkg/status
Code: Select all
W: Failed to fetch http://deb.debian.org/debian/dists/bookworm-updates/InRelease Could not resolve 'deb.debian.org'
W: Failed to fetch http://deb.debian.org/debian/dists/bookworm/InRelease Could not resolve 'deb.debian.org'
LT: MX19.1 Quad Core model: Intel Core i7-6820HQ Kernel: 5.0.0-7.1-liquorix-amd64 x86_64
Re: running MX on win10 using wsl
You are having some kind of network problem, do you have an IP address? You might might have to run dhclient or dhclient-script, not sure... can you get anything from Internet from the WSL side?
Code: Select all
apt policy xrdp
xrdp:
Installed: 0.9.21.1-1
Candidate: 0.9.21.1-1
Version table:
*** 0.9.21.1-1 500
500 http://deb.debian.org/debian bookworm/main amd64 Packages
100 /var/lib/dpkg/status
- mmikeinsantarosa
- Developer
- Posts: 2250
- Joined: Thu May 01, 2014 10:12 am
Re: running MX on win10 using wsl
The PC is at work and they just shut down power for the site. I won't be able to get back on this until I return to work Jan 2. Thanks for the info. I'll follow up when I get back.Adrian wrote: Tue Dec 19, 2023 12:45 pm You are having some kind of network problem, do you have an IP address? You might might have to run dhclient or dhclient-script, not sure... can you get anything from Internet from the WSL side?
Code: Select all
apt policy xrdp xrdp: Installed: 0.9.21.1-1 Candidate: 0.9.21.1-1 Version table: *** 0.9.21.1-1 500 500 http://deb.debian.org/debian bookworm/main amd64 Packages 100 /var/lib/dpkg/status
LT: MX19.1 Quad Core model: Intel Core i7-6820HQ Kernel: 5.0.0-7.1-liquorix-amd64 x86_64