"RedHat Enterprise Linux 7 install Oracle 12C" related script download

Source: Internet
Author: User

rootsetup.sh

#!/bin/bash

#Redhat 7

Rpm-q binutils compat-libcap1 compat-libstdc++ gcc gcc-c++ glibc glibc-devel ksh libaio libaio-devel libgcc libstdc++ li Bstdc++-devel libxi libxtst make Sysstat UnixODBC unixodbc-devel


/usr/sbin/groupadd oinstall &&/usr/sbin/groupadd dba &&/usr/sbin/useradd-g oinstall-g dba Oracle & & Echo ' a1a2a3a4! ' | passwd--stdin Oracle


#vi/etc/sysctl.conf

echo "FS.AIO-MAX-NR = 1048576" >>/etc/sysctl.conf

echo Fs.file-max = 6815744 >>/etc/sysctl.conf

# shmall=totalmem*40%

echo Kernel.shmall = 1717986918 >>/etc/sysctl.conf

# shmmax=totalmem*50%

echo Kernel.shmmax = 2147483648 >>/etc/sysctl.conf

echo Kernel.shmmni = 4096 >>/etc/sysctl.conf

echo Kernel.sem = 32000 >>/etc/sysctl.conf

echo net.ipv4.ip_local_port_range = 9000 65500 >>/etc/sysctl.conf

echo Net.core.rmem_default = 262144 >>/etc/sysctl.conf

echo Net.core.rmem_max = 4194304 >>/etc/sysctl.conf

echo Net.core.wmem_default = 262144 >>/etc/sysctl.conf

echo Net.core.wmem_max = 1048586 >>/etc/sysctl.conf


/sbin/sysctl-p

/sbin/sysctl-a


# vi/etc/security/limits.conf

echo Oracle Soft Nproc 2047 >>/etc/security/limits.conf

echo Oracle hard Nproc 16384 >>/etc/security/limits.conf

echo Oracle Soft nofile 1024x768 >>/etc/security/limits.conf

echo Oracle hard Nofile 65536 >>/etc/security/limits.conf



#vi/etc/pam.d/login

echo Session required/lib/security/pam_limits.so >>/etc/pam.d/login

echo Session required pam_limits.so >>/etc/pam.d/login


Mkdir-p/u01/app/&& mkdir/u01/tmp && chown-r oracle:oinstall/u01/app/&& chmod-r 775/u01/ap p/



Vi/etc/hosts

#增加 IP Address host name


Su-oracle



oraclesetup.sh

#!/bin/bash


#vi. Bash_profile

echo umask 022 >>.bash_profile

echo Export Oracle_base=/u01/app/oracle >>.bash_profile

Echo-e "Export oracle_home=\ $ORACLE _base/product/12c" >>.bash_profile

echo Export oracle_sid=oracle12c >>.bash_profile

Echo-e "path=\ $PATH: $HOME/bin:\ $ORACLE _home/bin:\ $ORACLE _home/lib:\ $ORACLE _home/lib64" >>.bash_profile

Echo-e "ld_library_path=\ $ORACLE _home/bin:/usr/bin" >>.bash_profile

echo Export nls_lang= "American_america. ZHS16GBK ">>.bash_profile


echo "if [$USER =" Oracle "]; Then ">>.bash_profile

echo "if [$SHELL ="/bin/ksh "]; Then ">>.bash_profile

echo ulimit-p 16384 >>.bash_profile

echo ulimit-n 65536 >>.bash_profile

echo Else >>.bash_profile

echo ulimit-u 16384-n 65536 >>.bash_profile

echo Fi >>.bash_profile

echo Fi >>.bash_profile


SOURCE ~/.bash_profile



This article is from the "Start from the Heart" blog, please be sure to keep this source http://ycrsjxy.blog.51cto.com/618627/1598938

"RedHat Enterprise Linux 7 install Oracle 12C" related script download

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.