WebSphere Issues

28/09/2010

The directory key stash file is inconsistent with the associated encrypted data

Filed under: TDS — Ishtiaque @ 10:21 am

When you import .ldif file onto your server you might get the following error:

GLPCRY007E The directory key stash file is inconsistent with the associated encrypted data.

In order to resolve this error you need to modify ibm-slapdCryptoSync and ibm-slapdCryptoSalt with the values specific to your ldap instance.

You can find out the above values at your server by running the command:

/opt/ibm/ldap/V6.1/bin/ldapsearch -D cn=root -w passw0rd -s base -b cn=crypto,cn=localhost cn=*

References:

http://publib.boulder.ibm.com/infocenter/tivihelp/v2r1/index.jsp?topic=%2Fcom.ibm.itim.doc%2Fmig510_install42.htm

SQL5043N Support for one or more communications protocols failed to start successfully

Filed under: DB2, Linux, TDS — Ishtiaque @ 8:35 am

After configuring Tivoli Directory Server databases some time we get following exception in:

/home/idsinst/sqllib/db2dump/db2diag.log

/home/idsinst/sqllib/log/db2start.log

SQL5043N  Support for one or more communications protocols failed to start successfully. However, core database manager functionality started successfully.

1. In order to resolve the above error enter following two lines in /etc/services file:

idsinstsvcids    3737/tcp
idsinstsvcidsi    3766/tcp

2. Run following commands to view and update SVCENAME parameter of idsinst instance:

-> db2 get dbm cfg | grep SVC

If it’s not set to idsinstsvcids, then run the following command to set it:

-> db2 update dbm cfg using SVCENAME idsinstsvcids

3. Verify TDS db alias node LDAPDB2N using correct service name i.e idsinstsvcids:

-> db2 list node directory

If LDAPDB2N node is not using idsinstsvcids service name, then un-catalog it and re-catalog it with correct service name.

-> db2 uncatalog node LDAPDB2N

Note: If you get the error SQL1326N The file or directory “” cannot be accesse, while running above command.

Then update the Group access (i.e Read and Write) for the files sqlnodir and sqlnobak inside the directory /home/idsinst/sqllib/sqlnodir/ from db2grp1 to idsldap OR dbsysadm (which ever group  idsinst is member of)

-> db2 catalog tcpip node LDAPDB2N remote localhost server idsinstsvcids

Node: After this step you might have to delete and recreate the itds db.

04/09/2010

Linux shell scripting basics

Filed under: Linux — Ishtiaque @ 9:40 am

1. Following  example will execute the script while passing argument to it:

./test.sh value1 value2

echo Script name $0     # $0 will contains script name

ARG1=$1

ARG2=$2

echo you entered $ARG1 and $ARG2

2. Following example will get argument at command prompt:

read USER

echo You entered $USER

3. Following example will verify number of arguments:

if [ $# != 2 ]

then

echo Please enter username and password

exit

fi

Note: There should be space b/w “[” and variable. Also “then” keyword should be placed no second line.

References:

a. http://www.ibm.com/developerworks/library/l-bash2.html

b. http://www.linuxconfig.org/Bash_scripting_Tutorial

c. http://linuxhelp.blogspot.com/2005/10/10-seconds-guide-to-bash-shell.html

Blog at WordPress.com.