Tuesday, October 13, 2009

Changing admin password in WebSphere Portal and Quickr

Run the 'Changing password' task according to Info center instructions

Files to be checked (depending on WebSphere version)
security.xml
wkplc.properties
wpconfig.properties

wimconfig.xml
wmm.xml
wmmur.xml
wmmWasAdmin.xml

Please put appropriate LTPA password

User password encoder to generate correct encrypted strings.

Reset password in ldap

Friday, October 9, 2009

Lotus Quickr DB2 start

To start db2 instance on Lotus Quickr, execute

/opt/IBM/Quickr/db2/instance/db2istrt

Friday, August 14, 2009

LDAP ports

Default port: 389

For Active Directory, to search global catalog use port 3268

Wednesday, July 29, 2009

WebSphere Portal Users and Groups listing

For WebSphere Portal 6.1 and above
Refer to wimconfig.xml for all settings

For WebSphere Portal below 6.1
Refer to wmm.xml

If you do not see any users under All authenticated portal users or groups, modify the search filter in the above corresponding file like searchFilter="" (empty without specifiying any values)

If your LDAP base has a lot of users, sometimes portal hangs. You can validate the users by searching using cn instead of viewing complete listing.

For clustered environments, refer to the above files both from Deployment Manager and Portal Server.

Tuesday, June 30, 2009

Opening RDP session through HTML

a href="javascript:void(0)" language="VBS" onclick="LaunchRDP('your-server-name')

script language="VBScript"
Sub LaunchRDP(strServerName)
Set oShell = CreateObject("WScript.Shell")
oShell.run "mstsc /v:" & strServerName
Set oShell = Nothing
End Sub
script

Datapower IP Change

xi50# configure terminal
Global configuration mode

xi50(config)# test hardware
[success] Backtrace file does not exist.
[success] MAC address of interface 'eth0' is 00:0a:4b:80:de:28.
[warning] Physical link on interface 'eth0' is down.
[success] Statistics for interface 'eth0' show no errors.
[success] MAC address of interface 'eth1' is 00:1b:21:0d:e3:ae.
[warning] Physical link on interface 'eth1' is down.
[success] Statistics for interface 'eth1' show no errors.
[success] MAC address of interface 'eth2' is 00:1b:21:0d:e3:af.
[warning] Physical link on interface 'eth2' is down.
[success] Statistics for interface 'eth2' show no errors.
[success] MAC address of interface 'mgt0' is 00:0a:4b:80:de:2c.
[success] Physical link on interface 'mgt0' is up.
[success] Statistics for interface 'mgt0' show no errors.
[success] Expected number of interfaces: 4 - Found: 4.
[success] The fan 'chassis-1' is ok.
[success] The fan 'chassis-2' is ok.
[success] The fan 'chassis-3' is ok.
[success] The fan 'chassis-4' is ok.
[success] The fan 'chassis-5' is ok.
[success] The fan 'chassis-6' is ok.
[success] The fan 'chassis-7' is ok.
[success] The fan 'chassis-8' is ok.
[success] Status of temperature reading 'Temperature CPU1' is ok.
[success] Status of temperature reading 'Temperature CPU2' is ok.
[success] Status of temperature reading 'Temperature System 1' is ok.
[success] Status of voltage reading 'Voltage +12' is ok.
[success] Status of voltage reading 'Voltage +3.3' is ok.
[success] Status of voltage reading 'Voltage +5' is ok.
[success] Battery status is OK.
[success] CPUs OK
[success] Status of crypto 'hardware2' is fully operational.

xi50(config)# int mgt0
Interface configuration mode (mgt0 )

xi50(config-if[eth4])# ip address your-ip-address/24
Operation succeeded

xi50(config-if[eth4])# ip default-gateway your-gateway-ip-address
Operation succeeded

xi50(config-if[eth4])# exit

xi50(config)# web-mgmt your-ip-address 9090
Web management: successfully started
xi50(config)# ssh your-ip-address

% Pending

SSH service listener enabled

xi50(config)# write memory
Overwrite previously saved configuration? [y/n]: y
Configuration saved successfully.
xi50(config)#

Monday, June 29, 2009

Windows CPL commands

appwiz.cpl - Add or Remove programs
services.msc - Services Panel
compmgmt.msc - Computer Management
hdwwiz.cpl - Add Hardware Wizard
sysdm.cpl - System

Monday, June 22, 2009

SSL URL Validation through Java

import java.io.BufferedInputStream;
import java.io.InputStream;
import java.net.URLConnection;

public class SSLConnection {

public void runTest( String url )
{
java.net.URL endpoint;
try
{
endpoint = new java.net.URL(url);
URLConnection connection = endpoint.openConnection();
InputStream in = new BufferedInputStream( connection.getInputStream() );

byte[] bytes = new byte[500];
int n = in.read(bytes, 0, 500 );

for ( int i = 0; i <>
System.out.print( new Character( (char) bytes[i] ) );
}

in.close();
}
catch (Exception e)
{
e.printStackTrace();
}
}
public static void main( String[] args )
{
SSLConnection test = new SSLConnection();

System.out.println("Connect without proxy - Non secure" );
test.runTest("http://your_url_goes_here");

System.out.println("Connect without proxy - Secure" );
test.runTest("https://your_url_goes_here");
System.setProperty("http.proxyHost", "your_proxy_name");
System.setProperty("http.proxyPort", "your_proxy_port");
System.out.println("Connect with proxy - Non secure" );
test.runTest("http://your_url_goes_here");
System.out.println("Connect with proxy - Secure" );
test.runTest("https://your_url_goes_here");
}
}

Friday, June 19, 2009

IP Subnet Calculator

http://www.subnet-calculator.com

Thursday, June 4, 2009

WebSphere 6.1 - JMX SOAP Connection Example

import java.util.Properties;
import com.ibm.websphere.management.AdminClient;
import com.ibm.websphere.management.AdminClientFactory;

public class JMXTest {

public static void main(String[] args) {
JMXTest jmxtest = new JMXTest();
jmxtest.execute();
}

public void execute() {
try {
Properties connectProps = new Properties(); 
connectProps.setProperty(AdminClient.CONNECTOR_TYPE, AdminClient.CONNECTOR_TYPE_SOAP); 
connectProps.setProperty(AdminClient.CONNECTOR_HOST, "{hostname}"); 
connectProps.setProperty(AdminClient.CONNECTOR_PORT, "{8879 or your-soap-port"); 
connectProps.setProperty(AdminClient.CONNECTOR_SECURITY_ENABLED, "true");
connectProps.setProperty(AdminClient.USERNAME, "{username}");
connectProps.setProperty(AdminClient.PASSWORD, "{password}");
connectProps.setProperty("javax.net.ssl.trustStore", "/opt/IBM/WebSphere/AppServer/profiles/Dmgr01/etc/DummyClientTrustFile.jks");
connectProps.setProperty("javax.net.ssl.keyStore", "/opt/IBM/WebSphere/AppServer/profiles/Dmgr01/etc/DummyClientKeyFile.jks");

AdminClient adminClient = null; 
try 
adminClient = AdminClientFactory.createAdminClient(connectProps); 
System.out.println("Connected Successfully");
catch (Exception e) 
System.out.println("Exception creating admin client: " + e); 
e.printStackTrace();
}
} catch (Exception e) {
e.printStackTrace();
}
}

Tuesday, May 26, 2009

DataPower XI150 Firmware upgrade steps

Login into data power 
1) Administration -> File Management -> image: Actions -> Upload Firmware image
2) Administration -> System Control -> Shudown -> Select Reload Firmware -> Perform Shutdown
3) Administration -> System Control -> Boot Image -> Select Firmware image -> Perform Boot 

Datapower will restart as part of steps 2 and 3 and you will have to relogin.
You can also perform continuous ping on data power IP to monitor its state (e.g. ping -t datapowerip) while performing steps 1 - 3.



 

Wednesday, May 20, 2009

WebSphere host lookup error

Problem:
ADMU0027E: An error occurred during federation 
ADMU0036E: The Deployment Manager cannot lookup by name host {hostname} at address 127.0.0.1; rolling back to original configuration.

Solution:
Check the /etc/hosts file. Remove loop back address and add hostname with relevant server IP.


WebSphere SOAP Connection Errors

Problem:
WASX7023E: Error creating "SOAP" connection to host "{hostname}"; exception information: com.ibm.websphere.management.exception.ConnectorNotAvailableException: [SOAPException: faultCode=SOAP-ENV:Client; msg=Error opening socket: javax.net.ssl.SSLHandshakeException: java.security.cert.CertificateException: Certificate not Trusted; targetException=java.lang.IllegalArgumentException: Error opening socket: javax.net.ssl.SSLHandshakeException: java.security.cert.CertificateException: Certificate not Trusted]

Solution:
Attempt to recreate the problem using wsadmin
./wsadmin.sh -conntype SOAP -host {hostname} -port {8879 or relevant port}  -user {username} -password {password}

Copy the deployment manager Dummy*.jks files from /etc location to app server /etc location.
Try running the above wsadmin command

Tuesday, May 12, 2009

PCI Compliance

To satisfy PCI compliance requirements with IBM HTTP Server 6.1 / Apache 2.0.47,  you will have to update httpd.conf with the following information.

TraceEnable off
FileETag MTime Size
UserDir disabled

Disable Mod status. Comment or remove the following line
-----------------------------------------------------------
#LoadModule status_module modules/mod_status.so

Disable SSLV2
---------------
SSLProtocolDisable SSLv2
Include the above line inside virtual host 443 section of each domain.

If you are hosting SSL in F5 BigIP LTM, in the corresponding clientssl profile, add the following in CIPHER textbox which has the value DEFAULT.
ALL:!ADH:!LOW:!EXP:!SSLv2:!NULL:HIGH:MEDIUM:RSA:RC4:

Friday, April 24, 2009

WebSphere 6.1 - JMX MBeans Query Example

Server side configuration
-------------------------
Set these parameters in Generic JVM arguments.
-Djavax.management.builder.initial= -Dcom.sun.management.jmxremote

Specify these JVM custom properties
com.sun.management.jmxremote.authenticate false
com.sun.management.jmxremote.port 9004
com.sun.management.jmxremote.ssl false

Restart the server for the changes to take effect.

Java client program
-------------------
import java.util.Set;
import javax.management.MBeanServerConnection;
import javax.management.ObjectName;
import javax.management.remote.JMXConnector;
import javax.management.remote.JMXConnectorFactory;
import javax.management.remote.JMXServiceURL;

public class JMXTest {

public static void main(String[] args) {
JMXTest jmxtest = new JMXTest();
jmxtest.execute();
}

public void execute() {
MBeanServerConnection mbeanServerConnection = null;
JMXServiceURL serviceURL;
try {
serviceURL = new JMXServiceURL(
"service:jmx:rmi://{your_host_name}:2809/jndi/JMXConnector");
JMXConnector jmxConnector = JMXConnectorFactory.connect(serviceURL);
mbeanServerConnection = jmxConnector.getMBeanServerConnection();
System.out.println("Successfully Connected!");

String query = "WebSphere:type=IlrBresModel,*";
ObjectName queryName = new ObjectName(query);
Set s = mbeanServerConnection.queryNames(queryName, null);
if (!s.isEmpty())
System.out.println(s.iterator().next());
else
System.out.println("MBean was not found");
} catch (Exception e) {
e.printStackTrace();
}

}

}

You should also have these two jars in the class path for the Java program to run.
com.ibm.ws.runtime_6.1.0.jar
ws_runtime.jar

Otherwise, runtime exceptions will be thrown. 

Friday, April 10, 2009

WebSphere 6.1 - Remove uninstallable enterprise apps

Problem:
WebSphere enterprise apps remain uninstalled after remove node.

Solution:
cd profile/config/cells/{cellname}/applications
Manually delete the ear directories.
Restart dmgr if necessary.

Thursday, April 9, 2009

Microsoft Word Mathematical Equations

Tools -> Customize -> Commands -> Insert -> Equation Editor

Click on Equation Editor, drag and drop on the tool bar

Tuesday, April 7, 2009

WebSphere Portal Server 6.1.0.1 database transfer

Problem:
WebSphere Portal Server 6.1.0.1 database transfer fails with message: ORA-02158: invalid CREATE INDEX option

Solution:
Update {dbdomain}.space_mapping.properties files table spaces without the quotes
dbdomian.AI_APP.tablespace=TABLESPACE TBLSNAME
instead of
dbdomian.AI_APP.tablespace="TABLESPACE TBLSNAME"

Thursday, April 2, 2009

Oracle list Indexes

select index_name, column_name, column_position from user_ind_columns where table_name='MYTABLENAME' order by index_name, column_position

Just replace the tablename