Saturday, December 21, 2013

Scheduled task won't run .bat file 2008R2

In our production environments, i scheduled a task to start some programs which is a BAT file in Windows Server 2008 R2.

If i double click the .bat file, it started. But from scheduled task, it is not starting. Although i select the task and try to run task manually , it is not starting.


 Fill in the "Start In (Optional)" field. There you need to enter the path of .BAT file.
Go to task's properties, Actions, Edit and put the path to BAT filr.

Ex: E:\MUBASHER-IT\ANBI\Documents\

No need to put double quotes.

Sunday, June 16, 2013

How to increase number of connections in Oracle

SQL> alter system set processes=200 scope=spfile/both; 

Sunday, June 2, 2013

Schedule a CRON Job in HP-UX

Few days back i have a problem to schedule a cron job in HP-UX to run a .sh script.
Cron is staring exactly on the scheduled time and the particular .sh script also calling from the cron job.
But that component is not starts.

This script is as follows.

/usr/java/jre1.5.0_22/bin/java -server -Xms512m -Xmx1024m -XX:MaxPermSize=512m -Dsun.rmi.dgc.client.gcInterval=90000 -Dsun.rmi.dgc.server.gcInterval=90000 -jar lib/DBC.jar> nohup_dbc.out &


What i did was, i created another script start-cron.cron file which as follows.

 "cd /<File path to>
  sleep 2
and save as .cron.
Change the permission as 777

Then i call the start-cron.cron  file in the CRON job scheduler.
Then the component was started.

Monday, May 20, 2013

Import PKCS12 private keys into JKS keystores using Java Keytool

1) Import alice.p12 into alice.jks

keytool -v -importkeystore -srckeystore certifiate.p12 -srcstoretype PKCS12 -destkeystore mykeystore.jks -deststoretype JKS


* Create an new empty JKS store.

keytool -genkey -alias mykey -keystore keystore.jks
keytool -delete -alias mykey - keystore keystore.jks

Wednesday, April 24, 2013

Websphere Application server-Transaction across two base servers fails

During a brokerage solution implementation, we have faced a issue of connecting two Websphere application servers. In "SystemOut.log" files, the following error appears.

>> SERVER (id=4773e3aa, host=ICAPNT17) TRACE START:
>>    org.omg.CORBA.TRANSACTION_ROLLEDBACK: javax.transaction.TransactionRolledbackException:  ; nested exception is:   vmcid: 0x0  minor code: 0  completed: No
>> at
>> at
>> at
>> at
>> at
>> at com.mubasher.connectors.web.session.EJSRemoteStatelessWebConnectorFacade_415e6c0a.createOrder(Unknown Source)
>> at com.mubasher.connectors.web.session._EJSRemoteStatelessWebConnectorFacade_415e6c0a_Tie.createOrder(
>> at com.mubasher.connectors.web.session._EJSRemoteStatelessWebConnectorFacade_415e6c0a_Tie._invoke(
>> at
>> at
>> at
>> at
>> at
>> at
>> at
>> at
>> at$
>> SERVER (id=4773e3aa, host=ICAPNT17) TRACE END.
  vmcid: 0x0  minor code: 0  completed: No In class: class
com.directfn.tradeweb.system.exceptions.ServiceException: javax.transaction.TransactionRolledbackException: CORBA TRANSACTION_ROLLEDBACK 0x0 No; nested exception is:

 I found that this is happening because of  global security enabled default behavior is for transaction protocol messages, e.g. prepare, commit, rollback to be secured. This prevents malicious completion of global transactions.

What we Did

1) Global transaction on WAS requires the two servers to "trust" each other. I solved the problem by importing server A's LTPA key into server B and vice-versa.

2) If you run in an environment where security is not a concern, or the servers are secured by another means, this behavior can be disabled by unchecking the Enable protocol security check box on the transaction
service panel in the admin console