Problems installing Oracle Database Express Edition 11g

前端 未结 7 2262
感动是毒
感动是毒 2021-02-19 13:14

I\'m trying to install Oracle Database in (X)ubuntu 13.04 64-bit using this guide. Everything goed well until I get to the following step:

$ sudo /etc/init.d/ora         


        
相关标签:
7条回答
  • 2021-02-19 13:23

    This link looks like it has the answer. You need to make sure that /dev/shm is mounted on your system, and assign it memory of at least MEMORY_TARGET.

    You can do this by adding the following to your fstab, and rebooting. (This will set the /dev/shm size to 2gb):

    shmfs /dev/shm tmpfs size=2048m 0 0
    
    0 讨论(0)
  • 2021-02-19 13:26

    I was in the same boat, trying to configure XE on a virtual machine (openSUSE 13.01 64bit).

    The solution in my case was the missing hostname in /etc/hosts. You can examine the errors in /u01/app/oracle/product/11.2.0/xe/config/log/CloneRmanRestore.log at the very beginning (the path depends on your XE version).

    Search for an info similar to: ORA-00119: invalid specification for system parameter LOCAL_LISTENER ORA-00130: invalid listener address '(ADDRESS=(PROTOCOL=TCP)(HOST=linux-cn65.site)(PORT=1521))

    So linux-cn65.site (the VM host) was missing. Add your host in /etc/hosts (as root):

    127.0.0.1 linux-cn65.site <-- your host here

    and run the configuration again (as root): sh /etc/init.d/oracle-xe configure

    Additional trickery

    • if you do not have the error files in the log folder, you may re-install XE without h flag, like this:

      • to find your package: sudo rpm -qa | grep -i oracle
      • to remove it: sudo rpm -e oracle-xe-11.2.0-1.0.x86_64 <-- your package here
    • install again without h flag: sudo rpm -iv oracle-xe-11.2.0-1.0.x86_64.rpm

    oh, replace the version (oracle-xe-11.2.0-1.0.x86_64.rpm) with yours. Cheers ;)

    0 讨论(0)
  • 2021-02-19 13:34

    I had this exact issue with Ubuntu 14.04. The issue came down to Oracle-XE expecting sufficient space at /dev/shm while ubuntu has changed to using /run/shm with a symlink from /dev/shm.

    The solution that worked for me was to create the file /etc/rc2.d/S01shm_load containing:

    #!/bin/sh
    case "$1" in
    start)
        mkdir /var/lock/subsys 2>/dev/null
        touch /var/lock/subsys/listener
        rm /dev/shm 2>/dev/null
        mkdir /dev/shm 2>/dev/null
        mount -t tmpfs shmfs -o size=2048m /dev/shm ;;
    *)
        echo error
        exit 1
        ;;    
    esac
    

    I got this from http://sysadminnotebook.blogspot.de/2012/10/installing-oracle-11g-r2-express.html which is similar to many other pages on installing XE but was the only one with this solution.

    PS. The file permissions are set at 755 so you will need to execute:

    sudo chmod 755 /etc/rc2.d/S01shm_load

    to set the permissions on this file.

    0 讨论(0)
  • 2021-02-19 13:37
    nano /etc/init.d/oracle-shm
    

    add text

    #! /bin/sh 
    # /etc/init.d/oracle-shm 
    # 
    case "$1" in 
    start) 
    echo "Starting script /etc/init.d/oracle-shm" 
    # Run only once at system startup  
    if [ -e /dev/shm/.oracle-shm ]; then 
    echo "/dev/shm is already mounted, nothing to do" 
    else 
    rm -f /dev/shm 
    mkdir /dev/shm 
    mount --move /run/shm /dev/shm 
    mount -B /dev/shm /run/shm 
    touch /dev/shm/.oracle-shm 
    fi 
    ;; 
    stop) 
    echo "Stopping script /etc/init.d/oracle-shm" 
    echo "Nothing to do" 
    ;; 
    *) 
    echo "Usage: /etc/init.d/oracle-shm {start|stop}" 
    exit 1 
    ;; 
    esac 
    # 
    ### BEGIN INIT INFO 
    # Provides: oracle-shm 
    # Required-Start: $remote_fs $syslog 
    # Required-Stop: $remote_fs $syslog 
    # Default-Start: 2 3 4 5 
    # Default-Stop: 0 1 6 
    # Short-Description: Bind /run/shm to /dev/shm at system startup. 
    # Description: Fix to allow Oracle 11g use AMM. 
    ### END INIT INFO
    

    make the file executable

    chmod 755 /etc/init.d/oracle-shm
    /etc/init.d/oracle-shm start
    

    At this stage reboot, then check

    df -kh /dev/shm
    

    further proceed to emulate chkconfig and continue with rest of configuration and install

    dpkg -i oracle-xe-11.2.0-1.0.x86_64.deb
    

    Check the environment variables and ORACLE_HOME and start database

    0 讨论(0)
  • 2021-02-19 13:43

    I struggled with this too. I have tried a few different solutions, but still got the problem. I "fixed" it by removing memory_target from the database configuration:

    sqlplus / as sysdba
    create pfile=‘<path>’ from spfile 
    !vi <path>
    

    Add # in front of the line with memory_Target, save and close file.

    startup from pfile=‘<path>'
    create spfile from pfile=‘<path>’
    

    This solution works nice with my XE database, hope it helps.

    0 讨论(0)
  • 2021-02-19 13:49

    Check your /etc/hosts file. It should looks like

    127.0.0.1 localhost.localdomain localhost hostname.domain hostname

    http://blog.christian-stankowic.de/?p=5276&lang=en

    0 讨论(0)
提交回复
热议问题