在LINUX下安装 Sybase ASE 11.0.3.3
从Sybase的站点上下载两个软件包,笔者下载了11.0.3.3版本,Sybase目前已经推出了ASE11.9.2,由
于11.9.2软件包很大,由6个rpm软件包组成,各位可以去其站点下载。对于Sybase 11.0.3,sybase提供了
两个rpm格式的软件包。
从http://www.openunix.org下载以下软件包:
sybase-ase-11.0.3.3-1.i386.rpm
sybase-doc-11.0.3.3-1.i386.rpm
sybase-ase-11.0.3.3-1.i386.rpm软件包中包含ASE 11.0.3.3,SQL Server,Backup Server,Sybinit,Sybmo
n及Open Client 10.0.4,Open Server 运行库,ESQL/C等。
sybase-doc-11.0.3.3-1.i386.rpm包中则包含全部文档。
安装软件
缺省情况下Sybase Adaptive Server Enterprise 安装在目录:/opt/sybase.
全部安装需要至少200M磁盘空间,但是,如果你不需要安装文档,则120M空间就够了,不过,既然是一
个重量级的数据库系统,最好还是多分一些空间给它。
一、安装前的准备工作:
在Red hat Linux 下安装ASE非常容易,你只要键入:
# rpm -i sybase-ase-11.0.3.3-1.i386.rpm
之后是一些有关版权的信息,选择YES后,可以将软件包释放到目前/opt/sybase中。如果你的系统中没
有sybase用户及相应的用户组,第一次运行以上命令时,安装程序会提示用户是否建立sybase用户及组。缺
省情况下,应选择自动建立sybase用户及组。
安装过程先建立用户及组(如果用户已经事先建了用户及组,安装程序会跳过这一步),然后安装数据库系
统。由于采用了rpm格式,安装十分简单。最后程序会提示你以sybase用户登录系统,运
行/opt/sybase/install/sybinit.以配置Sybase ASE。
以sybase用户登录系统,运行以下命令:
$ cd /opt/sybase/install
$./sybinit
运行后开始配置数据库服务器:
The log file for this session is '/opt/sybase/init/logs/log0908.001'.
SYBINIT
1. Release directory: /opt/sybase
2. Edit / View Interfaces File
3. Configure a Server product
4. Configure an Open Client/Server product
在弹出的菜单中选择3、Configure a Server product,之后,选择配置SQL Server告诉 'sybinit'要配
置SQL Server。
之后,出现以下菜单:
NEW OR EXISTING SQL SERVER
1. Configure a new SQL Server
2. Configure an existing SQL Server
3. Upgrade an existing SQL Server
从菜单中选择Configure a new SQL Server,缺省情况下,服务器名字为SYBASE,如果你想自己为服务器起
一个更好一点的名字,可以对其进行更名。本文选择采用缺省服务器名。
按CTRL-A继续配置,配置程序显示如下:
SQL SERVER CONFIGURATION
1. CONFIGURE SERVER'S INTERFACES FILE ENTRY Incomplete
2. MASTER DEVICE CONFIGURATION Incomplete
3. SYBSYSTEMPROCS DATABASE CONFIGURATION Incomplete
4. SET ERRORLOG LOCATION Incomplete
5. CONFIGURE DEFAULT BACKUP SERVER Incomplete
6. CONFIGURE LANGUAGES Incomplete
7. CONFIGURE CHARACTER SETS Incomplete
8. CONFIGURE SORT ORDER Incomplete
9. ACTIVATE AUDITING Incomplete
进入每一项进行配置,你可以不用更改任何参数而一直按Ctrl-a完成每一项配置。最后,完成后,以下9项都
变成了complete,表示配置完成。按Ctrl-a继续对数据库进行配置。
首先选择第1项,配置数据库的TCP服务端口,就如http服务在80端口上一样,这里随便给一个端口,如7100
。在SERVER INTERFACES FILE ENTRY SCREEN中选择3Add a new listener service,以增加一个监听服务,
其中'Retry Count' and 'Retry Delay' 两项先不更改。这两个参数主要用于多用户同时访问数据库时,会
造成对数据库性能的下降有关,以后可以自行调整。
以下增加TCP服务的过程:
菜单:EDIT TCP SERVICE
1. Hostname/Address: rh61.saturn.com
2. Port:
3. Name Alias:
4. Delete this service from the interfaces entry
编辑完成后,结果如下:
EDIT TCP SERVICE
1. Hostname/Address: rh61.saturn.com
2. Port: 7100
3. Name Alias: syb1103
4. Delete this service from the interfaces entry
至此,第一项CONFIGURE SERVER'S INTERFACES FILE ENTRY 配置完成,结果如下:
SQL SERVER CONFIGURATION
1. CONFIGURE SERVER'S INTERFACES FILE ENTRY Complete
2. MASTER DEVICE CONFIGURATION Incomplete
3. SYBSYSTEMPROCS DATABASE CONFIGURATION Incomplete
4. SET ERRORLOG LOCATION Incomplete
5. CONFIGURE DEFAULT BACKUP SERVER Incomplete
6. CONFIGURE LANGUAGES Incomplete
7. CONFIGURE CHARACTER SETS Incomplete
8. CONFIGURE SORT ORDER Incomplete
9. ACTIVATE AUDITING Incomplete
其余8项,均可以缺省配置。完成后,结果如下:
SQL SERVER CONFIGURATION
1. CONFIGURE SERVER'S INTERFACES FILE ENTRY Complete
2. MASTER DEVICE CONFIGURATION Complete
3. SYBSYSTEMPROCS DATABASE CONFIGURATION Complete
4. SET ERRORLOG LOCATION Complete
5. CONFIGURE DEFAULT BACKUP SERVER Complete
6. CONFIGURE LANGUAGES Complete
7. CONFIGURE CHARACTER SETS Complete
8. CONFIGURE SORT ORDER Complete
9. ACTIVATE AUDITING Complete
按Ctrl-a继续配置数据库,此时,程序开始建立数据库设备及重启动数据库服务器。用户可以看到屏幕上滚
动过很多信息,如果系统显示:Configuration completed successfully.表示服务器配置成功。
用户可以运行ps命令,查看系统中正在运行的服务程序。从中可以看到sybase服务器已经启动运行了。
完成后,回到主菜单,对备份数据库进行备份,菜单为:
返回到CONFIGURE SERVER PRODUCTS 菜单,首先为backup Server配置一下"interfaces"。
SERVER INTERFACES FILE ENTRY SCREEN
Server name: SYB_BACKUP
1. Retry Count: 0
2. Retry Delay: 0
3. Add a new listener service
之后,再增加新的listener service ,方式同建立服务器相同,本文略。
完成配置后,结果为:
SERVER INTERFACES FILE ENTRY SCREEN
Server name: SYB_BACKUP
1. Retry Count: 0
2. Retry Delay: 0
3. Add a new listener service
Listener services available:
Protocol Address Port Name Alias
4. tcp rh61.saturn.com 7110
最后,返回SYBINIT 主菜单。再选择配置Backup Server
BACKUP SERVER CONFIGURATION
1. Backup Server errorlog: /opt/sybase/install/backup.log
2. Enter / Modify Backup Server interfaces file information
3. Backup Server language: us_english
4. Backup Server character set: iso_1
5. Backup Server tape configuration file: /opt/sybase/backup_tape.cfg
所有配置均可按缺省配置进行。配置过程本文从略。
最后配置CONNECTIVITY PRODUCTS :
Products:
Product Date Installed Date Configured
1. Open Client Library
2. Open Server Library
3. Embedded SQL/C Precomp
完全采用缺省配置即可。
至此,配置即全部完成。
其余CONFIGURE CONNECTIVITY PRODUCTS 的配置,均可以按缺省情况对待。完成后,数据库服务器的配
置即全部完成。这时你可以运行isql登录系统,查看系统情况:
$ isql -Usa -P
1>;select @@version
2>; go
--------------------------------------------------------------------------------------
SQL Server/11.0.3.3/P/Linux Intel/Linux 2.0.36 i586/1/OPT/Sun Sep 6 09:36:01 CEST 1998
(1 row affected)
1>; sp_who
2>; go
spid status loginame hostname blk dbname cmd
----- ---------- ----------------------------------------------------------------
1 running sa snippy.syb 0 master SELECT
2 sleeping NULL 0 master NETWORK HANDLER
3 sleeping NULL 0 master DEADLOCK TUNE
4 sleeping NULL 0 master MIRROR HANDLER
5 sleeping NULL 0 master HOUSEKEEPER
6 sleeping NULL 0 master CHECKPOINT SLEEP
(6 rows affected, return status = 0)
表示数据系统已经速运行了。再看SYB_BACKUP的情况:
1>; SYB_BACKUP...sp_who
2>; go
spid status loginame hostname blk cmd
----------- ---------- ------------ ---------- --- ----------------------------
1 sleeping NULL NULL 0 CONNECT HANDLER
2 sleeping NULL NULL 0 DEFERRED HANDLER
3 runnable NULL NULL 0 SCHEDULER
5 runnable NULL NULL 0 SITE HANDLER
(5 rows affected)
SYB_BACKUP也正常运行。
qjhadm 回复于:2003-01-15 14:50:29
好!精辟!
long630 回复于:2003-01-16 11:58:15
能安装成功吗?
jazy 回复于:2003-04-19 17:21:36
前不久下载了个linux版的结果做MD校验时失败!
郁闷!!
wwyhy 回复于:2009-07-20 15:34:09
我按照你的文档配置Sybase-11.0.3.3,但配置到SYB_BACKUP 的时候添加了一个监听后,启动失败,不知道为什么
提示如下:
Enter the number of your choice and press return:
Execute the Backup Server configuration now? y
Running task: update the Backup Server runserver file.
Task succeeded: update the Backup Server runserver file.
Running task: boot the Backup Server.
waiting for server 'SYB_BACKUP' to boot...
SERVER ERROR: Failed to boot server 'SYB_BACKUP'.
Press <return> to continue.
提示启动失败,请指点
WFCJZ 回复于:2009-07-20 16:09:27
把日志发过来看一下!这个版本也太老了点吧!
wwyhy 回复于:2009-07-20 17:33:13
以下是errorlog:
其他版本要收费的嘛
--------------
00:2009/07/20 17:09:50.80 kernel Using config area from primary master device.
00:2009/07/20 17:09:50.81 kernel Configuration Error: Configuration file, '/opt/sybase/SYBASE.cfg', does not exist.
00:2009/07/20 17:09:50.82 kernel Warning: A configuration file was not specified and the default file '/opt/sybase/SYBASE.cfg' does not exist. SQL Server creates the default file with the default configuration.
00:2009/07/20 17:09:50.84 kernel Using 1024 file descriptors.
00:2009/07/20 17:09:50.84 kernel Internal run-time model set for Linux
00:2009/07/20 17:09:50.84 kernel SQL Server/11.0.3.3 ESD#6/P-FREE/Linux Intel/Linux 2.2.14 i686/1/OPT/Fri Mar 17 15:45:30 CET 2000
00:2009/07/20 17:09:50.84 kernel (c) Copyright 1987, 2000.
00:2009/07/20 17:09:50.84 kernel Sybase, Inc. All rights reserved.
00:2009/07/20 17:09:50.84 kernel
00:2009/07/20 17:09:50.84 kernel Unpublished rights reserved under U.S. copyright laws.
00:2009/07/20 17:09:50.84 kernel This software contains confidential and trade secret information of Sybase,
00:2009/07/20 17:09:50.84 kernel Inc. Use, duplication or disclosure of the software and documentation by
00:2009/07/20 17:09:50.84 kernel the U.S. Government is subject to restrictions set forth in a license
00:2009/07/20 17:09:50.84 kernel agreement between the Government and Sybase, Inc. or other written
00:2009/07/20 17:09:50.84 kernel agreement specifying the Government's rights to use the software and any
00:2009/07/20 17:09:50.84 kernel applicable FAR provisions, for example, FAR 52.227-19.
00:2009/07/20 17:09:50.84 kernel
00:2009/07/20 17:09:50.84 kernel Sybase, Inc. 6475 Christie Avenue, Emeryville, CA 94608, USA.
00:2009/07/20 17:09:50.84 kernel Using '/opt/sybase/SYBASE.cfg' for configuration information.
00:2009/07/20 17:09:50.85 kernel Logging SQL Server messages in file '/opt/sybase/install/errorlog'
.
00:2009/07/20 17:09:50.85 kernel Network and device connection limit is 1014.
00:2009/07/20 17:09:50.87 server Number of proc buffers allocated: 495.
00:2009/07/20 17:09:50.89 server Number of blocks left for proc headers: 543.
00:2009/07/20 17:09:50.89 server Memory allocated for the default data cache cache: 3718 Kb
00:2009/07/20 17:09:50.90 server Size of the 2K memory pool: 3718 Kb
00:2009/07/20 17:09:50.90 kernel Dynamic shared object (KAIO driver /opt/sybase/lib/kaioasync.so) does not exist.
00:2009/07/20 17:09:50.90 kernel Async disk I/O is permanent disabled.
00:2009/07/20 17:09:50.90 kernel kistartup: asynchronous I/O not available: No such file or directory
00:2009/07/20 17:09:50.90 kernel Initializing virtual device 0, '/opt/sybase/master.dat'
00:2009/07/20 17:09:50.90 kernel Virtual device 0 started using standard unix i/o.
00:2009/07/20 17:09:50.90 server No active traceflags
00:2009/07/20 17:09:50.91 server Opening Master Database ...
00:2009/07/20 17:09:50.93 server Loading SQL Server's default sort order and character set
00:2009/07/20 17:09:50.96 kernel network name YNXLT, type ether, port 7000
00:2009/07/20 17:09:50.97 server Recovering database 'master'
00:2009/07/20 17:09:50.97 server Recovery dbid 1 ckpt (1511,17)
00:2009/07/20 17:09:50.97 server Recovery no active transactions before ckpt.
00:2009/07/20 17:09:50.98 server 1 transactions rolled forward.
00:2009/07/20 17:09:51.00 server Database 'master' is now online.
00:2009/07/20 17:09:51.00 server The transaction log in the database 'master' will use I/O size of 2 Kb.
00:2009/07/20 17:09:51.00 server 0 dump conditions detected at boot time
00:2009/07/20 17:09:51.01 server server is unnamed
00:2009/07/20 17:09:51.01 server Warning: The 'sysconfigures' table is not updated since the SQL Server is started with the default configuration.
00:2009/07/20 17:09:51.02 server Recovering database 'model'.
00:2009/07/20 17:09:51.02 server Recovery dbid 3 ckpt (406,10)
00:2009/07/20 17:09:51.02 server Recovery no active transactions before ckpt.
00:2009/07/20 17:09:51.03 server The transaction log in the database 'model' will use I/O size of 2 Kb.
00:2009/07/20 17:09:51.03 server Database 'model' is now online.
00:2009/07/20 17:09:51.04 server Clearing temp db
00:2009/07/20 17:09:51.49 server The transaction log in the database 'tempdb' will use I/O size of 2 Kb.
00:2009/07/20 17:09:51.51 server The transaction log in the database 'tempdb' will use I/O size of 2 Kb.
00:2009/07/20 17:09:51.51 server Database 'tempdb' is now online.
00:2009/07/20 17:09:51.51 server Recovery complete.
00:2009/07/20 17:09:51.51 server SQL Server's default sort order is:
00:2009/07/20 17:09:51.51 server 'bin_iso_1' (ID = 50)
00:2009/07/20 17:09:51.51 server on top of default character set:
00:2009/07/20 17:09:51.51 server 'iso_1' (ID = 1).
00:2009/07/20 17:09:59.36 kernel Initializing virtual device 1, '/opt/sybase/sybprocs.dat'
00:2009/07/20 17:09:59.36 kernel Virtual device 1 started using standard unix i/o.
00:2009/07/20 17:10:14.36 server Configuration file '/opt/sybase/SYBASE.cfg' has been written and the previous version has been renamed to '/opt/sybase/SYBASE.001'.
00:2009/07/20 17:10:14.36 server The configuration option 'allow updates to system tables' has been changed by 'sa' from '0' to '1'.
00:2009/07/20 17:10:48.36 kernel ueshutdown: exiting
00:2009/07/20 17:17:07.19 kernel Using config area from primary master device.
00:2009/07/20 17:17:07.21 kernel Warning: Using default file '/opt/sybase/SYBASE.cfg' since a configuration file was not specified. Specify a configuration file name in the RUNSERVER file to avoid this message.
00:2009/07/20 17:17:07.23 kernel Using 1024 file descriptors.
00:2009/07/20 17:17:07.23 kernel Internal run-time model set for Linux
00:2009/07/20 17:17:07.23 kernel SQL Server/11.0.3.3 ESD#6/P-FREE/Linux Intel/Linux 2.2.14 i686/1/OPT/Fri Mar 17 15:45:30 CET 2000
00:2009/07/20 17:17:07.23 kernel (c) Copyright 1987, 2000.
00:2009/07/20 17:17:07.23 kernel Sybase, Inc. All rights reserved.
00:2009/07/20 17:17:07.23 kernel
00:2009/07/20 17:17:07.23 kernel Unpublished rights reserved under U.S. copyright laws.
00:2009/07/20 17:17:07.23 kernel This software contains confidential and trade secret information of Sybase,
00:2009/07/20 17:17:07.23 kernel Inc. Use, duplication or disclosure of the software and documentation by
00:2009/07/20 17:17:07.23 kernel the U.S. Government is subject to restrictions set forth in a license
00:2009/07/20 17:17:07.23 kernel agreement between the Government and Sybase, Inc. or other written
00:2009/07/20 17:17:07.23 kernel agreement specifying the Government's rights to use the software and any
00:2009/07/20 17:17:07.23 kernel applicable FAR provisions, for example, FAR 52.227-19.
00:2009/07/20 17:17:07.23 kernel
00:2009/07/20 17:17:07.23 kernel Sybase, Inc. 6475 Christie Avenue, Emeryville, CA 94608, USA.
00:2009/07/20 17:17:07.23 kernel Using '/opt/sybase/SYBASE.cfg' for configuration information.
00:2009/07/20 17:17:07.23 kernel Logging SQL Server messages in file '/opt/sybase/install/errorlog'
.
00:2009/07/20 17:17:07.26 kernel Network and device connection limit is 1014.
00:2009/07/20 17:17:07.35 server Number of proc buffers allocated: 495.
00:2009/07/20 17:17:07.51 server Number of blocks left for proc headers: 543.
00:2009/07/20 17:17:07.52 server Memory allocated for the default data cache cache: 3718 Kb
00:2009/07/20 17:17:07.53 server Size of the 2K memory pool: 3718 Kb
00:2009/07/20 17:17:07.53 kernel Initializing virtual device 0, '/opt/sybase/master.dat'
00:2009/07/20 17:17:07.53 kernel Virtual device 0 started using standard unix i/o.
00:2009/07/20 17:17:07.53 server No active traceflags
00:2009/07/20 17:17:07.56 server Opening Master Database ...
00:2009/07/20 17:17:07.60 server Loading SQL Server's default sort order and character set
00:2009/07/20 17:17:07.64 kernel network name YNXLT, type ether, port 7000
00:2009/07/20 17:17:07.64 server Recovering database 'master'
00:2009/07/20 17:17:07.64 server Recovery dbid 1 ckpt (1511,17)
00:2009/07/20 17:17:07.64 server Recovery no active transactions before ckpt.
00:2009/07/20 17:17:07.65 server 1 transactions rolled forward.
00:2009/07/20 17:17:07.68 server Database 'master' is now online.
00:2009/07/20 17:17:07.68 server The transaction log in the database 'master' will use I/O size of 2 Kb.
00:2009/07/20 17:17:07.68 server 0 dump conditions detected at boot time
00:2009/07/20 17:17:07.68 server server is unnamed
00:2009/07/20 17:17:07.71 server Recovering database 'model'.
00:2009/07/20 17:17:07.71 server Recovery dbid 3 ckpt (406,10)
00:2009/07/20 17:17:07.71 server Recovery no active transactions before ckpt.
00:2009/07/20 17:17:07.73 server The transaction log in the database 'model' will use I/O size of 2 Kb.
00:2009/07/20 17:17:07.74 server Database 'model' is now online.
00:2009/07/20 17:17:07.74 server Clearing temp db
00:2009/07/20 17:17:08.21 server The transaction log in the database 'tempdb' will use I/O size of 2 Kb.
00:2009/07/20 17:17:08.23 server The transaction log in the database 'tempdb' will use I/O size of 2 Kb.
00:2009/07/20 17:17:08.23 server Database 'tempdb' is now online.
00:2009/07/20 17:17:08.24 server Recovery complete.
00:2009/07/20 17:17:08.24 server SQL Server's default sort order is:
00:2009/07/20 17:17:08.24 server 'bin_iso_1' (ID = 50)
00:2009/07/20 17:17:08.24 server on top of default character set:
00:2009/07/20 17:17:08.24 server 'iso_1' (ID = 1).
00:2009/07/20 17:17:13.09 kernel Initializing virtual device 1, '/opt/sybase/sybprocs.dat'
00:2009/07/20 17:17:13.09 kernel Virtual device 1 started using standard unix i/o.
00:2009/07/20 17:17:59.14 server Configuration file '/opt/sybase/SYBASE.cfg' has been written and the previous version has been renamed to '/opt/sybase/SYBASE.002'.
00:2009/07/20 17:17:59.16 server The configuration option 'allow updates to system tables' has been changed by 'sa' from '1' to '0'.
00:2009/07/20 17:17:59.32 server Configuration file '/opt/sybase/SYBASE.cfg' has been written and the previous version has been renamed to '/opt/sybase/SYBASE.003'.
00:2009/07/20 17:17:59.33 server The configuration option 'allow updates to system tables' has been changed by 'sa' from '0' to '0'.
00:2009/07/20 17:17:59.39 server Configuration file '/opt/sybase/SYBASE.cfg' has been written and the previous version has been renamed to '/opt/sybase/SYBASE.004'.
00:2009/07/20 17:17:59.39 server The configuration option 'allow updates to system tables' has been changed by 'sa' from '0' to '1'.
00:2009/07/20 17:17:59.45 server Configuration file '/opt/sybase/SYBASE.cfg' has been written and the previous version has been renamed to '/opt/sybase/SYBASE.005'.
00:2009/07/20 17:17:59.46 server The configuration option 'allow updates to system tables' has been changed by 'sa' from '1' to '0'.
00:2009/07/20 17:17:59.53 server Configuration file '/opt/sybase/SYBASE.cfg' has been written and the previous version has been renamed to '/opt/sybase/SYBASE.006'.
00:2009/07/20 17:17:59.54 server The configuration option 'allow updates to system tables' has been changed by 'sa' from '0' to '1'.
00:2009/07/20 17:17:59.59 server Configuration file '/opt/sybase/SYBASE.cfg' has been written and the previous version has been renamed to '/opt/sybase/SYBASE.007'.
00:2009/07/20 17:17:59.60 server The configuration option 'allow updates to system tables' has been changed by 'sa' from '1' to '0'.
WFCJZ 回复于:2009-07-21 10:55:26
00:2009/07/20 17:17:59.14 server Configuration file '/opt/sybase/SYBASE.cfg' has been written and the previous version has been renamed to '/opt/sybase/SYBASE.002'.
00:2009/07/20 17:17:59.16 server The configuration option 'allow updates to system tables' has been changed by 'sa' from '1' to '0'.
从这上面入手看看,不过从上面的报错看,在你启动时库就有问题:
Recovering database 'master'
00:2009/07/20 17:17:07.64 server Recovery dbid 1 ckpt (1511,17)
00:2009/07/20 17:17:07.64 server Recovery no active transactions before ckpt.
00:2009/07/20 17:17:07.65 server 1 transactions rolled forward.
00:2009/07/20 17:17:07.68 server Database 'master' is now online.
00:2009/07/20 17:17:07.68 server The transaction log in the database 'master' will use I/O size of 2 Kb.
00:2009/07/20 17:17:07.68 server 0 dump conditions detected at boot time
|