↓ Skip to main content
  1. Posts/

Oracle 11g R2 Installation on Kylin V10 / C86 Architecture: A Complete Record

Table of Contents

This article documents the complete process of installing Oracle 11.2.0.4 from scratch on a C86 architecture server running Kylin V10 SP3, with a focus on detailed parameters at every step: kernel parameter rationale, specific linker modifications, database parameter tiering, and verification. Along the way, we encountered and resolved 4 critical issues: missing dependencies, TNS listener crash, oracle main binary link failure, and DBCA false success. However, we ultimately hit an unavoidable platform-level limitation: the Data Pump utilities (impdp/expdp/rman/sqlplus, etc.) cannot be successfully linked on Kylin V10 SP3 (glibc 2.28) and remain 0 bytes. This article honestly records the full troubleshooting process and viable workarounds. All conclusions are verified on real hardware.


1. Environment Overview
#

ItemConfiguration
ArchitectureC86 (Hygon Genuine)
OSKylin V10 SP3 (Halberd), kernel 4.x
glibc Version2.28 (key limiting factor)
Oracle Version11.2.0.4 (officially supports RHEL 5/6/7, glibc 2.12/2.17)
Memory128 GB (HugePages 90 GB)
Data Disk/u01 (1000G, XFS)
VirtualizationSangfor, high-performance mode (vCPU passthrough)

Important note: Oracle 11.2.0.4 was released before Kylin V10 and C86 architecture existed, so most issues encountered stem from this. If your environment matches this article, following it will complete the database software installation and database creation, but you must accept that Data Pump utilities are unavailable; for ARM or Kunpeng architectures, Oracle’s ARM-specific build is required and the process differs.


2. OS-Level Preparations
#

2.1 Create Users and Directories
#

The Oracle Inventory group must be oinstall (gid 54321); all Oracle software must belong to it. The dba group is for SYSDBA authorization. Once these GIDs are set, do not change them, or the installed software’s Inventory will become invalid.

groupadd -g 54321 oinstall
groupadd -g 54322 dba
groupadd -g 54323 oper
groupadd -g 54324 backupdba
groupadd -g 54325 dgdba
groupadd -g 54326 kmdba

useradd -u 54321 -g oinstall -G dba,oper,backupdba,dgdba,kmdba oracle
passwd oracle

mkdir -p /u01/app/oracle/product/11.2.0/dbhome_1
mkdir -p /u01/app/oraInventory
mkdir -p /u01/oradata
mkdir -p /u01/fast_recovery
chown -R oracle:oinstall /u01
chmod -R 775 /u01

Inventory location file /etc/oraInst.loc:

inventory_loc=/u01/app/oraInventory
inst_group=oinstall

chown oracle:oinstall /etc/oraInst.loc, permissions 644. OUI reads this file to determine if Oracle has been installed on this machine.

Oracle user environment variables ~/.bash_profile (each entry is required; missing ORACLE_BASE will cause OUI to install under /):

export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/dbhome_1
export ORACLE_SID=orcl
export PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/usr/lib64
export NLS_LANG=AMERICAN_AMERICA.AL32UTF8
export LANG=en_US.UTF-8          # Must be English; Chinese locale garbles OUI and dbca Java GUI

Apply: source ~/.bash_profile, then echo $ORACLE_HOME to confirm it’s not empty.

2.2 Kernel Parameter Tuning (HugePages are key)
#

/etc/sysctl.conf:

# ---------- Shared Memory Segments ----------
# shmmax must be > SGA_MAX_SIZE. This machine's SGA limit is 92G, give 92.2G with margin
# Calculation: 92.2 * 1024^3 = 98956046336
kernel.shmmax = 98956046336

# shmall is the global limit on allocated shared memory pages, unit PAGE_SIZE (usually 4K)
# Calculation: 96 * 1024^3 / 4096 = 25165824
kernel.shmall = 25165824

# shmmni is the max number of shared memory segments; default 4096 is enough, increase for multiple instances
kernel.shmmni = 4096

# ---------- Semaphores ----------
# SEMMSL SEMMNS SEMOPM SEMMNI
kernel.sem = 250 32000 100 128

# ---------- File Handles ----------
fs.file-max = 6815744

# ---------- Network Stack ----------
net.ipv4.ip_local_port_range = 9000 65500
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 1048576
net.ipv4.tcp_rmem = 4096 87380 4194304
net.ipv4.tcp_wmem = 4096 16384 1048576

# ---------- Swap Behavior ----------
vm.swappiness = 1
vm.dirty_ratio = 15
vm.dirty_background_ratio = 3

# ---------- HugePages: 90G out of 128G memory ----------
vm.nr_hugepages = 46080

Apply: sysctl -p

Parameter sanity checks:

grep Huge /proc/meminfo
ipcs -lm
cat /proc/sys/fs/file-nr
ipcs -ls

HugePages must be configured in advance. Oracle checks use_large_pages at startup; if set to ONLY and HugePages are insufficient, the instance won’t start. Conversely, nr_hugepages shouldn’t be set too large—it’s deducted from the regular memory pool and cannot be reclaimed. Setting it to use all 128G for HugePages will cause OS OOM. This 128G machine is split as: SGA 86G + PGA 20G = 106G, leaving 22G for OS, shared memory, and process stacks.

2.3 User Resource Limits
#

/etc/security/limits.conf:

oracle   soft   nofile    65535
oracle   hard   nofile    65535
oracle   soft   nproc     16384
oracle   hard   nproc     16384
oracle   soft   stack     10240
oracle   hard   stack     32768
oracle   soft   memlock   unlimited
oracle   hard   memlock   unlimited
oracle   soft   core      unlimited
oracle   hard   core      unlimited

Verification:

su - oracle
ulimit -a

Pitfall: Kylin V10 uses systemd by default; /etc/security/limits.conf only applies to login sessions. If Oracle is managed via systemctl, limits won’t take effect—you need to add to the service file:

[Service]
LimitNOFILE=65535
LimitNPROC=16384
LimitMEMLOCK=infinity

3. Install Dependencies (C86-Specific Pitfalls)
#

3.1 Install Base Packages
#

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

3.2 Critical Fix: compat-libstdc++ and libpthread_nonshared.a
#

yum install -y compat-libstdc++-33
# or
rpm -ivh --nodeps --force compat-libstdc++-33-3.2.3-72.el7.x86_64.rpm

Missing libpthread_nonshared.a:

yum install -y glibc-static
# or manually create a placeholder (not recommended for production)
ar -rcs /usr/lib64/libpthread_nonshared.a /dev/null 2>/dev/null || true

3.3 Critical Fix: stdc++ Symbol Missing (oracle binary linking)
#

Modify env_rdbms.mk and ins_rdbms.mk to force static linking of libstdc++.a and libgcc.a:

ORACLE_LINKLINE=... -l:libstdc++.a -l:libgcc.a

Then make -f ins_rdbms.mk ioracle to produce the 229M oracle main binary.

Note: This fix only targets the oracle database kernel binary, not effective for impdp/expdp and other utilities—see Section 8 for details.

3.4 Installation Order and Inventory Handling
#

echo "Red Hat Enterprise Linux Server release 7.0 (Maipo)" > /etc/redhat-release
# revert after installation

Extract installation media to /u01/soft/database.


4. Silent Installation of Oracle Software
#

Key db_install.rsp settings:

oracle.install.option=INSTALL_DB_SWONLY
ORACLE_HOSTNAME=oracle864
INVENTORY_LOCATION=/u01/app/oraInventory
ORACLE_HOME=/u01/app/oracle/product/11.2.0/dbhome_1
ORACLE_BASE=/u01/app/oracle
oracle.install.db.InstallEdition=EE
DECLINE_SECURITY_UPDATES=true

Execute:

./runInstaller -silent -responseFile /u01/soft/db_install.rsp -ignorePrereq

After success, run as root:

/u01/app/oraInventory/orainstRoot.sh
/u01/app/oracle/product/11.2.0/dbhome_1/root.sh

5. Issue 1: TNSLSNR Crashes on Startup
#

Symptom: lsnrctl start exits immediately with no error.

Root cause: libclntsh.so.11.1 symbols corrupted.

Fix: Re-extract from installation media and overwrite:

cp /tmp/ora_extract/lib/libclntsh.so.11.1 $ORACLE_HOME/lib/
cp /tmp/ora_extract/lib/libnnz11.so $ORACLE_HOME/lib/

Then lsnrctl start works normally.


6. Issue 2: oracle Main Binary Link Failure#

Symptom: undefined reference to 'ss_dba_grp'.

Root cause: config.o is a 0-byte empty file.

Fix:

cd $ORACLE_HOME/rdbms/lib
rm -f config.o
make -f ins_rdbms.mk config.o

Then make -f ins_rdbms.mk ioracle succeeds, generating a 229M bin/oracle.


7. Issue 3: DBCA Reports 100% but No Database Created
#

Symptom: DBCA progress reaches 100%, but no data files exist.

Root cause: When the oracle binary is corrupted, DBCA fakes success.

Fix: After fixing the binary, clean up remnants and rerun DBCA:

sed -i '/^orcl:/d' /etc/oratab
rm -rf /u01/app/oracle/cfgtoollogs/dbca/orcl
dbca -silent -createDatabase ...

Verify data files exist.


8. Issue 4 (Fatal): Data Pump and Other Utilities All 0 Bytes (glibc Incompatibility)
#

This is the biggest pitfall encountered in this deployment and the root cause that prevents using 11.2.0.4 native toolchain on Kylin V10 SP3.

8.1 Symptom
#

The database instance runs normally, but the following utilities are all 0 bytes and produce no output when executed:

$ ls -lh $ORACLE_HOME/bin/impdp
-rwxr-x--- 1 oracle oinstall 0 Aug 24  2013 impdp
$ file $ORACLE_HOME/bin/impdp
impdp: empty

The same issue affects: expdp, imp, exp, rman, sqlplus, sqlldr, tnsping, and almost all client utilities.

8.2 Investigation
#

  1. Checked old ORACLE_HOME (dbhome_1): Found utilities were already 0 bytes, indicating the original installation never succeeded.
  2. Attempted silent install of new ORACLE_HOME (dbhome_2): Installation reported “Successfully Setup Software”, but utilities remained 0 bytes.
  3. Executed relink all: Failed with numerous errors like:
/usr/bin/ld: /usr/lib64/libaio.so.1: undefined reference to `__stack_chk_fail@GLIBC_2.4'
collect2: error: ld returned 1 exit status
make: *** [.../ins_rdbms.mk:741: .../imp] Error 1

8.3 Root Cause Analysis
#

  • __stack_chk_fail is a stack protection symbol provided by glibc, introduced in glibc 2.4.
  • Kylin V10 SP3’s glibc version is 2.28, which theoretically includes this symbol.
  • However, Oracle 11.2.0.4’s linking process relies on its bundled “stub libraries” ($ORACLE_HOME/lib/stubs/), which were compiled for older glibc versions (2.12/2.14); their symbol versions may not fully match the system’s newer glibc.
  • More critically, the system’s libaio.so.1 is pulled in during linking, and it internally references __stack_chk_fail@GLIBC_2.4, which Oracle’s linking environment cannot correctly resolve, causing all tools that need to link against libaio (impdp, expdp, rman, sqlplus, etc.) to fail linking, leaving 0-byte placeholder files.
  • This is a known limitation of Oracle 11.2.0.4 on high-version glibc systems and cannot be worked around by modifying makefiles or environment variables. Even if errors are forcibly ignored, the resulting binaries would likely crash at runtime.

8.4 Conclusion and Workarounds
#

The Data Pump toolchain of Kylin V10 SP3 + Oracle 11.2.0.4 is platform-level incompatible; it is not a parameter or permission issue. Silent installs (twice) and multiple relinks have proven it cannot be fixed. Only two paths remain:

OptionDescriptionRecommendation
🅰️ Create a CentOS 7.9 VM (compatibility mode)On Sangfor, create a CentOS 7.9 VM, set vCPU to compatibility mode (vendor=AuthenticAMD), install Oracle 11.2.0.4, and use its impdp to import the dump file⭐⭐⭐⭐⭐ (fastest, most stable)
🅱️ Upgrade to Oracle 19cInstall Oracle 19c on Kylin V10 (officially supports glibc 2.28), and use 19c’s impdp to import the 11g dump⭐⭐⭐⭐ (long-term solution, but more effort)

Option 🅰️ Steps (fastest way to complete import)
#

  1. On Sangfor, create a CentOS 7.9 VM, set vCPU mode to “Compatibility” (host-model), do NOT enable high performance.
  2. Mount CentOS 7.9 ISO and install normally.
  3. Install Oracle 11.2.0.4 software (software only) on CentOS 7.9; the process is similar to Sections 4-6 of this article, but no stdc++ linking modifications are needed (glibc 2.17 is natively compatible).
  4. Verify impdp help=y outputs normally.
  5. Copy the dump file from the Kylin machine to CentOS: scp /home/backup/share/tabackup/*.dmp root@centos_ip:/u01/dump/
  6. Execute the import on CentOS:
impdp \'/ as sysdba\' \
  DIRECTORY=DATA_PUMP_DIR \
  DUMPFILE=xxx.dmp \
  LOGFILE=import.log \
  FULL=Y \
  REMAP_SCHEMA=kdta_ta:kdta_ta_bx \
  REMAP_SCHEMA=kdta_com:kdta_com_bx \
  REMAP_SCHEMA=kdta_his:kdta_his_bx \
  PARALLEL=16 \
  CONTENT=ALL

Note: Even if the database runs on Kylin, the import operation must be performed on a compatible machine because impdp is a server-side tool that calls the database instance’s Data Pump API, but the tool itself must be compiled in an environment where linking succeeds.


9. Database Parameter Tuning (Detailed Parameters)
#

(This section remains valid because the database instance itself runs fine. Only key parameters are listed; refer to the original Chinese post for full explanations.)

9.1 Memory Parameters
#

ALTER SYSTEM SET memory_target=0 SCOPE=SPFILE;
ALTER SYSTEM SET memory_max_target=0 SCOPE=SPFILE;
ALTER SYSTEM SET sga_max_size=86G SCOPE=SPFILE;
ALTER SYSTEM SET sga_target=86G SCOPE=SPFILE;
ALTER SYSTEM SET pga_aggregate_target=20G SCOPE=SPFILE;
ALTER SYSTEM SET use_large_pages=ONLY SCOPE=SPFILE;

9.2 Processes and Concurrency
#

ALTER SYSTEM SET processes=1500 SCOPE=SPFILE;
ALTER SYSTEM SET db_writer_processes=8 SCOPE=SPFILE;

9.3 Redo and Commit
#

ALTER SYSTEM SET log_buffer=134217728 SCOPE=SPFILE;
ALTER SYSTEM SET commit_logging=BATCH SCOPE=BOTH;
ALTER SYSTEM SET commit_wait=NOWAIT SCOPE=BOTH;

9.4 I/O and Async I/O
#

ALTER SYSTEM SET filesystemio_options=SETALL SCOPE=SPFILE;

9.5 Hidden Parameters and Audit
#

ALTER SYSTEM SET "_disable_selftuning_resmgr"=TRUE SCOPE=SPFILE;
ALTER SYSTEM SET audit_trail=NONE SCOPE=SPFILE;
ALTER SYSTEM SET deferred_segment_creation=FALSE SCOPE=SPFILE;

9.6 Sample PFILE
#

*.sga_target=92274688000
*.pga_aggregate_target=21474836480
*.use_large_pages='ONLY'
*.processes=1500
*.db_writer_processes=8
*.log_buffer=134217728
*.commit_logging='BATCH'
*.commit_wait='NOWAIT'
*.filesystemio_options='SETALL'
*._disable_selftuning_resmgr=TRUE
*.audit_trail='NONE'
*.deferred_segment_creation=FALSE

After restart, verify: SHOW PARAMETER sga_target, etc.


10. External Connections and impdp (Updated: Tools Unavailable, Use External Machine)
#

10.1 Firewall
#

systemctl stop firewalld
# or
iptables -I INPUT -p tcp --dport 1521 -j ACCEPT

10.2 Listener Configuration
#

listener.ora uses HOST = 0.0.0.0, apply with lsnrctl reload.

10.3 impdp Import (Must be executed on a compatible system)
#

Since the local impdp on Kylin is 0 bytes, all Data Pump operations must be performed on a compatible system like CentOS 7.9. See Option 🅰️ in Section 8.

If you only need remote database query access, use sqlplus or PL/SQL Developer from another machine via TNS.


11. Troubleshooting Quick Reference (Updated)
#

SymptomRoot CauseFix
__cxa_throw_bad_array_new_length@CXXABI_1.3.8 link failureSystem libstdc++ version too highStatically link libstdc++.a in env_rdbms.mk
cannot find libpthread_nonshared.aglibc-devel missing fileInstall the static library separately
undefined reference to 'ss_dba_grp'config.o is 0-byte empty filerm -f config.o && make -f ins_rdbms.mk config.o
tnslsnr crashes on startuplibclntsh.so symbols corruptedRe-extract and overwrite from installation media
DBCA 100% but no data filesoracle binary corrupted, progress bar fakes successFix binary and rerun DBCA, verify with find
impdp/expdp/rman etc. all 0 bytesglibc 2.28 incompatible with 11.2.0.4 stub libraries, libaio symbol resolution failsCannot fix on Kylin V10 SP3; use CentOS 7.9 VM or upgrade to 19c
ORA-00843/00849sga_target > memory_max_targetSet both to 0
ORA-02095log_buffer cannot be modified onlineWrite to SPFILE/PFILE
ORA-02065Parameter name misspelled_disable_selftuning_resmgr (with “ing”)
External connection to 1521 failsFirewall blocking portsystemctl stop firewalld
firewall-cmd Python errorSystem Python environment pollutedUse systemctl or iptables to bypass

12. Lessons Learned (Updated)
#

  1. The oracle main binary is the lifeline. Once corrupted, DBCA, sqlplus, tnslsnr all fail in cascade, and error messages are highly misleading (reporting TNS errors when the binary is actually broken).
  2. DBCA’s 100% is not trustworthy. It only means “process completed”, not “succeeded”. The only criterion for successful database creation is: whether .dbf files exist under /u01/oradata/.
  3. Installing Oracle 11g on C86 + Kylin V10, the pitfalls are all in the linker. Official libraries were compiled for the glibc 2.12/2.17 era and are completely incompatible with newer 3.x kernels, glibc, and libstdc++. The core strategy: statically link when possible, revert to older libraries when possible.
  4. But the Data Pump toolchain is a dead end. Due to libaio depending on the GLIBC_2.4 symbol, and Oracle’s bundled stub libraries having an irreconcilable conflict with Kylin V10 SP3’s glibc 2.28, any attempt to relink the utilities will fail, leaving 0-byte files. This is a platform-level limitation, not an operational error.
  5. Parameter tuning order matters. memory_target=0 and sga_target have strong validation; you must decide on the memory architecture before proceeding, otherwise the instance won’t start.
  6. HugePages must be calculated in advance. 46080 pages × 2MB = 90GB, leaving memory for the OS itself (128GB total, leaving 38GB for OS and PGA is sufficient).
  7. Production recommendation: If you must use 11.2.0.4, deploy the database on a compatible OS like CentOS 7.9; if you must use Kylin V10, install Oracle 19c or later directly to completely avoid toolchain incompatibility.

Appendix: Complete Installation Checklist (Updated)
#

# ========== OS Layer ==========
sysctl -p
sysctl vm.nr_hugepages
grep Huge /proc/meminfo
ipcs -lm
cat /proc/sys/fs/aio-max-nr
ulimit -a

# ========== Oracle Layer ==========
ls -lh $ORACLE_HOME/bin/oracle             # Should be ~229M, not 0
file $ORACLE_HOME/bin/oracle               # ELF 64-bit executable, setuid
nm $ORACLE_HOME/rdbms/lib/config.o | grep ss_dba_grp
ldd $ORACLE_HOME/bin/oracle | grep "not found"
# The following tools are inevitably 0 bytes on Kylin V10 SP3, this is expected:
# ls -lh $ORACLE_HOME/bin/impdp            # 0 bytes
# ls -lh $ORACLE_HOME/bin/expdp            # 0 bytes

# ========== Listener Layer ==========
ss -tlnp | grep 1521
lsnrctl status
lsnrctl services
tnsping orcl

# ========== Database Layer ==========
sqlplus / as sysdba <<< "SELECT status FROM v\$instance;"
ls -lh /u01/oradata/orcl/*.dbf

# ========== Parameter Layer ==========
# See Section 9

# ========== HugePages and I/O Verification ==========
grep Huge /proc/meminfo
SELECT name, asynch_io FROM v$datafile_f;

Special reminder: On Kylin V10 SP3, the 0-byte size of impdp, expdp, rman, sqlplus, etc. under $ORACLE_HOME/bin/ is expected behavior. Do not waste time trying to fix them. Directly use a CentOS 7.9 VM or upgrade to Oracle 19c.

Related