分类: 服务器与存储
2008-06-06 06:26:43
安装前介绍
2.1 概述
在安装DataWare之前,用户必须明确了解哪些关键业务需要DataWare管理。以下是安装DataWare双机系统前必须了解的一些基本事项。
1. 服务器运行必备的软件和硬件。
2. 服务器双机工作模式(Dual Active或Hot Standby)。
3. 磁盘子系统配置信息。
4. 本地磁盘和公共磁盘所需的磁盘空间。
5. 在磁盘阵列系统上的RAID级别设定。
6. 初始化文件”dw.dfg”的准备工作。
7. 启动和停止业务应用的程序。
2.2 最基本硬件需求
硬件配置
Dual Active模式
两台UNIX服务器
服务器内存至少16MB
每台服务器至少两块网卡
每台服务器配有一个SCSI接口(Fast SCSI、Wide、Ultra wide)
一个磁盘阵列系统(必须有双SCSI端口)。
在磁盘阵列系统中至少三块硬盘,三块工作盘作为一个逻缉磁盘设备。
Hot Standby模式
两台UNIX服务器
服务器内存至少16MB
每台服务器至少一块网卡
每台服务器必须有一个SCSI接口(Fast SCSI、Wide、Ultra Wide)
一个磁盘阵列系统(必须有双SCSI端口)
在磁盘阵列系统中至少三块硬盘,三块工作盘作为一个逻缉磁盘设备。
2.3 DataWare软件的发行介质
要运行DataWare系统,你必须有DataWare系统软盘。DataWare系统适合互备援模式和热备模式,两种模式之间区别就在于配置信息,关于设置的细节将在第三章讨论。
DataWare系统软件存储在一张磁盘上,它包含以下文件:
1. dwinst ── 安装程序
2. cfg.a ── A机配置信息模板文件
3. cfg.b ── B机配置信息模板文件
4. waredata ── 包括所有系统程序(DataWare的核心)
5. install.doc ── 简要系统安装指导
这些文件以UNIX系统”tar”格式存储,你可以用下面的命令检查软件包含的内容。
tar tvf /dev/xxx
其中”dev/xxx”是UNIX系统中软盘的设备文件名。
关于cfg.a和cfg.b中配置信息的描述语法将在第三章讨论。
2.4 磁盘系统准备
当我们明确运行DataWare的基本条件后时,就可以开始磁盘系统的挂接工作,首先必须去作RAID设置。RAID设置的主要目的是规划磁盘存储空间,例如:设置RAID级别,作Array组到Lun的映射。关于RAID设置,请参考“双机容错硬件培训“。
在RAID设置和初始化完成后,你可以将RAID系统挂接到服务器上。创建的文件系统路径和设备文件名称将决定DataWare的某些配置信息。
在DataWare双机容错系统中,数据库空间全部在磁盘阵列柜RAID逻辑盘中。为了利用该数据空间,需要在UNIX操作系统上创建磁盘阵列柜RAID逻辑盘的设备文件名。
系统进入单用户,运行“mkdev hd”,准备制作逻辑盘分区
# mkdev hd
Your rootdisk is attached to a SCSI controller.
Pick one of choices below or you may quit and
Invoke nkdev hd -u for a detailed usage message.
1) Add a hard disk to IDE controller
2) Add a hard disk to SCSI controller
3) Add a hard disk to IDA controller
Enter 1, 2, 3 or enter ‘q’ to quit: 2 →选择2
Enter the prefix of the SCSI host adapter that supports this device
Or press
Enter h for a list of host adapters or enter q to quit:
Which ‘alad’ SCSI host adapter supports this device?
Select 0-6, or enter q to quit: 0 →选择SCSI卡号
The Host Adapter paramters will be automatically configured
What SCSI Bus is this device attached to?
Press
Select 0-n, or h for help, or q to quit: →选择SCSI总线号
What is the Target ID for this device?
Select 0-15, or h for help, or q to quit:2 →选择设备的ID号
What is the LUN of this device?
Press
Select 0-7, or h for help, or q to quit:0 →选择LUN号
硬盘挂接到操作系统,准备重构系统核心
You are about to add the following SCSI device:
Host
Adapter Adapter
Type Device Number ID LUN BUS
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
alad Sdsk 0 2 0 0
Update SCSI configuration? (y/n) y
The SCSI configuration file has been updated.
A new kernel must be built and rebooted before disk configuration can continue
Would you like to relink at this time? (y/n) y
The UNIX Operating System will now be rebuilt.
This will take a few minutes. Please wait.
Root for this system build is /
The UNIX kernel has been rebuilt.
Do you want this kernel to boot by default? (y/n) y
Backing up unix to unix.old
Installing new unix on the boot file system.
The kernel environment includes device node files and /etc/inittab.
The new kernel may require changes to /etc/inittab or device nodes.
Do you want the kernel environment rebuilt? (y/n) y
The kernel has been successfully linked and installed.
To activate it, reboot your system.
Setting up new kernel environment.
After the system is rebooted with the new kernel,
Reinvoke mkdev hd to initialize the new hard disk.
#
重新启动系统,使新系统核心生效
# sync;sync; reboot
进入单用户模式,再次运行硬盘加载命令
# mkdev hd
Your rootdisk is attached to a SCSI controller.
Pick one of choices below or you may quit and
Invoke nkdev hd -u for a detailed usage message.
1) Add a hard disk to IDE controller
2) Add a hard disk to SCSI controller
3) Add a hard disk to IDA controller
Enter 1, 2, 3 or enter ‘q’ to quit: 2 →选择2
Enter the prefix of the SCSI host adapter that supports this device
Or press
Enter h for a list of host adapters or enter q to quit:
Which ‘alad’ SCSI host adapter supports this device?
Select 0-6, or enter q to quit: 0 →选择SCSI卡号
The Host Adapter paramters will be automatically configured
What SCSI Bus is this device attached to?
Press
Select 0-n, or h for help, or q to quit: →选择SCSI总线号
What is the Target ID for this device?
Select 0-15, or h for help, or q to quit:2 →选择设备的ID号
What is the LUN of this device?
Press
Select 0-7, or h for help, or q to quit:0 →选择LUN号
During installation you may choose to overwrite all
Or part of the present contents of your hard disk.
Do you wish to continue? (y/n) y →选择“y”
准备对增加的硬盘进行逻辑分区
The hard disk installation program will now invoke /etc/fdisk.
Entering ‘q’ at the following menu will exit /etc/fdisk,
And the hard disk installation will continue.
If you wish to exit the entire installation at this menu,
Press the ; key.
1. Display Partition Table
2. Use Entire Disk for Unix
3. Use Rest of Disk for Unix
4. Creat UNIX Partitin
5. Activate Partition
6. Delete Partition
7. Create Partition
Enter your choice or ‘q’ to quit: 2 →选择2
Current Hard Disk Drive: /dev/rdsk/3s0
+------------+---------+--------+--------+-------+---------+
| Partition | Status | Type | Start | End | Size |
+------------+---------+--------+--------+--------+--------+
| 1 | Active | UNIX | 1 | 528359 | 528359 |
+------------+---------+--------+--------+--------+--------+
Total disk size: 528615 tracks (256 reserved for masterboot and diagnostics)
Press
1. Display Partition Table
2. Use Entire Disk for Unix
3. Use Rest of Disk for Unix
4. Creat UNIX Partitin
5. Activate Partition
6. Delete Partition
7. Create Partition
Enter your choice or ‘q’ to quit: q →选择q
对于新创建的硬盘分区, 必须进行磁盘扫描,以保证数据空间的安全可靠
SCSI VERSION = 2
Vendor = MEGAR1 D
Product = LOGICAL DRIVE 1
1. Scan entire UNIX Partition
2. Scan a specified range of blocks
3. Scan a specified filesystem
4. List current bad block table
5. Add entries to bad block table
6. Delete entries from bad block table
7. Clear bad block table
8. Re-allocate bad blocks
Enter your choice or ‘q’ to quit: q →选择1
Select type of scan .
1. Thorough scan (6 Mbytes/min approx)
2. Quick scan (18 Mbytes/min approx)
Enter your choice or ‘q’ to quit: 2 →选择2
Do you want this to be a destructive scan ? (y/n) y →选择y
The contents of the region you are scanning will be destroyed.
Do you wish to continue ? (y/n) y →选择y
Scanning in progress, type < DEL>; to quit at any time
Scanning block xxxxxx, 15% complete, bad block count = 0.
0 bad blocks have been found.
Enter the number of bad blocks to allocate space for
Or press < Return >; to use the exising value of 511. →选择回车
WARNING: changing the value will remove all filesystem to this partion:0
当完成100%,并且bad block count为 0时,表示整个UNIX分区没有坏块,已经准备就绪。
盘分区并命名
+-------------------+-------------------+--------------+--+------------------+-----------------------+
| Name | Type | New FS | # | First Block | Last Block |
+-------------------+-------------------+--------------+--+------------------+-----------------------+
| ware | NON FS | no | 0 | 0 | 5000 |
| pp0 | NON FS | no | 1 | 8000 | 2008000 |
| pp1 | NON FS | no | 2 | 2008001 | 4008000 |
| pp2 | NON FS | no | 3 | 4008001 | 6008000 |
| dd2 | HTFS | yes | 4 | 6008001 | 16000000 |
| | NOT USED | no | 5 | - | - |
| | NOT USED | no | 6 | - | - |
| hd1a | WHOLE DISK | no | 7 | 0| 16643307 |
+-------------------+-------------------+--------------+--+------------------+-----------------------+
16635307 1K blocks for divisions, 8001 1K blocks reserved for the system
n[ame] Name or rename a division.
c[reate] Create a new file system on this division.
t[ype] Select or change filesystem type on new filesystems.
p[revent] Prevent a new file system from being created on this division.
s[tart] Start a division on a different block.
e[nd] End a division on a different block.
r[estore] Restore the original division table.
Enter your choice or q to quit: _
i[nstall] Install the division set-up shown
r[eturn] Return to the previous menu
e[xit] Exit without installing a division table
Please enter your choice: I →选择 i
说明:
ware :UNIX裸设备,作为DataWare软件侦听监控专用区
pp0, pp1, pp2 :UNIX裸设备,作为数据库存储专用设备
dd2 :UNIX块设备,作为DataWare软件安装测试用文件系统
在对个分区命名及定义文件系统类型后,准备制作测试用文件系统“/dd2”
Filesystem Initialization Program
This program performs maintenance tasks required to add or delete
An existing filesystem . Would you like to:
1.Add a new filesystem to system
2.Remove a filesystem.
Select an option or enter q to quit: 1 →选择 1
Enter a device name and press
Enter a directory name and press
Reserving slots in lost+found directory . . .
When entering multiuser mode:
1. Always mount /dev/dd2
2. Never mount /dev/dd2
3. Prompt before mounting /dev/dd2
Select an option: 2 →选择 2
Do you want to allow users to mount this file systems? (y/n) y
Updating system files . . .
Filesystem has been successfully added.
#