Chinaunix首页 | 论坛 | 博客
  • 博客访问: 90792647
  • 博文数量: 19283
  • 博客积分: 9968
  • 博客等级: 上将
  • 技术积分: 196062
  • 用 户 组: 普通用户
  • 注册时间: 2007-02-07 14:28
文章分类

全部博文(19283)

文章存档

2011年(1)

2009年(125)

2008年(19094)

2007年(63)

分类: DB2/Informix

2008-05-31 18:19:45

SDS:监视

可以使用 onstat 或系统监视接口(SMI)表查看 SDS 服务器统计信息。本节讨论以下主题:



可以使用 onstat -g sds 命令查看 SDS 服务器统计信息。onstat 的输出取决于运行它的位置(主服务器或从服务器)以及使用的选项。

在主服务器上运行这个命令,显示 SDS 环境的状态。



                    
$ onstat -g sds
IBM Informix Dynamic Server Version 11.10.FC1 -- On-Line (Prim) -- Up 01:00:55
 -- 39936 Kbytes

Local server type: HDR Primary
Number of SDS servers:1

SDS server information

SDS srv      SDS srv      Connection        Last LPG sent
name         status       status            (log id,page)
sds_informix       Active    Connected           19,516
        

在主服务器上运行这个命令,显示特定 SDS 节点的详细信息。



                    
$ onstat -g sds sds_informix
IBM Informix Dynamic Server Version 11.10.FB7TL -- On-Line (Prim) -- Up 01:05:15
 -- 39936 Kbytes

SDS server control block: 0xc15bba0
server name: sds_informix
server type: SDS
server status: Active
connection status: Connected
Last log page sent(log id,page):19,516
Last log page flushed(log id,page):19,516
Last LSN acked (log id,pos):19,2113560
Sequence number of next buffer to send: 229
Sequence number of last buffer acked: 0
Time of lask ack:2007/06/28 09:17:05
Total LSNs posted:0
Total LSNs sent:0
Total page flushes posted:0
Total page flushes sent:0
        

在主服务器上运行这个命令,显示与这个主服务器相连的每个 SDS 节点的详细信息。输出与分别运行 onstat -g sds 相同。

在从服务器上运行这个命令,显示本地 SDS 节点的状态。



                    
$ onstat -g sds
IBM Informix Dynamic Server Version 11.10.FB7TL -- Read-Only (SDS) -- Up 
00:25:10 -- 47104 Kbytes

Local server type: SDS
Server Status : Active
Source server name: pri_informix
Connection status: Connected
Last log page received(log id,page): 19,516
        

在从服务器上运行这个命令,显示本地 SDS 节点的详细信息。



                    
$ onstat -g sds verbose
IBM Informix Dynamic Server Version 11.10.FB7TL -- Read-Only (SDS) -- Up 
00:29:54 -- 47104 Kbytes

SDS server control block: 0xb242e20
Local server type: SDS
Server Status : Active
Source server name: pri_informix
Connection status: Connected
Last log page received(log id,page): 19,516
Next log page to read(log id,page):19,517
Last LSN acked (log id,pos):19,2113560
Sequence number of last buffer received: 0
Sequence number of last buffer acked: 0
Current paging file:/usr2/informix/class/sds/paging2
Current paging file size:2048
Old paging file:/usr2/informix/class/sds/paging1
Old paging file size:10240
        







sysmaster 数据库中的两个表(syssrcsds 和 systrgsds)记录每个 SDS 节点的相关信息。syssrcsds 表包含的信息与在主服务器上运行 onstat -g sds 的输出相同。systrgsds 表包含的信息与在从服务器上运行 onstat -g sds 的输出相同。下面是这两个表的输出:



                    
> select * from syssrcsds;

address             202750880
server_name         sds_informix
server_status       Active
connection_status   Connected
last_sent_log_uniq  19
last_sent_logpage   516
last_flushed_log_+  19
last_flushed_logp+  516
last_acked_lsn_un+  19
last_acked_lsn_pos  2113560
seq_tosend          451
last_seq_acked      0
timeof_lastack      1183040225
totallsn_posted     0
totallsn_sent       0
totalpageflush_po+  0
totalpageflush_se+  0

1 row(s) retrieved.
        



                    
> select * from systrgsds;

address             186920480
source_server       pri_informix
connection_status   Connected
last_received_log+  19
last_received_log+  521
next_lpgtoread_lo+  19
next_lpgtoread_lo+  522
last_acked_lsn_un+  19
last_acked_lsn_pos  2134040
last_seq_received   0
last_seq_acked      0
cur_pagingfile      /usr2/informix/class/sds/paging1
cur_pagingfile_si+  12288
old_pagingfile      /usr2/informix/class/sds/paging2
old_pagingfile_si+  6144

1 row(s) retrieved.
        







根据 SDS 主节点和从节点的活动,在在线日志中可以看到以下消息。



                    
08:37:25  SDS Source Node Alias Changed from () to (pri_informix)
        



                    
08:43:36  SDS Server sds_informix - state is now connected
        



                    
16:29:15  SDS Server sds_informix - state is now disconnected
        



                    
16:29:05  DR: DRAUTO is 0 (Off)
...
16:29:05  Servername:sds_informix
...
16:29:06  Setting checkpoint 21:3018 intvl:52
16:29:06  SDS Server pri_informix - state is now connected
...
16:29:06  IBM Informix Dynamic Server Initialized -- Shared Memory Initialized.

16:29:06  Initializing SDS Temp dbspace sds_temp1
16:29:06  Requesting logs from 21:3
...
16:29:06  Servername:sds_informix
...	
16:29:06  Space 'sds_temp1' added.
16:29:06  Onconfig parameter MSGPATH modified from 
            /usr2/informix/class/pri/online.log.informix to 
            /usr2/informix/class/sds/online.log.informix.
16:29:06  Onconfig parameter CONSOLE modified from 
            /usr2/informix/class/pri/online.log.informix to 
            /usr2/informix/class/sds/online.log.informix.
16:29:06  Onconfig parameter DBSERVERNAME modified from pri_informix to 
            sds_informix.
16:29:06  Onconfig parameter SERVERNUM modified from 201 to 204.
16:29:06  Onconfig parameter DUMPDIR modified from 
            /usr2/informix/class/pri to 
            /usr2/informix/class/sds.
16:29:06  Onconfig parameter DBSPACETEMP modified from  to sds_temp1.
...
16:29:06  Recovery Mode
16:29:06  Logical Recovery Started.
16:29:06  10 recovery worker threads will be started.
...
16:29:06  Start Logical Recovery - Start Log 21, End Log ?
16:29:06  Starting Log Position - 21 0x3018
16:29:06  DR: SDS secondary server operational
16:29:06  Cleaning up to 51
阅读(2332) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~