first, the environment preparation
1.1. Description
Working path/data/hdfs/data1/jianxin/
1.2. Software version
Oracle-xe-11.2.0-1.0.x86_64.rpm.zip
1.3, modify the Tmpfs
1.3.1, Oracle XE gives the minimum requirements in the Init.ora file, which is 1G by default. This expands the TMPFS to 2G:
To Modify the/etc/fstab file:
tmpfs/dev/shm tmpfs defaults 0 0
modified to:
tmpfs/dev/shm tmpfs defaults,size=2048m 0 0
1.3.2, Reload Tmpfs
Umount/dev/shm; Mount/dev/shm
1.3.3, df-h/dev/shm view output:
[email protected] ~]# df-h/DEV/SHM
Filesystem Size used Avail use% mounted on
tmpfs 12G 610M 12G 6%/dev/shm
1.4. Install Dependent packages
Install dependent packages
Yum install Libaio libaio-devel bc-y
(yum install libaio*)
the substance is installed:
libaio-0.3.107-10.el6.x86_64
libaio-devel-0.3.107-10.el6.x86_64
bc-1.06.95-1.el6.x86_64
Second, the official installation
2.1, Unzip decompression, RPM installation
cd/data/hdfs/data1/jianxin/
Unzip Oracle-xe-11.2.0-1.0.x86_64.rpm.zip
CD Disk1
RPM-IVH oracle-xe-11.2.0-1.0.x86_64.rpm
2.2. Execute command/etc/init.d/oracle-xe Configure configuration
/etc/init.d/oracle-xe Configure
Initial configuration:123456
Confirm the password:123456
user name: Root
Password: 123456
configuration information: Port of HTTP (Note If port 8080 is conflicting), Oracle listening port, login password.
after installation, the system will automatically establish a user named Oracle, home dir location in/u01/app/oracle, which is the location of the database installation.
2.3.1, modifying environment variables
Vi/etc/profile, adding
# Oracle Settingstmp=/tmp; Export tmptmpdir= $TMP; Export tmpdiroracle_base=/u01/app/oracle; Export Oracle_baseoracle_home= $ORACLE _base/product/11.2.0/xe; Export Oracle_homeoracle_sid=xe; Export oracle_sidoracle_term=xterm; Export Oracle_termpath=/usr/sbin: $PATH; Export pathpath= $ORACLE _home/bin: $PATH; Export pathtns_admin= $ORACLE _home/network/adminld_library_path= $ORACLE _home/lib:/lib:/usr/lib; Export ld_library_pathclasspath= $ORACLE _home/jlib: $ORACLE _home/rdbms/jlib; Export Classpathif [$USER = "Oracle"]; Then if [$SHELL = "/bin/ksh"], then ulimit-p 16384 ulimit-n 65536 else ulimit-u 16384-n 65536
fifi
Note:
2.3.1.1, XE version can only have a instance, will SID modified after seemingly will error, so SID will not have to change.
2.3.1.2, base and home two variables, try not to add a slash '/', there may be an error.
2.3.1.3, tns_admin this variable must have.
2.3.2,
Source/etc/profile
[email protected] jianxin]# echo $ORACLE _base
/u01/app/oracle
[email protected] jianxin]# echo $ORACLE _home
/u01/app/oracle/product/11.2.0/xe
2.4. Initialize the database
su Oracle
cd/u01/app/oracle/product/11.2.0/xe/dbs/
CP Init.ora Initxe.ora
vi Initxe.ora, modified to the following:
Db_name= ' XE ' memory_target=1gprocesses = 150audit_file_dest= '/u01/app/oracle/admin/orcl/adump ' audit_trail = ' db ' db_ block_size=8192db_domain= ' db_recovery_file_dest= '/u01/app/oracle/fast_recovery_area ' db_recovery_file_dest_ size=2gdiagnostic_dest= '/u01/app/oracle ' dispatchers= ' (protocol=tcp) (service=orclxdb) ' Open_cursors=300remote_ Login_passwordfile= ' EXCLUSIVE ' undo_tablespace= ' UNDOTBS1 ' # you could want to ensure that control files is created on Separat E physical# devicescontrol_files = ('/u01/app/oracle/oradata/', '/u01/app/oracle/oradata/') compatible = ' 11.2.0 '
Third, installation verification
3.1, verify one, command line under
Switch to Oracle user, connect to database using Sqlplus, go to sqlplus console
[email protected] jianxin]# Sqlplus/nolog
sql*plus:release 11.2.0.2.0 Production on Mon Apr 20:05:39
Copyright (c) 1982, Oracle. All rights reserved.
sql> Connect as Sysdba
Enter User-name:sys
Enter password:123456
Connected.
sql>
(You can do this, but do the following first)
The 11g XE version already has a built-in database XE, so you don't need to create the database manually, but you need to initialize the database structure and run the following two lines of code:
sql> @?/rdbms/admin/catalog.sql
sql> @?/rdbms/admin/catproc.sql
if database didn ' t open appears during the run, you will need to restart and mount the databases.
when you are done, execute the following test command:
sql> Create user MyAccount identified by "123456" DEFAULT tablespace users; (Next, the users table should already exist in the initial database. So you can insert the data directly.)
sql> GRANT DBA to MyAccount;
sql> CREATE TABLE test_table (txt VARCHAR2 () not NULL);
sql> INSERT INTO test_table values (' Yjx Oracle ');
sql> SELECT * from test_table;
sql> Select COUNT (1) from Tab;
3.2.1, web interface
Http://172.16.16.13:8080/apex
3.2.2, Graphical tool configuration
3.2.3, port occupancy
Iv. Other Orders
4.1.1, start Oracle command Startup/startup mount (start and load database)
4.1.2, turn off Oracle command shutdown
4.2.1, enter the Sqlplus console
[email protected] jianxin]# Sqlplus/nolog
sql*plus:release 11.2.0.2.0 Production on Mon Apr 20:05:39
Copyright (c) 1982, Oracle. All rights reserved.
sql> Connect as Sysdba
Enter User-name:sys
Enter password:123456
Connected.
sql>
4.2.2, exiting the Sqlplus console
sql> quit;/exit;
disconnected from Oracle Database 11g Express Edition Release 11.2.0.2.0-64bit Production
v. Other
Reference URL
http://docs.oracle.com/cd/E17781_01/install.112/e18802/toc.htm
http://blog.csdn.net/reda0821/article/details/7816562
http://blog.csdn.net/hqs_1992/article/details/41895389
oracle-1-Installation