当前位置:文档之家› SYBASE ASE12.5.3 For Linux安装配置

SYBASE ASE12.5.3 For Linux安装配置

۩f在Suse Linux Enterprise 3.0上安装Sybase ASE12.5.3一.安装准备1.1系统软件包信息操作系统:Suse Linux Enterprise AS Release 3JA V A包:java1.4数据库:Sybase ASE 12.5.31.2创建cdrom文件系统(如果没有cdrom文件系统)该步骤可以不做!1.3创建SYBASE文件系统 (Linux :)例如:/home/sybase 空间要求: 5G disk( local disk)该步骤可以不做!1.4创建SYBASE组和用户(Linux : useradd)增加sybase组和sybase用户,将sybase用户加入sybase组。

修改sybase文件系统的属主:chown –R sybase:sybase /home/sybase1.5确认基本安装信息:(安装后的情况)Master device /dev/rsybmasterSybsystemprocs device: /dev/rsybprocServer name: SYBASEErrorlog location /home/sybase/ASE-12_5/install/errorlogBackerup Server name SYBASE_backupLanguage u s_englishCharacter set utf8Sort order nocasePageSize 8k (12.5以上可以是2k-16k) 1.6创建SYBASE逻辑设备例:(卷组及逻辑卷的创建应由操作系统的工程师划分)修改设备权限:#chown sybase:sybase /dev/ rsyb* /dev/ syb*#chmod 660 /dev/ rsyb* /dev/ syb*二.SYBASE产品安装2.1SYBASE数据库的安装2.1.1安装数据包以sybase用户登录到主机,在Linux命令行下执行如下命令:#mount –r /dev/cd0 /mnt/cdrom$ cd /mnt/cdrom$./setup –console(字符安装模式) 或$./setup(图形方式)Initializing InstallShield Wizard........Launching InstallShield Wizard........-------------------------------------------------------------------------------Welcome to the InstallShield Wizard for Sybase Adaptive Server Enterprise Suite version 12.5.2 GAThe InstallShield Wizard will install Sybase Adaptive Server Enterprise Suiteon your computer.To continue, choose Next.Press 1 for Next, 3 to Cancel or 4 to Redisplay [1] 1-------------------------------------------------------------------------------1) Argentina 2) Australia3) Belgium(English) 4) Belgium(French)5) Brazil 6) Canada7) Denmark 8) Europe,Middle East, and Africa - General 9) France(English) 10) France(French)11) Germany(English) 12) Germany(German)13) Hong Kong 14) India15) Italy(English) 16) Italy(Italy)17) Japan 18) Korea19) Malaysia 20) Mexico21) Netherlands 22) New Zealand23) Norway 24) People's Republic of China(PRC)25) Philippines 26) Singapore27) Spain(English) 28) Spain(Spanish)29) Sweden 30) Switzerland(English)31) Switzerland(German) 32) Taiwan33) Thailand 34) United Kingdom35) United States of America 36) Any Other LocationsPlease enter the number of the location you are installing. (1-37) [1] 35?LICENSE AGREEMENTUnited States and CanadaIMPORTANT NOTICE: Read this License Agreement ("Agreement") carefully beforeusing the enclosed Program. You may Use the Program acquired in the United States and Canada only, in accordance with the following terms and conditions.IF YOU DO NOT AGREE TO BE BOUND BY THESE TERMS, YOU MAY NOT USE THE PROGRAM. Byinstalling or using the Program in any way, You acknowledge that You have read,understand and agree to the terms of this Agreement. If You do not agree with these terms, promptly return the Program and package (and all other product contents, including Documentation) with Your receipt or other proof of purchase to the entity from which You obtained this product within 30 days and request a refund. THIS IS A LICENSE AND NOT A SALE.click the "I agree" button if you wish to install the program.If You, Your company, or Your public agency have signed a written software license agreement with Sybase, Inc., or Sybase Canada Limited ("Sybase") or a Press ENTER to read the text [Type q to quit] qIf you cannot read the agreement for the related location, you may not have the fonts installed on your system to view the agreement properly. If you cannot read this agreement, go to /softwarelicenses and read it there before agreeing.I agree to the terms of the Sybase license for the install locationspecified.(Y/N) [N]YPress 1 for Next, 2 for Previous, 3 to Cancel or 4 to Redisplay [1] 1Please wait...-------------------------------------------------------------------------------Please enter the directory where you would like to install the products orpress ENTER to accept the default.Destination Directory [/home/sybase]Press 1 for Next, 2 for Previous, 3 to Cancel or 4 to Redisplay [1] 11. Yes2. NoYou have chosen to install into an existing directory. Any older versions of the products you choose to install that are detected in this directory willbereplaced. Do you want to continue with installation into this directory? [2]1 -------------------------------------------------------------------------------Choose the setup type that best suits your needs.[X] 1 - TypicalThe program will be installed with the suggested configuration.Recommended for most users.[ ] 2 - FullThe program will be installed with all the products and features. [ ] 3 - CustomThe program will be installed with the features you choose.Recommended for advanced users.To select an item enter its number, or 0 when you are finished: [0]Press 1 for Next, 2 for Previous, 3 to Cancel or 4 to Redisplay [1] 1 Performing install checks. Please wait...Please wait...------------------------------------------------------------------------------- Sybase Adaptive Server Enterprise Suite will be installed in the following location: /home/sybasewith the following features:Sybase ServersAdaptive Server EnterpriseASE Diagnostic ServerReplicatorConnectivityOpen ClientCommon ctlib filesCommon dblib filesLanguage ModulesjConnect 5.5 for JDBCjConnect 6.0 for JDBCSharedASE Adminstration ToolsPress ENTER to read the text [Type q to quit]Sybase CentralAdaptive Server PluginJob Scheduler Templates and UtilitiesSybase Software Asset Managementfor a total size:762.6 MBPress 1 for Next, 2 for Previous, 3 to Cancel or 4 to Redisplay [1] 1 Installing Sybase Adaptive Server Enterprise Suite. Please wait... |-----------|-----------|-----------|------------|0% 25% 50% 75% 100% ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||2.1.2设置环境变量编辑/home/sybase/.profile文件,如下:在PATH中加入路径/home/sybase/ASE-12_5/installSYBASE=/home/sybaseDSQUERY=SYBASESYBASE_ASE=ASE-12_5SYBASE_OCS=OCS-12_5LD_LIBRARY_PATH=$SYBASE/$SYBASE_ASE/libexport SYBASE DSQUERY PATH SYBASE_ASE SYBASE_OCS LD_LIBRARY_PATHPATH=$PATH: $SYBASE/$SYBASE_ASE/bin:export PATH../SYBASE.sh编辑/home/sybase/.bash_profile文件,如下SYBASE=/home/sybaseDSQUERY=SYBASESYBASE_ASE=ASE-12_5SYBASE_OCS=OCS-12_5LD_LIBRARY_PATH=$SYBASE/$SYBASE_OCS/libexport SYBASE DSQUERY PATH SYBASE_ASE SYBASE_OCS LD_LIBRARY_PATHPATH=$PATH:$SYBASE/$SYBASE_ASE/bin:$SYBASE/$SYBASE_OCS/bin: export PATHSYBPLATFORM=linuxexport SYBPLATFORMLANG=CP936export LANG2.2SYBASE数据库的配置2.2.1配置ASE服务器1.在Sybase系统文件安装完成后,利用init文件夹中已建立配置文件的样例来创建SYBASE数据库服务器(/home/sybase/ASE-12_5/init/sample_resource_files/srvbuild.adaptive_s erver.rs)1) 在/home/sybase下建立rs文件夹(mkdir rs);将样例文件拷贝到/home/sybase/rs文件夹下,并改名为sql.rs,在/home/sybase/ASE-12_5/init/sample_resource_filesl路径下执行下述命令:$ cp srvbuild.adaptive_server.rs /home/sybase/rs/sql.rs2) 用vi 命令修改配置参数$ vi sql.rs2.具体配置参数如下:sybinit.release_directory: /home/sybasesybinit.product: sqlsrvsqlsrv.server_name: SYBASEsqlsrv.new_config: yessqlsrv.do_add_server: yeswork_protocol_list: tcpHOSTNAME(对应IP:本机IP,应已记录在/etc/hosts中,下同)work_port_list: 7788sqlsrv.server_page_size: 8K (逻辑页大小)sqlsrv.force_buildmaster: nosqlsrv.master_device_physical_name: /dev/rsybmastersqlsrv.master_device_size: 160sqlsrv.master_database_size: 110sqlsrv.errorlog: /home/sybase/ASE-12_5/install/errorlogsqlsrv.do_upgrade: nosqlsrv.sybsystemprocs_device_physical_name:/dev/rsybprocsqlsrv.sybsystemprocs_device_size: 130sqlsrv.sybsystemprocs_database_size: 120sqlsrv.sybsystemdb_device_physical_name:USE_DEFAULTsqlsrv.sybsystemdb_device_size: USE_DEFAULTsqlsrv.sybsystemdb_database_size: USE_DEFAULTsqlsrv.default_backup_server: SYBASE_backup注意:sqlsrv.sybsystemprocs_device_size、sqlsrv.sybsystemdb_device_size 两个参数数值要略小于实际sybsystemprocs及sybsystemdb所建逻辑卷的大小(10M-25M左右);2.2.2初始化sybase adaptive server进入/home/sybase/ASE-12_5/bin路径中,在命令行下执行srvbuildres命令:$ srvbuildres–r /home/sybase/rs/sql.rs./srvbuildres: Building Adaptive Server 'SYBASE':./srvbuildres: Building master device..../srvbuildres: Master device complete../srvbuildres: Writing entry into directory services..../srvbuildres: Directory services entry complete../srvbuildres: Writing RUN_SYBASE file..../srvbuildres: RUN_SYBASE file complete../srvbuildres: Starting server..../srvbuildres: Server started../srvbuildres: Building sysprocs device and sybsystemprocs database..../srvbuildres: sybprocs device and sybsystemprocs database created../srvbuildres: Running installmaster script to install system stored procedures..../srvbuildres: /home/sybase/ASE-12_5/scripts/installmaster: 10% complete../srvbuildres: /home/sybase/ASE-12_5/scripts/installmaster: 20% complete../srvbuildres: /home/sybase/ASE-12_5/scripts/installmaster: 30% complete../srvbuildres: /home/sybase/ASE-12_5/scripts/installmaster: 40% complete../srvbuildres: /home/sybase/ASE-12_5/scripts/installmaster: 50%complete../srvbuildres: /home/sybase/ASE-12_5/scripts/installmaster: 60% complete../srvbuildres: /home/sybase/ASE-12_5/scripts/installmaster: 70% complete../srvbuildres: /home/sybase/ASE-12_5/scripts/installmaster: 80% complete../srvbuildres: /home/sybase/ASE-12_5/scripts/installmaster: 90% complete../srvbuildres: /home/sybase/ASE-12_5/scripts/installmaster: 100% complete../srvbuildres: installmaster script complete../srvbuildres: Installing common character sets (Code Page 437, Code Page 850,ISO Latin-1, Macintosh and HP Roman-8)..../srvbuildres: Character sets installed../srvbuildres: Setting server name in Adaptive Server..../srvbuildres: Server name added. The name will be visible from SQL afterrestarting the server../srvbuildres: Server 'SYBASE' was successfully created.完成服务器安装;2.2.3设置客户端字符集在/home/Sybase/locaels目录下,打开locales.dat文件,找到有[linux]的位置,将[linux]部分locale = default改为在.profile文件中添加如下内容LANG=defaultSYBLANG=cp936export LANG SYBLANG2.2.4服务器的启动与停止1. 手工启动数据库:$ cd /home/sybase/ASE-12_5/install$ startserver -f RUN_SYBASE2. 关闭数据库:isql –Usa –P -SSYBASE1>shutdown SYB_BACKUP <关闭备份数据库>2>go1>checkpoint2>go1>shutdown2>go2.3创建用户数据库例子3.4.1建立一个4000M的名为portal的数据设备为例$ isql –Usa –P –SSYBASE1> disk init name=“portaldb”, --数据库逻辑设备名2> physname=“/dev/rportaldb”,--逻辑卷名称3> vdevno=7, --设备号4> size=2048000 --数据设备大小5> go3.4.2建立一个1000M的名为logdb的日志设备为例$ isql –Usa –P –SSYBASE1> disk init name=“logdb”, --数据库逻辑设备名2> physname=“/dev/rlogdb”,--逻辑卷名称3> vdevno=8, --设备号4> size=512000 --日志设备大小5> go3.4.3创建用户数据库portal1> create database portal on portaldb=4000 log on logdb=10002> go一般数据库的日志设备大小是数据设备大小的20-30%。

相关主题