onspaces 功能可以创建dbspace或临时dbspace,命令选项如下所示。
-c 表明操作为创建dbspace
-d spacename 指定创建的新dbspace 的名称
-m pathname offset 镜像的路径名和偏移量
-o offset 初始chunk在设备中的偏移量,以KB计算
-p pathname 初始chunk所在的磁盘分区名或设备名
-s size 初始chunk的大小,以KB计算
-t 指定该dbspace为临时dbspace
以下例子为创建一个镜像dbspace,名为dbspace1,大小为100000KB,使用裸设备/dev/rdsk/device1,偏移量为200000,原镜像dbspace位于裸设备/dev/rdsk/device2,偏移量为450000:
onspaces -c -d dbspace1 -p /dev/rdsk/device1 -o 200000 -s 100000 -m /dev/rdsk/device2 450000
以下例子为创建一个临时dbspace,名为tempdbs1,大小为500000,使用裸设备/dev/rdsk/device9,偏移量为100000:
onspaces -c -t -d tempdbs -p /dev/rdsk/device9 -o 100000 -s 500000