|
TN0010: Lessons learned while installing SAP DB on SuSE 8.0 Professional This technical notes describes some of the problems I ran into when I installed SAP-DB on a S.u.S.E 8.0 Professional system, and how I solved them. What is SAP DB? SAP DB is database software that has been made available for free by the German firm SAP AG. The server part is distributed under GPL, and the client parts of it are distributed under LGPL. As of August 2002 it is available for Windows, Linux (Intel), Solaris, HP-UX, Tru64 and AIX operating systems. According to the SAP DB web site, SAP AG uses this database for its own commercial software and all new software development is done using SAP DB as the database. First Attempt: SAP DB CD files on SuSE 7.1 My first attempt was with the RPM files from the SAP DB CD (dated May 2002) that can be ordered for free at the SAP online shop. I installed everything there was as root, did a reboot, logged in again as root, and tried to create a new instance. This failed. The client said something to the extent that it could not connect to the x_server. On the Internet, I soon found out, that SAP DB has an internal component called the X Server that is responsible for inter-machine communication, just like Oracle's tnslistener. You can either start this service by executing the program x_server on your machine as root, or you can run the client software with the -s option. As SAP DB is meant to be run as client/server software, I decided to start x_server. After that, I tried creating a database again, but got another internal runtime error. This time, the system was complaining about a failed mktmp system call. I tried fixing this with some brute force attempts but to no avail. I came to the conclusion that maybe this was a glibc or kernel version mismatch problem, similar to the one Oracle 8.1.6 or Oracle 8.1.7 had on SuSE systems when SuSE switched their GLIBC versions between 7.1 and 7.2 (or was it 7.2 and 7.3?). Why should not SAP DB run into the same problem? Second Attempt: SuSE 8.0 RPMs on a new SuSE 8.0 installation In order to root out all version problems, I decided to start with a fresh installation of SuSE 8.0 professional which is the current version at the time of this writing (August 2002). I selected Standard without Office, and enabled the developer options. Reboot. On the Internet, I learned earlier, that SuSE started including SAP DB RPMs with version 7.2. So in order to minimize version problems, I decided to install SAP DB from these RPMs which I did using YaST2. With version 8, SuSE includes a runlevel editor. I started this utility, and activated the SAP DB service and the SAP DB web interface service for runlevels 3 and 5. Under the hood, this activates a script that starts x_server when entering the appropriate runlevels. Reboot. A quick check with pstree showed an active vserver process which is what I wanted. I logged on as root, and executed the script that is supposed to create the TST database, but again, I got runtime error complaining about mktmp. After going through lots of other pages on the Internet, I found one where the "su sapdb" command was used. The "su" command under Unix/Linux allows you to switch the user account that you are working under. If, for example, you are logged in as user "ck" and you type in "su" or "su root", then you are asked for the root password, and if you know it, you will be authenticated as root and all further actions will be done as root. If you are logged in as "root" and you issue "su sapdb", then from nowon all your actions will be done under the account "sapdb". ("root" is the only account that does not have to provide a password.) So "su" comes in handy if you are root and if you want to perform work under some special account like sapdb without knowing the active password. So this -- su sapdb -- was all that was necessary. Apparently, when there is no database present on the computer, dbmcli can only connect to the server when the user performing the dbmcli command is "sapdb". "root" does not help here. After I did a "su sapdb", the database creation skript went through smoothely, and everything was honkey-dorey. After the TST database was created on my system, I could start it up, shut it down, access it to my heart's content from whichever user I wanted. It took me three days to get there. After I got SAP DB installed on my Linux box, I fired up my Windows box, installed SAP DB from SAP's CD, and connected to my Linux box with the GUI tools. No problems at all here. It took me three minutes, the boot-up included. Useful links Appart from the SAP DB web site at http://www.sapdb.org/, I found the following two documents extremely helpful: Rainer Stickdorn's "sapdb-dbmcli - HowTo" located at http://www.rst-consult.com/database/sapdb/dbmcli_us_html.html. If this document contained a strong emphasis on the fact that "su sapdb" is necessary for creating a fresh database, it would be perfect. Rainer Stickdorn's "ODBC auf Linux RedHat 6.2. Using ProstgreSQL and SAP DB 7.2.4 as examples." located at http://www.rst-consult.com/database/sapdb/odbc_us/index.html. Installation Chapters of my forthcoming book Because of popular demand I have made PDF files of the chapters that deal with installation issues of SAP DB under Windows and Linux of my forthcoming book available online. This is all still work in progress but I hope it will help people with their first steps with SAP DB. Warning! The text is in German. You can download the PDF files here: Pages 1-23: http://www.kuckuk.com/public/tn/SapDbInstallation1-23.pdf Pages 23-44: http://www.kuckuk.com/public/tn/SapDbInstallation23-44.pdf Document History First Version: August 12, 2002 Second Version: June 22, 2003: Added some explanations about the su command; because of popular demand I put the installation chapter of my forthcoming book online Questions? If you have any questions, please send e-mail to Carsten Kuckuk at . |