Aix5.3 use bare devices to install oracle10g in the system -- 4 K offset problem

Source: Internet
Author: User
Today, when a friend installed oracle10g Database creation on the aix5.3 system with a bare device, dbca database creation to 2% reports an error and exits. Observe the alert Log and find that the temp tablespace space is insufficient. View the bare settings of the tablespace Data File

Today, when a friend installed oracle10g Database creation on the aix5.3 system with a bare device, dbca database creation to 2% reports an error and exits. Observe the alert Log and find that the temp tablespace space is insufficient. View the bare settings of the tablespace Data File

Today, when a friend installed oracle 10 Gb database on the aix 5.3 system using a bare device, dbca database creation to 2% reports an error and exits. Observe the alert Log and find that the temp tablespace space is insufficient. Check that the raw device capacity of the tablespace data file is 512 MB, and the size of the data file given during database creation is also 512 MB. It may be because the aix system is calculated in decimal order, while the oracle database computing capacity is in decimal order, which leads to a gap. If the oracle data file size is changed to 1000 MB, the system will pass normally.

However, the following prompt appears in alert logs: warning: You are creating datafile/dev/temp01.
WARNING: Oracle recommends creating new datafiles on devices with zero offset. the command "/usr/sbin/mklv-y LVname-t o-w n-s n-r n VGname NumPPs" can be used. please contact Oracle customer support for more details. By querying information and help from friends, I finally found the cause of the problem and got a solution.

When creating an AIX vg, there are three optional vg types: Original Volume Group, Big Volume Group, and Scalable Volume Group.
For an ordinary VG (Original Volume Group), No matter what command you use to create an lv, it is a common DS_LV Type LV.
For Big VG, it is the only VG that allows both types of LV to exist at the same time. If we specify-t o (Note: Here is the uppercase letter O ), create an lv of the DS_LVZ type. Otherwise, create a LV of the common type. For example
/Usr/sbin/mklv-y LVname-t o-w n-s n-r n VGname NumPPs.
For the VG type of Scalable-type VG, no matter how you use the command to create the lv, it is an extended DS_LVZ type LV.
From the warning log of Oracle, we can see that when Oracle uses raw devices, it is recommended to set a lv without 4 K.

AIX calls this 4 K offset lvcb (logical volume control block), which occupies the first 512 bytes of 4 K. It is similar to the Oracle data file header and retains the creation time of lv, image copy information and file system mount points.

Check whether the lv has a 4 K offset in two ways.
1. Host Layer
No 4 K offset:

Reference

# Lslv jfkdb_2G_044
Logical volume: jfkdb_2G_044 volume group: jfk_dbvg_01
Lv identifier: 00c3dff400004c00000001217a9d839e. 84 PERMISSION: read/write
Vg state: active/complete lv state: closed/syncd
TYPE: raw write verify: off
MAX LPs: 1024 pp size: 32 megabyte (s)
COPIES: 1 sched policy: parallel
LPs: 64 PPs: 64
STALE PPs: 0 bb policy: relocatable
INTER-POLICY: maximum RELOCATABLE: yes
INTRA-POLICY: middle upper bound: 1024
Mount point: N/a label: None
Mirror write consistency: on/ACTIVE
Each lp copy on a separate pv? : Yes
Serialize IO? : NO
DEVICESUBTYPE: DS_LVZ


4 K offset:

Reference

[Root @ jfk_p560q/] # lslv jfkdb_2G_044
Logical volume: jfkdb_2G_044 volume group: jfk_db_vg01
Lv identifier: 00ce76demo-4c00000001134ee6bc51. 84 PERMISSION: read/write
Vg state: active/complete lv state: opened/syncd
TYPE: raw write verify: off
MAX LPs: 1024 pp size: 32 megabyte (s)
COPIES: 1 sched policy: parallel
LPs: 64 PPs: 64
STALE PPs: 0 bb policy: relocatable
INTER-POLICY: maximum RELOCATABLE: yes
INTRA-POLICY: middle upper bound: 16.
Mount point: N/a label: None
Mirror write consistency: on/ACTIVE
Each lp copy on a separate pv? : Yes
Serialize IO? : NO


(2) Oracle:
Oracle provides a small tool dbfsize (under $ ORACLE_HOME/bin) to check whether the lv has a 4 K offset.
No 4 K offset:

Reference

$ Dbfsize/dev/rlvsysaux_1g

Database file:/dev/rlvsysaux_1g
Database file type: raw device without 4 K starting offset
Database file size: 40960 8192 byte blocks


4 K offset:

Reference

[Oracle @ jfk_p560q/dev] $ dbfsize/dev/mongofkdb_2g_054

Database file:/dev/mongofkdb_2g_054
Database file type: raw device
Database file size: 262016 8192 byte blocks



If the database uses a block size of 16 k, create an lv with a 4 k offset across PVS, and the size of the striped block is 64 k. This will cause 4th blocks to span two PVS (striping operation, and calculation of lvcb into the Strip block ). This will cause
Strip block of the 4th Oracle block across the disk, regardless of performance considerations, if the system is abnormal down, or the storage is abnormal down, it is very easy to cause database block damage, cause ora-01578 error. (Metalink ID 261460.1)

Reference

$ Oerr ora 1, 01578
01578,000 00, "ORACLE data block upload upted (file # % s, block # % s )"
// * Cause: The data block indicated was has upted, mostly due to software
// Errors.
// * Action: Try to restore the segment containing the block indicated. This
// May involve dropping the segment and recreating it. If there
// Is a trace file, report the errors in it to your ORACLE
// Representative.

That is to say, when Original Volume Group is used, the parameter cannot be used to cancel the 4 k offerset. The only way is to set the db_block_size of the oracle database to 4 k. (Not recommended)

When using big VG, you can create a lv of the DS_LVZ type by adding the-T-O parameter to the LV by creating the LV, thus canceling the offset of the previous 4 K. (However, it is said that big vg has known bugs and is not recommended for use ).

In contrast, the Scalable-type VG type does not have a 4 K offset when creating an LV, and supports more pp and the maximum file capacity. (Recommended)


This article is from the blog "DBA life with culture hooligans". For more information, contact the author!

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.