我新安裝的Linux Mint 13 「Maya」 Xfce RC,但由於是基於Xubuntu 12.04,因此對於XUbuntu與Ubuntu的12.04都應該能夠適用html
http://www.oracle.com/technetwork/products/express-edition/downloads/index.htmlweb
Oracle Database Express Edition 11g Release 2 for Linux x64shell
因爲下載的是rpm包ubuntu沒法直接使用因此須要alien來轉換express
sudo apt-get install alien sudo alien -d --scripts oracle-xe-11.2.0-1.0.x86_64.rpm
成功轉換後獲得oracle-xe_11.2.0-2_amd64.deb安裝文件ubuntu
雙擊deb安裝這個包,這時包安裝成功可是咱們會獲得一個錯誤說/sbin/chkconfig不存在。oracle
咱們要修改/var/lib/dpkg/info/oracle-xe.postinst腳本app
if [ -f /etc/SuSE-release ] then cp -f /u01/app/oracle/product/11.2.0/xe/config/scripts/oracle-xe.sles /etc/init.d/oracle-xe /usr/lib/lsb/install_initd /etc/init.d/oracle-xe > /dev/null 2>&1 /sbin/insserv /etc/init.d/oracle-xe > /dev/null 2>&1 /sbin/SuSEconfig > /dev/null 2>&1 #else # /sbin/chkconfig --add oracle-xe fi
把else與/sbin/chkconfig --add oracle-xe註釋掉,而後再執行
sudo /var/lib/dpkg/info/oracle-xe.postinst
會提示你運行/etc/init.d/oracle-xe configure進行配置。但別急,咱們還須要一些步驟再執行。ide
sudo apt-get install libaio1
用root登陸post
sudo su -
粘貼下載的代碼到命令行,來建立oracle-shm
cat > /etc/init.d/oracle-shm <<-EOF #! /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 -B /run/shm /dev/shm mount -t tmpfs shmfs -o size=2048m /dev/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 EOF
安裝oracle-shm
chmod 755 /etc/init.d/oracle-shm update-rc.d oracle-shm defaults 01 99
重啓
reboot
sudo /etc/init.d/oracle-xe configure
選擇web管理端口默認8080
選擇監聽端口默認1521ui
輸入管理員密碼與確認密碼(sys密碼)
最後詢問你是否自動啓動默認y
從菜單中選擇Other->Get Started with Oracle Database 11g Express Edition