CN109582584A - A kind of BMC Smashclp method for automatically testing functions and device - Google Patents

A kind of BMC Smashclp method for automatically testing functions and device Download PDF

Info

Publication number
CN109582584A
CN109582584A CN201811549394.0A CN201811549394A CN109582584A CN 109582584 A CN109582584 A CN 109582584A CN 201811549394 A CN201811549394 A CN 201811549394A CN 109582584 A CN109582584 A CN 109582584A
Authority
CN
China
Prior art keywords
bmc
smashclp
information
test
corresponding information
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
CN201811549394.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.)
Zhengzhou Yunhai Information Technology Co Ltd
Original Assignee
Zhengzhou Yunhai Information 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 Zhengzhou Yunhai Information Technology Co Ltd filed Critical Zhengzhou Yunhai Information Technology Co Ltd
Priority to CN201811549394.0A priority Critical patent/CN109582584A/en
Publication of CN109582584A publication Critical patent/CN109582584A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The present invention discloses a kind of BMC Smashclp method for automatically testing functions and device, and expect script is used to log in BMC and Smashclp Cmd Shell interface;The test command of Smashclp is executed, BMC corresponding information is obtained;BMC is obtained referring to information;The BMC corresponding information and step BMC obtained according to the test command for executing Smashclp judges Smashclp test result referring to information.The present invention can well solve the drawbacks of manual testing, improve testing efficiency and test quality, and easy to operate, clear in structure between each module with stronger ease for use, convenient for safeguarding;Without lengthy and jumbled result treatment, the testing time is greatly saved, improves testing efficiency.

Description

A kind of BMC Smashclp method for automatically testing functions and device
Technical field
The present invention relates to BMC testing fields, and in particular to a kind of method of BMC Smashclp Function Test Automation and Device.
Background technique
BMC is responsible for server admin, and the functional module of diagnosis and configuration control is supervised commonly used in remote server administration Control.There are three ways to remote control server: tri- kinds of access modes of web, ipmitool and Smashclp.Web access is logical The mode for crossing login BMC web page carrys out management server;Ipmitool is to access BMC based on IPMI protocol;Smashclp is The Xiang Xieyi pushed by DMTF and SMWG, provides the standard of system administration CLI implementation, and BMC Smashclp provides order The mode access control BMC of row interaction can be logged in BMC in a manner of order line CLI, and pass through specified order control and pipe Manage BMC.
The test method of current Smashclp function is all the interface manual entry Smashclp, then one by one order send into Row test, this mode not only repeat time-consuming but also easy omission or erroneous judgement.
Summary of the invention
To solve the above problems, the present invention provides a kind of BMC Smashclp method for automatically testing functions and device, it can To improve testing efficiency and test quality.
The technical scheme is that a kind of BMC Smashclp method for automatically testing functions, comprising the following steps:
S11: BMC and Smashclp Cmd Shell interface is logged in using expect script;
S22: executing the test command of Smashclp, obtains BMC corresponding information;
S33: BMC is obtained referring to information;
S44: judged according to the BMC that the step S22 BMC corresponding information obtained and step S33 are obtained referring to information Smashclp test result.
Further, step S11 logs in BMC and Smashclp Cmd Shell interface using expect script, specific to wrap It includes:
Ssh Telnet BMC is passed through according to BMC IP address using expect script;
It sends order and enters Smashclp Cmd Shell interface.
Further, step S22 executes the test command of Smashclp, obtains BMC corresponding information, specifically includes:
Whole test commands in Smashclp order line are successively executed, BMC letter corresponding with each test command is obtained Breath;
After having executed whole test commands, Smashclp Cmd Shell interface is exited;
The BMC corresponding information that will acquire is saved in the first Log file.
Further, step S33 obtains BMC referring to information, specifically includes:
It executes ipmitool order and obtains BMC corresponding information as BMC referring to information;
It will be saved in the 2nd Log file by executing the acquired BMC corresponding information of ipmitool order.
Further, step S44, the BMC obtained according to the step S22 BMC corresponding information obtained and step S33 is referring to letter Breath judges Smashclp test result, specifically includes:
The first Log file is parsed, BMC corresponding information acquired in the test command for executing Smashclp is extracted;
The 2nd Log file is parsed, extracts and executes BMC corresponding information acquired in ipmitool order;
Whether BMC information acquired in more above two mode is consistent;
If consistent, Smashclp test passes through;
If inconsistent, Smashclp test does not pass through.
Invention additionally discloses a kind of BMC Smashclp Function Test Automation devices, comprising:
Login module: for logging in BMC and Smashclp Cmd Shell interface using expect script;
First BMC data obtaining module: for executing the test command of Smashclp, BMC corresponding information is obtained;
2nd BMC data obtaining module: for obtaining BMC referring to information;
As a result judgment module: BMC corresponding information and the 2nd BMC letter for being obtained according to the first BMC data obtaining module Breath obtains the BMC that module obtains and judges Smashclp test result referring to information.
Further,
Login module is ordered according to BMC IP address by ssh Telnet BMC, and by sending using expect script Into Smashclp Cmd Shell interface.
Further,
First BMC data obtaining module successively executes whole test commands in Smashclp order line, obtain with it is each The corresponding BMC information of test command;
After first BMC data obtaining module is also used to execute whole test commands, Smashclp Cmd Shell is exited Interface, the BMC corresponding information that will acquire are saved in the first Log file.
Further,
2nd BMC data obtaining module obtains BMC corresponding information as BMC referring to letter by executing ipmitool order Breath, and will be saved in the 2nd Log file by executing the acquired BMC corresponding information of ipmitool order.
Further, as a result judgment module is specifically used for:
The first Log file is parsed, BMC corresponding information acquired in the first BMC data obtaining module is extracted;
The 2nd Log file is parsed, BMC corresponding information acquired in the 2nd BMC data obtaining module is extracted;
Whether BMC information acquired in more above two mode is consistent;
If consistent, Smashclp test passes through;
If inconsistent, Smashclp test does not pass through.
BMC Smashclp method for automatically testing functions and device provided by the invention, are stepped on automatically by expect script Smashclp is recorded, it is automatic to execute Smashclp interactive instruction, the BMC information and BMC reference obtained by Smashclp order Information (can be obtained by ipmitool mode) compares judge whether Smashclp corresponding instruction function is normal.This hair Bright the drawbacks of can well solving manual testing, improves testing efficiency and test quality, and easy to operate, has relatively strong easy-to-use Property, it is clear in structure between each module, it is convenient for safeguarding;Without lengthy and jumbled result treatment, the testing time is greatly saved, improves test Efficiency.
Detailed description of the invention
Fig. 1 is one method flow schematic diagram of the specific embodiment of the invention.
Specific embodiment
The present invention will be described in detail with reference to the accompanying drawing and by specific embodiment, and following embodiment is to the present invention Explanation, and the invention is not limited to following implementation.
Embodiment one
The present invention provides a kind of BMC Smashclp method for automatically testing functions, principle be by expect script from Dynamic to log in Smashclp, automatic execution Smashclp interactive instruction the BMC information obtained by Smashclp instruction and passes through The BMC information that ipmitool mode is got compares judge whether Smashclp corresponding instruction function is normal, if with The BMC information got by ipmitool mode unanimously then judges that Smashclp corresponding function is normal, otherwise judges this function It is abnormal.
As shown in Figure 1, this method specifically includes the following steps:
S11: BMC and Smashclp Cmd Shell interface is logged in using expect script;
S22: executing the test command of Smashclp, obtains BMC corresponding information;
S33: BMC is obtained referring to information;
S44: judged according to the BMC that the step S22 BMC corresponding information obtained and step S33 are obtained referring to information Smashclp test result.
In the present embodiment, step S11's logs in BMC and Smashclp Cmd Shell interface, tool using expect script Body is realized by following below scheme:
Ssh Telnet BMC is passed through according to BMC IP address using expect script;
It sends order and enters Smashclp Cmd Shell interface.
In the present embodiment, step S22 execution Smashclp test command, obtain BMC corresponding information, especially by with Lower process is realized:
Whole test commands in Smashclp order line are successively executed, BMC letter corresponding with each test command is obtained Breath;
After having executed whole test commands, Smashclp Cmd Shell interface is exited;
The BMC corresponding information that will acquire is saved in the first Log file.
It should be noted that there is multiple test commands in Smashclp order line, the present embodiment successively executes each order, Obtain BMC information corresponding with order.Such as the order ipconfig of the first row in Smashclp order line is executed, obtain BMC The network information.
In the present embodiment, the acquisition BMC of step S33 be can be referring to information by executing ipmitool order acquisition BMC information, the step are realized by following below scheme:
It executes ipmitool order and obtains BMC corresponding information as BMC referring to information;
It will be saved in the 2nd Log file by executing the acquired BMC corresponding information of ipmitool order.
It should be noted that the BMC information preservation that will acquire is in journal file, so as to it is subsequent to Smashclp function into Row judgement.
In the present embodiment, step S44, the BMC reference obtained according to the step S22 BMC corresponding information obtained and step S33 Information judges Smashclp test result, realizes especially by following below scheme:
The first Log file is parsed, BMC corresponding information acquired in the test command for executing Smashclp is extracted;
The 2nd Log file is parsed, extracts and executes BMC corresponding information acquired in ipmitool order;
Whether BMC information acquired in more above two mode is consistent;
If consistent, Smashclp test passes through;
If inconsistent, Smashclp test does not pass through.
It should be noted that it is obstructed out-of-date to test in the present embodiment, specific unacceptable Smashclp life may also display It enables, is checked so as to subsequent.
For further the method for the present embodiment is explained, the script of this method is given below (with order For ipconfig instruction):
According to the feature list of BMC smashclp, all smashclp orders are all integrated into test by above step The functional automatic test of smashclp institute can be realized in script.
Embodiment two
Based on embodiment one, the present embodiment provides a kind of BMC Smashclp Function Test Automations for realizing the above method Device, the device comprise the following modules:
Login module: for logging in BMC and Smashclp Cmd Shell interface using expect script;
First BMC data obtaining module: for executing the test command of Smashclp, BMC corresponding information is obtained;
2nd BMC data obtaining module: for obtaining BMC referring to information;
As a result judgment module: BMC corresponding information and the 2nd BMC letter for being obtained according to the first BMC data obtaining module Breath obtains the BMC that module obtains and judges Smashclp test result referring to information.
In the present embodiment, the specifically used expect script of login module passes through ssh Telnet according to BMC IP address BMC, and enter Smashclp Cmd Shell interface by sending order.
In the present embodiment, the first BMC data obtaining module successively executes whole test commands in Smashclp order line, Obtain BMC information corresponding with each test command;First BMC data obtaining module is also used to execute whole test commands Afterwards, Smashclp Cmd Shell interface is exited, the BMC corresponding information that will acquire is saved in the first Log file.
In the present embodiment, the 2nd BMC data obtaining module obtains the conduct of BMC corresponding information by executing ipmitool order BMC will be saved in the 2nd Log file referring to information by executing the acquired BMC corresponding information of ipmitool order.
In the present embodiment, as a result judgment module judges result especially by following below scheme:
The first Log file is parsed, BMC corresponding information acquired in the first BMC data obtaining module is extracted;
The 2nd Log file is parsed, BMC corresponding information acquired in the 2nd BMC data obtaining module is extracted;
Whether BMC information acquired in more above two mode is consistent;
If consistent, Smashclp test passes through;
If inconsistent, Smashclp test does not pass through.
Disclosed above is only the preferred embodiment of the present invention, but the present invention is not limited to this, any this field What technical staff can think does not have creative variation, and without departing from the principles of the present invention made by several improvement and Retouching, should all be within the scope of the present invention.

Claims (10)

1. a kind of BMC Smashclp method for automatically testing functions, which comprises the following steps:
S11: BMC and Smashclp Cmd Shell interface is logged in using expect script;
S22: executing the test command of Smashclp, obtains BMC corresponding information;
S33: BMC is obtained referring to information;
S44: the BMC obtained according to the step S22 BMC corresponding information obtained and step S33 judges that Smashclp is surveyed referring to information Test result.
2. BMC Smashclp method for automatically testing functions according to claim 1, which is characterized in that step S11 makes BMC and Smashclp Cmd Shell interface is logged in expect script, is specifically included:
Ssh Telnet BMC is passed through according to BMC IP address using expect script;
It sends order and enters Smashclp Cmd Shell interface.
3. BMC Smashclp method for automatically testing functions according to claim 1, which is characterized in that step S22 is held The test command of row Smashclp obtains BMC corresponding information, specifically includes:
Whole test commands in Smashclp order line are successively executed, BMC information corresponding with each test command is obtained;
After having executed whole test commands, Smashclp Cmd Shell interface is exited;
The BMC corresponding information that will acquire is saved in the first Log file.
4. BMC Smashclp method for automatically testing functions according to claim 3, which is characterized in that step S33 is obtained It takes BMC referring to information, specifically includes:
It executes ipmitool order and obtains BMC corresponding information as BMC referring to information;
It will be saved in the 2nd Log file by executing the acquired BMC corresponding information of ipmitool order.
5. according to BMC Smashclp method for automatically testing functions described in right 4, which is characterized in that step S44, according to step The BMC that the BMC corresponding information and step S33 that rapid S22 is obtained obtain judges Smashclp test result referring to information, specific to wrap It includes:
The first Log file is parsed, BMC corresponding information acquired in the test command for executing Smashclp is extracted;
The 2nd Log file is parsed, extracts and executes BMC corresponding information acquired in ipmitool order;
Whether BMC information acquired in more above two mode is consistent;
If consistent, Smashclp test passes through;
If inconsistent, Smashclp test does not pass through.
6. a kind of BMC Smashclp Function Test Automation device characterized by comprising
Login module: for logging in BMC and Smashclp Cmd Shell interface using expect script;
First BMC data obtaining module: for executing the test command of Smashclp, BMC corresponding information is obtained;
2nd BMC data obtaining module: for obtaining BMC referring to information;
As a result judgment module: BMC corresponding information and the 2nd BMC information for being obtained according to the first BMC data obtaining module obtain The BMC that modulus block obtains judges Smashclp test result referring to information.
7. BMC Smashclp Function Test Automation device according to claim 6, which is characterized in that
Login module is entered according to BMC IP address by ssh Telnet BMC, and by sending order using expect script Smashclp Cmd Shell interface.
8. BMC Smashclp Function Test Automation device according to claim 6, which is characterized in that
First BMC data obtaining module successively executes whole test commands in Smashclp order line, obtains and each test Order corresponding BMC information;
After first BMC data obtaining module is also used to execute whole test commands, Smashclp Cmd Shell interface is exited, The BMC corresponding information that will acquire is saved in the first Log file.
9. BMC Smashclp Function Test Automation device according to claim 8, which is characterized in that
2nd BMC data obtaining module obtains BMC corresponding information as BMC referring to information by executing ipmitool order, and It will be saved in the 2nd Log file by executing the acquired BMC corresponding information of ipmitool order.
10. BMC Smashclp Function Test Automation device according to claim 9, which is characterized in that result judgement Module is specifically used for:
The first Log file is parsed, BMC corresponding information acquired in the first BMC data obtaining module is extracted;
The 2nd Log file is parsed, BMC corresponding information acquired in the 2nd BMC data obtaining module is extracted;
Whether BMC information acquired in more above two mode is consistent;
If consistent, Smashclp test passes through;
If inconsistent, Smashclp test does not pass through.
CN201811549394.0A 2018-12-18 2018-12-18 A kind of BMC Smashclp method for automatically testing functions and device Pending CN109582584A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811549394.0A CN109582584A (en) 2018-12-18 2018-12-18 A kind of BMC Smashclp method for automatically testing functions and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811549394.0A CN109582584A (en) 2018-12-18 2018-12-18 A kind of BMC Smashclp method for automatically testing functions and device

Publications (1)

Publication Number Publication Date
CN109582584A true CN109582584A (en) 2019-04-05

Family

ID=65929861

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811549394.0A Pending CN109582584A (en) 2018-12-18 2018-12-18 A kind of BMC Smashclp method for automatically testing functions and device

Country Status (1)

Country Link
CN (1) CN109582584A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110955446A (en) * 2019-11-08 2020-04-03 苏州浪潮智能科技有限公司 CPLD firmware updating method, system and device
CN111526046A (en) * 2020-04-14 2020-08-11 浪潮商用机器有限公司 Method, device, equipment and storage medium for setting BMC (baseboard management controller) time

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080205286A1 (en) * 2007-02-26 2008-08-28 Inventec Corporation Test system using local loop to establish connection to baseboard management control and method therefor
CN101834890A (en) * 2010-04-02 2010-09-15 浪潮(北京)电子信息产业有限公司 Intelligent management system and method of distributed system
CN108322342A (en) * 2018-02-02 2018-07-24 郑州云海信息技术有限公司 Server S MASH CLP module informations acquisition methods, system, equipment and storage medium

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080205286A1 (en) * 2007-02-26 2008-08-28 Inventec Corporation Test system using local loop to establish connection to baseboard management control and method therefor
CN101834890A (en) * 2010-04-02 2010-09-15 浪潮(北京)电子信息产业有限公司 Intelligent management system and method of distributed system
CN108322342A (en) * 2018-02-02 2018-07-24 郑州云海信息技术有限公司 Server S MASH CLP module informations acquisition methods, system, equipment and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
蔡积淼: "基于IPMI的服务器管理的软硬件设计与实现", 《中国优秀硕士学位论文全文库 信息科技辑》 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110955446A (en) * 2019-11-08 2020-04-03 苏州浪潮智能科技有限公司 CPLD firmware updating method, system and device
CN111526046A (en) * 2020-04-14 2020-08-11 浪潮商用机器有限公司 Method, device, equipment and storage medium for setting BMC (baseboard management controller) time

Similar Documents

Publication Publication Date Title
TWI741505B (en) Topology processing method, device and system
US6993683B2 (en) Analysis of pipelined networks
CN103856774B (en) A kind of video monitoring intelligent checking system and method
CN106502853A (en) Embedded intelligence fault detect warning system
US11176030B2 (en) Conducting automated software testing using centralized controller and distributed test host servers
CN103138988B (en) Positioning treatment method and positioning treatment device of network faults
CN106776320A (en) Android intelligent terminal automatization test system and method
CN109560996B (en) Automatic testing system and method for terminal of Internet of things
CN109462490B (en) Video monitoring system and fault analysis method
CN109582584A (en) A kind of BMC Smashclp method for automatically testing functions and device
CN112073263B (en) Method, system, equipment and medium for testing and monitoring reliability of white box switch
CN106209503A (en) RPC interface test method and system
CN110365540A (en) A kind of security system data processing equipment
CN103326902A (en) Configurable monitoring system and monitoring method for distributed type mainframe performance testing data
CN106021066A (en) Fault information detection method and electronic device
CN108989067A (en) The method of calibration and equipment of configuration file consistency
CN110035087A (en) A kind of method, apparatus, equipment and storage medium from flow reduction account information
CN111752741A (en) System performance detection method and device
CN115664939A (en) Comprehensive operation and maintenance method and device based on automation technology and storage medium
CN106598793A (en) Test system and method based on BIOS serial port log data
CN117411804A (en) Server network testing method and device, electronic equipment and storage medium
CN107544830A (en) A kind of method and device of automatic installation database
WO2016188223A1 (en) Fault information collection method and apparatus
CN116401202A (en) Atmospheric component observation data acquisition edge server system and data processing method
CN106844158A (en) The monitoring method and device of a kind of server node state

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
RJ01 Rejection of invention patent application after publication

Application publication date: 20190405

RJ01 Rejection of invention patent application after publication