Home > Database > Oracle > How to install Oracle database on Linux system

How to install Oracle database on Linux system

PHPz
Release: 2023-04-17 17:15:17
Original
4532 people have browsed it

Oracle database is a scalable, highly reliable relational database management system (RDBMS). It is used in various enterprise-level applications such as finance, logistics, human resources, etc. This article will introduce how to install Oracle database on Linux system.

Step 1: Check the system requirements

Before installing the Oracle database, you need to ensure that the system meets the following requirements:

  • The operating system is Linux
  • Hard disk free space is at least 4GB
  • Memory size is at least 1GB
  • Sufficient processor power

Step 2: Download Oracle database software

Download the Oracle database software for Linux from the Oracle official website. You need to choose the package that matches your operating system version. Unzip the downloaded file to the directory where you want to install the Oracle database, such as /usr/local/oracle.

Step 3: Create Oracle user

You need to create a user for running the Oracle database. This user can be any name, here we take oracle as an example. Create a user using the following command:

useradd -d /home/oracle -m oracle

After creating the user, you need to set a password:

passwd oracle

Step 4: Set environment variables

In order for the Oracle database to work properly, you need to set some environment variables. Add the following lines to the /etc/profile file:

export ORACLE_BASE=/usr/local/oracle
export ORACLE_HOME=$ORACLE_BASE/product/12.2.0/dbhome_1
export PATH=$ORACLE_HOME /bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib

After saving the file, use the following command to take effect the environment variable:

source /etc /profile

Step 5: Install necessary software packages

Before installing the Oracle database, you need to install some necessary software packages. Install the required packages using the following commands:

yum install -y binutils compat-libcap1 compat-libstdc -33 gcc gcc-c glibc glibc-devel ksh libgcc libstdc libstdc -devel libaio libaio-devel make sysstat unixODBC unixODBC-devel

Step 6: Run the Oracle database installation program

Now, you can run the Oracle database installation program. In the command line, switch to the folder where you downloaded the Oracle database software and use the following command to start the installation program:

./runInstaller

Next, you need to follow the instructions of the wizard. During the installation process, you need to select the installation location of the Oracle database, the administrator password of the Oracle database, database configuration and other information. Before the installation is successful, please make sure that all options in the wizard are set correctly.

Step 7: Start the Oracle database

After successful installation, you need to start the Oracle database. Execute the following command:

$ORACLE_HOME/bin/dbstart $ORACLE_HOME

If you want to automatically start the Oracle database when the system starts, please use the following command:

ln -s $ORACLE_HOME/bin/dbstart /etc/init.d/dbora
chkconfig --add dbora
chkconfig dbora on

Finally, you can use tools such as SQLPlus to log in to the Oracle database and start using it.

The above is the detailed content of How to install Oracle database on Linux system. For more information, please follow other related articles on the PHP Chinese website!

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template