当前位置:Linux教程 - Mysql - Sybase 11.0.3.3落户FreeBSD [三] 下载软件及解压

Sybase 11.0.3.3落户FreeBSD [三] 下载软件及解压


作者:薛启康 来源:赛迪网
三、下载软件及解压
  到Sybase的站点下载最新的sybase-ase-11.0.3.3更新包。Sybase对这一版本进行了多次改进,目前推出了专为FreeBSD准备的一个软件包,其中包括以下三个文件:

  sybase-ase-11_0_3_3-FreeBSD-6_i386.tgz

  sybase-doc-11_0_3_3-FreeBSD-6_i386.tgz

  sybase-ocsd-10_0_4-FreeBSD-6_i386.tgz

  可以看出这已是该版本的第6次更新了。

  以root登录FreeBSD主机,增加用户sybase
  #adduser

  根据提示增加一个Sybase用户,同时增加一个Sybase组用户。

  将下载的软件包拷贝到/opt/sybase目录中

  # cd Sybase

  以sybase用户登录,解压以上三个压缩文件:

  $ gunzip -c Sybase-ase-11_0_3_3-FreeBSD-6_i386.tgz|tar vxpf -

  $ gunzip -c Sybase-doc-11_0_3_3-FreeBSD-6_i386.tgz|tar vxpf -

  $ gunzip -c Sybase-oscd-10_0_4-FreeBSD-6_i386.tgz|tar vxpf -

  解压完成,以下开始配置SQL服务器。

  配置数据库服务器
  以sybase用户登录FreeBSD主机

  $ cd Sybase

  $ cd install

  $ ./sysinit

  屏幕显示以下画面选单项:

  SYBINIT

  1. Release directory: /opt/sybase

  2. Edit / View Interfaces File

  3. Configure a Server product

  4. Configure an Open Client/Server product

  Ctrl-a Accept and Continue, Ctrl-x Exit Screen, ? Help.

  Enter the number of your choice and press return:3

  选择3后:出现以下提示:

  CONFIGURE SERVER PRODUCTS

  Products:

  Product Date Installed Date Configured

  1. SQL Server Mar 22 2000 21:22

  2. Backup Server Mar 22 2000 21:22

  Ctrl-a Accept and Continue, Ctrl-x Exit Screen, ? Help.

  Enter the number of your choice and press return: 1

  选择1后,出现以下提示:

  EXISTING SYBASE SERVER

  1. Configure a new Adaptive Server

  2. Configure an existing Sybase Server

  3. Upgrade an existing Sybase Server

  Ctrl-a Accept and Continue, Ctrl-x Exit Screen, ? Help.

  Enter the number of your choice and press return: 1

  再选择1

  ADD NEW ADAPTIVE SERVER

  1. Adaptive Server name: SYBASE

  Ctrl-a Accept and Continue, Ctrl-x Exit Screen, ? Help.

  Enter the number of your choice and press return: 1

  如果你要更改adaptive Server 的名称,选择1,键入你想用的名称,完成后使用Ctrl-a接受目前配置,出现以下提示,开始对服务器进行具体配置。

  SYBASE 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. CONFIGURE AUDITING Incomplete

  Ctrl-a Accept and Continue, Ctrl-x Exit Screen, ? Help.

  Enter the number of your choice and press return:

  可以选择1~9各项,对以上9项内容进行配置。

  例如,选择第1项,配置完成后显示如下:

  SERVER INTERFACES FILE ENTRY SCREEN

  Server name: SYBASE

  1. Retry Count: 0

  2. Retry Delay: 0

  3. Add a new listener service

  Modify or delete a service

  Listener services available:

  Protocol Address Port Name Alias

  4. tcp freebsd 7100 syb1103

  Ctrl-a Accept and Continue, Ctrl-x Exit Screen, ? Help.

  Enter the number of your choice and press return:

  配置完全部1~9项后,结果如下:

  SYBASE 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. CONFIGURE AUDITING Complete

  Ctrl-a Accept and Continue, Ctrl-x Exit Screen, ? Help.

  Enter the number of your choice and press return:

  选择ctrl-a之后,出现以下警告:

  WARNING: '/home/sybase/master.dat' is a regular file which is not recommended for a Server device.

  Press <return> to continue.

  这是因为我们正在使用的数据库文件不是直接放置在raw设备上,而是使用了操作系统屏蔽下的文件系统,没有关系,直接回车即可。接着程序生成设备、数据库文件等,整个过程要2~3分钟。最后程序提示“configuration completed successfully”,SQL Server的配置完成。

  据说,在Sybase-11.0.3.3中加入了对raw设备的支持,有兴趣的朋友可以自己试试看。至此,服务器配置完成。

  配置备份服务器
  SQL Server配置好后,连按Ctrl-a进入如下选单画面:

  SYBINIT

  1. Release directory: /opt/sybase

  2. Edit / View Interfaces File

  3. Configure a Server product

  4. Configure an Open Client/Server product

  此时,选择2配置BACKUP Server,配置过程如下:

  选择要配置的服务器名(SYB_BACKUP),输入相应的主机名称、TCP端口号、别名等如下所示:

  SERVER INTERFACES FILE ENTRY SCREEN

  Server name: SYB_BACKUP

  1. Retry Count: 0

  2. Retry Delay: 0

  3. Add a new listener service

  Modify or delete a service

  Listener services available:

  Protocol Address Port Name Alias

  4. tcp freebsd 8000 SYB_BACKUP_Alias

  Ctrl-a Accept and Continue, Ctrl-x Exit Screen, ? Help.

  Enter the number of your choice and press return:

  本例中,笔者用了端口号8000,别名为:SYB_BACKUP_Alias(容易记)。之后按Ctrl-a确认。

  然后,配置BACKUP Server的日志文件位置、语言、字符集等,如下所示:

  Enter the number of your choice and press return:

  BACKUP SERVER CONFIGURATION

  1. Backup Server errorlog: /opt/sybase/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/sybase/backup_tape.cfg

  Ctrl-a Accept and Continue, Ctrl-x Exit Screen, ? Help.

  Enter the number of your choice and press return:

  按Ctrl-a确认完成配置,之后安装程序会保存配置,并试图启动BACKUP Server。

  至此,备份服务器配置完成。