Cloning a portal installation on IBM Smartcloud

In ISSC we have been using IBM Smartcloud Enterprise as a means quickly to create servers. To save installing new software every time, we have been exploring the creation of custom images.

First step – as normal, we installed a WebSphere Portal v8.0.0.1 server and applied CTC v4 and PortalNOW to it. We also did some set-up such as configuring the firewall to open the relevant portal ports and so on. We want to be able to instantiate many copies of this server, so future projects can quickly start from a known configuration.

Now we need to make an image from our instance. Stop the portal server and the login to the SCE admin console. Select the instance and then choose “create private image” – thanks to admin restrictions of SCE you can only do this if you actually created the original instance.

00-CreateImage

You’re then prompted for some details and then SCE will stop the instance, create the image, and restart the instance. This process takes a while, once done, you can share the image with others if you want to.

To create a new instance from the image, you select “add instance” and then search for Private or Shared images in the data centre where your image was stored (according to the sharing settings you apply to the image). See below for screenshot.

02-AddInstance

There are three further steps to create the image – basically giving it a name, choosing a private key, and accepting the terms and conditions. When the instance is created, you get a  screenshot like the first one above confirming the details of the new instance.

Now, to rename it.

Login via SSH to the image as normal (make sure your certificate has permissions 600 or SCE won’t let you log in):

ssh -i {keyfile_path} idcuser@{hostname}

Use the hostname -f command to check that the new instance’s hostname is the one that SCE tells you it should be and not the same as original you cloned from. SCE should have fixed this as part of image instantiation but in case not, use YaST to update.

Now change the WebSphere Application Server hostname. Start by launching the portal server.

cd /opt/IBM/WebSphere/wp_profile/bin

./startServer.sh WebSphere_Portal

This can take quite a while, but it should start up after a while.

./wsadmin.sh -user wpadmin -password PrettyVacant! -c 
"\$AdminTask changeHostName {-nodeName portalNowNode -hostName 
new.host.name}"

Where new.host.name is the new host name, of course. When this command completes successfully, we now need to synchronize the portal server with the new WAS host name.

cd /opt/IBM/WebSphere/wp_profile/ConfigEngine/properties

Update wkplc.properties as follows:

WasRemoteHostName=new.host.name

WpsHostName=new.host.name

And then run the following command:

./ConfigEngine.sh localize-clone -DPortalAdminPwd={YourPortalAdminPwd} -DWasPassword={YourWasAdminPwd}

Where YourPortalAdminPwd and YourWasAdminPwd are replaced with the relevant values. When this completes, restart your portal and the process seems complete.

In my case, although the portal started up, I was unable to access portal and received scheduler errors in the logs such as:

[...] 0000006a AlarmListener E SCHD0063E: A task with ID 451 failed to run on Scheduler WPSTaskScheduler (wps/Scheduler) because of an exception: 
java.rmi.RemoteException: CORBA INTERNAL 0x4942f58c No; 
nested exception is as follows:
org.omg.CORBA.INTERNAL: initial and forwarded IOR inaccessible vmcid: IBM minor code: 58C completed: No.

There is a technote that describes this situation, and offers two potential ways forward. The first, which involved deleting and recreating the WPSTaskScheduler did not work and the same errors repeated on restart. The second option, involved purging tasks from the Scheduler as follows:

  • Stop the portal
  • Change to the ConfigEngine directory and run the following command:
./ConfigEngine.sh action-clean-scheduled-tasks
  • Restart the portal server

In my case, this resolved the issue and I was able to log into the portal.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s