You are not logged in.

#1 2009-10-23 09:47:09

unregistered
Member
Registered: 2008-04-09
Posts: 134

oracle-xe

when I do yaourt -Sy oracle-xe
The installation goes fine until I get the following error:
==> ERROR: oracle-xe-univ-10.2.0.1-1.0.i386.rpm was not found in the build directory and is not a URL.
Error: Makepkg was unable to build oracle-xe package.

What should I do? where is the build directory that I have to put the rpm in?
I have the directories aur-oracle-xe and oracle-xe in /tmp/yaourt-tmp-username/
so which one is it?

link to package
http://aur.archlinux.org/packages.php?ID=12643

Last edited by unregistered (2009-10-23 09:51:18)

Offline

#2 2009-10-23 10:04:42

Ashren
Member
From: Denmark
Registered: 2007-06-13
Posts: 1,229
Website

Re: oracle-xe

Three options:

1. Download the oracle-xe tar.gz from the AUR. Extract locally. Download oracle-xe rpm and place in the build dir. Run makepkg.

2. Or place the rpm in the aur-oracle-xe dir and rerun yaourt.

3. Edit the PKGBUILD so it grabs the oracle-xe rpm from oracle.com.

Offline

#3 2009-10-23 11:51:34

unregistered
Member
Registered: 2008-04-09
Posts: 134

Re: oracle-xe

Ashren wrote:

Three options:

1. Download the oracle-xe tar.gz from the AUR. Extract locally. Download oracle-xe rpm and place in the build dir. Run makepkg.

2. Or place the rpm in the aur-oracle-xe dir and rerun yaourt.

3. Edit the PKGBUILD so it grabs the oracle-xe rpm from oracle.com.

ok I did 2. and I got a new error, post 14 in this link:
http://bbs.archlinux.org/viewtopic.php?id=30524

any help?

Offline

#4 2009-10-24 12:52:10

unregistered
Member
Registered: 2008-04-09
Posts: 134

Re: oracle-xe

ok since the mod closed the other thread I guess I should post the problem here:

hey I have this error after installing and running the oraconfig script, can anyone help? What should I do?

Configuring Database...
ORA-00821: Specified value of sga_target 4M is too small, needs to be at least 24M
ORA-01078: failure in processing system parameters
select TO_CHAR(systimestamp,'YYYYMMDD HH:MI:SS') from dual
*
ERROR at line 1:
ORA-01034: ORACLE not available


declare
*
ERROR at line 1:
ORA-01034: ORACLE not available


select TO_CHAR(systimestamp,'YYYYMMDD HH:MI:SS') from dual
*
ERROR at line 1:
ORA-01034: ORACLE not available


Create controlfile reuse set database "XE"
*
ERROR at line 1:
ORA-01034: ORACLE not available


BEGIN dbms_backup_restore.zerodbid(0); END;


*
ERROR at line 1:
ORA-01034: ORACLE not available


ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
Linux Error: 2: No such file or directory
ORA-00821: Specified value of sga_target 4M is too small, needs to be at least 24M
ORA-01078: failure in processing system parameters
Create controlfile reuse set database "XE"
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter system enable restricted session
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter database "XE" open resetlogs
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter database rename global_name to "XE"
*
ERROR at line 1:
ORA-01034: ORACLE not available



alter database "XE" open resetlogs
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter database rename global_name to "XE"
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter system switch logfile
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter system checkpoint
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter database drop logfile group 3
*
ERROR at line 1:
ORA-01034: ORACLE not available


ALTER TABLESPACE TEMP ADD TEMPFILE '/usr/lib/oracle/xe/oradata/XE/temp.dbf' SIZE 20480K REUSE AUTOEXTEND ON NEXT 640K MAXSIZE UNLIMITED
*
ERROR at line 1:
ORA-01034: ORACLE not available


select tablespace_name from dba_tablespaces where tablespace_name='USERS'
*
ERROR at line 1:
ORA-01034: ORACLE not available


select sid, program, serial#, username from v$session
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter user sys identified by "oracle"
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter user system identified by "oracle"
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter system disable restricted session
*
ERROR at line 1:
ORA-01034: ORACLE not available


CREATE OR REPLACE LIBRARY dbms_sumadv_lib AS '/usr/lib/oracle/xe/app/oracle/product/10.2.0/server/lib/libqsmashr.so';
*
ERROR at line 1:
ORA-01034: ORACLE not available


create or replace directory DATA_PUMP_DIR as '/usr/lib/oracle/xe/app/oracle/admin/XE/dpdump/'
*
ERROR at line 1:
ORA-01034: ORACLE not available


commit
*
ERROR at line 1:
ORA-01034: ORACLE not available


BEGIN dbms_swrf_internal.cleanup_database(cleanup_local => FALSE); END;

*
ERROR at line 1:
ORA-01034: ORACLE not available


commit
*
ERROR at line 1:
ORA-01034: ORACLE not available


begin
*
ERROR at line 1:
ORA-01034: ORACLE not available



File created.ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
Linux Error: 2: No such file or directory
ORA-00821: Specified value of sga_target 4M is too small, needs to be at least 24M
select 'utl_recomp_begin: ' || to_char(sysdate, 'HH:MI:SS') from dual
*
ERROR at line 1:
ORA-01034: ORACLE not available


BEGIN utl_recomp.recomp_serial(); END;

*
ERROR at line 1:
ORA-01034: ORACLE not available


select 'utl_recomp_end: ' || to_char(sysdate, 'HH:MI:SS') from dual
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter user hr password expire account lock
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter user ctxsys password expire account lock
*
ERROR at line 1:
ORA-01034: ORACLE not available
alter user outln password expire account lock
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter user mdsys password expire
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter user flows_020100 password expire
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter user flows_files password expire
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter user sys identified by "PASSWORD"
*
ERROR at line 1:
ORA-01034: ORACLE not available


alter user system identified by "PASSWORD"
*
ERROR at line 1:
ORA-01034: ORACLE not available


Done
Starting Oracle Database 10g Express Edition Instance...ORA-00821: Specified value of sga_target 4M is too small, needs to be at least 24M
Done
Installation Completed Successfully.

Offline

#5 2009-10-30 19:03:51

rwd
Member
Registered: 2009-02-08
Posts: 671

Re: oracle-xe

unregistered wrote:

ok since the mod closed the other thread I guess I should post the problem here:

hey I have this error after installing and running the oraconfig script, can anyone help? What should I do?
(...)

I'm not familiar with this package, but it I would investigate line 1 in the error message.

Last edited by rwd (2009-10-30 19:04:12)

Offline

#6 2009-10-31 06:29:42

MadTux
Member
Registered: 2009-09-20
Posts: 553

Re: oracle-xe

Your initialization parameter SGA_TARGET is way too small, which prevents the database from starting up. All the other errors are due to the fact that Oracle hasn't been started. Locate the initialization parameter file for your database (usually in $ORACLE_HOME/dbs) and increase this particular parameter.

Offline

#7 2009-10-31 14:49:54

unregistered
Member
Registered: 2008-04-09
Posts: 134

Re: oracle-xe

MadTux wrote:

Your initialization parameter SGA_TARGET is way too small, which prevents the database from starting up. All the other errors are due to the fact that Oracle hasn't been started. Locate the initialization parameter file for your database (usually in $ORACLE_HOME/dbs) and increase this particular parameter.

my $ORACLE_HOME/dbs/init.ora file does not contain anything with regards to sga_target

but in my
$ORACLE_HOME/config/scripts/init.ora file are these lines

###########################################
# SGA Memory
###########################################
sga_target=128

do I have to change this line in this file?
if yes, what do I change it to?

Last edited by unregistered (2009-10-31 14:53:28)

Offline

#8 2009-10-31 15:23:10

MadTux
Member
Registered: 2009-09-20
Posts: 553

Re: oracle-xe

What init.ora does the config script use? I cannot see that from your post. I don't think it is the one with sga_target=128, because then it wouldn't complain. It may be $ORACLE_HOME/dbs/init.ora. You could try to copy your initialization file over that one and try it again.

Offline

#9 2009-11-01 06:06:01

unregistered
Member
Registered: 2008-04-09
Posts: 134

Re: oracle-xe

ok so this is the script that is run when I configure oracle-xe
oraconfig.sh in $ORACLE_HOME/config/scripts:

#!/bin/bash 

# Set path if path not set (if called from /etc/rc)
case $PATH in
    "") PATH=/bin:/usr/bin:/sbin:/etc
        export PATH ;;
esac

# Save LD_LIBRARY_PATH
SAVE_LLP=$LD_LIBRARY_PATH

RETVAL=0
ORACLE_HOME=/usr/lib/oracle/xe/app/oracle/product/10.2.0/server
ORACLE_OWNER=oracle
ORACLE_SID=XE
LSNR=$ORACLE_HOME/bin/lsnrctl
SQLPLUS=$ORACLE_HOME/bin/sqlplus
SU=/bin/su
export ORACLE_HOME
export ORACLE_SID
export PATH=$ORACLE_HOME/bin:$PATH
LOG="$ORACLE_HOME_LISTNER/listener.log"

export LC_ALL=C

if [ $(id -u) != "0" ]
then
    echo "You must be root to run the configure script.  Login as root and then run the configure script."
    exit 1
fi

CONFIG_NAME=oracle-xe
CONFIGURATION="/etc/sysconfig/$CONFIG_NAME"

if [ -f /etc/arch-release ]
then

    init_status() {
        return 0
    }
    exit_status() {
        exit $?
    }
    success_status() {
        success
        echo
    }
    failure_status() {
        failure $?
        echo
    }
fi
    
success () {
    echo " [OK]"
}

failure () {
     echo " [FAILED]" 
}

# Source configuration

[ -f "$CONFIGURATION" ] && . "$CONFIGURATION"

init_status

#
# if_fail()
#
# Evaluates return codes.  If 0, prints "OK", if 1, prints "Failed"
# and exits.  If 2, status is "already done" and nothing is printed.
# The rest of the functions in here all honor this convention.
#
if_fail() {
    RC="$1"
    REASON="$2"
    if [ "$RC" = "0" ]
    then
        return
    elif [ "$RC" = "2" ]
    then
        return
    fi
    failure_status "${REASON}"
    exit 1
}


#
# write_sysconfig()
#
# Writes the system configuration
#
write_sysconfig()
{
    cat >"$CONFIGURATION" <<EOF
    
#This is a configuration file for automatic starting of the Oracle
#Database and listener at system startup.It is generated By running
#'/etc/init.d/oracle-xe configure'.Please use that method to modify this 
#file

# ORACLE_DBENABLED:'true' means to load the Database at system boot.
ORACLE_DBENABLED=${ORACLE_DBENABLED:-false}

# LISTENER_PORT: Database listener
LISTENER_PORT=${LISTENER_PORT}

# HTTP_PORT : HTTP port for Oracle Application Express
HTTP_PORT=${HTTP_PORT}

# Configuration : Check whether configure has been done or not
CONFIGURE_RUN=${CONFIGURE_RUN}

EOF
    
    if [ $? != 0 ]
    then
        return 1
    fi
    return 0
}




# configure_perform()
#
# Instantantiate listener.ora,tnsnames.ora,and create the database,
# sets the password,start the listener,and adds database to inittab
# if necessary

configure_perform() {
    
    sed -i "s/%sga_target%/$SGA_SIZE/g" $ORACLE_HOME/config/scripts/init.ora
    sed -i "s/%pga_aggregate_target%/$PGA_SIZE/g" $ORACLE_HOME/config/scripts/init.ora
    /bin/chown oracle:dba $ORACLE_HOME/config/scripts/init.ora
    
    sed -i "s/%sga_target%/$SGA_SIZE/g" $ORACLE_HOME/config/scripts/initXETemp.ora
    sed -i "s/%pga_aggregate_target%/$PGA_SIZE/g" $ORACLE_HOME/config/scripts/initXETemp.ora
    /bin/chown oracle:dba $ORACLE_HOME/config/scripts/initXETemp.ora
    
    sed -i "s/%hostname%/`hostname`/g" $ORACLE_HOME/network/admin/listener.ora
    sed -i "s/%port%/$LISTENER_PORT/g" $ORACLE_HOME/network/admin/listener.ora
    /bin/chown oracle:dba $ORACLE_HOME/network/admin/listener.ora

    sed -i "s/%hostname%/`hostname`/g" $ORACLE_HOME/network/admin/tnsnames.ora
    sed -i "s/%port%/$LISTENER_PORT/g" $ORACLE_HOME/network/admin/tnsnames.ora
    /bin/chown oracle:dba $ORACLE_HOME/network/admin/tnsnames.ora

    sed -i "s/%httpport%/$HTTP_PORT/g" $ORACLE_HOME/config/scripts/postDBCreation.sql
    /bin/chown oracle:dba $ORACLE_HOME/config/scripts/postDBCreation.sql

    if test $LISTENER_PORT -ne 1521
    then
    if [ -f /tmp/local_listener ]
    then
    cat >/tmp/local_listener$$ <<EOF
###########################################
# Registration of instance with listsner
###########################################
local_listener="(ADDRESS = (PROTOCOL=TCP) (HOST=%hostname%) (PORT=%port%))"
EOF
    /bin/chmod 664 /tmp/local_listener$$
    cat /tmp/local_listener$$ >> $ORACLE_HOME/config/scripts/init.ora
    else
    cat >/tmp/local_listener <<EOF
###########################################
# Registration of instance with listsner
###########################################
local_listener="(ADDRESS = (PROTOCOL=TCP) (HOST=%hostname%) (PORT=%port%))"
EOF
    /bin/chmod 664 /tmp/local_listener
    cat /tmp/local_listener >> $ORACLE_HOME/config/scripts/init.ora
    fi

    if test -f /tmp/local_listener
    then
        rm -fr /tmp/local_listener
    elif test -f /tmp/local_listener$$
    then
        rm -fr /tmp/local_listener$$
    fi
    
    sed -i "s/%port%/$LISTENER_PORT/g" $ORACLE_HOME/config/scripts/init.ora
    sed -i "s/%hostname%/`hostname`/g" $ORACLE_HOME/config/scripts/init.ora
        /bin/chown oracle:dba $ORACLE_HOME/config/scripts/init.ora

    fi

    sed -i "s/%httpport%/$HTTP_PORT/g" $ORACLE_HOME/config/scripts/DatabaseHomePage.sh
    /bin/chown oracle:dba $ORACLE_HOME/config/scripts/DatabaseHomePage.sh

    sed -i "s/%httpport%/$HTTP_PORT/g" $ORACLE_HOME/config/scripts/readonlinehelp.sh
    /bin/chown oracle:dba $ORACLE_HOME/config/scripts/readonlinehelp.sh

    homedir=`echo $HOME`
    if [ "$homedir" = "/root" ]
    then
        homedir=`sh -c "echo ~$USER"`
    fi

    if [ -f $homedir/.gnome-desktop/oraclexe-gettingstarteddesktop.desktop ]  
    then
            /bin/chown oracle:dba $homedir/.gnome-desktop/oraclexe-gettingstarteddesktop.desktop
            /bin/chmod 664  $homedir/.gnome-desktop/oraclexe-gettingstarteddesktop.desktop
    fi
    if [ -f $homedir/Desktop/oraclexe-gettingstarteddesktop.desktop ]
    then
    /bin/chown oracle:dba $homedir/Desktop/oraclexe-gettingstarteddesktop.desktop
    /bin/chmod 664  $homedir/Desktop/oraclexe-gettingstarteddesktop.desktop
    fi

    if [ -f $ORACLE_HOME/bin/tnslsnr ]  
    then
         echo -n "Starting Oracle Net Listener..."
           $SU -s /bin/bash $ORACLE_OWNER -c "$LSNR  start" ## > /dev/null 2>&1
    echo "Done"
    fi

    echo -n "Configuring Database..."
    $SU -s /bin/bash $ORACLE_OWNER -c "$ORACLE_HOME/config/scripts/XE.sh" ## > /dev/null 2>&1
    err=`grep "ORA-44410" $ORACLE_HOME/config/log/*.log`
    if test "$err" != ""
    then
    echo "Database Configuration failed.  Look into $ORACLE_HOME/config/log for details"
    exit 1
    fi
    echo  alter user sys identified by \"$ORACLE_PASSWORD\"\; | $SU -s /bin/bash $ORACLE_OWNER -c "$SQLPLUS -s / as sysdba" ## > /dev/null 2>&1
     echo  alter user system identified by \"$ORACLE_PASSWORD\"\; | $SU -s /bin/bash $ORACLE_OWNER -c "$SQLPLUS -s / as sysdba" ## > /dev/null 2>&1
    echo "Done"

    /bin/chmod -R 640 /usr/lib/oracle/xe/oradata/XE
    /bin/chmod 750 /usr/lib/oracle/xe/oradata/XE
     rm -fr $ORACLE_HOME/config/seeddb 

    if [ -f /etc/oratab ]
    then
    echo "XE:$ORACLE_HOME:N" >> /etc/oratab
    else
       echo "XE:$ORACLE_HOME:N" >> /etc/oratab
    /bin/chown oracle:dba /etc/oratab
    /bin/chmod 644 /etc/oratab
    fi
    
   echo -n "Starting Oracle Database 10g Express Edition Instance..."
   pmon=`ps -ef | egrep pmon_$ORACLE_SID'\>' | grep -v grep`

   if [ "$pmon" = "" ];
   then
       $SU -s /bin/bash  $ORACLE_OWNER -c "$SQLPLUS -s /nolog @$ORACLE_HOME/config/scripts/startdb.sql" ## > /dev/null 2>&1
   fi
   echo "Done"

   echo "Installation Completed Successfully."

    
   return 0
}

#
#configure_ask()
#
# Ask configuration questions,setting the variables.
#

configure_ask() {
    cat <<EOF

Oracle Database 10g Express Edition Configuration
-------------------------------------------------
This will configure on-boot properties of Oracle Database 10g Express 
Edition.  The following questions will determine whether the database should 
be starting upon system boot, the ports it will use, and the passwords that 
will be used for database accounts.  Press <Enter> to accept the defaults. 
Ctrl-C will abort.

EOF

    #get the http port value
    while :
    do
        while [ 1 ]
        do
            echo -n Specify the HTTP port that will be used for Oracle Application Express [8080]:
            read LINE
            if [ -z $LINE ]
            then
                LINE=8080
            fi
            port=`netstat -n --tcp --listen | grep :$LINE | awk '{print $4}' | cut -d':' -f2`
            if [ "$port" = "$LINE" ]
            then
                echo Port $port appears to be in use by another application.\
                Please specify a different port.
            else
                break;
            fi
        done

        case "$LINE" in
        "")
            break
            ;;
        *[^0-9]*)
            echo "Invalid http port: $LINE"
            ;;
        *)
            HTTP_PORT=$LINE
            break
            ;;
        esac
    done
    
    #get the listener port value
    while : 
    do
        echo 
        while [ 1 ]
        do
            echo -n Specify a port that will be used for the database listener [1521]:
            read LINE
            if [ -z $LINE ]
            then
                LINE=1521
            fi
            echo
            port=`netstat -n --tcp --listen | grep :$LINE | awk '{print $4}' | cut -d':' -f2`
            if [ "$port" = "$LINE" ]
            then    
                echo Port $port appears to be in use by another application.\
                Please specify a different port.
            else
                break;
            fi
        done
              
        case "$LINE" in
        "")
            break
            ;;
        *[^0-9]*)
            echo "Invalid port: $LINE" >&2
            ;;
        *) 
                if [ "$HTTP_PORT" != "$LINE" ]
            then
                LISTENER_PORT=$LINE
                    break
            else
                echo Database listener cannot be configured on the same port as Oracle Application Express.
            fi
            ;;
        esac
    done
    
    #get the sga size
    while : 
    do
        echo 
        while [ 1 ]
        do
            echo -n Specify your sga size [128M]:
            read LINE
            if [ -z $LINE ]
            then
                LINE="128M"
            fi
            break;
        done
              
        case "$LINE" in
        "")
            break
            ;;
       
        *) 
            
        SGA_SIZE=$LINE
        break
            ;;
        esac
    done
    
    #get the pga_aggregate_target size
    while : 
    do
        echo 
        while [ 1 ]
        do
            echo -n Specify your pga size [96M]:
            read LINE
            if [ -z $LINE ]
            then
                LINE="96M"
            fi
            break;
        done
              
        case "$LINE" in
        "")
            break
            ;;
       
        *) 
            
        PGA_SIZE=$LINE
        break
            ;;
        esac
    done
    
    #get the database password
        while :
        do
        echo -n "Specify a password to be used for database accounts.  Note that the same
password will be used for SYS and SYSTEM.  Oracle recommends the use of 
different passwords for each database account.  This can be done after 
initial configuration:"
       while [ 1 ]
       do
         /bin/stty -echo ## > /dev/null 2>&1
         temp=`echo $IFS`
             export IFS="\n"    
         while [ 1 ]
           do
         read LINE
             while [ -z "$LINE" ]
         do
         echo
         echo -n "Password can't be null. Enter password:"  
             read LINE
         done

         result=`expr index "$LINE" [\'\"]`
         if [ $result != 0 ];
         then
                 echo 
            echo -n "The password you entered contains invalid characters. Enter password:"    
         else
        break
         fi
         done
        echo
        echo -n "Confirm the password:"
            read LINE1
        echo
                if [ "$LINE" != "$LINE1" ];
        then
            echo    
            echo -n "Passwords do not match.  Enter the password:"
        else
            break
        fi
    done
            /bin/stty echo ## > /dev/null 2>&1
            ORACLE_PASSWORD=$LINE
        export IFS=$temp
            break;
    done

    if [ "$ORACLE_DBENABLED" = "true" ]
    then
        CUR=y
    else
        CUR=n
    fi
    
    ORACLE_DBENABLED=true
          
    
}

configure() {
    configure_ask
    configure_perform
    CONFIGURE_RUN=true
    write_sysconfig
    echo To access the Database Home Page go to \"http://127.0.0.1:$HTTP_PORT/apex\"
}

configure

it seems to me that most of the paths to init.ora in the script lies in
$ORACLE_HOME/config/scripts/init.ora

Offline

Board footer

Powered by FluxBB