Saturday, May 26, 2018

Getting XMind 8 to work on openSUSE Leap 15

openSUSE Leap 15 was officially launched on 25th May 2018.  More at https://en.opensuse.org/Portal:15.0

XMind is my go-to mind mapping software for a few years now.  More at https://www.xmind.net/

Challenge:

Using the XMind 8 Linux package (zip file) and following the, albeit brief, instructions at http://support.xmind.net/customer/en/portal/articles/2639667-begin-to-use-xmind-8-on-linux, you will see XMind launch with the GUI Splash screen but the program will fail and exit.




Root-cause:

XMind is a Java-based application and it is sensitive to the version of Java.  The default Java runtime in openSUSE Leap 15 is OpenJDK version 10.0.1 (dated 2018-04-17).


Resolution:

Install the older OpenJDK version 1.8.0.  Instead of removing the default version 10.0.1, I elected to install the older version 1.8.0 alongside and switch the default path for Java to 1.8.0.

Here are my steps:

zypper in java-1_8_0-openjdk



update-alternatives --config java
(followed by picking the newly installed jre-1.8.0)



Validate:  java -version

That's it.  Now, when we execute the XMind program, it will work and launched successfully.  



Keep Calm & Carry On loving Linux!

Tuesday, May 1, 2018

openSUSE Leap 42.3 on Google Cloud Platform (GCP)

Blogging... I'm glad I started in 2008, it is like having a diary that you can never misplace... and reading some old entries can bring back wonderful memories, as I recall and review the course of my life from this, albeit narrow, technology perspective.

Anyway, its been a good 4+ years since my last entry and the longest hiatus... glad and grateful to say that I am now working for Google.  My personal Linux passion is still very much alive and personal bias towards all things SUSE (more openSUSE since 2011).

Problem Statement:

So, it is May 2018 and I am little disappointed that openSUSE Leap did not make it to the out-of-the-box public images on Google Cloud Platform (GCP).  However, it is listed in the "Community supported images" category.

PS:  I'm placing my vain hope that Leap 15 will make it though...

This blog entry describes the steps to create a vanilla openSUSE Leap 42.3 VM on GCP and thereafter, create a custom image from this said VM so you can easily/quickly create openSUSE Leap 42.3 VMs for other workloads in the future through the GCP Web Console.

From this point on, I will assume you have a GCP account and therefore access to GCP consoles etc.  It is not difficult to start with Google Cloud Platform, just go to https://cloud.google.com/free/ to get a Free Tier account.

Create an openSUSE Leap 42.3 VM on GCP:

  1. Login to your GCP console and your project (default or otherwise).
  2. From Menu (top-left),  Compute Engine -> VM instances
  3. Note that openSUSE is not listed as an Operating System image when you try to create a new VM.  This is well documented at the Images section of the Compute Engine topic.
  4. Launch the Cloud Shell within the console, on the top-right.
  5. Find the available community supported openSUSE Leap image with the following command input to the Cloud Shell. 
    • gcloud compute images list --project opensuse-cloud --no-standard-images 
  6. Create a VM with the openSUSE Leap 42.3 image in the Singapore datacenter (or any Zones that is closest to you)

  7. SSH into your newly created openSUSE Leap 42.3 VM to download and apply the latest updates/patches.  Click the SSH button (see screenshot above).
    • Once you SSH into your VM,  zypper up.
  8. Reboot the VM to test all updates are working.
    • Reboot:  sudo reboot.  You will lose SSH connection, naturally.
    • Sign back in via SSH button... it may take a few tries as the VM is rebooting.
    • Sign out of SSH:  exit
  9. Shutdown the VM.  Select the VM (checkbox) from the Console and Click STOP.

Create a custom image in your GCP Project for Re-use later:

  1. From the GCP console, navigate to Compute Engine -> Images
  2. Click [+] CREATE IMAGE 
  3. Put in the name of your new image (eg. my-opensuse-leap-423) and select Source as Disk and Source disk as the boot disk from the right VM (eg. osleap423).
    • (Optional) You can click the command line link at the bottom to note the equivalent Cloud Shell command.  This is useful if you want to script actions for future re-use and not use the web-console.
  4. Once your custom image is created, you will be able to select it for the next VM you wish to create.
Enjoy! :-)