[Gambas-user] Gambas on Windows with WSL2 and gwsl with Debian backport edition of gambas

Brian G brian at westwoodsvcs.com
Wed Jul 6 18:15:45 CEST 2022


----- On Jul 6, 2022, at 3:10 AM, Rolf-Werner Eilert rwe-sse at osnanet.de wrote: 

​​​​​> Am 06.07.22 um 08:20 schrieb Brian G: 
>> Hi I don't know if anyone else is interested in this or has done this... 
>> but now with the Backport working 
>> it is possible to install all stock software and run your gambas apps on 
>> a windows platform. 
>> 

> 
> 
> Very interesting! I had a trial with a former version which still needed 
> a separate Xserver. But it runs well anyway. 
> 
> However, that older version does not support a drive pointing to a Samba 
> drive on a linux server. In my case, I would need my programs picking 
> data from a drive X: which is a Samba release from the server which runs 
> on an ext4 partition. 
> 
> If they have solved that by now, it's great. If not, it would still be a 
> showstopper for me. 
> 
> On our system, I have linux terminal servers running everywhere. My 
> solution was a virtual box on the Windows machine which boots like any 
> of the terminals. Of course that runs flawlessly, but it is somewhat... 
> roundabout I would say. 
> 
> Regards 
> Rolf 
> 
> 
> ----[ http://gambaswiki.org/wiki/doc/netiquette ]---- 

I am a little confused by what you have stated. The Application is running in a linux virtual box with a full linux kernel 
when using wsl 2. Therefore any application running would be able to use nsf or samba to communicate with a file server. 
The difference between wsl and wsl 2 is that wsl only runs a fake sort of kernel for linux. not the full kernel. 

To fully enable wsl 2 there is a patch for windows 10. 

Maybe I don't understand the issue correctly 
what follows is having the wsl 2 vm access a linux samba server share 
On the debian wsl 2 side: 

After installing samba and restarting the windows pc, to force a reboot of the debian vm.... maybe there is some other way 

07/06/2022 15:20:29.819> sudo smbpasswd -a brian ' not really needed lol 
New SMB password: 
Retype new SMB password: 
Added user brian. 

07/06/2022 15:20:57.375> sudo apt install cifs-utils 
Reading package lists... Done 
Building dependency tree... Done 
Reading state information... Done 
Suggested packages: 
smbclient winbind bash-completion 
The following NEW packages will be installed: 
cifs-utils 
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. 
Need to get 90.4 kB of archives. 
After this operation, 314 kB of additional disk space will be used. 
Get:1 http://security.debian.org/debian-security bullseye-security/main amd64 cifs-utils amd64 2:6.11-3.1+deb11u1 [90.4 kB] 
Fetched 90.4 kB in 1s (165 kB/s) 
Selecting previously unselected package cifs-utils. 
(Reading database ... 48397 files and directories currently installed.) 
Preparing to unpack .../cifs-utils_2%3a6.11-3.1+deb11u1_amd64.deb ... 
Unpacking cifs-utils (2:6.11-3.1+deb11u1) ... 
Setting up cifs-utils (2:6.11-3.1+deb11u1) ... 
update-alternatives: using /usr/lib/x86_64-linux-gnu/cifs-utils/idmapwb.so to provide /etc/cifs-utils/idmap-plugin (idmap-plugin) in auto mode 
Processing triggers for man-db (2.10.1-1~bpo11+1) ... 

07/06/2022 15:25:08.325> !mkdir myX 

07/06/2022 15:32:05.637> sudo mount -t cifs //gn41/vssdata myX 
Password for root@//gn41/vssdata: 

07/06/2022 15:34:08.311> cd myX 

07/06/2022 15:34:17.706> ls 
AdvancedETLEnt_32.zip evenless.IIF qodbc.exe sqlitestudio-3.3.3 
almostall.IIF extracted ripOLE sqlitestudio-3.3.3.zip 
DatabaseBrowser_Portable.zip gambasonwin.docx SQLA17_Windows_Client.exe 'VSS.QBW' 
DBrowser_32 QB2022_Install SQLAnywhere12_Full.exe VSS.QBM 
DBrowser_32.zip qbEnterprise12 sqlite-dll-win32-x86-3360000.zip windowsgambas.png 

07/06/2022 15:34:21.395> 

NOTE: On the linux Samba server must setup a user to access the share I used root..lol 

root at GN41:/home/brian# smbpasswd -a root 
New SMB password: 
Retype new SMB password: 
root at GN41:/home/brian# 

This image shows both Windows accessing the share and the debian vm accessing the share: 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20220706/7a63c349/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: sambas share.png
Type: image/png
Size: 132180 bytes
Desc: not available
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20220706/7a63c349/attachment-0001.png>


More information about the User mailing list