CN114070705A - Device network management method, medium and device based on command line - Google Patents

Device network management method, medium and device based on command line Download PDF

Info

Publication number
CN114070705A
CN114070705A CN202111357768.0A CN202111357768A CN114070705A CN 114070705 A CN114070705 A CN 114070705A CN 202111357768 A CN202111357768 A CN 202111357768A CN 114070705 A CN114070705 A CN 114070705A
Authority
CN
China
Prior art keywords
command
network management
management method
command group
device network
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.)
Pending
Application number
CN202111357768.0A
Other languages
Chinese (zh)
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.)
Guangdong Jiubo Technology Co ltd
Original Assignee
Guangdong Jiubo Technology 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 Guangdong Jiubo Technology Co ltd filed Critical Guangdong Jiubo Technology Co ltd
Priority to CN202111357768.0A priority Critical patent/CN114070705A/en
Publication of CN114070705A publication Critical patent/CN114070705A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/02Standardisation; Integration
    • H04L41/0246Exchanging or transporting network management information using the Internet; Embedding network management web servers in network elements; Web-services-based protocols
    • H04L41/0266Exchanging or transporting network management information using the Internet; Embedding network management web servers in network elements; Web-services-based protocols using meta-data, objects or commands for formatting management information, e.g. using eXtensible markup language [XML]

Abstract

The invention discloses a device network management method, medium and device based on a command line, wherein the device network management method comprises the following steps: configuring a command group corresponding to a service; obtaining device data, the device data comprising: device ID, command parameters, and command group ID; connecting the equipment according to the equipment ID; and circularly executing the command group, analyzing the command result after the execution of each command is finished, and judging whether to continue executing. The equipment network management method can be configured and dynamically customized, can be developed at one time, can complete different equipment service combinations by various configurations, has the characteristics of flexibility, convenience and high efficiency, and can obtain the final required result by only inputting the corresponding equipment ID, command combination and command parameters.

Description

Device network management method, medium and device based on command line
Technical Field
The invention belongs to the technical field of network communication management, and particularly relates to a device network management method, a medium and a device based on a command line.
Background
In the existing communication technology of network management and equipment, the currently known method of accessing a target equipment through a telnet protocol to obtain the most original data, then analyzing and processing the data and finally obtaining a result needs to perform independent customized development and data analysis aiming at each specific service, and therefore the method is low in development efficiency and poor in flexibility. And moreover, development and adaptation processing are needed for different telnet protocols or different devices, and when more and more devices are supported, the system complexity is higher and higher, and the maintainability is greatly reduced.
Disclosure of Invention
In order to overcome the technical defects, the first aspect of the invention provides a device network management method based on a command line, which comprises the following steps:
configuring a command group corresponding to a service;
obtaining device data, the device data comprising: device ID, command parameters, and command group ID;
connecting the equipment according to the equipment ID;
and circularly executing the command group, after the execution of each command is finished, analyzing the command result, judging whether to continue to execute the next command, if not, directly returning the result, otherwise, normally executing the next command until the result is normally returned.
As a further improvement of the present invention, the step of configuring the command group corresponding to the service includes:
if the command group exists, taking the serial number of the command group as a command group ID;
and if the command group does not exist, configuring the command group, automatically numbering the command group, and generating a command group ID.
As a further improvement of the present invention, the step of configuring the command group corresponding to the service includes:
adding an associated command for the command group, if the associated command is not found, adding a new command, and associating the new command with the command group;
the execution order of the command groups is set.
As a further improvement of the present invention, the step of configuring the command group corresponding to the service includes:
configure conversion of command line return values or identify keywords.
As a further improvement of the present invention, the acquiring device data includes: and acquiring an IP address, a port number, a user name and a password required by telnet login according to the equipment ID.
As a further improvement of the invention, the invention also comprises the following steps:
and providing a command line list management interface to realize the configuration of the command group.
As a further improvement of the invention, the command line list management interface comprises:
the list includes a number modification column, a command code modification column, a command content modification column, a command name modification column, a command description modification column, an exception eligibility and an action column modification column.
As a further improvement of the invention, the invention also comprises the following steps:
and saving the execution result record.
In a second aspect of the present invention, a computer-readable storage medium is provided, where at least one instruction, at least one program, a code set, or a set of instructions is stored in the computer-readable storage medium, and the at least one instruction, at least one program, a code set, or a set of instructions is loaded and executed by a processor to implement the device network management method described above.
In a third aspect of the present invention, a computer device is provided, where the computer device includes a processor and a memory, where the memory stores at least one instruction, at least one program, a code set, or a set of instructions, and the at least one instruction, at least one program, a code set, or a set of instructions is loaded and executed by the processor to implement the above-mentioned device network management method.
Compared with the prior art, the invention has the following beneficial effects: the equipment network management method can be configured and dynamically customized, one-time development is realized, different equipment service combinations can be completed through various configurations, the method has the characteristics of flexibility, convenience and high efficiency, and a user can obtain a final required result only by inputting a corresponding equipment ID, a command combination and command parameters.
Drawings
Embodiments of the invention are described in further detail below with reference to the attached drawing figures, wherein:
fig. 1 is a flowchart of a network management method of a device described in embodiment 1;
fig. 2 is a command line list in the device network management method according to embodiment 1;
fig. 3 is a detailed command parameter list in the device network management method according to embodiment 1;
fig. 4 is a command set list in the device network management method according to embodiment 1;
fig. 5 is a list of command management settings in the device network management method described in embodiment 1;
fig. 6 is a device command execution log list in the device network management method according to embodiment 1;
fig. 7 is a detail list of device command logs in the device network management method according to embodiment 1;
fig. 8 is a schematic structural diagram of the computer device according to embodiment 3.
Detailed Description
The preferred embodiments of the present invention will be described in conjunction with the accompanying drawings, and it will be understood that they are described herein for the purpose of illustration and explanation and not limitation.
Example 1
The embodiment discloses a device network management method based on a command line, as shown in fig. 1, comprising the steps of:
s1, configuring a command group corresponding to the service, as shown in fig. 2 to 5, this step is a condition that must be satisfied before executing the engine, and can be specifically implemented by the following steps:
s11, if the command group of the same service exists, the serial number is directly used as the ID of the command group, otherwise, a new command group needs to be configured, the description of the command group is remarked, and the serial number is automatically produced by the system as the ID of the command group after the configuration is successful.
S12, adding the association command for the command group, if the association command is not found, adding a new command, and associating the new command with the command group; and setting the execution sequence of the command group, and after all the commands are associated, confirming whether the execution sequence of the commands is correct and whether the execution between the commands is continuous or not again and the commands can be correctly executed.
Further, the content of the command group configuration includes: the method comprises the steps of configuring a command line of the equipment, configuring command parameters, performing combined configuration on the configured command line, a set of complete analysis and processing engines based on the combination of the command line and the command, analyzing the result of the command line, converting the result of the command line, performing the next processing method on the result of the command line and the like.
The device command line configuration comprises a command code, command content and whether to ignore exception or not; the command parameter setting comprises parameter names, parameter contents, whether the command must be filled or not and parameter sequence.
The combined configuration of the configured command lines comprises adding commands and performing up-shifting and down-shifting operations on the commands.
A complete set of parsing and processing engines based on command lines and command combinations comprises device command group processing, command execution and processing, result parsing and data processing, and the command combinations are limited to a plurality of command combinations of the same device and do not support quartic devices.
The method for analyzing and converting the command line result and processing the command line result in the next step comprises the steps of primarily processing the command line result, filtering characters of differentiation and marks of various equipment models, and primarily extracting result data; extracting command line result data for the second time, converting the command line result data into structured data according to a unified standard and a standard, wherein the conversion standard, the rule and the output are dynamically configurable; and further processing the standardized result data aiming at different services, extracting, filtering, rearranging and combining the original data, and finally returning the real service data.
The equipment command group processing engine is responsible for extracting the equipment model according to the equipment information and matching the command combination corresponding to the equipment; the command executing and processing engine is responsible for executing, analyzing and storing the command set of the command combination one by one and extracting standard structured data corresponding to the commands; the result analysis and data processing engine finally combines the previous single command data according to the business requirements of the command group and returns the data meeting the requirements.
S2, acquiring device data, where the device mentioned in this embodiment may be an ipran type device, or may be another type device, as long as the device supports a command line operation, where the device data includes: device ID, command parameters, and command group ID; and acquiring an IP address, a port number, a user name and a password required by telnet login according to the equipment ID, wherein the execution engine can be connected to the equipment based on the IP address, the port number, the user name and the password, so as to provide a precondition for command execution.
And S3, connecting the equipment according to the equipment ID.
And S4, circularly executing the command group, after the execution of each command is finished, analyzing the command result, judging whether to continue executing the next command, if not, directly returning the result, otherwise, normally executing the next command until the result is normally returned.
Specifically, the result returned by the command line is partially replaced and converted, and corresponding configuration setting is performed in the system interface, wherein the setting information comprises an identification keyword, conversion output and whether to continue executing the next command.
S5, saving the execution result record, as shown in fig. 6 and 7, which facilitates monitoring the execution process and implementing quick positioning of the problem, wherein the execution result record includes: command group ID, command content, device name, device ID, execution result, execution time, execution status.
The embodiment also provides a command queue management interface to realize the configuration of the command group. As shown in fig. 2, the command line list management interface includes a number, a command code, a command content, a command name, a command description, and whether to ignore an exception and an operation column, and command line maintenance operations such as adding, deleting, modifying, searching, and checking may be performed on all command lines in the management interface; as shown in fig. 3, the parameter corresponding to the command may be changed through a parameter setting operation; as shown in FIG. 4, the command packet contains query, add, delete, edit and associated command settings for the command group; as shown in fig. 5, all the command lists, command execution sequences, and parameter detailed descriptions corresponding to command execution can be found through "association setup" corresponding to the command group, and command parameter data required for entry of the execution engine can be conveniently and quickly obtained through this interface.
The present embodiment is further explained with reference to the specific implementation process, as follows:
the user configures the command group according to the service type; the device ID, command group ID, and command parameters are input and directly accessed through the API interface.
The execution engine receives the device ID, the command group ID and the parameter set of all commands corresponding to the command group, which are transmitted by the caller, as entries, and after the system receives the parameters, the system connects the devices according to the device ID, acquires the command set according to the command group ID, and acquires the parameters required by executing the commands according to the command parameters. And the execution engine executes the command group naming cycle under the conditions of ready connection, ready command and ready parameter of all the devices, analyzes and extracts the command result after the execution of each command is finished, judges whether to continue to execute the next command, and directly returns the result if the next command is not required to be executed, otherwise, normally executes the command until the result is normally returned.
In summary, the present embodiment has the following technical effects:
1. different telnet protocol devices can be supported, and analysis and conversion of the returned result of the command line of the customized device are supported; the method has the characteristics of simple use, rapidness, flexibility, high efficiency and the like, can effectively improve the data acquisition from network management equipment, effectively improves the production efficiency and reduces the production cost;
2. through command line configuration, command parameter setting and command line combined configuration, the system supports equipment of different models, a user only needs to input a required command line into the system according to requirements, increase, decrease, management and maintenance can be carried out on the command at any time, changes of all command lines can be traced, the change of the command lines does not need to modify programs, and the change and the effect are really achieved;
3. the method comprises the execution and the analysis of all command lines and is suitable for the operation of all command lines of all equipment, so that the acquisition of the equipment data can be realized without modifying programs and flows for newly added or changed commands.
4. The method is simple to use, wide in application range, flexible and efficient, production efficiency is effectively improved, and production cost is reduced.
Example 2
The present embodiment provides a computer-readable storage medium, where at least one instruction, at least one program, a code set, or a set of instructions is stored in the computer-readable storage medium, and the at least one instruction, the at least one program, the code set, or the set of instructions is loaded and executed by a processor to implement the device network management method in embodiment 1.
Optionally, the computer-readable storage medium may include: a Read Only Memory (ROM), a Random Access Memory (RAM), a Solid State Drive (SSD), or an optical disc. The Random Access Memory may include a resistive Random Access Memory (ReRAM) and a Dynamic Random Access Memory (DRAM).
Example 3
The present embodiment provides a computer device, as shown in fig. 8, including a processor and a storage, where the storage stores program codes, and the processor executes the program codes to execute the device network management method according to embodiment 1.
Those skilled in the art will recognize that, in one or more of the examples described above, the functions described in the embodiments of the present application may be implemented in hardware, software, firmware, or any combination thereof. When implemented in software, the functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Computer-readable media includes both computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. A storage media may be any available media that can be accessed by a general purpose or special purpose computer.
The present invention is not intended to be limited to the particular embodiments shown and described, but is to be accorded the widest scope consistent with the principles and novel features herein disclosed.

Claims (10)

1. A device network management method based on command line is characterized in that the method comprises the following steps:
configuring a command group corresponding to a service;
obtaining device data, the device data comprising: device ID, command parameters, and command group ID;
connecting the equipment according to the equipment ID;
and circularly executing the command group, after the execution of each command is finished, analyzing the command result, judging whether to continue to execute the next command, if not, directly returning the result, otherwise, normally executing the next command until the result is normally returned.
2. The device network management method according to claim 1, wherein the step of configuring the command group corresponding to the service includes:
if the command group exists, taking the serial number of the command group as a command group ID;
and if the command group does not exist, configuring the command group, automatically numbering the command group, and generating a command group ID.
3. The device network management method according to claim 2, wherein the step of configuring the command group corresponding to the service comprises:
adding an associated command for the command group, if the associated command is not found, adding a new command, and associating the new command with the command group;
the execution order of the command groups is set.
4. The device network management method according to any one of claims 1 to 3, wherein the step of configuring the command group corresponding to the service includes:
configure conversion of command line return values or identify keywords.
5. The device network management method according to claim 1, wherein the acquiring device data comprises: and acquiring an IP address, a port number, a user name and a password required by telnet login according to the equipment ID.
6. The device network management method according to claim 1, further comprising the steps of:
and providing a command line list management interface to realize the configuration of the command group.
7. The device network management method according to claim 4, wherein the command line list management interface comprises:
the list includes a number modification column, a command code modification column, a command content modification column, a command name modification column, a command description modification column, an exception eligibility and an action column modification column.
8. The device network management method according to claim 1, further comprising the steps of:
and saving the execution result record.
9. A computer-readable storage medium, wherein at least one instruction, at least one program, a set of codes, or a set of instructions is stored in the computer-readable storage medium, and the at least one instruction, at least one program, a set of codes, or a set of instructions is loaded and executed by a processor to implement the device network management method according to any one of claims 1 to 8.
10. A computer device, characterized in that the frequency converter comprises a processor and a memory, wherein at least one instruction, at least one program, code set or instruction set is stored in the memory, and the at least one instruction, at least one program, code set or instruction set is loaded and executed by the processor to implement the device network management method according to any one of claims 1 to 8.
CN202111357768.0A 2021-11-16 2021-11-16 Device network management method, medium and device based on command line Pending CN114070705A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111357768.0A CN114070705A (en) 2021-11-16 2021-11-16 Device network management method, medium and device based on command line

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111357768.0A CN114070705A (en) 2021-11-16 2021-11-16 Device network management method, medium and device based on command line

Publications (1)

Publication Number Publication Date
CN114070705A true CN114070705A (en) 2022-02-18

Family

ID=80272784

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111357768.0A Pending CN114070705A (en) 2021-11-16 2021-11-16 Device network management method, medium and device based on command line

Country Status (1)

Country Link
CN (1) CN114070705A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117319226A (en) * 2023-11-29 2023-12-29 中南大学 Meta universe-based data processing method and device, electronic equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1946039A (en) * 2006-11-17 2007-04-11 杭州华为三康技术有限公司 Method and device for analyzing command line back display information based on template volume
JP2010015512A (en) * 2008-07-07 2010-01-21 Nippon Telegr & Teleph Corp <Ntt> Apparatus and method for creating configuration management model and program thereof
CN101651565A (en) * 2009-09-16 2010-02-17 中兴通讯股份有限公司 Cancel recovering method and device by human-computer commands
US7823069B1 (en) * 2006-03-23 2010-10-26 Cisco Technology, Inc. Method and application tool for dynamically navigating a user customizable representation of a network device configuration
CN107911249A (en) * 2017-11-28 2018-04-13 新华三技术有限公司 Order line sending method, device and the equipment of a kind of network equipment
CN113448793A (en) * 2020-03-25 2021-09-28 大唐移动通信设备有限公司 System monitoring method and device compatible with multiple operating systems

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7823069B1 (en) * 2006-03-23 2010-10-26 Cisco Technology, Inc. Method and application tool for dynamically navigating a user customizable representation of a network device configuration
CN1946039A (en) * 2006-11-17 2007-04-11 杭州华为三康技术有限公司 Method and device for analyzing command line back display information based on template volume
JP2010015512A (en) * 2008-07-07 2010-01-21 Nippon Telegr & Teleph Corp <Ntt> Apparatus and method for creating configuration management model and program thereof
CN101651565A (en) * 2009-09-16 2010-02-17 中兴通讯股份有限公司 Cancel recovering method and device by human-computer commands
CN107911249A (en) * 2017-11-28 2018-04-13 新华三技术有限公司 Order line sending method, device and the equipment of a kind of network equipment
CN113448793A (en) * 2020-03-25 2021-09-28 大唐移动通信设备有限公司 System monitoring method and device compatible with multiple operating systems

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117319226A (en) * 2023-11-29 2023-12-29 中南大学 Meta universe-based data processing method and device, electronic equipment and storage medium
CN117319226B (en) * 2023-11-29 2024-02-23 中南大学 Meta universe-based data processing method and device, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
CN103210386B (en) Method, system and the equipment of conglomeration search
CN102802139A (en) Gateway data adapting system and method of Internet of Things
CN101694626A (en) Script execution system and method
CN106897159A (en) A kind of system and method for gathering Data of Automatic Weather
CN113079198B (en) Method and device for converting cloud platform interface protocol
CN101729316A (en) Test method and system and remote management platform equipment for different types of home gateways
CN111460019A (en) Data conversion method and middleware of heterogeneous data source
CN114070705A (en) Device network management method, medium and device based on command line
CN113726762A (en) Internet of things equipment protocol analysis method based on configuration file
WO2021189195A1 (en) Data querying method and apparatus, server, and storage medium
CN114465937B (en) Network card testing method, device, server and medium
WO2022033079A1 (en) Pico base station configuration method and apparatus, and storage medium and electronic apparatus
CN113821565A (en) Method for synchronizing data of multiple data sources
CN108365976B (en) Network service optimization method and device
CN112883088B (en) Data processing method, device, equipment and storage medium
CN113157904A (en) Sensitive word filtering method and system based on DFA algorithm
CN100386989C (en) General command line inputting device based on man-machine interactive languages, and its method
CN101938765B (en) The method and system of a kind of webmaster and network element automatic adaptation
US20080126520A1 (en) Devices, systems and methods for network device conversion
CN115544548A (en) Internet financial wind control incoming system interface field checking and managing system and method
CN106775818A (en) ECU upgrade methods and ECU updating apparatus based on CAN
CN116827566A (en) Equipment data transmission method, device and system
CN114116712A (en) Extended field processing method and device, electronic equipment and storage medium
CN112445811A (en) Data service method, device, storage medium and component based on SQL configuration
CN109710605B (en) Automatic equipment information acquisition device and method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination