Saturday, May 5, 2012

SQL0970N The system attempted to write to a read-only file. SQLSTATE=5500

I got this message when I removed the earlier installed DB2 and installed V9.5  of DB2 and I wanted to create a WAREHOUS user  ( db2 create database WAREHOUS )

SQL0970N The system attempted to write to a read-only file. SQLSTATE=5500

Turns out that I did not have the write perms on the /tmp folder on my RHEL server where I was installing.

chmod ugo+w /tmp - did it.

Looking at the dbinst1/sqllib/db2diag.log - told something about the permission in that folder.




Thursday, May 3, 2012

Configuring DB2 on a Linux for Tivoli Enterprise Monitoring and Portal Server

[ Views and opinions are my own and does not reflect my employer IBM - there may be better ways to do this, but  this below worked for me ]

How to install DB2 Express on a Linux RHEL 32 bit.

Create a separate folder.
See that you have at least 900 MB free.
Untar this first in the new folder.
DB2_Exp_Ed_97_Linux_x86.tar.gz

Pre-reqs:
1. Check that the dasadm ( administration server ) is not running from an earlier installation.
it is usually in the /home/dasadm folder.
Stop it first.  /opt/ibm/db2/V9.x/das/bin/db2admin



http://publib.boulder.ibm.com/infocenter/db2luw/v9/index.jsp?topic=%2Fcom.ibm.db2.udb.admin.doc%2Fdoc%2Fr0002037.htm

If you do not - during installation - you will get this message

ERROR: ## call function cleanup_reg_list das crt dasusr1
DBI1103E  The Administration Server already exists.


2. Also, check that there are no users like itmuser, in /etc/passwd
3. cd /opt/ibm and check that there is no db2 folder
4. clean up any older db2 log files in the /tmp folder.
(5. /tmp has the rwx perms )




See that you have the xsession on a Linux server up and vnc to that server. 

Execute    db2setup

Things to remember - so make notes.
What was the instance name during creation : 

What was the password for dasusr1.
What was the password for db2inst1
What was the password for db2fenc1.
 



su - db2inst2
db2start -
ps -ef |grep db2 - there will be a few processes running
db2stop - all these should be down.
this should give an indication that the installation is good.


Uninstalling tips -
I had to  db2stop and then remove the folder /opt/ibm/db2
There was one nagging process db2fmcd - that would start over and over again - although I killed it, so ......
I had to search for this executable and do this 'db2fmcu -d ( this is an entry in inittab ) which keeps respawning.