Showing posts with label WAS. Show all posts
Showing posts with label WAS. Show all posts

IBM WAS Liberty Profile 8.5.5.4

Liberty profile saves hours of development time  for WebSphere developers with its simplicity and configurable modules architecture. Especially when working with WebSphere Application Server where it includes so many integration components (ofcourse they are so useful at enterprise level) and it may take longer times to publish changes or to restart the server. But modularized architecture (configurable features) of liberty profile make these changes almost instantly.

Few new features introduced in the WAS Liberty profile are
  1. Java Servlets 3.1
  2. Dynamic Routing
  3. Concurrency Utilities for Java EE1.0
  4. Javascript object Notation Processing (JSONP)
  5. Java API for WebSocket 1.0
  6. Java Persistence API 2.0
  7. Application Security 1.0


  1. Install Liberty profile development tools for eclipse
    1. From eclipse go to "eclipse marketplace" , help-->eclipse market place
    2. Enter the following in search box "IBM Websphere Application Server Liberty Profile Developer Tools"
    3. Select version specific to your eclipse


  1. Select all confirm


  1. After installation ask for restart of eclipse

  1. Install Liberty profile server runtime from eclipse
    1. To install the liberty profile runtime  , Eclipse Menu --> Window Preference -->Server --> Server Runtime
    2. Click on add to add new server runtime (make sure you have selected isntall from archive option)
    1. Select download and install a new runtime environment from and provide the installation directory.
 

 
  1. And select the optional plugin if any you want to install



  1. I just chose couple of sample applications while installing (but it is not mandatory , if not selected anything it just installs liberty profile runtime )



  1. Create a server profile
    1. Once the Liberty server runtime installed , now you can add/create the server profile from the eclipse servers view. (new --> server-->select liberty server runtime-->give the name of the server profile)

                     

  1. Deploying the application on WAS Liberty profile
    1. You can deploy the applications different way just like tomcat, I mostly either drop the war/ear file in liberty profile dropins folder or add project direct from the eclipse. You can find the dropin folder in liberty installation.

C:\IBM\WAS85Liberty\usr\servers\LibertyServer\dropins

Portal (WAS) Installation problems with UNC paths (Shared drive paths)


Environment variables will look like below in environment where shared drives are used for the user profiles,

HOMEDRIVE=<drive letter>:
HOMEPATH=\<path>
HOMESHARE=\\<server name>\<share name>

Installations fails if there is UNC reference in the PATH environment variable, Changing the above environment variables doesn't not help, windows will revert back , only way to modify these are changing the group polices or changing the user terminal services in the Active directory.

But most of the cases you mayn't have access to group polices or AD to change the user profiles related in corporate networks.

I tried to install portal (WAS) had the same issue and tried to follow the options specified in the below IBM support article but that doesn't help me

Finally had to disable all network drives for the successful installation of Portal (WAS).


Resources

Problem with UNC(Universal Naming Convention) paths while creating additional WAS server profiles


Encountered below problem when I was trying to create additional WAS profiles using the RAD 

following are error details ,( by looking at log)

!SESSION 2013-12-02 18:02:08.084 -----------------------------------------------
eclipse.buildId=unknown
java.fullversion=JRE 1.6.0 IBM J9 2.4 Windows 7 x86-32 jvmwi3260sr10fp1-20120202_101568 (JIT enabled, AOT enabled)
J9VM - 20120202_101568
JIT  - r9_20111107_21307ifx1
GC   - 20120202_AA
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US
Framework arguments:  -jar startup.jar
Command-line arguments:  -jar startup.jar -os win32 -ws win32 -arch x86 -clean -dev C:\Program Files (x86)\IBM\SDP\runtimes\base_v7\lib\bootstrap.jar,C:\Program Files (x86)\IBM\SDP\runtimes\base_v7\lib\j2ee.jar,C:\Program Files (x86)\IBM\SDP\runtimes\base_v7\lib\mail-impl.jar

!ENTRY org.eclipse.osgi 4 0 2013-12-02 18:02:09.886
!MESSAGE Startup error
!STACK 1
java.nio.channels.OverlappingFileLockException
               at sun.nio.ch.FileChannelImpl$SharedFileLockTable.checkList(FileChannelImpl.java:1187)
               at sun.nio.ch.FileChannelImpl$SharedFileLockTable.add(FileChannelImpl.java:1089)
               at sun.nio.ch.FileChannelImpl.tryLock(FileChannelImpl.java:889)
               at java.nio.channels.FileChannel.tryLock(FileChannel.java:962)
               at org.eclipse.core.runtime.internal.adaptor.Locker_JavaNio.lock(Locker_JavaNio.java:32)
               at org.eclipse.osgi.storagemanager.StorageManager.initializeInstanceFile(StorageManager.java:190)
               at org.eclipse.osgi.storagemanager.StorageManager.open(StorageManager.java:700)
               at org.eclipse.osgi.internal.baseadaptor.BaseStorage.initFileManager(BaseStorage.java:160)
               at org.eclipse.osgi.internal.baseadaptor.BaseStorage.initialize(BaseStorage.java:137)
               at org.eclipse.osgi.baseadaptor.BaseAdaptor.initializeStorage(BaseAdaptor.java:124)
               at org.eclipse.osgi.framework.internal.core.Framework.initialize(Framework.java:138)
               at org.eclipse.osgi.framework.internal.core.Framework.<init>(Framework.java:112)
               at org.eclipse.osgi.framework.internal.core.OSGi.createFramework(OSGi.java:90)
               at org.eclipse.osgi.framework.internal.core.OSGi.<init>(OSGi.java:31)
               at org.eclipse.core.runtime.adaptor.EclipseStarter.startup(EclipseStarter.java:286)
               at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:173)
               at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
               at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:48)
               at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
               at java.lang.reflect.Method.invoke(Method.java:600)
               at org.eclipse.core.launcher.Main.invokeFramework(Main.java:334)
               at org.eclipse.core.launcher.Main.basicRun(Main.java:278)
               at org.eclipse.core.launcher.Main.run(Main.java:973)
               at org.eclipse.core.launcher.Main.main(Main.java:948)
!SESSION Mon Dec 02 18:02:09 EST 2013 ------------------------------------------
!ENTRY org.eclipse.core.launcher 4 0 2013-12-02 18:02:09.907
!MESSAGE Exception launching the Eclipse Platform:
!STACK
java.lang.NullPointerException
               at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:186)
               at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
               at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:48)
               at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
               at java.lang.reflect.Method.invoke(Method.java:600)
               at org.eclipse.core.launcher.Main.invokeFramework(Main.java:334)
               at org.eclipse.core.launcher.Main.basicRun(Main.java:278)
               at org.eclipse.core.launcher.Main.run(Main.java:973)
               at org.eclipse.core.launcher.Main.main(Main.java:948)



Solution is

1.      Open Profile management configuration file i.e config.ini  from directory below
…\IBM\SDP\runtimes\base_v7\bin\ProfileManagement\configuration


2.      Update following entries

i.e. remove the @user.home and add some local temporary directory as below
osgi.instance.area.default=c:/temp/PMT/workspace
osgi.configuration.area=c:/temp/PMT/workspace/configuration

3.      Once you save the file , click on the “Run Profile Management Tool”  in RAD (from window->prefrerences->servers->was)


Ref: