64-bit ubuntu10.04 lts installation Oracle10g notes

Source: Internet
Author: User

(1) update the system to the latest version and install the following package

Sudo apt-Get install alien binutils GCC ia32-libs lesstif2 lesstif2-dev lib32stdc + + 6 lib32z1 libaio1 libc6 libc6-dev libc6-dev-i386 libc6-i386 libmotif3 make libstdc + + 5 rpm

 

(2) create a user

$ Sudo adduser Oracle

 

(3) create an installation directory

$ Sudo mkdir-P/opt/Oracle/DB $ sudo chown-r ORACLE: Oracle/opt/Oracle

 

(4) Modify/etc/sysctl. conf and add the following lines to/etc/sysctl. conf.

Kernel. shmmax = 3147483648

Kernel. shmmni = 4096

Kernel. Shmall = 2097152

Kernel. SEM = 250 32000 100 128

FS. File-max = 65536

Net. ipv4.ip _ local_port_range = 1024 65000

 

 

Modify/etc/security/limits. conf and add the following lines to/etc/security/limits. conf.

* Soft nproc 2407

* Hard nproc 16384

* Soft nofile 1024

* Hard nofile 65536

 

Make the modified parameters take effect

$ Sudo sysctl-P

 

Create link:

 

$ Sudo ln-S/usr/bin/awk

$ Sudo ln-S/usr/bin/RPM

$ Sudo ln-S/usr/bin/basename

 

 

(5) set the user environment

Switch to Oracle user

$ Su Oracle

Edit/home/Oracle/. bashrc

# Add the following content

Export oracle_base =/opt/Oracle

Export ORACLE_HOME = $ oracle_base/product/10.2.0/db_2

Export Path = $ ORACLE_HOME/bin: $ ORACLE_HOME/Apache/bin: $ path

Export oracle_owner = Oracle

Export oracle_sid = orcl

Export oracle_term = xterm

 

(6) Start installation preparation

You need to create a file RedHat-release in the/etc/directory. You need the permission to create the file. After the file is created, add the following content:

$ Sudo Vim/etc/RedHat-release

 

# Add

Red Hat Linux release 3.1 (Drupal)

 

Download an xmanager from the Local Machine (Windows). After installation, xstart connects to Ubuntu,

 

Xmanager: http://www.onlinedown.net/softdown/32684_2.htm

 

After installation, configure protocol to SSH, and select xterm (Linux: Type 2) for execution command)

 

(7) install Oracle

 

Go to http://www.oracle.com/policy/software/products/database/index.htmlto download the corresponding response. If the desired machine is 32-bit or 64-bit

 

You need to register a user name and password for free.

Log on to xmanager and perform the following operations:

# As mentioned earlier, Oracle is required for installation. Now, if you log out, the system is changed to Oracle for logon.

$ Unzip 10201_database_linux32.zip (if the. cpio file is downloaded, use cpio-idmv <10201_database_linux_x86_64.cpio to decompress it)

$ CD database

To avoid Chinese garbled characters on the interface during subsequent installation, you can install JDK. However, you do not need to install JDK by entering the following command on the command line.

$ Export lang = en_us run the following command to go to the Oracle Installation interface.

$./Runinstaller

 

(8) problems encountered during installation:

1. Various errors will be reported during the installation process, but it is best to check the logs starting with $ ORACLE_HOME/orainventory/logs with installactions at any time. The logs show a wide range of contents. There are also many error messages.

 

2. Because $ oracle_sid is set to orcl in the preceding configuration file, it is best to select this option by default during installation and record your global database name and database password information.

 

3. an error occurred while installing the ora-27125 unable to create shared memory segment. Check the installeractions log for detailed information, because the cause of each installation error is different, the solution may be different, but I wrote export disable_hugetlbfs = 1 on the Internet, but it does not take effect. I checked a lot of information and finally figured out how to solve the problem, run $ export disable_hugetlbfs = 1 under an oracle user.

 

# Cd $ ORACLE_HOME/bin

# Mv Oracle. Bin

# Cat> Oracle <"EOF"

#! /Bin/bash

Export disable_hugetlbfs = 1

Exec $ ORACLE_HOME/bin/oracle. Bin $ @

EOF

# Chmod + x oracle

 

After the problem is solved in this way, the subsequent installation will be smooth. If this problem is not solved, it will not be able to continue. Of course, the cause of this error may be something else. You have to try it on your own.

 

4. error in invoking target 'all _ no_orcl ihsodbc 'of makefile'/opt/Oracle/DB/rdbms/lib/ins_rdbms.mk '. see '/opt/Oracle/orainventory/logs/installActions2010-08-02_02-14-48PM.log' for details.

 

This problem occurs because libstdc ++. so.5 is required for Oracle compilation,

Solution:

 

A: make a soft link sudo ln-S/usr/lib/libstdc ++. so.6/usr/lib/libstdc ++. so.5 (this method can be used in general cases. If this method cannot be used, please refer to it)

 

B: Your libstdc ++. So version is too high, so you need to download libstdc ++. so.5, is attached here: http://packages.ubuntu.com/jaunty/libstdc++5

 

C: Your system has not installed libstdc ++. So. You know what to do.

 

5. after installation, an interface is displayed, prompting you to run two script files orainstroot with the root user. SH and root. sh do not click OK at this time. Open the terminal and use root to log on and execute the command. If you need to install and configure a new database, enter the dbca command in xmanager. In fact, a database is created by default during Oracle Installation, that is, the configured orcl, therefore, dbca is automatically called in the background during the installation process. If no errors occur during the installation process, no errors will occur when dbca is called later.

 

========================================================== ========================================================== ============== Uninstall Oracle, it is very easy to uninstall oracle in Linux. The command is as follows:

 

1. run $ ORACLE_HOME/bin/localconfig Delete

2. rm-RF $ oracle_base /*

3. rm-F/etc/orainst. Loc/etc/oratab

4. rm-RF/etc/Oracle

5. rm-F/etc/inittab.css d

6. rm-F/usr/local/bin/coraenv/usr/local/bin/dbhome/usr/local/bin/oraenv

7. rm-RF $ orcle_home

 

After oracle is installed, tables cannot be created in the database immediately. You must first create a user for the database and specify a tablespace for the user.

 

Log On With sqlplus/nolog

Connect/As sysdba or connect sys/sys password @ database name as sysdba

 

1. if a database named 'News' has been created, the news directory already exists in the/Oracle/product/10.1.0/oradata/directory (Note: My Oracle10g is installed in/Oracle, if your Oracle is installed in another directory, the database directory you created is in the */product/10.1.0/oradata/directory ).

2. Before creating a user, create a tablespace:

The format is: Create tablespace table name datafile 'data filename 'size tablespace size;

For example:

SQL> Create tablespace news_tablespace datafile 'f:/Oracle/product/10.1.0/oradata/news/news_data.dbf 'size 500 m;

'News _ tablespace' is the name of your custom tablespace, which can be named at will; 'f: /Oracle/product/10.1.0/oradata/news/news_data.dbf 'is the data file storage location, 'news _ data. dbf' the file name is also arbitrary; 'size m' specifies the size of the data file, that is, the tablespace size.

 

3. Now the table space named 'news _ tablespace 'has been created. Now you can create a user in the following format: Format: create user username identified by password default tablespace table;

For example:

SQL> create user news identified by news default tablespace news_tablespace;

The default tablespace 'default tablespace' uses the tablespace created above.

 

4. Authorize the new user:

SQL> grant connect, resource to news; -- grants connect and resource permissions to news users.

SQL> grant DBA to news; -- Grant DBA permission to news users

Authorization successful.

OK! The database user has been created. Now you can use this user to create a data table!

 

From: http://bluewind1521.iteye.com/blog/754620

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.