CN101795206B - Method and device for realizing SNMP agent on distributed equipment - Google Patents

Method and device for realizing SNMP agent on distributed equipment Download PDF

Info

Publication number
CN101795206B
CN101795206B CN2009102248477A CN200910224847A CN101795206B CN 101795206 B CN101795206 B CN 101795206B CN 2009102248477 A CN2009102248477 A CN 2009102248477A CN 200910224847 A CN200910224847 A CN 200910224847A CN 101795206 B CN101795206 B CN 101795206B
Authority
CN
China
Prior art keywords
snmp
rpc
request
xdr
message
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN2009102248477A
Other languages
Chinese (zh)
Other versions
CN101795206A (en
Inventor
马晓靖
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Zhigu Tech Co Ltd
Original Assignee
Fujian Star Net Communication Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fujian Star Net Communication Co Ltd filed Critical Fujian Star Net Communication Co Ltd
Priority to CN2009102248477A priority Critical patent/CN101795206B/en
Publication of CN101795206A publication Critical patent/CN101795206A/en
Application granted granted Critical
Publication of CN101795206B publication Critical patent/CN101795206B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention discloses a method and a device for realizing an SNMP agent on distributed equipment. The method comprises that when the SNMP agent receives a simple network management protocol (SNMP) message transmitted by a network management system (NMS), an operation request in the SNMP message is converted into a remote procedure call (RPC) request which is transmitted to an RPC client; the RPC client uses RPC communication to transmit the RPC request to an RPC server on a controlled board; the RPC server converts the RPC request into a function call to a local managed object, a module to be managed is called to complete management request operation, and the return value of the procedure call is transmitted to an RPC client on a master control board; the RPC client transmits the return value of the RPC call to the SNMP agent; and after the SNMP agent receives the return value, the SNMP agent explains the return value into SNMP operation results, and the SNMP operation results are encapsulated in an SNMP answer message and are returned to the NMS. By adopting the method and the device, the invention can solve the problems in the prior art that the complexity of SNMP multilevel agents is high and the workload is heavy.

Description

A kind of method and apparatus of on distributed constitution equipment, realizing the SNMP agency
Technical field
The present invention relates to network communications technology field, relate in particular to a kind of method and apparatus of on distributed constitution equipment, realizing the SNMP agency.
Background technology
The formation of a SNMP (Simple Network Management Protocol, Simple Network Management Protocol) system is as shown in Figure 1 usually, comprises following element:
Several nodes, each node memory is acted on behalf of at a SNMP, and this entity has comprised response command and the application program that produces announcement; Node with the whole SNMP of comprising agency in some technical documentations is called the SNMP agency, then is meant the software module of intra-node completion SNMP agent functionality in this article;
At least one manager NMS (Network Management Station), this entity have comprised the application program that produces order and/or receive announcement.
A management agreement, promptly snmp protocol is used for transmit management information between NMS and agency.In the SNMP system, managed object defines according to the requirement of SMI (Structure of Management Information, structure of management information) standard, and this message structure main feature can be summarized as follows:
Whole management object system is with classification, tree structure tissue, and managed object is the leaf node of tree structure, and managed object is retrieved and traveled through with the mode of dictionary preface.
The database that defines all kinds of managed objects is called MIB (Management Information Base, management information bank), and the file of depositing these information is called mib file.In mib file; Managed object is divided into each module (MODULE) by its function of dominant; The module here is not meant software module; Both do not have necessary relation, and usually managed object possesses the equivalence value of an inside in software module, and the operation requests of managed object is converted into the operation to its equivalence value in software module.
As shown in Figure 2, the building method of interface between SNMP agency and the managed object in the prior art, SNMP node processing NMS operation requests specifically comprises step:
Step 201, the SNMP that receives input asks;
Step 202 is carried out syntactic analysis and is converted internal form to;
Step 203 is mapped to local equivalence value with mib variable;
Step 204, this locality of carrying out request obtains/stores;
Step 205 will be replied and converted foreign format to;
Step 206 is sent response and is given NMS.
In the above-mentioned steps, step (4) is accomplished by the module at managed object place, and other process is all accomplished by the SNMP proxy module.Because object distribution that SNMP managed is in each module of system, how the relation of treatment S NMP proxy module and these modules is technological emphasis that the SNMP agency designs, and concrete in the prior art implementation comprises:
The SNMP node of A, distributed formation;
As shown in Figure 3, the equipment of distributed formation generally includes with lower member:
A master control borad is responsible for the collaborative work of whole equipment, and management interface externally is provided, and for example, handles the order of man-machine interaction, the reception/transmission of the message in the SNMP mode;
A plurality of controlled board, each controlled board are comparatively independently computer subsystems, are responsible for the service part of equipment, and these business itself need externally provide management interface;
Possess management channels between master board and the controlled board, the control request of master board and response are through this management channels transmission.
In the equipment of distributed formation; Owing to possibly be distributed on a plurality of controlled board by administration module; Their address space is isolated, and can not adopt local function call to accomplish the operation requests of SNMP again, and the method for therefore above-mentioned mib compiling structure software can not directly be used again.
To above-mentioned situation, existing solution is normally acted on behalf of classification with SNMP: in master board, realize master agent, realize sub agent on the controlled board, the distribution of being responsible for snmp message by master agent with converge.For example, (RFC1227) (Agent Extensibility Protocol acts on behalf of Extended Protocol to standardized SMUX agreement, and what RFC2741) adopt all is this model with the AgentX agreement for SNMP multiplexing protocol, SNMP multiplex protocol.Below be the operation principle that example is introduced this model with SMUX:
As shown in Figure 4, mark off master agent and sub agent at intra-node, the step of SNMP node processing NMS operation requests comprises:
Step 401, after sub agent started, the MIB subtree that it is in charge of was registered on the master agent;
Step 402, master agent is resolved management request after the snmp management request that receives from NMS, judges the MIB subtree position of managed object, management request is transmitted to the sub agent of this MIB subtree of management;
If comprised the operation requests that mails to a plurality of sub agents in the snmp message, then handle complicated more: master agent sends to corresponding sub agent after need message being disassembled by subtree, also will the response of each sub agent be synthesized one and reply;
Step 403, sub agent after receiving the snmp management request that master agent forwards, accomplish handle after, will reply and send back to master agent;
Step 404, master agent will be replied relaying and sent to NMS;
This type is that based on multistage agency's distributed schemes major defect the complexity of scheme is higher, realizes that workload is bigger.If distributed apparatus is inner to be adopted multistagely when acting on behalf of scheme, following difficulty is arranged:
Master agent on the master control borad need be known the distribution of sub agent, resolves replying that the request mail to sub agent and sub agent beam back.When the operation requests of a plurality of sub agents need was crossed in processing, collaborative work was just complicated more, for example, and when having comprised the request to a plurality of sub agents in snmp message; And for example, when get-next operation when a sub-tree crosses another subtree, all need master agent further to handle according to the formation of MIB tree and the return results of sub agent;
Because master control borad this locality also has by administration module, master agent constitute two kinds of selections: the local sub agent of also being realized in the administration module, then master agent does not need directly with mutual by administration module; Perhaps master agent comprises tradition agency's function.No matter any method all makes the SNMP function of master control borad realize the complicacy than the tradition agency undoubtedly.
On each controlled board, all need realize the function of SNMP sub agent; It is redundant that master control borad and controlled board have partial function, like message parse, security control etc.;
Define the communication mode that adopts between master control borad and the controlled board, for example SNMP SMUX will use the TCP link.
Summary of the invention
The present invention provides a kind of method and apparatus of on distributed constitution equipment, realizing the SNMP agency, is used for overcoming the multistage complexity height of acting on behalf of of prior art SNMP, realizes the bigger problem of workload.
A kind of SNMP agent node of on distributed constitution equipment, realizing comprises master control borad and controlled board, comprises SNMP agency and RPC client computer in the said master control borad; Comprise managed object and RPC server in the said controlled board, wherein,
The SNMP agency; The Simple Network Management Protocol snmp message that the person NMS that is used for the receiving management sends; And convert the operation requests in this snmp message into invocation of procedure RPC request; This invocation of procedure RPC request is passed to the RPC client computer, and the return value that the RPC client computer is sent is interpreted as the SNMP operating result, and this SNMP operating result is packaged in sends back to said NMS in the SNMP response message;
The RPC client computer is used to use RPC communication that said RPC request is sent to the RPC server, and receives the return value of RPC request;
Said RPC server is used for converting the RPC request into to the local management object function call, sends function call request to said managed object, and said RPC client computer is returned in the return value transmission of said function call;
Managed object is used to provide the function call interface of accomplishing management request, receives the call request that said RPC server sends, and will call the result and return to said RPC server.
A kind of method that on distributed constitution equipment, realizes the SNMP agency is characterized in that, comprising:
When the agency of the SNMP in the master control borad receives the Simple Network Management Protocol snmp message of manager NMS transmission; Convert said snmp message into native data formats; And convert the operation requests in this snmp message into invocation of procedure RPC request, pass to the RPC client computer that is provided with on this master control borad;
The RPC client computer uses RPC communication that the RPC request is sent to the RPC server on the controlled board;
RPC server on the controlled board converts RPC request into to the local management object function call, and calls and saidly accomplished the management request operation by administration module, and master control borad is returned in the return value transmission of the invocation of procedure;
After said SNMP agency receives said return value, this return value is interpreted as the SNMP operating result, and this SNMP operating result is packaged in the SNMP response message returns to NMS.
The method and apparatus that the embodiment of the invention provided docks the SNMP system with ONC RPC system, utilize ONC RPC to transmit the management operation request between master control borad and the controlled board.Shield the difference of remote procedure call and LPC by ONC RPC, make SNMP proxy module and constructed, avoid the multistage SNMP agency plant of complex structure by the mode that administration module can still call according to this locality.
Description of drawings
Fig. 1 is the formation structure chart of SNMP system in the prior art;
Fig. 2 is the flow chart of the building method of interface between SNMP agency and the managed object in the prior art;
Fig. 3 acts on behalf of the structure chart of the equipment of distributed formation for SNMP in the prior art;
Fig. 4 is for marking off the flow chart of the SNMP node processing NMS operation requests of master agent and sub agent in the prior art at intra-node;
Fig. 5 A is a RPC process of the program frame sketch map that rpcgen generates in the prior art;
Fig. 5 is a kind of structural representation of on distributed constitution equipment, realizing SNMP agency's node of the embodiment of the invention;
Fig. 6 is a kind of flow chart of on distributed constitution equipment, realizing SNMP agency's method of the embodiment of the invention.
Embodiment
A kind of node of on distributed constitution equipment, realizing the SNMP agency of the embodiment of the invention comprises master control borad and controlled board, comprises SNMP agency and RPC client computer in the said master control borad; Comprise managed object and RPC server in the said controlled board; Wherein, the Simple Network Management Protocol snmp message that SNMP agency, the person NMS that is used for the receiving management send; And convert the operation requests in this snmp message into invocation of procedure RPC request; This invocation of procedure RPC request is passed to the RPC client computer, and the return value that the RPC client computer is sent is interpreted as the SNMP operating result, and this SNMP operating result is packaged in sends back to said NMS in the SNMP response message; The RPC client computer is used to use RPC communication that said RPC request is sent to the RPC server, and receives the return value of RPC request; Said RPC server is used for converting the RPC request into to the local management object function call, sends function call request to said managed object, and said RPC client computer is returned in the return value transmission of said function call; Managed object is used to provide the function call interface of accomplishing management request, receives the call request that said RPC server sends, and will call the result and return to said RPC server.
For reaching the task of the SNMP proxy module of realizing distributed constitution equipment, the present technique scheme is docked the SNMP system with ONC RPC system, utilize ONC RPC to transmit the management operation request between master control borad and the controlled board.Shield the difference of remote procedure call and LPC by ONC RPC, make SNMP proxy module and constructed, avoid the multistage SNMP agency plant of complex structure by the mode that administration module can still call according to this locality.
Wherein RPC (Remote procedure call, remote procedure call) is specially:
RPC is a kind of inter-process communication mechanisms; It makes a computer program can call the process that is positioned at another address space; And need not pay close attention to the details of this remote interaction, need not be concerned about again when it makes coding the process that need call be local, or on remote system (said here process is exactly a function for the C programming language).
RPC has multiple implementation, can adopt ONC RPC (Open NetworkComputing Remote Procedure Call, open network calculate RPC) in embodiments of the present invention, wherein ONC RPC framework mainly comprise following characteristics:
Process can only have a parameter, a return value; When needs transmit a plurality of numerical value, can take they are encapsulated as the method for a structure;
The transport layer independence does not need transmission service reliably;
Call semanteme, call semantical definition client computer to calling the hypothesis that the result can do.ONC RPC provides " once minimum " semanteme, promptly calls when returning when one, and it has been performed once at least;
Data representation, the data type of ONC RPC adopt XDR (External Data Representation, External Data Representation) expression, and XDR is a kind of dtd standard, and it has defined the expression way of transmission data between the computer system of different systems.
XDR is a kind of data type by implication definition; The information that does not comprise data type in the data that this mode defines; Therefore require data producer and consumer that the explanation of data is reached an agreement through other means, as arranging to explain through additional document or interface.
A process is through tlv triple (program number, program version numbering, process numbering) sign
Program is meant the set of one group of correlated process, and each process wherein all has unique numbering.For example, NFS (Network File System, NFS) is exactly a program among the RPC, and its program number is 0x10_0002, and current version numbering is 3, and file operation such as read (reading), write (writing) etc. all are the processes among the NFS.
The uniqueness of numbering can adopt the whole bag of tricks to guarantee.This programme only relates to the numbering of device interior, and the scope that numbering is used is very little, so solution do not need very complicatedly, for example can take preallocated method.
Bind, which platform main frame is client computer need know service earlier on, then could the access services process.This problem can adopt several different methods to solve; For example; Can solidify the corresponding relation of service processes and address, more method in common is a service processes with its service registry in a certain appointed position, the client when operation from the corresponding relation of the appointed position service of obtaining with the address.
ONC RPC adopts the client-server working model, and client computer refers to call the program (or software systems) of RPC process, and server is meant the program (or software systems) that realizes the RPC process.
ONC RPC realizes that needed program frame adopts RPC CompilerTools (RPCLanguage Compiler) rpcgen to construct usually.Rpcgen can be according to the remote process explanation in the RPC specification file (RPCspecification); Generation is used to dock the program frame of client computer and server, makes the developer need not be concerned about that the RPC process accomplishes needed program module and reciprocal process.
The content of RPC specification file is to indicate client computer and server needs Sharing Information, generally includes the tabulation of program number/start context, process statement far away, comprises its parameter declaration, returned value specification and numbering:
For example, realize the process of a long-range integer summation, its RPC specification file is following:
The organization definition * of struct add_oper{/* procedure parameter/
int?oper1;
int?oper2;
};
program?ADDPROG{
version?ADDVERS{
Int ADD (struct add_oper)=1; / * process numbering */
}=1; / * program version */
}=100; / * program number */
According to this file, rpcgen just can generate the framework of client computer and server program.
Shown in Fig. 5 A, in the program frame that rpcgen generates, be usually directed to 6 modules in the RPC process, comprise module, the client program 1 that calls RPC, module, server program 2 and two RPC protocol modules of realizing RPC:
Client computer RPC interface module is responsible for converting the RPC request into the RPC protocol massages, and is received the return value from the invocation of procedure of server;
Server RPC interface module is responsible for converting the RPC message into invocation of procedure request again, and the process in the caller 2 is come complete call, and will call result's client of redispatching back;
The RPC protocol module is responsible for utilizing the transmission service of system that message is passed to the opposite end, or receives message from the opposite end, and this module all exists with serving in client computer;
There is not direct correlation with " client program 1 " in the upper module and " server program 2 "; For " client program 1 "; Do not know it calling a remote process, for " server program 2 ", it does not know that its caller is a long-range program.Other module generates by the RPC CompilerTools.
In embodiments of the present invention the SNMP proxy module with by administration module in the Different software system; The SNMP proxy module is resolved the snmp message production process and is called; The invocation of procedure that obtains through the RPC framework pass on the controlled board by administration module, the concrete realization comprises:
As shown in Figure 5, a kind of node of on distributed constitution equipment, realizing the SNMP agency of the embodiment of the invention comprises master control borad and controlled board, and wherein said master control borad comprises SNMP agency 501 and RPC client computer 502; Said controlled board comprises RPC server 503 and managed object 504:
Said SNMP agency 501; The Simple Network Management Protocol snmp message that the person NMS that is used for the receiving management sends; And convert the operation requests in this snmp message into invocation of procedure RPC request; This invocation of procedure RPC request is passed to RPC client computer 502, and the return value that RPC client computer 502 is sent is interpreted as the SNMP operating result, and this SNMP operating result is packaged in sends back to said NMS in the SNMP response message;
This SNMP agency 501 is used for that also the simple syntactic variable of self and applicational grammar variable are converted into external data XDR and representes.
In order to explain the improper value in the RPC invoked procedure, the mistake of the RPC invoked procedure that this SNMP agency 501 also is used for the RPC request is returned transforms the error condition " noAccess " of SNMP.
For the correct managed object 504 on the controlled board that calls, this SNMP agency 501 also is used for the object identity of the managed object of snmp message is converted into the address of managed object.
RPC client computer 502 on the master control borad, the invocation of procedure request that is used for SNMP agency 501 is sent passes to the RPC server 503 on the controlled board with the form of RPC message, and the invocation of procedure return value that RPC server 503 transmits is back returned to SNMP acts on behalf of 501;
RPC server 503 on the controlled board is used for converting the invocation of procedure from RPC client computer 502 into to local managed object 504 function call; And the return value of this function call passed to RPC client computer 502 with the RPC form of message;
Managed object 504 on the controlled board, being used to provides the function call interface of accomplishing management request, receives the call request that said RPC server sends, and accomplishes the SNMP operation requests, and the result is returned to caller.
Wherein, SNMP agency 501 will resolve snmp message; Convert internal form into, mib variable is mapped to local equivalence value, SNMP agency 501 can use distinct methods and realize; They but in fact all be that the SNMP operation requests is converted into by the function call of administration module, but the concrete form of function interface maybe be different.Because the information function interface corresponding with it in the snmp message exists fixing mapping relations usually; Therefore; Directly the function of information in the snmp message and RPC is contrasted analysis in the embodiment of the invention, this analysis conclusion is applicable to that also whether analyze RPC is enough to carry by the converted function call of snmp message, resolves snmp message in embodiments of the present invention; Convert internal form into, specifically comprise:
The XDR that ONC RPC uses in the embodiment of the invention can represent the data type of all objects among the SNMP, and transformation rule is following:
(A), three kinds of simple syntactic variables among the SNMP are converted into the XDR form:
Integer type INTEGER: directly corresponding to the Integer type among the XDR;
8 hyte character string OCTET STRING: because the type is a varying string; Use the string of XDR to represent it; Preceding 4 bytes in the inside of the string type of XDR are data lengths; Because ASN.1 is the explicit data definition, when using OCTECT STRING, must comprise the length of this character string, when conversion, this length taking-up is inserted in the length field of XDR string type.
Object identity OBJECT IDENTIFIER: i.e. the sign of managed object, this value is not used in function call, but when RPC calls, OBJECT IDENTIFIER will convert the address of the managed object in the RPC communication into.
(B), 6 kinds of applicational grammar variablees among the SNMP are converted into the XDR form:
IPv4 address IpAddress, the Fixed-Length Array (fixed length array) of use XDR, length is 4;
32 digit counter Counter32, the Unsigned Integer type of use XDR;
32 signless integer Unsigned32, the Unsigned Integer type of use XDR;
The time answer TimeTicks that ticks uses the Unsigned Integer type of XDR;
Nontransparent type Opaque is identical with the conversion of OCTET STRING;
64 digit counter Counter64, the Unsigned Hyper Integer type of use XDR;
64 signless integer Unsigned46, the Unsigned Integer type of use XDR;
In addition, for the SNMP object of form types, adopt a structure that the variable of form is encapsulated and get final product, because the form types member is made up of above-mentioned simple types, then can be regarded as be the conversion to member in the form in the conversion of form.
(C), the conversion of the improper value that returns of RPC call error value and SNMP operation requests:
The terminal error of the invocation of procedure has two kinds of possibilities, and the one, the mistake in the RPC invoked procedure is referred to as external error in embodiments of the present invention; Another kind of is internal error during the invocation of procedure realizes, and this moment, the RPC invoked procedure was successful, and type of error is referred to as internal error in embodiments of the present invention in the return value of the invocation of procedure;
In the RPC process issuable external error comprise that program does not exist, program does not match, process does not exist, parameter does not match, system mistake, authentication error and RPC version error.
More than except that " system mistake ", other wrong only possibility can convert all external error values into the error condition " noAccess " of SNMP owing to design mistake occurs.Because the error condition of SNMP just is used for prompting usually, NMS no longer further handles error condition, so the inaccuracy of error condition can not have influence on the management process of NMS.
Internal error is that the requirement according to SNMP when handling management request of far-end process produces improper value, does not need to change again, and this moment, the return value of RPC process was success.
(D), the implicit type of XDR definition:
The implicit type definition that XDR adopts needs the producer of data and consumer that the explanation of data is reached an agreement in advance, and this problem solves through the process statement of RPC.Comprised parameter and return value type in the statement of RPC process, therefore statement when data are dealt on the server by client computer, can guarantee that both are consistent for the explanation of data with the program that is used for simultaneously on client computer and the server.
(E), the semantic change of the invocation of procedure:
ONC RPC does not guarantee that the invocation of procedure is necessarily reliable, and snmp protocol has also been supposed the unreliability of SNMP operation requests, so the SNMP agency can tolerate the unreliability of RPC;
(F), by the addressing of administration module:
For accomplishing the SNMP agency to by the invocation of procedure of administration module; Need the OBJECT IDENTIFIER of managed object in the snmp message be converted into by the address of administration module; By the addressing of administration module is not the scope of the said concern of the embodiment of the invention, and present embodiment can be selected to be confirmed by the address of administration module by the address table that presets.Owing to constituted the network of device interior between master control borad and the controlled board; In the system schema addressing method must be arranged; The addressing scheme of device interior is generally all fairly simple; For example: if device interior uses is the TCP/IP network, then can with TCP or udp port with by the just curing when the system design of the mapping relations between the administration module.
As shown in Figure 6, the embodiment of the invention also provides a kind of method that on distributed constitution equipment, realizes the SNMP agency, specifically may further comprise the steps:
Step 601; When the agency of the SNMP in the master control borad receives the Simple Network Management Protocol snmp message of manager NMS transmission; Convert said snmp message into native data formats; And convert the operation requests in this snmp message into invocation of procedure RPC request, pass to the RPC client computer that is provided with on this master control borad;
Step 602, RPC client computer use RPC communication that the RPC request is sent to the RPC server on the controlled board;
Step 603, the RPC server on the controlled board converts RPC request into to the local management object function call, and calls and saidly accomplished the management request operation by administration module, and the RPC client computer on the master control borad is returned in the return value transmission of the invocation of procedure;
Step 604, the return value that the RPC client computer on the master control borad is called RPC pass to the SNMP agency;
Step 605 after the SNMP agency on the master control borad receives said return value, is interpreted as the SNMP operating result with this return value, is packaged in the SNMP response message and returns to NMS.
Because the information function interface corresponding with it in the snmp message exists fixing mapping relations usually; Therefore; The embodiment of the invention directly with snmp message in the function of information and RPC contrast analysis, this analysis conclusion is applicable to also whether analyze RPC is enough to carry by the converted function call of snmp message:
Then said step 601 converts said SNMP request into invocation of procedure RPC request, passes to the RPC client computer that is provided with on this master control borad, specifically comprises:
The XDR that ONC RPC uses in the embodiment of the invention can represent the data type of all objects among the SNMP, and transformation rule is following:
(A), three kinds of simple syntactic variables among the SNMP are converted into the XDR form:
INTEGER: directly corresponding to the Integer type among the XDR;
OCTET STRING: because the type is a varying string; Use the string of XDR to represent it; Preceding 4 bytes in the inside of the string type of XDR are data lengths; Because ASN.1 is the explicit data definition, when using OCTECT STRING, must comprise the length of this character string, when conversion, this length taking-up is inserted in the length field of XDR string type.
OBJECT IDENTIFIER: i.e. the sign of managed object, this value is not used in function call, but when RPC calls, OBJECT IDENTIFIER will convert the address of the managed object in the RPC communication into.
(B), 6 kinds of applicational grammar variablees among the SNMP are converted into the XDR form:
IpAddress, the Fixed-Length Array (fixed length array) of use XDR, length is 4;
Counter32, the Unsigned Integer type of use XDR;
Unsigned32, the Unsigned Integer type of use XDR;
TimeTicks, the Unsigned Integer type of use XDR;
Opaque is identical with the conversion of OCTET STRING;
Counter64, the Unsigned Hyper Integer type of use XDR;
Unsigned32, the Unsigned Integer type of use XDR;
In addition, for the SNMP object of form types, adopt a structure that the variable of form is encapsulated and get final product, because the form types member is made up of above-mentioned simple types, then can be regarded as be the conversion to member in the form in the conversion of form.
(C), the conversion of the improper value that returns of RPC call error value and SNMP operation requests:
The terminal error of the invocation of procedure has two kinds of possibilities, and the one, the mistake in the RPC invoked procedure is referred to as external error in embodiments of the present invention; Another kind of is internal error during the invocation of procedure realizes, and this moment, the RPC invoked procedure was successful, and type of error is referred to as internal error in embodiments of the present invention in the return value of the invocation of procedure;
In the RPC process issuable external error comprise that program does not exist, program does not match, process does not exist, parameter does not match, system mistake, authentication error and RPC version error.
More than except that " system mistake ", other wrong only possibility can convert all external error values into the error condition " noAccess " of SNMP owing to design mistake occurs.Because the error condition of SNMP just is used for prompting usually, NMS no longer further handles error condition, so the inaccuracy of error condition can not have influence on the management process of NMS.
Internal error is that the requirement according to SNMP when handling management request of far-end process produces improper value, does not need to change again, and this moment, the return value of RPC process was success.
(D), the implicit type of XDR definition:
The implicit type definition that XDR adopts needs the producer of data and consumer that the explanation of data is reached an agreement in advance, and this problem solves through the process statement of RPC.Comprised parameter and return value type in the statement of RPC process, therefore statement when data are dealt on the server by client computer, can guarantee that both are consistent for the explanation of data with the program that is used for simultaneously on client computer and the server.
(E), the semantic change of the invocation of procedure:
ONC RPC does not guarantee that the invocation of procedure is necessarily reliable, and snmp protocol has also been supposed the unreliability of SNMP operation requests, so the SNMP agency can tolerate the unreliability of RPC;
(F), by the addressing of administration module:
For accomplishing the SNMP agency to by the invocation of procedure of administration module; Need the OBJECT IDENTIFIER of managed object in the snmp message be converted into by the address of administration module; By the addressing of administration module is not the scope of the said concern of the embodiment of the invention, and present embodiment can be selected to be confirmed by the address of administration module by the address table that presets.Owing to constituted the network of device interior between master control borad and the controlled board; In the system schema addressing method must be arranged; The addressing scheme of device interior is generally all fairly simple; For example: if device interior uses is the TCP/IP network, then can with TCP or udp port with by the just curing when the system design of the mapping relations between the administration module.
The method and apparatus that the embodiment of the invention provides docks the SNMP system with ONC RPC system, utilize ONC RPC to transmit the management operation request between master control borad and the controlled board.Shield the difference of remote procedure call and LPC by ONC RPC, make SNMP proxy module and constructed, avoid the multistage SNMP agency plant of complex structure by the mode that administration module can still call according to this locality.
Method of the present invention is not limited to the embodiment described in the embodiment, and those skilled in the art's technical scheme according to the present invention draws other execution mode, belongs to technological innovation scope of the present invention equally.Obviously, those skilled in the art can carry out various changes and modification to the present invention and not break away from the spirit and scope of the present invention.Like this, belong within the scope of claim of the present invention and equivalent technologies thereof if of the present invention these are revised with modification, then the present invention also is intended to comprise these changes and modification interior.

Claims (10)

1. a node of on distributed constitution equipment, realizing the SNMP agency comprises master control borad and controlled board, it is characterized in that, comprises Simple Network Management Protocol SNMP agency and invocation of procedure RPC client computer in the said master control borad; Comprise managed object and RPC server in the said controlled board, wherein,
The SNMP agency; The snmp message that the person NMS that is used for the receiving management sends; And convert the operation requests in this snmp message into RPC request; This RPC request is passed to the RPC client computer, and the return value that the RPC client computer is sent is interpreted as the SNMP operating result, and this SNMP operating result is packaged in sends back to said NMS in the SNMP response message;
The RPC client computer is used to use RPC communication that said RPC request is sent to the RPC server, and receives the return value of RPC request;
Said RPC server is used for converting the RPC request into to the local management object function call, sends function call request to managed object, and said RPC client computer is returned in the return value transmission of said function call request;
Said managed object is used to provide the function call interface of accomplishing management request, receives the call request that said RPC server sends, and will call the result and return to said RPC server.
2. node according to claim 1 is characterized in that, said SNMP agency is used for that also the simple syntactic variable of self and applicational grammar variable are converted into external data XDR and representes.
3. node according to claim 1 is characterized in that, the mistake of the RPC invoked procedure that said SNMP agency also is used for the RPC request is returned is converted into the error condition " noAccess " of SNMP.
4. node according to claim 1 is characterized in that, said SNMP agency also is used for the object identity of the managed object of snmp message is converted into the address of managed object.
5. a method that on distributed constitution equipment, realizes the SNMP agency is characterized in that, comprising:
When the agency of the Simple Network Management Protocol SNMP in the master control borad receives the snmp message of manager NMS transmission; Convert said snmp message into native data formats; And convert the operation requests in this snmp message into invocation of procedure RPC request, pass to the RPC client computer that is provided with on this master control borad;
The RPC client computer uses RPC communication that the RPC request is sent to the RPC server on the controlled board;
RPC server on the controlled board converts the RPC request into to the local management object function call, and calls by administration module and accomplish the management request operation, and master control borad is returned in the return value transmission of the invocation of procedure;
After said SNMP agency receives said return value, this return value is interpreted as the SNMP operating result, and this SNMP operating result is packaged in the SNMP response message returns to NMS.
6. method as claimed in claim 5 is characterized in that, converts the operation requests in this snmp message into the RPC request, comprising:
The simple syntactic variable of said operation requests and applicational grammar variable are converted into external data XDR to be represented.
7. method as claimed in claim 6 is characterized in that, the simple syntactic variable of said SNMP request is converted into external data XDR to be represented, comprising:
Integer type Integer in the said SNMP request is directly corresponding to the Integer type among the XDR; Use the character string string of XDR to represent 8 hyte character string OCTET STRING; Object identity OBJECT IDENTIFIER is converted into the address of the managed object in the RPC communication.
8. method as claimed in claim 6 is characterized in that, the applicational grammar variable of said SNMP request is converted into external data XDR representes, comprising:
Use the fixed length array Fixed-Length Array of XDR to represent the IPv4 address IpAddress in the SNMP request, length is 4;
Use the signless integer Unsigned Integer type of XDR to represent 32 digit counter Counter32 in the SNMP request;
Use the Unsigned Integer type of XDR to represent 32 signless integer Unsigned32 in the SNMP request;
Use the Unsigned Integer type of XDR to represent time in SNMP request answer TimeTicks that ticks;
Use the character string string of XDR to represent the nontransparent type Opaque in the SNMP request;
Use the Unsigned Hyper Integer type of XDR to represent 64 digit counter Counter64 in the SNMP request;
Use the Unsigned Integer type of XDR to represent 64 signless integer Unsigned64 in the SNMP request;
If be the SNMP request of form types, adopt structure that the variable of form is encapsulated.
9. method as claimed in claim 6 is characterized in that, converts the operation requests in this snmp message into the RPC request and also comprises: the address that the object identity of the managed object in the said SNMP request is converted into managed object.
10. method as claimed in claim 5; It is characterized in that; If the SNMP on master control borad agency confirms that said return value is a RPC call error value after receiving said return value, the mistake in the RPC invoked procedure that then the RPC request is returned is converted into the error condition " noAccess " of SNMP.
CN2009102248477A 2009-11-26 2009-11-26 Method and device for realizing SNMP agent on distributed equipment Active CN101795206B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2009102248477A CN101795206B (en) 2009-11-26 2009-11-26 Method and device for realizing SNMP agent on distributed equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2009102248477A CN101795206B (en) 2009-11-26 2009-11-26 Method and device for realizing SNMP agent on distributed equipment

Publications (2)

Publication Number Publication Date
CN101795206A CN101795206A (en) 2010-08-04
CN101795206B true CN101795206B (en) 2012-08-15

Family

ID=42587639

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2009102248477A Active CN101795206B (en) 2009-11-26 2009-11-26 Method and device for realizing SNMP agent on distributed equipment

Country Status (1)

Country Link
CN (1) CN101795206B (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8356100B2 (en) 2010-11-08 2013-01-15 Google Inc. Full-duplex bi-directional communication over a remote procedure call based communications protocol, and applications thereof
CN102540911B (en) * 2010-12-10 2014-08-27 北京北方微电子基地设备工艺研究中心有限责任公司 Control device and control method for equipment
US8825825B2 (en) 2012-03-06 2014-09-02 International Business Machines Corporation SNMP request processing within distributed device architecture
CN102739552B (en) * 2012-07-19 2015-09-23 迈普通信技术股份有限公司 A kind of method and system realizing many master controls remote procedure call
US10353783B1 (en) 2013-06-26 2019-07-16 EMC IP Holding Company LLC Pluggable recovery in a data protection system
US10235392B1 (en) 2013-06-26 2019-03-19 EMC IP Holding Company LLC User selectable data source for data recovery
US9904606B1 (en) 2013-06-26 2018-02-27 EMC IP Holding Company LLC Scheduled recovery in a data protection system
US9641486B1 (en) 2013-06-28 2017-05-02 EMC IP Holding Company LLC Data transfer in a data protection system
CN110808847B (en) * 2019-09-23 2021-10-15 三维通信股份有限公司 Method and device for managing DAS (data-based system), electronic device and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1557067A (en) * 2002-05-10 2004-12-22 �Ҵ���˾ Network attached storage SNMP single system image
CN1933418A (en) * 2005-09-14 2007-03-21 华为技术有限公司 Network management system and method using simple network management protocol
US7472186B2 (en) * 2004-09-09 2008-12-30 International Business Machines Corporation Method for using SNMP as an RPC mechanism for exporting the data structures of a remote library
CN101494561A (en) * 2009-03-04 2009-07-29 中兴通讯股份有限公司 Network management method and system based on simple network management protocol

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1557067A (en) * 2002-05-10 2004-12-22 �Ҵ���˾ Network attached storage SNMP single system image
US7472186B2 (en) * 2004-09-09 2008-12-30 International Business Machines Corporation Method for using SNMP as an RPC mechanism for exporting the data structures of a remote library
CN1933418A (en) * 2005-09-14 2007-03-21 华为技术有限公司 Network management system and method using simple network management protocol
CN101494561A (en) * 2009-03-04 2009-07-29 中兴通讯股份有限公司 Network management method and system based on simple network management protocol

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
李国俊.基于XML-RPC的分布式网络管理的研究与设计.《中国优秀博硕士学位论文全文数据库(硕士)信息科技辑》.2007, *
李敏等.SNMP-DMI转换代理的设计与实现.《计算机工程与设计》.2006,第27卷(第21期),第4120-4122页. *

Also Published As

Publication number Publication date
CN101795206A (en) 2010-08-04

Similar Documents

Publication Publication Date Title
CN101795206B (en) Method and device for realizing SNMP agent on distributed equipment
Medved et al. Opendaylight: Towards a model-driven sdn controller architecture
US6757899B2 (en) Dynamic CORBA gateway for CORBA and non-CORBA clients and services
CN101202665B (en) Method for generating graphical user interface
CN102185716B (en) Universal management method and system for communication equipment
Choi et al. XML‐Based Network Management for IP Networks
CN104883266B (en) network configuration access method and device
CN106559251A (en) A kind of Compilation Method and corresponding interface, component and system based on YANG models
CN1968134B (en) Middleware-based multimedia consolidation service realizing method and system
CN111552568B (en) Cloud service calling method and device
CN110768820B (en) Data communication method based on SNMP (simple network management protocol) and related equipment
Pavlou et al. The OSIMIS platform: Making OSI management simple
CN107450993A (en) A kind of data interactive method of distributed IEC61850 communication components
Leppinen et al. Java-and CORBA-based network management
CN109445384A (en) A kind of more apparatus control systems
CN110321236B (en) OpenDDS-based remote method call implementation method
Miori et al. Domotic technologies incompatibility becomes user transparent
EP2134032B1 (en) Method, system and device for managing customer premises equipment
CN114124859B (en) Intelligent customer service robot of network maintenance platform and maintenance method
CN103475506A (en) Multi-equipment management control method and multi-equipment management control system
US6898792B1 (en) Foreign object definition information repository
Pavlou The OSIMIS TMN Platform: Support for Multiple Technology Integrated Management Systems
Popić et al. Efficient Usage of Resources in SDN by Modifying YANG Modules in Linux-based Embedded Systems
CN105141674B (en) A kind of ability cut-in method and system
AU740953B2 (en) System and method relating to generic handling of data

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
ASS Succession or assignment of patent right

Owner name: BEIJING Z-GOOD TECHNOLOGY SERVICE CO., LTD.

Free format text: FORMER OWNER: FUJIAN XINGWANGRUIJIE NETWORK CO., LTD.

Effective date: 20140514

C41 Transfer of patent application or patent right or utility model
COR Change of bibliographic data

Free format text: CORRECT: ADDRESS; FROM: 350002 FUZHOU, FUJIAN PROVINCE TO: 100085 HAIDIAN, BEIJING

TR01 Transfer of patent right

Effective date of registration: 20140514

Address after: 100085 Beijing city Haidian District No. 33 Xiaoying Road 1 1F06 room

Patentee after: BEIJING ZHIGU TECHNOLOGY SERVICES CO., LTD.

Address before: Cangshan District of Fuzhou City, Fujian province 350002 Jinshan Road No. 618 Garden State Industrial Park building 19#

Patentee before: Fujian Xingwangruijie Network Co., Ltd.

EE01 Entry into force of recordation of patent licensing contract

Application publication date: 20100804

Assignee: Fujian Xingwangruijie Network Co., Ltd.

Assignor: BEIJING ZHIGU TECHNOLOGY SERVICES CO., LTD.

Contract record no.: 2014990000767

Denomination of invention: Method and device for realizing SNMP agent on distributed equipment

Granted publication date: 20120815

License type: Common License

Record date: 20140924

LICC Enforcement, change and cancellation of record of contracts on the licence for exploitation of a patent or utility model