→ 🚀What's New? Join Us for the Fall Product Launch! Register Now !
‎08-29-2022 01:59 PM - last edited on ‎05-16-2024 10:35 AM by Riley
Hello, I am looking for a report in Lansweeper to get all installed Linux distributions on Windows Subsystem for Linux. Until now I only can see where WSL is activated by running a Windows installed Features report ( https://www.lansweeper.com/report/installed-windows-features/ ) and then filter by the WSL feature. But I also want to know which Linux distributions are installed ( wsl.exe --list -v ) in these WSL instances.
Solved! Go to Solution.
‎09-08-2022 11:50 AM
Unfortunately, the MS Store is the only place where this information can be found in Lansweeper right now. You could automate it somewhat by providing a list of known distro's in the query, for example:
Select Top 1000000 tblAssets.assetid,
tblAssets.AssetName,
tsysOS.Image As icon,
tblSoftwareUni.softwareName As Software,
tblSoftware.softwareVersion As Version,
tblAssets.Domain,
tblAssets.Username,
tblAssets.Userdomain,
tblAssets.IPAddress,
tblAssets.Description,
tblAssetCustom.Manufacturer,
tblAssetCustom.Model,
tblAssetCustom.Location,
tsysIPLocations.IPLocation,
tsysOS.OSname As OS,
tblAssets.SP As SP,
tblAssets.OScode + '.' + tblAssets.BuildNumber As Build,
tblAssets.Version As [OS Version],
tblAssets.Firstseen As [Created at],
tblAssets.Lastseen As [Last successful scan]
From tblSoftware
Inner Join tblSoftwareUni On tblSoftware.softID = tblSoftwareUni.SoftID
Inner Join tblAssetCustom On tblSoftware.assetid = tblAssetCustom.AssetID
Inner Join tblAssets On tblAssets.AssetID = tblSoftware.assetid
Inner Join tsysOS On tblAssets.OScode = tsysOS.OScode
Left Join tsysIPLocations On tblAssets.LocationID = tsysIPLocations.LocationID
Where (tblSoftwareUni.softwareName Like '%ubuntu%' Or
tblSoftwareUni.softwareName Like '%suse%' Or tblSoftwareUni.softwareName
Like '%debian%' Or tblSoftwareUni.softwareName Like '%kali%') And
tblAssetCustom.State = 1
Order By tblAssets.AssetName
‎11-04-2022 10:38 AM
Meanwhile I have added many more of the distrubution names from the MS app store. So as long as the distribution name is known, this kind of filter is fine. But it is not able to detect 'new' distributions and it also can not detect not well registered distributions and for some reasons it displays distributions which already have been uninstalled/deregistered. In the past I tested some WSL distributions which were not displayed in the system-control / app control panel but they were seen with the "wsl --list" command. These ones would not be detected by this report.
‎04-10-2024 01:54 PM
Hi @papillon68000 , could you share your report please?
Thanks
‎09-08-2022 01:58 PM
"right now" is nice to hear, so you may have this point on your radar for future enhancement.
Thanks for this report, I have enhanced it with keywords from MS store to identify more WSL distributions, so basically this works. But one must also consider that WSL also allows to sideload Linux distribution aside from MS store., so if one missed to define them in the lansweeper report, they will not be found. So does for example "Docker Desktop" for WSL can be downloaded from website and one can install it into WSL by starting that EXE, it's not in the store. If I would not know that Docker Desktop is used here I would not come to the idea to add it into the LS report. So it would stay undedected, %docker desktop% helps...
‎09-08-2022 09:17 AM
Yes, it is possible that way. But it is still a very manual process, I need to know which distributions could be there and then actively search them. I would prefer an automatic report which also finds more exotic ones than Ubuntu, Suse, Debian and Kali.
‎09-08-2022 11:50 AM
Unfortunately, the MS Store is the only place where this information can be found in Lansweeper right now. You could automate it somewhat by providing a list of known distro's in the query, for example:
Select Top 1000000 tblAssets.assetid,
tblAssets.AssetName,
tsysOS.Image As icon,
tblSoftwareUni.softwareName As Software,
tblSoftware.softwareVersion As Version,
tblAssets.Domain,
tblAssets.Username,
tblAssets.Userdomain,
tblAssets.IPAddress,
tblAssets.Description,
tblAssetCustom.Manufacturer,
tblAssetCustom.Model,
tblAssetCustom.Location,
tsysIPLocations.IPLocation,
tsysOS.OSname As OS,
tblAssets.SP As SP,
tblAssets.OScode + '.' + tblAssets.BuildNumber As Build,
tblAssets.Version As [OS Version],
tblAssets.Firstseen As [Created at],
tblAssets.Lastseen As [Last successful scan]
From tblSoftware
Inner Join tblSoftwareUni On tblSoftware.softID = tblSoftwareUni.SoftID
Inner Join tblAssetCustom On tblSoftware.assetid = tblAssetCustom.AssetID
Inner Join tblAssets On tblAssets.AssetID = tblSoftware.assetid
Inner Join tsysOS On tblAssets.OScode = tsysOS.OScode
Left Join tsysIPLocations On tblAssets.LocationID = tsysIPLocations.LocationID
Where (tblSoftwareUni.softwareName Like '%ubuntu%' Or
tblSoftwareUni.softwareName Like '%suse%' Or tblSoftwareUni.softwareName
Like '%debian%' Or tblSoftwareUni.softwareName Like '%kali%') And
tblAssetCustom.State = 1
Order By tblAssets.AssetName
‎09-07-2022 06:27 PM
On client systems, you can find installed WSL distributions in the list of installed MS Store apps. For example, for Ubuntu and Suse:
This feature requires the SOFTWAREMSSTOREAPPS scanning item to be enabled on the Scanning/Scanned Item Interval page.
Not sure this approach will work on servers without MS Store though.
Experience Lansweeper with your own data. Sign up now for a 14-day free trial.
Try Now