Geneos

Sybase Plug-In - Technical Reference

Introduction

The Sybase Knowledge Module allows for monitoring of SYBASE database parameters and the SYBASE server parameters. There are two plug-ins:

The Sybase database monitor can be configured to monitor multiple databases on multiple machines.

To view the list of supported and unsupported Sybase character sets, see Appendices.

Views

CAPACITY View

This dataview shows a breakdown of the physical disk space allocated and used for particular segments of a database.

sybase_image5

CAPACITY Headline Legend

Name Description
databaseName Name of the database being monitored.
status Status of the database connection.
creationDate Date the database was created.
lastTransactionDump Date the transaction log was last dumped.
secsSinceLastTransactionDump number of seconds passed since the transaction log was last dumped.
logUtilisation Total percent utilisation of all combined log segments.
dataUtilisation Total percent utilisation of all combined data segments.

CAPACITY Table Legend

Name Description
fragmentID The virtual ID of the particular fragment in question, this represents an actual piece of physical disk space allocated to a particular database.
segment The name of a particular segment that exist on this fragment.
deviceName Name of a Sybase physical device on which the corresponding segment is placed.
totalPages Total number of 2K pages available to the segment.
usedPages Total number of available pages that have already been used.
totalMB TotalPages value expressed as Megabytes.
usedMB Total number of available Megabytes that have already been used.
percentUtilisation Percent of the particular segments space that has been used.

SEGMENTS View

This dataview shows a breakdown of the logical segment utilisation for a particular database.

sybase_image1

SEGMENTS Headline Legend

Name Description
databaseName Name of the database being monitored.
status Status of the database connection.
totalSegments Total logical units used by the database.

SEGMENTS Table Legend

Name Description
segmentID Name of the particular logical segment.
segmentName Name of the particular logical segment (same as segmentID).
totalPages Total number of 2k pages available for use by the segment.
usedPages Total number of available pages that have already been used by the segment.
totalMB Total number of Megabytes available for use by the segment.
usedMB Total number of available Megabytes that have already been used by the segment.
percentUtilisation Percentage of available space that has already been used.

USERS View

This dataview shows information regarding the Sybase users (client processes) currently connected to the particular database.

sybase_image2

USERS Headline Legend

Name Description
databaseName Database being monitored.
status Status of the database connection.
totalUsers Total users currently connected to the database.

USERS Table Legend

Name Description
serverProcesssID Internal Sybase process ID given to that user connection.
status Status of the user process.
priority Priority with which the process is running in the database.
loginName Username.
clientHostName Name of the machine that has connected if available.
clientApplication The name of the application that has connected if available.
command Current command being executed by the process.

LOCKS View

This dataview shows a display of the current locks for a particular database.

sybase_image3

LOCKS Headline Legend

Name Description
databaseName Database being monitored.
status Status of the database connection.
totalLocks Total locks currently held on a database.

LOCKS Table Legend

Name Description
serverProcessID Internal Sybase process ID given to that user holding the lock.
loginName Name of the login account that is holding the lock.
lockedTable Name of the database table upon which the lock is held.
lockType Type of lock that is held, the Sybase Adaptive Server documentation provides more information on the meaning of different lock types.
page Page number that has been locked.
status Status of the process that holds the lock.
command type that created the lock.

LONG-RUNNING QUERIES View

This dataview shows a display of all the long running queries.

sybase_image4

LOCKS Headline Legend

Name Description
status Whether the database server is up and running or not
timeThreshold The amount in seconds over which a query should be considered as being 'long running'
totalLongRunningQueries The current number of 'long running' queries

LOCKS Table Legend

Name Description
serverProcessID Internal Sybase process ID given to that user holding the lock.
startTime The time at which the query was started.
timeElapsed The age in seconds that the query has been running.
transaction The name of the transaction that the query is part of.
username The username of the user who is running this query.
hostname The name of the machine on which this query is being run.
program The program which is running this query against the database.
command The type of command that is currently being run
   

Note: The maximum number of DB connections that can be made by a Netprobe is configurable by setting the environment variable MAX_DATABASE_CONNECTIONS. This configuration option can be accessed from the Gateway Setup Editor > Advanced tab for Probes. The default value is 10.

Plug-in Configuration

The following parameters can be configured for this plug-in:

server

Name of the Sybase server on which the target database resides. This string should match an entry in the Sybase interfaces file [case sensitive].

Mandatory: Yes

databaseName

The name of the target database.

Mandatory: Yes

applicationName

The application name to be set to the connection created from the sampler to the Database Server.

Mandatory: No
Default: NetProbe (listen-port <Netprobe's port>)

userName

The username of the account used to connect to the database with. This account should have read permissions to the master and target databases.

The plug-in needs read permission for the following tables:

master.dbo.spt_values
master.dbo.syslocks
master.dbo.syslogins
master.dbo.sysprocesses
master..sysdatabases
master..sysdevices
master..sysprocesses
master..systransactions
master..sysusages

For setting the user permission, check the Sybase website http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc01672.1572/html/sec_admin/CIHEGCIA.htm for reference. See Chapter 6, Managing User Permissions, or the sub-section Granting default permissions to system tables and stored procedures.

Mandatory: Yes

password

Password of the account used to connect to the database with. To set an encrypted password, click on the "Set Password" button, then enter and confirm the password to be used.

Mandatory: Yes

showQueries

Whether a dataview showing long running queries should be shown or not.

Mandatory: No

showQueries > timeThreshold

The age in seconds over which running queries should be considered to be long-running.

Mandatory: No
Default: 30 seconds

Appendices

Additional Requirements

Netprobe can be run on the actual database server machine or on a remote host. It also needs the standard Sybase shared client libraries, charset files and appropriate interfaces file installed on the Netprobe host.

The following environment variables MUST be set in the start_netprobe script in addition to the variables in the Sampler descriptor.

Name Description Notes
LD_LIBRARY_PATH PATH (for Windows) The variable needs to point to the Sybase shared client library directory. Mandatory
SYBASE The variable should point to the Sybase client installation. By default the Sybase interfaces file should reside here. Mandatory
DEBUG=SYBASE:SYBASE If this variable is defined then debug information is displayed. Optional

Ensure that the libraries in the folders lib3p for 32-bit Gateways/Netprobes, and lib3p64 for 64-bit Gateways/Netprobes, are included in LD_LIBRARY_PATH.

In addition, Microsoft.VC80.CRT redistributables are required when using AES-256 passwords in Windows machines.

Configuring the Netprobe Environment

The plug-in behavior will depend on the Sybase client library referenced in these environment variables. For every environment, it needs an assortment of libraries usually found in the lib directory of the Sybase installation directory. If wide table and columns are used, Sybase client library version should at least be 12.5.

Replace <ver> below with the library version.

Windows

SYBASE=C:\Sybase12
set PATH=C:\Sybase12\OCS-<ver>\dll;%PATH%

Solaris

setenv SYBASE /opt/sybase
setenv LD_LIBRARY_PATH /opt/sybase/OCS-<ver>/lib

Linux

setenv SYBASE /opt/sybase
setenv LD_LIBRARY_PATH /opt/sybase/OCS-<ver>/lib

AIX

setenv SYBASE /opt/sybase
setenv LD_LIBRARY_PATH /opt/sybase/OCS-<ver>/lib

Sybase character sets

Supported character sets
ascii_7 cp1250 iso88597
big5 cp1251 iso88598
big5hk cp1252 iso88599
cp037 cp1253 iso15
cp437 cp1254 koi8
cp500 cp1255 mac
cp850 cp1256 mac_cyr
cp852 cp1257 mac_ee
cp855 cp1258 macgreek
cp857 deckanji macturk
cp860 eucgb sjis
cp863 eucjis tis620
cp864 eucksc ucs2
cp866 gb18030 utf8
cp869 ibm420  
cp874 ibm918  
cp932 iso_1  
cp936 iso88592  
cp949 is088595  
cp950 iso88596  
     
Unsupported character sets
cp1047
euccns
greek8
roman8
turkish8