on 03-17-2015 12:39 PM
Hi all,
I am using ASE-15.0.2 and when I use sp_monitorconfig 'remote logins' it shows 1300 active connections but when I check in sysremotelogins table it is empty.
After going through the source of sp_monitorconfig I noticed that it fetches the data from a temporary table "resource_result_tbl" and data in this table is inserted through,
insert into #resource_monitor_tbl values(19, 118, "active_remote_logins", "hwm_remote_logins",null, null, 0, 1)
After checking futher I found config_admin() function.
What does this function do..?
How does it get the data..?
Is it the wrong way of checking for this information..?
Any help would be of great use..
conifg_admin is a TSQL function, it is intended for internal use rather than for direct customer use and so isn't documented in the user manuals. It serves a number of purposes, but in general it's function is to transfer values to and from the SQL realm into ASE's internal memory structures. The most basic use is in sp_configure, when you change the value of a parameter like "number of locks", the SQL in sp_configure can update the value in sysconfigures, but the value also needs to be changed in ASE's internal memory structures where it can be accessed by the c and c++ code ASE is written in.
The header comments for sp_monitorconfig do contain some information on how it is used by that procedure:
132: ** 2. API for getting monitoring stats:
133: ** -- config_admin() is used to get monitoring stats from the server.
134: ** Following values are passed into this API to indicate the specific
135: ** info we are trying to gather:
136: ** o cmd - Set to be 22 (CFG_RESOURCEMONITOR_VALUE)
137: ** indicating we are gathering statistics.
138: ** o value1 - Set to the @confignum of the resource
139: ** we are interested in.
140: ** o value2 - Set to one of following values:
141: ** 1 - gathering adjusment value
142: ** 2 - gathering the active value
143: ** 3 - gathering the HWM value
144: ** 4 - gathering the reused value
145: ** o value3 - not used
146: ** o value4 - Set to the monitor counter name of
147: ** the resource we are gathing, if
148: ** we get the stats from monitor counters
sp_montitorconfig is certainly a proper way for getting this information, but there may be bugs in it (I didn't find any known ones that would apply to "remote logins" in 15.x). The MDA monitoring tables are another good source for this general kind of information.
Could you post the actual output of your sp_monitorconfig?
Does it show 1300 active remote connections immediately after rebooting ASE, or does the figure grow over time?
-bret
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Bret,
Thanks for the reply..
The limit for the remote connections is 100.
I have an application that creates a remote login to ASE.so far so good..
recently, due to some changes, the applicaiton is getting crashed without closing the remote login connection.
Leave apart the program changes but..why am i not able to see the remote login connection in the sysremotelogin table..?
I now understand what config_admin() does..but how and where does sp_monitorconfig get this information of remotelogins..
User | Count |
---|---|
87 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.