Sybase复制服务器安装配置过程中常见问题及解决办法

 Sybase复制服务器安装配置过程中常见问题及解决办法

一、不能成功连接到服务
  错误信息:
  CONNECTIVITY ERROR: CT-Library error: 'ct_connect(): network packet layer: internal net library error: Net-Lib protocol driver call to connect two endpoints failed'.
  CONNECTIVITY ERROR: Login attempt failed: server = ''.
  问题原因:可能接口文件配置的服务信息不完整,或者给定的登陆用户名密码有误。
  解决办法:
  1. 检查接口文件中服务信息是否完整、正确,注意格式要正确,尤其是不可见控制字符。
  热备份应用中,接口文件需要包含主点DS,备点DS,RS以及维护RSSD的ASE DS的信息,这几个点的接口文件必须都包含以上信息。
  推荐使用dsedit图形界面方式编辑接口文件,或者使用dscp命令行界面工具编辑接口文件。如果非要使用vi来编辑接口文件,出现问题可是自找的!嘿嘿~~ 特别要注意不可见控制字符。
  2. 检查指定的服务是否已经运行,检查给定的登陆用户名及密码是否正确。
  
  如果接口文件没有问题,并且指定服务已经运行,用户名密码都正确,那通过isql可以在各个点上均能登陆以上服务。
  
  二、找不到请求的服务名导致RS安装失败。
  错误信息:
  CONNECTIVITY ERROR: CT-Library error: 'ct_connect(): directory service layer: internal directory control layer error: Requested server name not found.'.
  CONNECTIVITY ERROR: Login attempt failed: server = ''.
  问题原因:请求的服务名没有找到。
  解决办法:
  1. 确认各服务器接口文件中包含了要用到的服务名包括IP,端口信息,尤其要注意接口文件的格式,格式不正确,或者多出不必要的控制字符有可能读取接口文件时会失败。
  2. 通过telnet 测试远端服务是否可用,或者通过isql测试能否成功登陆到远端的服务。
  
  三、过程缓存不足导致安装RSSD失败。
  
  错误信息:
  SERVER ERROR: "There is not enough procedure cache to run this procedure, trigger, or SQL batch. Retry later, or ask your SA to reconfigure SQL Server with more procedure cache."
  Unable to load the Replication Server System Database in 'phs'.
  Task failed: configure the Replication Server System Database. Terminating configuration.
  问题原因:数据库的 "procedure cache" 设置值不够
  解决办法:
  方法1. 直接修改cfg文件中的"procedure cache size" 重起服务。
  方法2. 直接修改数据库中的设置,动态参数,修改生效(推荐) 。
  1> sp_configure "procedure cache" // 查看当前过程缓存值
  2> go
  1> sp_configure "procedure cache",40 // 将过程缓存值改为40
  2> go
  
  四、RSSD日志设备空间满导致RS安装过程不能继续。
  错误信息:
  SQL Server message: msg 7412, level 10, state 1
  "Space available in the log segment has fallen critically low in database 'rssd'. All future modifications to this database will be suspended until the log is successfully dumped and space becomes available."
  SQL Server message: msg 7415, level 10, state 1
  "The transaction log in database rssd is almost full. Your transaction is being suspended until space is made available in the log."
  问题原因:RSSD日志设备空间满,导致RS安装过程不能继续。
  解决办法:
  方法1. 增大RSSD日志设备。
  (注:提醒在创建RSSD设备时应该考虑到为其分配足够的空间)
  方法2. 清除RSSD日志设备上的日志 。
  1> dump transaction RSSD_name
  2> with truncate_only
  3> go
  
  五、更改默认字符集导致RS服务不能启动。
  错误信息:
  ERR initialization failed. ((Intl-Lib error: Unable to open file)(OS error: No such file or directory) Localization File: 030/rs.loc Location: r/errloc.c(279))
  问题原因:可能配置文件设置了复制服务器不兼容的字符集
  解决办法:
  将复制服务器字符集更改为已经安装的且复制服务器支持的字符集,即可。
  -----------------------------------------
  要查看复制服务器已经安装的字符集,进入 $SYBASE/locales目录。已经安装的字符集位于 chinese或us_english或unicode之类的目录中。
  其中,locales.dat中包含了ASE或者RS支持的不同操作系统支持的字符集。
  操作系统环境变量的设置一般要与该处的设置相一致。
  
  
  (注:应该保证复制系统中各复制服务器和主点从点数据库字符集及语言的互相兼容。如果数据库字符集与复制服务器字符集不一致,有可能导致复制数据的异常,甚至复制事务失败。
  
  
  六、数据库最大内存设置不足导致向复制系统添加数据库时启动复制代理失败。
  错误信息:
  WARNING: "The current 'max memory' value '4194304', is not sufficient to change
  the parameter 'enable rep agent threads' to '1'. 'max memory' should be greater
  than 'total logical memory' '4286243' required for the configuration."
  Unable to execute query 'exec sp_configure "enable rep agent threads",1' against
  server 'SXJHWG'.
  Task failed: configure the Replication Agent. Terminating configuration.
  问题原因:max memory设置值过小。
  解决办法:
  增加max memory值。该值为动态值,修改直接生效,无须重起服务。
  
  1> sp_configure "max memory",8388608
  2> go
  
  七、向复制系统添加备用数据库时,发生找不到用户名问题
  错误信息:
  Running task: configure database for primary data.
  Granted maintenance user permissions on the lastcommit functions and rs_marker.
  WARNING: Please verify that suids in the syslogins table of the Standby SQL
  server correspond to syslogins of the Active SQL Server
  SQL Server message: msg 11105, level 16, state 3
  WARNING: "No such user/role 'sybase_maint_user' exists."
  问题原因:
  rs_init不会自动创建在standby 点的longin用户 sybase_maint_user 。
  解决办法:
  在standby 点的longin用户 sybase_maint_user需要用户手工建立的(rs_init不会自动完成) 。 可以手动在备点添加,也可以通过dump/load从主点同步过去。
  ----------------------------------------------------
  $ isql -SStandbyDS -Usa -PsaPassword
  1> sp_addlogin testdb_maint,testdb_maint_ps,testdb
  2> go
  1> use testdb
  2> go
  1> sp_adduser "testdb_maint"
  2> go
  
  调整主备点库的维护用户的相关信息与主点库一致
  
  设置可以更改系统表
  
  1> sp_configure "allow updates to system tables",1
  2> go
  
  (这里修改使得:
  master库的syslogins表和每个用户数据库的sysusers表中的每个登陆用户名的服务器用户ID(suid)必须与主点库相同。
  master库的syalogins和sysloginroles表中,服务器用户ID和角色设置也必须相同。
  有关这部分信息,可以登陆到主点库,查询相应表,或者从主点库bcp相关表到备点库)
  
  取消更改系统表的权限
  
  1> sp_configure "allow updates to system tables",0
  2> go
  
  对维护用户授权
  
  1> sp_role "grant",sa_role,"testdb_maint"
  2> go
  1> sp_role "grant",replication_role,"testdb_maint"
  2> go
  -------------------------------------------------------
  
  
  八、数据库库的“select into/bulkcopy”标记没打开导致添加数据库库失败。
  错误信息:
  SQL Server message: msg 4977, level 16, state 1
  WARNING: "You cannot run ALTER TABLE LOCK in this database because the 'select into/bulkcopy' option is off. Please check with the DBO."
  
  Unable to execute query 'alter table rs_lastcommit lock datarows' against server 'SXCNCRSSD'.
  Task failed: configure the Replication Server System Database. Terminating configuration.
  问题原因:要配置的库的“select into/bulkcopy/pllsort”标记没有打开。
  解决办法:
  1> sp_dboption SXCNCRS_RSSD,"select into/bulkcopy/pllsort",true
  2> go
  
  九、主点活动库不能成功配置复制代理
  错误信息:
  Running task: configure the Replication Agent.
  SQL Server message: msg 18382, level 16, state 1
  
  WARNING: "Database 'testdb' is already configured to use Replication Agent.
  Request to enable Replication Agent has been ignored."
  
  Unable to execute query 'exec sp_config_rep_agent "testdb", enable,"TESTRS",
  "TESTRS_ra", "TESTRS_ra_ps"' against server 'TESTRS'.
  
  Task failed: configure the Replication Agent. Terminating configuration.
  问题原因:以前活动库曾经加入到一个复制系统中,再次添加时因为复制代理已经存在,所以不能成功配置复制代理。
  解决办法:
  1> use testdb
  2> go
  1> sp_config_rep_agent testdb,"disable"
  2> go
  
  十、复制服务器最大线程数不足导致复制异常。
  错误信息:
  I. 2007/01/22 17:41:44. The DSI thread for database 'TESTRS.testdb' is started.
  E. 2007/01/22 17:41:45. ERROR #21 DSI(104 TESTRS.testdb) - /dsithrd.c(1426)
   Open server call to routine 'srv_spawn' failed.
  I. 2007/01/22 17:41:45. Open Server error: Error: 16115, State: 0, Severity 10 -- 'Could not start thread'.
  I. 2007/01/22 17:41:45. The DSI thread for database 'TESTRS.testdb' is shutdown.
  问题原因:num_threads数目不够。
  解决办法:
  方法1:
  1> configure replication server set "num_threads" to "100"
  2> go
  方法2:
  1> rs_configure "num_threads","100"
  2> go
  
  其他几个可能需要调整的参数,包括"memory_limit","memory_max","num_client_connections"调整方法类似。

猜你喜欢

转载自wang-z-p2007.iteye.com/blog/1596661
今日推荐