实验环境 RedHat server 6
首先下载 oracle XE :
- wget 没有找到正确的方式下载 (直接本地下载上传的 <^^>)
- 解压,需要使用 unzip 解压,假如没有安装 unzip ,先安装 unzip
-
#http://www.oracle.com/technetwork/database/database-technologies/express-edition/downloads/index.html #安装 unzip yum install unzip #解压安装压缩包 unzip oracle-xe-11.2.0-1.0.x86_64.rpm.zip
- oracle xe 需要 2G 的交换空间
见我的博文 Linux 设置 Swap 空间 - 设置 tmpfs , oracle xe 要求 1g 的 tmpfs (在 init.ora 文件中),这里将tmpfs设为 2g
-
#查看 tempfs df -h #修改文件 /etc/fstab vi /etc/fstab #加上或修改 tmpfs /dev/shm tmpfs defaults,size=2048M 0 0 #重新挂载 umount /dev/shm mount /dev/shm #查看 df -h /dev/shm
安装依赖包
centOS 7:
yum install libaio*
redhat 6 需要先去 这里 下载安装包
tar zxvf libao-1.2.0.tar.gz
cd libao-1.2.0
./configure --prefix=/usr &&
>make
make install &&
>install -v -m644 README /usr/share/doc/libao-1.2.0
安装 oracle xe
进入 Disk1 目录
cd Disk
rpm -ivh oracle-xe-11.2.0-1.0.x86_64.rpm
配置 oracle xe 数据库
/etc/init.d/oracle-xe configure
.
.
.
Specify the HTTP port that will be used for Oracle Application Express [8080]:1522
#修改默认http端口 ,直接回车默认为8080
.
.
.
Specify a port that will be used for the database listener [1521]:
# oracle xe 数据库端口,直接回车即为默认 1521
.
.
.
#输入 sys和system用户密码:
This can be done after initial configuration:
#确认
Confirm the password:
软件安装在 /u01/app/oracle