A 5-minute screencast of this blog post can be found here.
Would you like to run GemStone/S 64 Bit on a Microsoft Windows machine? If so, then the Windows Subsystem for Linux makes that possible. Starting with a 64-bit version of Windows 10, follow these steps:
Install Ubuntu 18.04
- Run Windows PowerShell as Administrator and enter the following (on one line):
Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
- Confirm a restart to complete the process.
- From the Windows Store application, install Ubuntu 18.04, pin it to the Start menu, and then launch it.
- When prompted, enter a new UNIX username and password.
Install GemStone
- Update your system and install the unzip utility:
sudo apt-get update
sudo apt-get upgrade -y
sudo apt-get dist-upgrade -y
sudo apt-get install unzip - In the Linux shell, create some GemStone directories:
sudo mkdir /opt/gemstone
sudo chown $USER /opt/gemstone
cd /opt/gemstone
mkdir locks log - In a web browser, navigate to the GemStone product page and copy the link for the Linux download. Use wget to download the product (the following is supposed to be one line, but WordPress hides some; copy the whole thing and past into a text editor):
wget https://downloads.gemtalksystems.com/pub/GemStone64/3.4.3/GemStone64Bit3.4.3-x86_64.Linux.zip
- Unzip the product:
unzip GemStone*
- Create a symbolic link to the unzipped directory:
ln -s GemStone* product
- Edit your profile to add/update environment variables:
vim ~/.profile # add the following two lines
export GEMSTONE=/opt/gemstone/product
export PATH=$GEMSTONE/bin:$PATH - Update your environment to include the above variables by doing one of the following:
- Enter the two lines from step 6 into your command shell;
source ~/.profile
; or,- Close your shell and open a new shell.
- Edit the services file to add an entry for NetLDI:
sudo vim /etc/services # add the following line
gs64ldi 50377/tcp # GemStone/S 64 Bit 3.x - Copy in a new database:
cp $GEMSTONE/bin/extent0.dbf $GEMSTONE/data/
chmod +w $GEMSTONE/data/extent0.dbf
Start GemStone
Open a new Linux shell to get your environment variables and start GemStone:
gslist
startnetldi -g -a $USER
startstone
gslist
Install Jade into Windows
- Open a web browser on the Jade Releases.
- Download (Save) Jade.zip (one of the assets) to your Downloads folder.
- Open the Downloads folder and extract the download.
- Copy the entire Jade folder to
C:\Program Files (x86)
or any handy directory (it doesn’t need to be anywhere in particular). - Pin
Jade.exe
to the Start Menu. - Edit
C:\Windows\System32\drivers\etc\services
(as a Windows administrator using a Windows text editor such as Notepad++) to add an entry for NetLDI:
gs64ldi 50377/tcp # GemStone/S 64 Bit 3.4.2
Log in to GemStone with Jade
- From the Start Menu, launch Jade. If Windows identifies Jade as an unrecognized app, click More info and then click the Run anyway button.
- Ensure that the version shown in Jade is a close match to the GemStone version, and click the Login button.
- Now you can explore your GemStone/S database that is running in Windows!
Stop GemStone
From a Linux shell you can stop GemStone:
gslist
stopstone gs64stone DataCurator swordfish
stopnetldi
gslist
7 comments
Comments feed for this article
September 9, 2018 at 2:28 am
GemStone… et Windows 10! | L'Endormitoire
[…] Tous les détails ici. […]
September 19, 2018 at 5:44 am
Marten Feldtmann
Hello James,
I tried that … but starting the stone failed – the stone was killed because of CPUAffinity problems – it tried to use 8 cores, but the community license limited it to 2 cpus. Actually I do not know, why this killed the stone.
Using my unlimited license and it started.
Another word: please follow close that video. You MUST enter the service file on both sides. With localhost it worked – with the actual IP number it did not work.
September 19, 2018 at 5:47 am
Marten Feldtmann
Another note: GsdevKit_home does not work … the installation fails due to Ubuntu 18.04, the shared memory setting does not work and the last part I am working on fails due to the error, that pharo can not be startet due to false exec format – so all command in GsDevKit_home can not be started … very sad :-(((
June 14, 2019 at 10:15 am
Dale Henrichs
Marten … WLS does not support 32 bit executables and it appears that they don’t plan to add that suport … sad indeed … I hope to replace the 32 pharo vms with topaz solo vms, but that is not at the very top of my todo list:)… also we are not testing on WLS (at the moment), so there may be other issues with this configuration that we are not aware of…
December 17, 2020 at 2:23 am
Jorge Chiva Segura
Thank you for the detailed step-by-step guide. In order make it work with the community license, the number of cores available in WSL2 can be limited by executing the following commands on Windows Command Prompt:
1. Create a WSL2 config file that limits the number of available cores to 2:
(echo [wsl2]&echo;processors=2) > %UserProfile%\.wslconfig
2. Stop the WSL2:
wsl –shutdown
After that, when WSL2 is started it should have the configuration specified (this can be verified with ‘top’, ‘lscpu’, etc.).
Sources:
https://www.bleepingcomputer.com/news/microsoft/windows-10-wsl2-now-allows-you-to-configure-global-options/
https://docs.microsoft.com/en-us/windows/wsl/wsl-config#configure-global-options-with-wslconfig
I also wanted to mention that in order to connect Jade to gemstone, in my case, it doesn’t work with localhost but it works with the IP address that gets listed from executing ‘ifconfig’ on WSL2.
December 17, 2020 at 2:51 am
James Foster
Jorge, That is wonderful news and will make this much more useful. Thanks for you insight and post here. I’ll pass the word along.
—James
December 17, 2020 at 6:08 am
Jorge Chiva Segura
You are more than welcome. Sorry, I see that the command for shutting down WSL2 was modified by wordpress and it merged the two dashes into only one. I don’t see a way to modify my comment so I will try to post it correctly here by encapsulating the command inside a “code” tag:
wsl --shutdown