Summary of the invention
In view of this, fundamental purpose of the present invention is to propose a kind of process monitoring method, realizes cross-platform process monitoring, reduces and safeguard and cost of development.
Another object of the present invention is to propose a kind of process monitoring system, realize cross-platform process monitoring, reduce and safeguard and cost of development.
For achieving the above object, the invention provides a kind of process monitoring method, this method comprises:
Receive the monitored Host List request of inquiry of client, obtain windows and the linux Host List managed, return monitored Host List to said client then;
Receive the polling message of the monitored main frame that the setting of client chooses and the concern process list of this main frame, the log-on message that signs in to this main frame is set, and returns the concern process list of this main frame to said client;
Receive the real-time process information of user through the current operation of the monitored main frame of client query; Sign in to this main frame based on the SSH service safe; All real-time process tabulations of the current operation of this main frame are obtained in service based on SNMP; Policy filtering according to the concern process list of this main frame and setting is in advance fallen invalid progress information, exports the real-time process parameter of obtaining to client shows then.
Said monitored Host List comprises: the ip address information of network element, the name information of monitoring process, whether produce that warning information, monitoring process descriptor, acquiescence start script information, acquiescence is closed script information and acquiescence rpms restart script RPMS information.
Said monitored Host List is provided with a kind of or its combination in database format and the extend markup language form.
Said process is made up of a plurality of process parameters, and said process parameter comprises: process identification (PID), process title, process manufacturer identifier, process operating path, process initiation parameter, process type, running state of process, CPU service time and internal memory use size.
Said process type comprises: UNKNOWN TYPE, OS Type, device drives type and Application Type.
Said running state of a process comprises: move, can move, can not move and illegally.
Said process monitoring comprises: process inquiry, process status poll, process initiation, process stops and process is restarted.
Said process initiation comprises:
From pay close attention to the process configuration tabulation, obtain and do not start the process title;
Starting mode according to monitored Host Type, process title and user select is constructed the startup command character string that will carry out;
The process monitoring server is through SSH agreement fill order on monitored main frame, startup process.
Further comprise:
After the monitored main frame fill order success, the SSH service returns to the process monitoring server with the command execution successful information with the byte stream form;
The result that the process monitoring server parses is returned, and obtain the process supplemental characteristic of monitored main frame operation through SNMP;
The process monitoring server exports process supplemental characteristic and the process of startup successful information to the client shows of request process monitoring.
Further comprise:
Concern process list to being provided with upgrades.
Said renewal comprises: increase monitoring process, revise monitoring process and reshuffle the network element polling message.
Saidly export the real-time process parameter of obtaining to client shows and comprise:
The warning strategies of confirming to be provided with in advance is for breaking down in process or notifying the user during unexpected the termination, then after confirming process failure, outputting alarm information notified the user and exported the process parameter information of this fault to client shows.
Further comprise:
Confirm to break down or unexpected concern process status of ending recovers normal, send alarm clearance information to the user.
Said policy filtering according to the concern process list of this main frame and setting is in advance fallen invalid progress information, exports the real-time process parameter of obtaining to client shows then and comprises:
Then confirm can adopt the user name, the password that have disposed to be communicated with by the main frame of request process monitoring through the SSH agreement data acquisition interval time that in paying close attention to the process configuration tabulation, is provided with in advance;
Obtain the real-time process supplemental characteristic set of each monitored main frame according to SNMP;
Identical process, running state of process are for can not move or illegal process in the filter course supplemental characteristic set, and the process supplemental characteristic that obtains filtering is gathered;
Traversal is paid close attention to the concern process in the process configuration tabulation, the identical process of process title of inquiry and the process of concern in the process supplemental characteristic set of filtering, and the concern process that will inquire places real-time process to gather;
Whether the query procedure monitoring server produced not on-line alarm information to the concern process in the real-time process set, if transmission should the on-line alarm of concern process be removed information, otherwise transmission should not on-line alarm of concern process information;
Concern process configuration tabulation according to the concern process updated stored in the real-time process set.
Said log-on message comprises: user name, password, poll time and polling message whether.
A kind of process monitoring system, said process monitoring system comprises based on the C/S structure: client and process monitoring server, wherein,
Client receives the network element list update notice of process monitoring server, trigger obtain the process monitoring server obtain the network element list request, and the monitored network element tabulation that process monitoring server FE end returns is re-loaded on the interface; The real-time process poll that receives the process monitoring server is successfully notified, and triggers and obtains this main frame real-time process request of data, and hold the real-time process tabulation of returning goods to be re-loaded on the interface process monitoring server FE; Trigger the request of monitored host computer polls information setting, the additions and deletions that trigger the concern process change to make a thorough investigation of to be asked, and triggers the manual renewal request of real-time process, triggers the modification request of real-time process;
The process monitoring server; Receive the request that is provided with of monitored host computer polls information; Receive the concern process list request of monitored main frame; The real-time process that receives monitored main frame is revised request, and after the success of SQL statement modification database data, the FE end through self returns to client with result then; At the polling message that has set monitored main frame and after paying close attention to process list; The process monitoring server is connected to the safety certification of this main frame based on the SSH service implementing; The real-time process tabulation of the current operation of this monitored main frame is obtained in service based on SNMP; Concern process list and filtercondition according to this monitored main frame setting filter out invalid process, and the FE end through self returns to client with the real-time process data at last.
Said client comprises: service forwarding module, real-time process configuration module, concern management of process module and display module,
The service forwarding module is used for the various RMI requests, the SOCKET request that receive are transmitted;
Pay close attention to the management of process module, be used for the concern process configuration request of client is forwarded to the process monitoring server; Receive concern process list that the process monitoring server returns and increase, modification, deletion is paid close attention to the process result and is transmitted to display module;
The real-time process configuration module, the real-time process that is used to trigger client is revised, real-time process is manually upgraded request, and with the process monitoring server lookup to the real-time process tabulation of monitored main frame export display module to;
Display module receives and pays close attention to process list, real-time process tabulation, monitored Host List information, shows.
Said client further comprises:
Concern process update module, the concern process additions and deletions that are used to trigger this monitored main frame change to make a thorough investigation of to be asked, and generates according to the data in the process monitoring server database behind the XML file and to pay close attention to process list and show in client.
Said process monitoring service end comprises front end and rear end, wherein,
Front end; The concern process of the client that receives is upgraded request; The request of monitored host computer polls information setting, monitored main frame real-time process is upgraded request, and monitored main frame is paid close attention to process; The real-time process query requests, and obtain all monitored Host List requests of server end and be transmitted to then to the rear end;
The rear end; Receive the request that is provided with of monitored host computer polls information, receive the concern process list request of monitored main frame, the real-time process that receives monitored main frame is revised request; After the success of SQL statement modification database data, then result is returned to client; At the polling message that has set monitored main frame and after paying close attention to process list; Process monitoring server B E end group is connected to the safety certification of this main frame in the SSH service implementing; The real-time process tabulation of the current operation of this monitored main frame is obtained in service based on SNMP; Concern process list and filtercondition according to this monitored main frame setting filter out invalid process, at last the real-time process data are returned FE.
Said rear end is further used for obtaining all monitored windows of server database and Linux Host List, and the concern process list of particular host and real-time process tabulation.
The process that said rear end is further used for being polled to monitored main frame from online become not online, the real-time process tabulation of updated stored, and export this information the client of front end to the notice request process monitoring.
Visible by above-mentioned technical scheme; A kind of process monitoring method and process monitoring system that the embodiment of the invention provides; Receive the request that is provided with of monitored host computer polls information, receive the concern process list request of monitored main frame, the real-time process that receives monitored main frame is revised request; After the success of SQL statement modification database data, the FE end through self returns to client with result then.At the polling message that has set monitored main frame and after paying close attention to process list; The process monitoring server is connected to the safety certification of this main frame based on the SSH service implementing; The real-time process tabulation of the current operation of this monitored main frame is obtained in service based on SNMP; Concern process list and filtercondition according to this monitored main frame setting filter out invalid process, and the FE end through self returns to client with the real-time process data at last.
Like this; Difference through SNMP shielding different operating platform; Reduced maintenance and cost of development,, got access to the process that the user pays close attention to according to SNMP through being provided with and the tabulation of storage concern process configuration; Perhaps order through the long-range execution script of SSH agreement then, thus the configurable and cross-platform process monitoring of implementation process monitoring.
Embodiment
For making the object of the invention, technical scheme and advantage clearer, will combine accompanying drawing and specific embodiment that the present invention is done to describe in detail further below.
Existing process monitoring method realizes the process monitoring under the Windows operating system through calling Windows API, perhaps; Realize the process monitoring under the (SuSE) Linux OS through Linux API, therefore, process monitoring can not be accomplished real cross-platform; And the process monitoring tabulation is provided with by the program development personnel in advance, can not satisfy user's individual demand configuration; For example, in the practical application, the user maybe not need pay close attention to all progress informations; Only need to pay close attention to comparatively crucial several processes, know these in real time and pay close attention to states of a process and change and get final product.
Simple Network Management Protocol (SNMP; Simple Network Management Protocol) be to be used at the IP network managing network node; For example, a kind of standard application layer protocol of client, server, workstation, router and switch etc., the isolating construction of employing agreement and management information; Receive event report message through SNMP from network node (network element); NMS (NMS, Network Management System) can be known the problem that each network element occurs in the network, makes to use SNMP can realize the purpose of different network nodes (network element) in monitoring and the management NMS.
Secure Shell (SSH; Secure Shell) agreement is to be based upon agreement on application layer and the transport layer basis, that security is provided for telnet session and other network services; Have functions such as safe and reliable authenticating user identification, network information encrypted transmission, can be applicable to the different operation platform, thereby; Utilize the SSH agreement, can effectively prevent the information leakage problem in the telemanagement process.
According to internet activities board (IAB; Internet Activities Board) suggestion; All Network Transmission control protocol/Internet protocols (TCP/IP, Transfer Control Protocol/Internet Protocol) equipment must be manageable.Thereby; In the embodiment of the invention, consider implementation process monitoring process initiation, stop, restarting and realize on the basis that is based on the process inquiry, and SNMP can shield the difference of Windows operating platform and Linux operating platform; Process configuration file through being provided with and storing monitored client is to satisfy the demand of user individual; Come the process of the current operation of monitored client is inquired about in real time through SNMP, and, the state of monitoring process reflected in real time through the SNMP status poll; And through the SSH agreement realize to process startup, stop, restarting; Through obtaining of progress information, if confirm that in a single day process breaks down, just through the alarm notification user.Promptly get access to the process that the user pays close attention to through SNMP; Generate corresponding SSH order according to different monitored clients, different process operation; Then through long-range execution script of SSH agreement or order; Thereby the startup of implementation process, stop and restarting, make process startup, stopping and restarting can compatible Windows operating platform and Linux operating platform, thereby realize the process monitoring of cross-platform (system).
The overall procedure of the embodiment of the invention is: receive user's additions and deletions and change and look into the concern process requested, the result who handles is returned client; Receive the user request of host computer polls parameter is set, the result who is provided with after the completion is returned to client; Receive the request of upgrading the network element tabulation, export the network element list collection to on-line client and show; Receive the request of user inquiring real-time process, realize purview certification, obtain host computer side real-time process data based on Simple Network Management Protocol SNMP based on Secure Shell SSH protocol service; And filter out process repeats and invalid process based on specific filtering rule; The concern process that has disposed with this main frame is then done coupling, after coupling is accomplished, according to alarm regulation; Send corresponding alarm, the real-time process after will handling at last exports client shows to.Use the present invention, can realize cross-platform process monitoring, reduce and safeguard and cost of development.
Fig. 1 is the process monitoring method flow synoptic diagram of the embodiment of the invention.Referring to Fig. 1, this process monitoring flow process comprises:
Step 101 receives the monitored Host List request of inquiry of client, obtains windows and the linux Host List managed, returns monitored Host List to said client then;
In this step, receive the process monitoring configuring request of client, obtain monitored host information, return the process monitoring configured list that carries monitored main frame to said client based on SNMP service and SSH protocol service.
In this step,, like this, can not in the practical application, follow SNMP and SSH service, specifically can repeat no more at this referring to the correlation technique document as monitored object if will install at main frame if monitored main frame is not installed SNMP service and SSH protocol service.
Under the default situations, monitored main frame is not dispose the concern process in advance, can increase the concern process through dual mode, follow-uply is described in detail again.The process monitoring client if the user need be provided with the process of oneself the paying close attention to range monitoring of advancing of going forward side by side, is then upgraded request through sending the concern process to the process monitoring server after startup, process configuration is paid close attention in request.
Windows or the monitored main frame of linux that the monitoring of process monitoring server is come up by topology (Topo) discovery; Providing interface to distinguish monitored main frame according to TOPO is Windows operating system or (SuSE) Linux OS, and is loaded into corresponding default concern process list according to OS Type.
The ProcessMonitor.xml partial content is as follows:
Comprise < poll>node among the ProcessMonitor.xml; < poll>node comprises < process>node; It is the process monitoring configured list; < process>node comprises a plurality of < search>node, and < search>node is represented a monitoring process configuration information, and the implication of each attribute of < search>node is as shown in table 1.
Table 1
?ID |
Element name |
?matchCriteria |
Match pattern (only supporting to equate) |
?matchValue |
Matching value |
?generateEvent |
Whether transmission is alarmed |
?severity |
Severity level |
?de?scription |
The process descriptor |
In the table 1, network element is meant monitored main frame.
The process monitoring configured list is stored among the database table HostkeyProcess, and the implication of each field is as shown in table 2 among the table HostkeyProcess.
Table 2
NeID |
The ip address of network element |
ProcessName |
The title of monitoring process |
IsSendNotification |
Whether generation is alarmed |
Description |
Monitoring process is described |
startScript |
Acquiescence starts script |
stopScript |
Acquiescence is closed script |
restartScript |
The acquiescence rpms restart script RPMS |
In the table 2; With element name and concern process of process title combination sign; And with the ip address of network element with pay close attention to process name and be called sign and pay close attention to process configuration, for example, whether produce that alarm, concern process are described, acquiescence starts script, acquiescence is closed script and give tacit consent to rpms restart script RPMS.
Paying close attention to process list can be with extend markup language (XML; Extensible Markup Language) file layout is provided with, and can realize the configurable of the process of paying close attention to the concern progress information of each different monitored main frames of storage to database through this XML file of dynamic change.
A process is made up of a plurality of process parameters; The process parameter mainly comprises: process identification (PID) (PID), process title, process manufacturer identifier, process operating path, process initiation parameter, process type, running state of process, CPU service time and internal memory use size; Wherein
Process type comprises: UNKNOWN TYPE, OS Type, device drives type and Application Type;
Running state of a process comprises: move, can move, can not move and illegally.
Table 3 shows main process parameter and the implication thereof that process comprises.
Table 3
Parameter name |
Meaning of parameters |
Process identification (PID) (PID) |
The process unique identifier is an integer |
The process title |
The title of process is a length between the character string of 0 to 64 byte |
The process manufacturer identifier |
Object identifier, developer's information of this process of unique identification |
The process operating path |
The path of process operation is the character string of a length between 0 to 328 byte |
The process initiation parameter |
Parameter during process initiation is the character string of a length between 0 to 328 byte |
Process type |
The unknown, operating system, device drives, application program |
Running state of process |
Move, can move, can not move, illegally |
CPU service time |
This process has been used the time of CPU |
Internal memory uses size |
The memory size that this process has been distributed |
During process monitoring system initial start,, be windows, load windows and pay close attention to process list such as the main frame of selecting according to the monitored main frame that the user selects.Specifically, return following list information to said client:
Obtain the monitored Host List of process monitoring server;
Realize the purview certification of each monitored main frame based on said SSH protocol service after; Get access to the process of the current operation of each monitored main frame through SNMP; According to the process of the current operation of each monitored main frame of obtaining and the process monitoring configured list that is provided with in advance, the real-time process configured list that the monitoring process configuration information generates monitored main frame, and export the process monitoring client to.
Obtain the concern process list of monitored main frame;
About obtaining the flow process of monitored main frame real-time process through SNMP, follow-uply be described in detail again.
Step 102; Receive the polling message of the monitored main frame that the setting of client chooses and the concern process list of this main frame; Setting signs in to the user name, password, poll time of this main frame and polling message whether, and returns the concern process list of this main frame to said client;
In this step, receive the real-time process query requests of user, carry out process monitoring according to paying close attention to the process configuration tabulation to the monitored main frame chosen.
In this step, process monitoring comprises: process inquiry, process poll, process initiation, process stops and process is restarted etc.
The client user of request process monitoring chooses the login user name of monitored main frame through input; Password authentification has also set the concern process triggers and has obtained the real-time process list request, after receiving the real-time process tabulation that process monitoring server FE end sends over, reloads the real-time process client of tabulating.
Fig. 2 logins the real-time process monitoring configured list interface synoptic diagram of entering for embodiment of the invention user.Referring to Fig. 2, the user logins through host subscriber's name and main frame password, in the process monitoring configured list interface; Include concern process list, whether autopolling tick boxes information and the data acquisition interval information of the network element name of each monitored main frame, the current monitored main frame of choosing, among Fig. 2, process monitoring configured list interface is divided into two hurdles; Hurdle, a left side is monitored Host List, includes four monitored main frames and checks for the user, certainly; Because monitored main frame maybe be a lot, in left hurdle, can also search for monitored main frame according to the network element name; Right hurdle is that the monitored main frame concern process of choosing is provided with the hurdle; The top is whether autopolling tick boxes and data acquisition interval information frame, and the user can be provided with autopolling through choosing the autopolling tick boxes; And through input corresponding data acquisition interval information in data acquisition interval information frame; So that the progress information acquisition time to be set, the below is that the monitored network element of choosing is paid close attention to process list, comprising: whether monitor tick boxes, monitoring process title, monitoring process description, start the script configuration, close script configuration and rpms restart script RPMS configuration.The user can deposit this monitoring process in database to carry out actual monitoring through choosing the monitoring tick boxes.When the user clicks different network element names, the then corresponding network element of this monitored main frame of showing is paid close attention to process list.
In the embodiment of the invention, the user selects the process of monitoring process title http, java, ping, vsftpd in the network element of network element 170.20.27.32 by name to monitor as the concern process, and opens the autopolling function, data acquisition is set is spaced apart 15 seconds.Certainly, in the practical application, can also inquire about other monitored main frame.
After setting the concern process; Client is sent the real-time process query requests and is forwarded to the process monitoring server; The request of receiving of process monitoring server is through SSH service implementing safety certification; Obtain the real-time process data of monitored main frame through SNMP, and from the real-time process of the monitored main frame that obtains, match the real-time process tabulation that is complementary with the concern process, then the real-time process tabulation is sent to client through FE.
Certainly; In the practical application, the polling message that the user also can upgrade and monitored main frame is set the concern process of monitored main frame, renewal comprises: increase monitoring process, revise monitoring process, delete monitoring process and reshuffle network element polling message etc.; Wherein
When needs increased monitoring process, the user got into process monitoring host configuration interface, and the network element of selecting according to the user loads the monitoring process tabulation from ProcessMonitor.xml and database table HostKeyProcess, and loading rule is following:
For the network element monitoring process that exists among the database table HostKeyProcess; On the interface, be shown as the state of choosing; For there not being the still network element monitoring process of ProcessMonitor.xml existence among the database table HostKeyProcess, on the interface, be shown as cancellation and choose state.
Like this, the user can increase to database table with monitoring process through following dual mode.
(1) chooses optional monitoring process tabulation;
(2) manually increase monitoring process in database table HostKeyProcess.
The modification of monitoring process:
When the user gets into process monitoring host configuration interface; The network element of selecting according to the user loads the monitoring process tabulation from ProcessMonitor.xml and database table HostKeyProcess; After loading completion; Selection needs the monitoring process supplemental characteristic of modification, can accomplish the modification to monitoring process, and the revisable field of monitoring process is following:
(1) Description, the descriptor of modification monitoring process;
(2) startScript, the acquiescence of revising monitoring process starts script position;
(3) stopScript revises the acquiescence of monitoring process and closes script;
(4) restartScript, the acquiescence rpms restart script RPMS of modification monitoring process.
Reshuffling of network element polling message:
Can be at the polling message of host configuration panel configuration network element, be provided with successfully after, be saved among the database table NePoller, configurable network element polling message field is following:
(1), host subscriber's name, promptly connect the user name of this main frame;
(2), the main frame password, promptly connect the password of this main frame;
(3), whether autopolling, promptly the process supplemental characteristic of periodic polling main frame whether has only the user name of working as, password comes into force and main frame when the SSH service has been installed, autopolling field parameter is just effectively for this;
(4), data acquisition at interval, i.e. cycle of poll, when having only whether autopolling to choose, this data acquisition spacing parameter is just meaningful.
After being provided with successfully, with the NePoller that deposits in the database table, each parameter is as shown in table 4 in the NePoller table.
Table 4
NeID |
The ip address of main frame |
userName |
Host subscriber's name |
password |
The main frame password |
Type |
NE type |
IsPoller |
Whether carry out the process status poll |
Period |
The polling interval |
Carrying out process monitoring mainly is to check main frame process supplemental characteristic.
If satisfy following two conditions, can switch perhaps to click through network element and confirm to jump to main frame process supplemental characteristic panel:
(1) user has configured the network element polling message and the user name password is correct, and installs and started the SSH protocol service;
(2) this main frame is installed and has been started the SNMP service, if the SNMP service is not installed, can't obtain main frame process supplemental characteristic through SNMP.
Main frame real-time process inquiry is based on SNMP, can shield the difference of dissimilar network elements through SNMP, and obtains the progress information of the current operation of main frame through table hrSWRunTable in the Query Database and table hrSWRunPerfTable.Specifically, at first inquire the monitoring process of this network element, be complementary with table hrSWRunTable that obtains through SNMP and table hrSWRunPerfTable then, thereby obtain the progress information of the current operation of main frame from database table HostKeyProcess.
Above-mentioned increase monitoring process, modification monitoring process and configuration network element polling message are in the process monitoring client by the user; In the practical application; Can also mainly be to monitor newfound network element, thereby in the process monitoring configured list of storage in advance, carry out the inquiry of network element tabulation, the automatic renewal of network element tabulation and the manual renewal of network element tabulation by process monitoring server initiation request to the process monitoring server; Wherein
The inquiry of network element tabulation:
Network element and the tabulation of the NE type in the ProcessMonitor.xml file that the user finds according to Topo backstage (process monitoring server) get into process monitoring host configuration interface and load new network element.
The automatic renewal of network element tabulation:
When Topo backstage new discovery Windows or Linux main frame, upgrade the network element tabulation through the client of all connections of Socket communication notifications.
The manual renewal of network element tabulation:
The manual renewal of network element tabulation is mainly used in when upgrading failure automatically, and is consistent with database for guaranteeing the network element tabulation of process monitoring place.Specifically, the network element data that the NE type list query from database in the ProcessMonitor.xml file need be upgraded, and be loaded on the process monitoring network element panel.
Step 103; Receive the real-time process information of user through the current operation of the monitored main frame of client query; Sign in to this main frame based on the SSH service safe; All real-time process tabulations of the current operation of this main frame are obtained in service based on SNMP, fall invalid progress information according to the policy filtering of the concern process list of this main frame and setting in advance, export the real-time process parameter of obtaining to client shows then.
In this step, export the real-time process parameter of obtaining that is complementary with the concern process to client shows.
In this step; Filter real-time process according to the concern process that is provided with in advance: if be arranged in advance that process breaks down or notify the user during unexpected the termination; Then after confirming process failure, notify the user also to export the process parameter information of this fault to client shows outputting alarm information; Show concern process parameter if be provided with in advance, the process parameter information of the concern that then will obtain exports client shows to.
Further, the situation for outputting alarm information also comprises:
Confirm to break down or unexpected concern process status of ending recovers normal, send alarm clearance information to the user.Like this; Real-time status management through process inquiry and poll running state of a process implementation process if the critical processes that the user pays close attention to is ended because of accident, then produces the alarm information noticing user; If the critical processes recovering state that the user pays close attention to is normal, then send alarm clearance information.
Fig. 3 is for obtaining the schematic flow sheet of process parameter through the process status poll in the existing process monitoring method.Referring to Fig. 3, adopt process status polling mode query procedure state, the process poll is carried out at the process monitoring server end, and this flow process comprises:
Step 301, whether inquiry has opened the poll switch, if, execution in step 302, otherwise, process ends;
In this step; The data acquisition interval time that is provided with in advance then; If NMS (NMS; Network Management System) inquires in the concern process configuration tabulation that the client (network element) in the request process monitoring of storage is provided with and opened the autopolling switch, then enter into step 302, otherwise finish this poll.
In the embodiment of the invention, network element is monitored windows or linux main frame, and promptly monitored main frame, NMS comprise process monitoring server and process monitoring client.
Step 302, whether inquiry can adopt the user name, the password that have disposed to be communicated with this monitored main frame of choosing through the SSH agreement, if, execution in step 303, otherwise, process ends;
In this step, monitored main frame carries out authentication to the process monitoring server.
Step 303, the process supplemental characteristic set of obtaining monitored network element according to SNMP;
In this step, send the request of process parameter acquiring to monitored network element, obtain and create the real-time process supplemental characteristic set A of each monitored network element side through SNMP.
Step 304, identical process among the filter course supplemental characteristic set A is obtained process supplemental characteristic set A1;
In this step, judge whether two processes are identical, adopt process title and process operating path to mate.If the process title of two process parameters is all identical with the process operating path, then confirm two identical or repetitions of process, keep one of them process.
Step 305, running state of process obtains process supplemental characteristic set A2 for can not move or illegal process among the filter course supplemental characteristic set A1;
In this step, from process supplemental characteristic set A1, filter out running state of process, obtain the process of running state of process for moving and can move for moving the process of (not-running), illegal (invalid).
Step 306 is obtained the concern process configuration tabulation that the user is provided with from nms database, obtain paying close attention to process collection B;
In this step; In the concern process configuration tabulation that the user is provided with, be provided with the concern process of each monitored network element, paying close attention to the process configuration tabulation is the network element side configuration of user at the request monitoring process; Can increase, delete, revise the concern process of each network element, deposit nms database after the configuration successful in.
Step 307, if the element number of paying close attention among the process collection B is 0, execution in step 316, otherwise, execution in step 308;
In this step, create concern process collection C to be updated and real-time process set D.Traversal is paid close attention to process collection B, if pay close attention to the concern process that does not have configuration among the process collection B, the element number of promptly paying close attention among the process collection B is 0, gets into step 316, otherwise, execution in step 308.
Step 308 for arbitrary concern process of paying close attention among the process collection B, is gathered the identical process of process title of inquiring about among the A2 with the process of concern at the process supplemental characteristic, and the concern process that will inquire places real-time process set D;
In this step, from process supplemental characteristic set A2, seek and pay close attention to the real-time process of the process title of the concern process among the process collection B, put into real-time process set D.
Whether step 309, the number of judging element among the real-time process set D greater than 0, if, execution in step 310, otherwise, execution in step 332;
In this step,, show among the process supplemental characteristic set A2 that obtains through SNMP to have the concern process that is complementary with concern process collection B if whether the number of element is greater than 0 among the real-time process set D.
Step 310, whether inquiry NMS had produced the not on-line alarm information that this network element is paid close attention to process, if, execution in step 311, otherwise, execution in step 315;
In this step, process is not online to comprise that process can not be moved and process is illegal.
Step 311, NMS sends this network element and pays close attention to process on-line alarm removing information;
In this step; If NMS had produced this network element and had paid close attention to not on-line alarm of process information; Promptly this network element concern process occurred unusual before the current process status poll and notified the user; Then send this network element and pay close attention to process on-line alarm and remove information, and revise this network element pay close attention to process whether the generation alarm attributes is false.Alarm attributes identifies through zone bit, pays close attention to process and whether has produced alarm in order to represent this network element, when zone bit is true; It is not online to represent that this network element is paid close attention to process, and when zone bit is false, it is online to pay close attention to process; Certainly; In the practical application, also can be provided with when zone bit be true, it is online to represent that this network element is paid close attention to process.
Step 332, whether inquiry NMS had produced this network element and had paid close attention to not on-line alarm of process, if not, execution in step 315, otherwise, execution in step 313;
In this step, if the number of element is 0 among the real-time process set D, show among the process supplemental characteristic set A2 that obtains through SNMP not exist the network element that is complementary with concern process collection B to pay close attention to process that it is online for not that this network element is paid close attention to process status.
Step 313, NMS sends this network element and pays close attention to process on-line alarm removing information;
Step 314 is added network element concern process among the concern process collection C to be updated to;
In this step, pay close attention to process status when network element and become onlinely, perhaps become not onlinely, all need revise and whether send the alarm field in the database by online by not online, thereby, need to upgrade nms database.
In step 313 to the step 314, pay close attention to not on-line alarm of process if produce this network element before the NMS, then NMS sends this network element and pays close attention to not on-line alarm of process, and revise network element pay close attention to process whether the generation alarm attributes is True.
Step 315, transmission should not on-line alarm of concern process information, and all processes among the concern process collection C to be updated are increased among the real-time process set D, return execution in step 307;
In this step,, add network element and pay close attention to process in concern process collection C to be updated, and concern process collection C to be updated is added among the real-time process set D if the number of element is 0 among the real-time process set D; Otherwise directly network element concern process is added among the real-time process set D.
Step 316 is updated to the element among the concern process collection C to be updated in the nms database;
Step 317, the element that real-time process is gathered among the D is updated in the nms database.
So far, process poll flow process finishes, and the inquiry of process status is equivalent to once simple process poll, and its flow process and process poll flow process are similar, repeat no more at this.
Fig. 4 is the process monitoring system architecture synoptic diagram of the embodiment of the invention.Referring to Fig. 4, this system comprises: client (Client) and process monitoring server (Server), and the process monitoring system is based on the C/S structure, wherein,
Client receives the network element list update notice of process monitoring server, trigger obtain the process monitoring server obtain the network element list request, and the monitored network element tabulation that process monitoring server FE end returns is re-loaded on the interface; The real-time process poll that receives the process monitoring server is successfully notified, and triggers and obtains this main frame real-time process request of data, and hold the real-time process tabulation of returning goods to be re-loaded on the interface process monitoring server FE; Also be responsible for triggering the request of monitored host computer polls information setting in addition, the additions and deletions that trigger the concern process change to make a thorough investigation of to be asked, and triggers the manual renewal request of real-time process, triggers the modification request of real-time process.
The process monitoring server; Receive the request that is provided with of monitored host computer polls information; Receive the concern process list request of monitored main frame; The real-time process that receives monitored main frame is revised request, and after the success of SQL statement modification database data, the FE end through self returns to client with result then.At the polling message that has set monitored main frame and after paying close attention to process list; The process monitoring server is connected to the safety certification of this main frame based on the SSH service implementing; The real-time process tabulation of the current operation of this monitored main frame is obtained in service based on SNMP; Concern process list and filtercondition according to this monitored main frame setting filter out invalid process, and the FE end through self returns to client with the real-time process data at last.
Wherein,
Client comprises: service forwarding module, real-time process configuration module, concern management of process module and display module (not shown),
The service forwarding module is used for the various RMI requests, the SOCKET request that receive are transmitted;
The real-time process configuration module, the real-time process that is used to trigger client is revised, real-time process is manually upgraded request, and with the process monitoring server lookup to the real-time process tabulation of monitored main frame export display module to;
Pay close attention to the management of process module, be used for the concern process configuration request of client is forwarded to the process monitoring server; Receive concern process list that the process monitoring server returns and increase, modification, deletion is paid close attention to the process result and is transmitted to display module;
Display module receives and pays close attention to process list, real-time process tabulation, monitored Host List information, shows.
Preferably, this client further comprises:
Concern process update module, the concern process additions and deletions that are used to trigger this monitored main frame change to make a thorough investigation of to be asked, and generates according to the data in the process monitoring server database behind the XML file and to pay close attention to process list and show in client.
In the present embodiment, pay close attention to the process configuration tabulation,, pay close attention to the process configuration tabulation thereby generate through choosing in the tick boxes that in the process monitoring configured list, provides with respect to the process monitoring configured list.
Renewal comprises: increase monitoring process, delete monitoring process, revise monitoring process and reshuffle the network element polling message.
Process through not choosing during the concern process configuration is tabulated is chosen, thereby can realize the increase of monitoring process, certainly, also can pass through manual releasing, in paying close attention to the process configuration tabulation, increases monitoring process.If choose paying close attention to the process cancellation of choosing in the process configuration tabulation, then can realize the deletion of monitoring process.
Choose and pay close attention to the monitoring process of choosing in the process configuration tabulation, revise the supplemental characteristic of this monitoring process, can accomplish modification monitoring process.Reshuffling of network element polling message can be realized through revising host subscriber's name of paying close attention in the process configuration tabulation, main frame password, whether autopolling and data acquisition interval information in similar ground.
As previously mentioned, the process monitoring server is deleted monitoring new NE Discovery or old network element, needs to upgrade the process monitoring configured list; And with the client of this information notice request process monitoring; Like this, the process monitoring config update tabulation of the concern process update module receiving process monitoring server of client output is upgraded and is paid close attention to the process configuration tabulation; For example; For the monitored main frame that increases newly, in paying close attention to the process configuration tabulation, add the progress information of corresponding this monitored main frame, so that the user provides selection when next update is paid close attention to the process configuration tabulation.
The process monitoring server comprises front end (FE, Front End) and rear end (BE, Back End) (not shown), wherein,
FE; The concern process of the client that receives is upgraded request; The request of monitored host computer polls information setting, monitored main frame real-time process is upgraded request, and monitored main frame is paid close attention to process; The real-time process query requests, and obtain all monitored Host List requests of server end and be transmitted to then to the rear end;
BE; Receive the request that is provided with of monitored host computer polls information, receive the concern process list request of monitored main frame, the real-time process that receives monitored main frame is revised request; After the success of SQL statement modification database data, then result is returned to client; At the polling message that has set monitored main frame and after paying close attention to process list; Process monitoring server B E end group is connected to the safety certification of this main frame in the SSH service implementing; The real-time process tabulation of the current operation of this monitored main frame is obtained in service based on SNMP; Concern process list and filtercondition according to this monitored main frame setting filter out invalid process, at last the real-time process data are returned FE.
Further, BE also is used to obtain all monitored windows of server database and Linux Host List, and the concern process list of particular host and real-time process tabulation.
Preferably, the process that BE also is used to be polled to monitored main frame from online become not online, the real-time process tabulation of updated stored, and export this information the client of front end to the notice request process monitoring.
Face the mainly responsible operation of FE and BE down and remake description.
FE, the main renewal (for example, the increase of network element, deletion, modification etc.) of monitoring network element, the monitoring of network element polling message change, the RMI (RMI of client of being responsible for; Remote Method Invocation) request and, after autopolling is accomplished, send socket (Socket) message etc. to client; The promptly main request of being responsible for receiving client; And it is transmitted to BE, and receive the information of BE output, forward it to client.
BE is responsible for main operation, comprises that (DB Database), be i.e. the inquiry of process monitoring configured list, carry out the SSH order, obtains the process supplemental characteristic of network element side through SNMP through the SSH agreement to the network management data storehouse.
Client, the main displaying of being responsible for user's mutual and process supplemental characteristic.
Relation between Client, FE, the BE is following:
Client and the identical Socket of FE registration are to carry out Socket communication.
Client communicates by letter through RMI with FE, and FE communicates by letter through RMI with BE.
Client is responsible for receiving user's request; Call the RMI interface of FE and (for example revise the network element polling message; Whether poll, host subscriber's name, main frame password and polling interval etc.), concern process, real-time process start script, rpms restart script RPMS, close the configuration of script, can also call the RMI interface of FE, FE is forwarded to the BE end with these RMI requests again; FE end is not done actual processing, by the startup of BE end implementation process, stop, restarting and the manual renewal of process status.
In addition, client safeguards also that with FE Socket communicates by letter, and Client mainly receives the following incident from FE:
I, when NMS finds newly-increased network element, deletion network element or revises network element attribute, Client receives the renewal network element list message that FE sends over through Socket, Client reloads the network element tabulation from nms database then.
II, the process autopolling of network element is accomplished in NMS, and Client receives the updating real-time process interface message that FE sends over through Socket, and Client reloads the real-time process tabulation from nms database then.
III, after client is upgraded the success of network element polling message, send to FE and to upgrade polling tasks message, server FE loads up-to-date network element polling tasks tabulation from nms database then.
Fig. 5 obtains the schematic flow sheet of process supplemental characteristic through SNMP for the embodiment of the invention.SNMP obtains the process supplemental characteristic and refers to; NMS obtains the data among table hrSWRunTable of Host-resource.mib on the monitored client and the table hrSWRunPerfTable through SNMP; Shown hrSWRunTable and shown the hrSWRunPerfTable detail record progress information of current monitored client operation; Referring to Fig. 5, this flow process comprises:
Step 501, client are chosen and are not started the process record, click the process that do not start;
In this step, client selects not start process through paying close attention to the process configuration tabulation.
Step 502 is obtained this and is not started the process title;
Step 503 is constructed the startup command character string that will carry out according to the Starting mode that NE type, process title and user select;
In this step, client can only be carried out start-up operation to the process that does not start, and can construct startup command through three kinds of modes:
(1) script startup mode: promptly directly carry out startup with user configured startup script;
(2) service Starting mode: comprise that the net start Service name startup of windows operating system and the service Service name start of (SuSE) Linux OS start;
(3) User Defined Starting mode: user oneself input order arbitrarily starts.
Similar ground for stopping process, can only carry out shut-down operation to the process that has started, and the process of stopping can being constructed order through four kinds of modes:
(1) script stops mode: promptly directly carry out and stop with the user configured script that stops;
(2) service stopping mode: the net stop Service name that comprises windows operating system stops and the service Service name stop of (SuSE) Linux OS stops;
(3) force to stop mode: the taskkill/F/PID process ID that comprises windows operating system stops and the kill-9pid of (SuSE) Linux OS stops;
(4) User Defined stops mode: user oneself input order arbitrarily stops.
For restarting process, can only carry out start-up operation to the process that does not start, can construct order through three kinds of modes:
(1) script is restarted mode: promptly directly carry out with user configured rpms restart script RPMS and restart;
(2) mode is restarted in service: net stop Service name, the net start Service name that comprises windows operating system restarted and the service Service name restart of (SuSE) Linux OS;
(3) User Defined is restarted mode: user oneself input order is arbitrarily restarted.
Step 504, the interface that calls front end will be carried out startup process command request and be forwarded to front end;
Step 505, front end receive the startup process requested of monitored main frame, and are forwarded to the rear end;
Step 506, rear end are called the SSH agreement and on monitored main frame, are carried out the SSH order;
Step 507, monitored main frame are carried out the SSH order, and execution result (success of startup process) is returned to the rear end with the byte stream form;
Step 508, the result who returns is resolved in the rear end, and obtains the up-to-date data of monitored network element side through SNMP;
Step 509, the real-time process after the rear end will be handled deposits in the SNM database;
The real-time process result that step 510, rear end are returned after the processing gives front end;
The real-time process result that step 511, front end are returned after the processing gives client;
Step 512, result after the client shows startup process and up-to-date implementation process table data.
By above-mentioned visible; The process monitoring method of the embodiment of the invention, process monitoring Apparatus and system; Through the difference of SNMP shielding Windows operating platform and Linux operating platform, and the process configuration file through monitored client is set is to satisfy the demand of user individual.Like this, can inquire about in real time the process of the current operation of monitored client through SNMP, and through the SSH agreement realize to process startup, stop, restarting, make when process breaks down, can be through the alarm notification user.Have following beneficial effect:
One, reflects state of a process in real time, make the variation of process status to be reflected in real time on the user client;
Two, can be through revising the configurable of configuration file implementation process monitoring;
Three, shielded the difference of operating system in the process monitoring, accomplished real cross-platform;
Four, can reduce cost of development, minimizing maintenance workload, improve the work efficiency of process monitoring.
The above is merely preferred embodiment of the present invention, is not to be used to limit protection scope of the present invention.All within spirit of the present invention and principle, any modification of being done, be equal to replacement and improvement etc., all should be included within protection scope of the present invention.