1 Unpack Files
Unzip the files:
unzip linux.x64_11gR2_database_1of2.zip
unzip linux.x64_11gR2_database_2of2.zip
2 Set Kernel Parameters
Add the following lines to the /etc/sysctl.conf file:
#kernel.shmall = 2097152
#kernel.shmmax = 2147483648
kernel.shmmni = 4096
# semaphores: semmsl, semmns, semopm, semmni
kernel.sem = 250 32000 100 128
fs.file-max = 6820000
fs.aio-max-nr = 1050000
net.ipv4.ip_local_port_range = 9000 65500
net.core.rmem_default=4194304
net.core.rmem_max=4194304
net.core.wmem_default=262144
net.core.wmem_max= 1050000
备用参数
#net.ipv4.ipfrag_high_thresh=524288
#net.ipv4.ipfrag_low_thresh=393216
#net.ipv4.tcp_rmem=4096 524288 16777216
#net.ipv4.tcp_wmem=4096 524288 16777216
#net.ipv4.tcp_timestamps=0
#net.ipv4.tcp_sack=0
#net.ipv4.tcp_window_scaling=1
#net.core.optmem_max=524287
#net.core.netdev_max_backlog=2500
#sunrpc.tcp_slot_table_entries=128
#sunrpc.udp_slot_table_entries=128
#net.ipv4.tcp_mem=16384 16384 16384
Run the following command to change the current kernel parameters:
/sbin/sysctl -p
3 Add the following lines to the /etc/security/limits.conf file:
* soft nproc 2047 或者 oracle soft nproc 2047
* hard nproc 16384
* soft nofile 1024
* hard nofile 65536
4 Add the following line to the /etc/pam.d/login file, if it does not already exist:
session required pam_limits.so
5 Disable secure linux by editing the /etc/selinux/config file, making sure the SELINUX flag is set as follows:
SELINUX=disabled
6 Setup
Install the following packages:
yum install setarch-2* make-3* glibc-2* libaio-0* compat-libstdc++-33-3* compat-gcc-34-3* compat-gcc-34-c++-3* gcc-4* libXp-1* openmotif-2* compat-db-4* elfutils-libelf-* glibc-devel-* gcc-c+* libaio-devel-* libstdc++* sysstat-7* unixODBC-*
或者这样..
# From RedHat AS5 Disk 1
cd /media/cdrom/Server
rpm -Uvh setarch-2*
rpm -Uvh make-3*
rpm -Uvh glibc-2*
rpm -Uvh libaio-0*
cd /
eject
# From RedHat AS5 Disk 2
cd /media/cdrom/Server
rpm -Uvh compat-libstdc++-33-3*
rpm -Uvh compat-gcc-34-3*
rpm -Uvh compat-gcc-34-c++-3*
rpm -Uvh gcc-4*
rpm -Uvh libXp-1*
cd /
eject
# From RedHat AS5 Disk 3
cd /media/cdrom/Server
rpm -Uvh openmotif-2*
rpm -Uvh compat-db-4*
cd /
eject
7 Create the new groups and users:
useradd oracle
echo oracle | passwd --stdin oracle
8 Create the directories in which the Oracle software will be installed:
mkdir -p /u01/app/oracle/product/11.2.0/db_1
chown -R oracle.oracle /u01
9 Login as the oracle user and add the following lines at the end of the .bash_profile file:
# Oracle Settings
ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE
ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1; export ORACLE_HOME
PATH=$ORACLE_HOME/bin:$PATH; export PATH
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH
CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH
if [ $USER = "oracle" ]; then
if [ $SHELL = "/bin/ksh" ]; then
ulimit -p 16384
ulimit -n 65536
else
ulimit -u 16384 -n 65536
fi
fi
vim /etc/fstab
修改下面选项为
tmpfs /dev/shm tmpfs defaults,size=10240M 0 0
mount -o remount /dev/shm
查询使用率可以使用df -k /dev/shm
转载于:https://blog.51cto.com/youxi/790985