oracle database 11g on Slackware 12.2

mostly taken from
http://roqet.org/oracle_on_slackware.html

Note: Oracle database needs X environment for installation procedure

1.) Create Oracle user and install and management groups (as root):

groupadd dba
groupadd oinstall
adduser oracle #make the initial group oinstall, and additional groups dba,users

2.) unzip and run Oracle Installer (I skipped part with checking system prerequisites and modifying ~/.profile – we’ll see if it works)
– in installer – advanced installation
– enterprize database
– all groups set to dba
– I ran Installer without any parameters so installer failed when checking type of system – it didn’t recognize Slackware linux, but I clicked install anyway so installation continued
– all directories are set to be in /home/oracle/
– got error: “Error in invoking target ‘all_no_orcl’ of makefile ‘/home/oracle/app/oracle/product/11.1.0/db_1/rdbms/lib/ins_rdbms.mk'” and clicked Continue
– there were more errors, but in the end it seems that database runs ok, but now I miss that configuration script in .profiles file, e.g.PATH is not set, but judging by enterprize manager it looks like the database is running
– I even managed to connect to database with TOAD – everything looks fine
– but after restart, database was not started – I have to make a startup script and call it after boot

Errors:
– runInstaller: line 88: /home/oracle/database/install/.oui: Permission denied
#  chmod +x database/install/.oui
– database/install/unzip: Permission denied
# chmod +x database/install/unzip

3.) startup scripts
– /etc/oratab – change N to Y at the end of database path (the end of file) – dbstart starts only those instances with ‘Y’ entry
– set environment variables before calling dbstart:
– make startup script like this:
$ nano ~/start_oracle.sh
– and put these lines in it:
ORACLE_HOME=/home/oracle/app/oracle/product/11.1.0/db_1
ORACLE_SID=orcl
LD_LIBRARY_PATH=$ORACLE_HOME/lib:$ORACLE_HOME/network/lib
export ORACLE_HOME ORACLE_SID LD_LIBRARY_PATH
$ORACLE_HOME/bin/dbstart $ORACLE_HOME

– next make that script executable:
$ chmod +x ~/start_oracle.sh
– and change rc.local so it starts after boot (this must be done as root)
$ echo su - oracle -c /home/oracle/start_oracle.sh >> /etc/rc.d/rc.local

4.) optional – set PATH variable to ease running oracle tools:
$ echo ORACLE_HOME=/home/oracle/app/oracle/product/11.1.0/db_1 >> ~/.bashrc
$ echo PATH=$PATH:$ORACLE_HOME/bin >> ~/.bashrc
$ echo export ORACLE_HOME PATH >> ~/.bashrc

that’s it,
reboot and Oracle Database 11g should be up and running :))

99.) troubleshooting
a) TNS-12555 – listener cannot start – permission denied
– change file permissions for all Oracle binaries
– or for all oracle files:
$ chown oracle:dba $ORACLE_HOME

Leave a comment