Tuesday 29 July 2014

Create multiple instances of Maximo

I found below link to create multiple instances of Maximo in websphere. We strongly recommend that this procedure be used only for educational and experimental environments and must not used in commercial situations.

Source: http://maximo8.com/?p=70

We recommend this procedure be used only for educational and experimental environments. While you may find that you can satisfy Sarbanes-Oxley requirements for multiple environments this way, please don;t. Yes, this is a disclaimer. However, if you insist that you need a second environment and this your only way to go, here's a free, no mystery, step-by-step procedure. Do so at your own risk. Please remember that you didn't get this here.

The "How To" and "Start Here"

First, always create a backup copy of your Maximo production database. It is assumed you know how to do that, but if you don't, google for guide for backing up a DB2, SQL Server or an Oracle database and learn the procedure well. After you have created a backup, restore the database and name it MaxTest.

Log into the Websphere admin console. The default username is 'wasadmin'. Expand 'Servers' and click on 'Application Servers'. There you should find one instance called 'MXServer' which is the one you already installed. Click on 'New' to create a new app server. Enter 'MXTest' as your server name and hit 'Next'.

Accept the default template and check the box for 'Generate Unique Ports'. Finish and confirm your new app server. Finally save directly to your master configuration.

Click on the 'MXTest' app server. Under 'Server Infrastructure', expand 'Java and Process Management' and click on 'Process Definition'. Click on 'Java Virtual Machine' under the Additional Properties. Here you need to set the Initial Heap Size to 512 and the Maximum Heap Size to 1024.
Don't forget to save to master.

Now we need to know what our new application server is using for ports. Go back to your Application Server list and click on 'MXTest', expands 'Ports' and make note of the ports numbers for the four port names that begin with 'WC'. Take note of the port numbers, which should look like this:

Websphere ports 1
Websphere ports 1
Create a new virtual host. Expand 'Environment' in the left pane and click on 'Virtual Hosts'. Here you will see a list o ghosts such as maximo_host, admin_host, etc. Click on 'New' and name it 'maxtest_host' and click on Apply. Now click on 'Host Aliasses'. This list should be empty, and we will be creating 5 new aliases. Click on 'New' and accept the default port 80 and click 'Apply'. Next, create four more ports that look like the following:

Host aliases
Host aliases
Go to your Maximo installation directory, the default is "C:/ibm/SMP". Just beneath SMP you will find a directory named "maximo". Copy that entire directory and rename it 'maxtest'. We find this is a better choice than copying the entire ivm/SMP branch. This will not only save space, but will avoid confusion later on.

Next, navigate to the "C:/ibm/SMP/maxtest/applications/maximo/META-INF" folder and open the 'application.xml' file. Search for '<context-root>/maximo</contextroot>' and change it to '<context-root>/maxtest</context-root>'. This will be used in the url of reconnecting to your new instance. For example, the url for connecting to your  Maximo test application server will be
"http://servername:port/maxtest".

Go find and edit the same property in the 'deployment-application.xml' as well. Save both files.

Open your maximo.properties file at 'C:/ibm/SMP/maxtest/applications/maximo/properties'. Change the 'database' to the name of your newly created SQL Server database. The database property should
look something like this:

database=MAXTEST&amp;language=us_english&amp;nowarnings=true&amp;mars=false

Also change the 'mxe.registry.port' property. Keep it simple, just add one to the existing value.

Finally, the last property to modify is 'mxe.int.webappurl'. Change it to: mxe.int.webappurl=http://{servername}:9081/meaweb/mxe.int.globaldir=MaxTest

Finally, rebuild and deploy your maximo ear fils for the newly created maxtest application server. Access your Maximo test environment at ''http://servername:9081/maxtest'



Copy Job plan description to PM generated Work Order

To copy Job Plan description to auto generated PM Work Order description, I have found below link from IBM website:

http://www-01.ibm.com/support/docview.wss?uid=swg21645602&myns=swgtiv&mynp=OCSSLKT6&mync=R

Source: IBM

Wednesday 23 July 2014

Maximo database migration error

Below errors may occur while doing Maximo 7.5 SQL Server migration to DB2 by using maxinst.bat (to import .db2 file). 

Error: The row length of the table exceeded a limit of "32677" bytes.

Generated "db2demo.db2" file from unlvct.bat contains wrong lengths for few columns.

For example: MAXMESSAGES table has more columns which has varchar (2000). But create table script in db2demo.db2 file may contain varchar (4000). It means unlvct.bat file doubled the length of the column.

To resolve the issue open the .db2 file and modify a error table (not always MAXMESSAGES) to decrease the length half (from 4000 to 2000, some cases 2000 to 1000 or 8000 to 4000).

Error: "N.ROWSTAMP" is not valid in the context where it is used.

Generated "db2demo.db2" file from unlvct.bat contains trigger scripts for interface related tables. Just modify .db2 file to remove/comment all scripts related to interface tables triggers.

For example:
  • MXIN_INTER_TRANS_T
  • MXIN_INTER_TRANS_U
  • MXOUT_INTER_TRANST
  • MXOUT_INTER_TRANSU
and also interface table related triggers. For instance, there was an existing interface table for PO called PO_IFACE. There must be a triggers in .db2 file, PO_IFACE_T and PO_IFACE_U. Just remove these trigger scripts in .db2 file.

Hope this article may help. Please correct me, if anything wrong.





BMXAA4076E - There was no value found for the system start date. The database load may not have completed successfully. Contact your system administrator to ensure that the database was installed properly.

BMXAA4076E - There was no value found for the system start date. The database load may not have completed successfully. Contact your system administrator to ensure that the database was installed properly.

This error will occur when maxinst.bat or configdb.bat or updatedb.bat file execution completed with errors.  Make sure all are executed successfully without any errors. Thereafter, there will be an entry in dummy_crypto column of dummy_table. Based on this crypto value "System Start Date" will generate by class (MXServer).

PM generating WO but not able to see record in Work Order Tracking application

We can generate a work order from PM application. Some times we can see the message that work order is generated, but not able to find that WO in work order tracking application.

Cause: When PM is created while admin mode is ON, it will create a PM record, but doesn't create a record in PMANCESTOR table. Such PM's doesn't generate work order and also it will not throw any error, just displays a message "PM **** generated work order ****".

Work Around: Identify the PM's which doesn't has entry in PMANCESTOR. Insert a record in PMANCESTOR from backend. Restart the server and generate a work order. It will successfully create a WO.

Solution: Before creating PM, make sure admin mode is OFF.

Thursday 29 May 2014

Maximo: update table without rowstamp

In system properties, you can find property called "mxd.db.updateWithoutRowstamp". If this property is 1, then we can update table without rowstamp.

Usually interface tables doesn't have rowstamp. To update these kind of tables by using mbo customization, set this property to 1.

Wednesday 28 May 2014

how to customise rich tooltips / record hovers

Please find the information by clicking below link - IBM site:

https://www.ibm.com/developerworks/community/blogs/e25892f0-20f7-46ff-bbe9-c7c03fb3036f/entry/customizing_rich_tooltips_on_sccd_also_known_as_record_hovers?lang=en


Thursday 10 April 2014

Import classifications in Maximo 7.x

While importing classifications in Maximo 7.1 version, I was facing many problems like class structure is blank and hierarchal problems.

Firstly, my requirement is to load classifications with given hardcoded class structure id rather than auto generated integer number.

Secondly, need to import parent and child hierarchal structure.

1.       Duplicate MXCLASSIFICATION Object Structure and name it as per your requirement, remove the Inbound processing class.
2.       In ‘Restrict Attributes’ menu option, In the Source Object List, select CLASSSTRUCTURE
3.       Uncheck Restrict checkbox and check Override checkbox for below fields:
a.       Classstructureid
b.      Parent
4.     - Select Action > Exclude / Include Fields
5.     In the Source Object List, select CLASSSTRUCTURE
6.     In the Persistant Fields sub-tab, look for HASCHILDREN and UNCHECK the EXCLUDE checkBox. This will include the field in the schema.

Tuesday 8 April 2014

Using discardable MBOs

Whenever we are going to get MboSet for traversing purpose, then it is better to make mbo set discardable.
By this, Mboset will not cache the MBOs as it fetches from directly from database. This will minimise the JVM memory usage.

Discardable Mbo Sets used for traversing forward only and not to be edited/saved. Discardable Mbo Sets are always read only.

Sample Code:

MboSetRemote poSet = getMboSet("PO");
poSet.setFlag(MboConstants.DISCARDABLE, true);
......
.........
............
.................
poSet.close();

Disable Maximo 7.x login page autocomplete

Some times clients will ask not to store either user name or password in Maximo login page.

There are two ways to do disable auto complete:

1. By using IE settings. Hopefully every body aware about this. But this is applicable to entire Internet Explorer, irrespective of any login page.

2. Another way is by modifying Maximo login.jsp.

Source: IBM
Link: http://www-01.ibm.com/support/docview.wss?uid=swg21587221 

1. Modify the login.jsp file and add autocomplete="off" to the input lines pointed by the arrow below. Login.jsp is usually located
at <MAXIMO_Root>\applications\maximo\maximouiweb\webmodule\webclient\login\ directory:

Existing login.jsp:


After changes:



2. Save the modified file.
3. Stop the MXServer
4. Rebuild maximo ear (make a backup of the existing maximo ear before rebuilding)
5. Deploy the new maximo ear
6. Start the MXServer
7. Clear the browser cache.

The auto-complete will be disabled. You will have to type in the username/password every time logging in to Maximo.

Sort maximo start centre inbox assignments

Sorting Maximo 7.x start center inbox assignments :

I used below logic to set order by to due date (Descending) on start centre inbox assignments.

Create a custom class and extend WFAssignmentSet. Write a code in getInboxAssignment() method.

Sample Code:

package test.workflow;

import java.rmi.RemoteException;

import psdi.mbo.MboServerInterface;
import psdi.util.MXException;
import psdi.workflow.WFAssignmentSet;
import psdi.workflow.WFAssignmentSetRemote;

public class TestWFAssignmentsSet extends WFAssignmentSet implements WFAssignmentSetRemote
{
     public TestWFAssignments(MboServerInterface ms) throws RemoteException {
super(ms);
}

public void getInboxAssignments() throws RemoteException, MXException
         {
            super.getInboxAssignments();
            setOrderBy(" DUEDATE desc");
            reset();
         }
}

Error deploying maximo.ear file in Websphere

Error:
A composition unit with name MAXIMO already exists. Select a different application name.
ADMA5011I: The cleanup of the temp directory for application MAXIMO is complete
ADMA5014E: The installation of application MAXIMO failed.

Delete caches in websphere:
1. Stop the maximo server
2. Go to services.msc  : stop ctgCellManager01 and node agent
3. Delete Maximo directory -- IF FOUND IN BELOW PATH:    
  • <Drive>:\IBM\WebSphere\AppServer\profiles\ctgDmgr01\config\cells\ctgCell01\blas
  • <Drive>:\IBM\WebSphere\AppServer\profiles\ctgDmgr01\config\cells\ctgCell01\cus
4. Delete maximo.ear -- IF FOUND IN BELOW PATH:
  • <Drive>:\IBM\WebSphere\AppServer\profiles\ctgAppSrv01\config\cells\ctgCell01\applications
  • <Drive>:\IBM\WebSphere\AppServer\profiles\ctgDmgr01\config\cells\ctgCell01\applications
5. Delete all files in the following directories:
  • <Drive>:\IBM\WebSphere\AppServer\profiles\ctgAppSrv01\temp
  • <Drive>:\IBM\WebSphere\AppServer\profiles\ctgAppSrv01\wstemp
  • <Drive>:\IBM\WebSphere\AppServer\profiles\ctgAppSrv01\config\temp
  • <Drive>:\IBM\WebSphere\AppServer\profiles\ctgDmgr01\temp
  • <Drive>:\IBM\WebSphere\AppServer\profiles\ctgDmgr01\wstemp
  • <Drive>:\IBM\WebSphere\AppServer\profiles\ctgDmgr01\config\temp
6. Start services. I think automatically server will start. So stop the server again.
7. Deploy maximo.ear file. After successful deployment, save the changes into master repository.
8. Start the maximo server.
   

Maximo SOAPUI error javax.xml.ws.WebServiceException

SOAPUI error while sending payload to below url (in cluster environment) http://localhost:9080/meaweb/services/MXASSET Error : <f...