Sybase数据库添加磁盘空间报错官方分析
Sybase创建设备报错的故障分析
???? 在日志空间满了的处理过程中,执行disk init失败的报错,官方给出的可能原因和分析方案:
Error 5123
Severity
16
Error message text(错误消息)
???? DISK INIT encountered an error while attempting to open/create the physical file. Please consult the SQL Server error log (in the SQL Server boot directory) for more details.
This error may be caused by a hardware problem.
Explanation(错误分析)
???? This error occurs when a disk init command fails while trying to initialize an operating system file or a raw partition for use as a database device. It can occur for the following reasons:
??? Incorrect physical device name
??? Permission problem
??? Incorrect size specified (for raw devices, when you request initialization of ????a device larger than the size of the raw partition)
??? Not enough room on the device.
Action (各种错误具体分析过程)
??? Check each section below, make any needed changes and then run the command again.
Incorrect Device Name
??? Make sure you have the correct physical device name. Refer to the Adaptive Server installation and configuration guide or the System Administration Guide for instructions.
Permission Problem
??? If Adaptive Server was started by the "sybase" account, it must have permission to write to the raw partition or to create a file in the directory specified by disk init. Raw partitions used by Sybase should always be owned by the "sybase" account. Correct the permissions problem and execute the command again, using a different vdevno. Refer to "Virtual Device Number" for more information.
Adaptive Server should not be started by "root." If it is started by root, you will get Error 5123 if the device or file is owned by "sybase."
Incorrect Size
???????? When you request initialization of a raw device, make sure the size you specify is not larger than the size of the raw partition.
??? The size parameter of the disk init command must be specified in units of 2K blocks (size of most data pages). There are 512 2K blocks in a megabyte. Use the formula:
#_of_Megabytes * #_of_data_pages_per_Megabyte = #_of_2K_blocks
For example, to initialize a 10MB Sybase device, specify 5120 for the size:
10MB * 512 = 5120
To determine the number of 2K blocks to use for a raw partition on a UNIX system, convert the size of the partition, in sectors, to 2K blocks. The size of a sector varies on different UNIX systems. For example, it is 512 bytes on Sun, so use sectors/4 for the size parameter. It is 1024 bytes on HP, so use sectors/2. Also, see the information below about virtual device numbers. You must restart Adaptive Server or use a different virtual device number when you reissue the disk init command.
??? Refer to the Adaptive Server installation and configuration guide for more information about Sybase and your operating system's partitions. For example, on UNIX, there is a size limitation of 2GB for a device file.
Not all operating systems have partitions as described above.
Additional information
??? Refer to "Initializing Database Devices" in the System Administration Guide for information about disk init.
Versions in which this error is raised
All versions
?