Oracle-XE手工创建数据库
先是用Oracle-xe创建数据库(用root)。rpm -ivh oracle-xe-univ-10.2.0.1-1.0.i386.rpm完成之后会创建oracle.dba。基本的配置:
先是用Oracle-xe创建数据库(用root)。
rpm -ivh oracle-xe-univ-10.2.0.1-1.0.i386.rpm
完成之后会创建oracle.dba。
基本的配置:
/etc/init.d/oracle-xe configure
这时就可以su - oracle
配置环境变量。
重点是你的sid
cat .bash_profile
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
PATH=$PATH:$HOME/bin
export PATH
export LANG=zh_CN.UTF-8
export ORACLE_HOME=/usr/lib/oracle/xe/app/oracle/product/10.2.0/server
export ORACLE_BASE=/usr/lib/oracle/xe/app/oracle
export ORACLE_SID=xxxxxxxxxx
export PATH=$PATH:$ORACLE_HOME/bin
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/usr/lib
export NLS_LANG="SIMPLIFIED CHINESE_CHINA.AL32UTF8"
修改初始化文件
cat /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/dbs/init$ORACLE_SID.ora
aq_tm_processes=0
audit_file_dest=$ORACLE_BASE/admin/$ORACLE_SID/adump
background_dump_dest=$ORACLE_BASE/admin/$ORACLE_SID/bdump
compatible=10.2.0.1.0
control_files=$ORACLE_BASE/oradata/$ORACLE_SID/control01.ctl, $ORACLE_BASE/oradata/$ORACLE_SID/
control02.ctl, $ORACLE_BASE/oradata/$ORACLE_SID/control03.ctl
core_dump_dest=$ORACLE_BASE/admin/$ORACLE_SID/cdump
db_block_size=8192
db_domain=""
db_file_multiblock_read_count=16
db_name=$ORACLE_SID
instance_name=$ORACLE_SID
dispatchers="(PROTOCOL=TCP) (SERVICE=$ORACLE_SIDXDB)"
job_queue_processes=10
nls_length_semantics=BYTE
open_cursors=300
pga_aggregate_target=94371840
processes=150
remote_login_passwordfile=EXCLUSIVE
resource_manager_plan=""
sessions=170
sga_target=285212672
undo_management=AUTO
undo_retention=900
undo_tablespace=UNDOTBS1
user_dump_dest=$ORACLE_BASE/admin/$ORACLE_SID/udump
###有了这个配置,在sqlplus里面startup的时候就会把系统日志写到$ORACLE_BASE/admin/$ORACLE_SID/bdump 。
创建必要的目录(可以参考/usr/lib/oracle/xe/app/oracle/product/10.2.0/server/config/scripts/):XE.sh
mkdir -p /usr/lib/oracle/xe/app/oracle/admin/$ORACLE_SID/adump
mkdir -p /usr/lib/oracle/xe/app/oracle/admin/$ORACLE_SID/bdump
mkdir -p /usr/lib/oracle/xe/app/oracle/admin/$ORACLE_SID/cdump
mkdir -p /usr/lib/oracle/xe/app/oracle/admin/$ORACLE_SID/dpdump
mkdir -p /usr/lib/oracle/xe/app/oracle/admin/$ORACLE_SID/pfile
mkdir -p /usr/lib/oracle/xe/app/oracle/admin/$ORACLE_SID/udump
mkdir -p /usr/lib/oracle/xe/app/oracle/admin/cfgtoollogs/dbca/$ORACLE_SID
mkdir -p /usr/lib/oracle/xe/app/oracle/admin/$ORACLE_SID/dbs
mkdir -p /usr/lib/oracle/xe/app/oracle/flash_recovery_area
mkdir -p /usr/lib/oracle/xe/oradata/$ORACLE_SID
mkdir -p /usr/lib/oracle/xe/app/oracle/oradata/$ORACLE_SID/
创建建库用的sql脚本:
cat createdb.sql
CREATE DATABASE ctetl
MAXINSTANCES 1
MAXLOGHISTORY 1
MAXLOGFILES 5
MAXLOGMEMBERS 5
MAXDATAFILES 100
DATAFILE '/usr/lib/oracle/xe/app/oracle/oradata/ctetl/system01.dbf' size 50M reuse autoextend on next 1m maxsize unlimited extent management local
sysaux datafile '/usr/lib/oracle/xe/app/oracle/oradata/ctetl/sysaux01.dbf' size 100m
UNDO TABLESPACE UNDOTBS DATAFILE '/usr/lib/oracle/xe/app/oracle/oradata/ctetl/undotbs01.dbf' size 50M
AUTOEXTEND ON NEXT 5120K MAXSIZE UNLIMITED
DEFAULT TEMPORARY TABLESPACE tempts TEMPFILE '/usr/lib/oracle/xe/app/oracle/oradata/ctetl/temp01.dbf' size 50M
CHARACTER SET US7ASCII
NATIONAL CHARACTER SET AL16UTF16
LOGFILE GROUP 1 ('/usr/lib/oracle/xe/app/oracle/oradata/ctetl/redo01.log') size 100M,
GROUP 2 ('/usr/lib/oracle/xe/app/oracle/oradata/ctetl/redo02.log') size 100M,
GROUP 3 ('/usr/lib/oracle/xe/app/oracle/oradata/ctetl/redo03.log') size 100M;
现在就是创建数据库了。
###注意从装好rpm包到现在使用的都应该是oracle用户。
sqlplus "/as sysdba"
SQL> startup nomount
SQL> @/usr/lib/oracle/xe/createdb.sql
SQL> create user USER identified by PASSWD default tablespace users;
SQL> grant resource,connect,dba to ctetl;
@/usr/lib/oracle/xe/app/oracle/product/10.2.0/server/rdbms/admin/catalog.sql
@/usr/lib/oracle/xe/app/oracle/product/10.2.0/server/rdbms/admin/catproc.sql
更多Oracle相关信息见Oracle 专题页面 ?tid=12

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

In 2025, global digital virtual currency trading platforms are fiercely competitive. This article authoritatively releases the top ten digital virtual currency trading platforms in the world in 2025 based on indicators such as transaction volume, security, and user experience. OKX ranks first with its strong technical strength and global operation strategy, and Binance follows closely with high liquidity and low fees. Platforms such as Gate.io, Coinbase, and Kraken are at the forefront with their respective advantages. The list covers trading platforms such as Huobi, KuCoin, Bitfinex, Crypto.com and Gemini, each with its own characteristics, but investment should be cautious. To choose a platform, you need to consider factors such as security, liquidity, fees, user experience, currency selection and regulatory compliance, and invest rationally

PrimeFactor−Innumbertheory,theprimefactorsofapositiveintegeraretheprimenumbersthatdividethatintegerexactly.Theprocessoffindingthesenumbersiscalledintegerfactorization,orprimefactorization.Example−Primefactorsof288are:288=2x2x2x2x2

Ranking of the top ten virtual currency trading platforms (latest in 2025): Binance: Global leader, high liquidity, and regulation has attracted attention. OKX: Large user base, supports multiple currencies, and provides leveraged trading. Gate.io: A senior exchange, with a variety of fiat currency payment methods, providing a variety of trading pairs and investment products. Bitget: Derivatives Exchange, high liquidity, low fees. Huobi: An old exchange that supports a variety of currencies and trading pairs. Coinbase: A well-known American exchange, strictly regulated. Phemex and so on.

Top 10 digital currency trading platforms: 1. OKX, 2. Binance, 3. Gate.io, 4. Huobi Global, 5. Kraken, 6. Coinbase, 7. KuCoin, 8. Bitfinex, 9. Crypto.com, 10. Gemini, these exchanges have their own characteristics, and users can choose the platform that suits them based on factors such as security, fees, currency selection, user interface and customer support.

This article recommends ten digital currency trading apps: 1. OKX; 2. Binance; 3. Gate.io; 4. Huobi Global; 5. Kraken; 6. Coinbase; 7. KuCoin; 8. Crypto.com; 9. Bitfinex; 10. Poloniex. When choosing a platform, you need to consider factors such as security, liquidity, transaction fees, currency selection, user interface, customer service support and regulatory compliance, and carefully evaluate risks and never blindly follow the trend.

This article provides Android and Apple mobile APP download methods for mainstream digital currency trading platforms such as Binance, OKX, Gate.io, Huobi Global, Coinbase, KuCoin, Kraken and Bitfinex. Whether it is an Android user or an Apple user, you can easily find the official APP download link for the corresponding platform and complete the installation according to the steps. The article provides detailed guidance on searching and downloading on their respective official websites or app stores, and provides instructions on the special steps for installing APK files on Android, so that users can download and use them quickly and easily.

Reliable digital currency platforms include: 1. OKX, 2. Binance, 3. Gate.io, 4. Huobi Global, 5. Kraken, 6. Coinbase, 7. KuCoin, 8. Bitfinex, 9. Crypto.com, 10. Gemini. These exchanges have their own characteristics. Users can choose the platform that suits them based on factors such as security, fees, currency selection, user interface and customer support.

The rankings of the top ten virtual currency trading platforms are: 1. OKX; 2. Binance; 3. Gate.io; 4. Huobi Global; 5. Kraken; 6. Coinbase; 7. KuCoin; 8. Crypto.com; 9. Bitfinex; 10. Gemini. The ranking is based on comprehensive considerations such as platform liquidity, currency selection, security, user experience, handling fees and compliance, but is for reference only. Investment should be cautious and at your own risk.
