CN109710483A - A kind of smashclp function test method, device, terminal and storage medium - Google Patents
A kind of smashclp function test method, device, terminal and storage medium Download PDFInfo
- Publication number
- CN109710483A CN109710483A CN201811603553.0A CN201811603553A CN109710483A CN 109710483 A CN109710483 A CN 109710483A CN 201811603553 A CN201811603553 A CN 201811603553A CN 109710483 A CN109710483 A CN 109710483A
- Authority
- CN
- China
- Prior art keywords
- smashclp
- information
- destination server
- standard
- test
- 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.)
- Withdrawn
Links
- 238000010998 test method Methods 0.000 title claims abstract description 12
- 238000012360 testing method Methods 0.000 claims abstract description 41
- 238000011990 functional testing Methods 0.000 claims abstract description 23
- 230000006870 function Effects 0.000 claims description 24
- 238000000034 method Methods 0.000 claims description 20
- 230000015654 memory Effects 0.000 claims description 19
- 238000004590 computer program Methods 0.000 claims description 4
- 238000000605 extraction Methods 0.000 claims description 3
- 238000004891 communication Methods 0.000 description 4
- 238000005516 engineering process Methods 0.000 description 4
- 238000012545 processing Methods 0.000 description 4
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 238000010586 diagram Methods 0.000 description 3
- 230000008878 coupling Effects 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 238000006467 substitution reaction Methods 0.000 description 2
- 238000013459 approach Methods 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000005540 biological transmission Effects 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 230000007812 deficiency Effects 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 230000005611 electricity Effects 0.000 description 1
- 238000005538 encapsulation Methods 0.000 description 1
- 238000009434 installation Methods 0.000 description 1
- 238000012423 maintenance Methods 0.000 description 1
- 238000012544 monitoring process Methods 0.000 description 1
- 238000005192 partition Methods 0.000 description 1
- 230000008569 process Effects 0.000 description 1
- 238000000926 separation method Methods 0.000 description 1
- 230000003068 static effect Effects 0.000 description 1
- 239000000126 substance Substances 0.000 description 1
- 238000012795 verification Methods 0.000 description 1
Landscapes
- Debugging And Monitoring (AREA)
Abstract
The present invention provides a kind of smashclp function test method, device, terminal and storage medium, comprising: obtains destination server FRU information as comparison standard using ipmi order;Destination server FRU information is obtained as test information using smashclp;By the way that the test information and the standard that compares are compared acquisition smashclp functional test results, the automatic test to smashclp function is can be achieved in the present invention, improves the accuracy for obtaining FRU information.
Description
Technical field
The invention belongs to server the field of test technology, and in particular to a kind of smashclp function test method, device, end
End and storage medium.
Background technique
It is well known that the BMC system in server is an independent system, it does not depend on it is other hard in system
Part, also do not depend on BIOS, OS etc., it is mainly responsible for monitoring and controls other hardware capabilities, and the object of operation is system hardware,
The FRU information of server includes product type, name of product, manufacturer, product serial number, asset number etc., these information are all
Entered in EEPROM before server factory by the order line brush that BMC is provided, is used convenient for follow-up maintenance personnel inquiry information, institute
It is vital to guarantee that FRU can inquire settable by order.
Smashclp is a kind of method for easily obtaining FRU information, but the feelings of the presence of Smashclp function missing
It will lead to the FRU INFORMATION OF INCOMPLETE of acquisition under condition or there is a problem of mistake.But there is presently no be directed to Smashclp function
The automatic test approach of stabilizability.
Summary of the invention
In view of the deficiencies of the prior art, the present invention provides a kind of smashclp function test method, device, terminal and storage
Medium, to solve the above technical problems.
In a first aspect, the embodiment of the present application provides a kind of smashclp function test method, which comprises
Destination server FRU information is obtained as comparison standard using ipmi order;
Destination server FRU information is obtained as test information using smashclp;
By the way that the test information and the standard that compares are compared acquisition smashclp functional test results.
With reference to first aspect, described to obtain target clothes using ipmi order in the first embodiment of first aspect
Device FRU information of being engaged in as comparison standard includes:
It issues ipmi order and obtains FRU information;
Product Name is extracted from FRU information.
With reference to first aspect, described to obtain target clothes using smashclp in second of embodiment of first aspect
Business device FRU information conduct tests information and includes:
Destination server is logged in using expect script;
Into smash command mode;
Smashclp order is issued to the Product that destination server obtains destination server by expect script
Name。
With reference to first aspect, described by the way that information and the ratio will be tested in the third embodiment of first aspect
Comparing acquisition smashclp functional test results to standard includes:
Judge the test information and whether described to compare standard consistent:
It is then to determine that smashclp functional test passes through;
It is no, then determine that smashclp functional test does not pass through.
Second aspect, the embodiment of the present application provide a kind of smashclp device for testing functions, and described device includes:
Standard acquiring unit is configured to obtain destination server FRU information as comparison standard using ipmi order;
Sample acquisition unit is configured to obtain destination server FRU information as test information using smashclp;
As a result acquiring unit is configured to the test information and the standard that compares comparing acquisition
Smashclp functional test results.
In conjunction with second aspect, in the first embodiment of second aspect, the standard acquiring unit includes:
Data obtaining module is configured to issue ipmi order acquisition FRU information;
Content extraction module is configured to extract Product Name from FRU information.
In conjunction with second aspect, in second of embodiment of second aspect, the sample acquisition unit includes:
Target login module is configured to log in destination server using expect script;
Mode enters module, is configured to enter smash command mode;
Order issues module, is configured to expect script for smashclp order and is issued to destination server acquisition
The Product Name of destination server.
In conjunction with second aspect, in the third embodiment of second aspect, the result acquiring unit includes:
Consistent judgment module is configured to judge the test information and whether described to compare standard consistent;
By determination module, it is configured to determine that smashclp functional test passes through;
Mistake determination module is configured to determine that smashclp functional test does not pass through.
The third aspect provides a kind of terminal, comprising:
Processor, memory, wherein
The memory is used to store computer program,
The processor from memory for calling and running the computer program, so that terminal executes above-mentioned terminal
Method.
Fourth aspect provides a kind of computer storage medium, instruction is stored in the computer readable storage medium,
When run on a computer, so that computer executes method described in above-mentioned various aspects.
5th aspect, provides a kind of computer program product comprising instruction, when run on a computer, so that
Computer executes method described in above-mentioned various aspects.
The beneficial effects of the present invention are,
Smashclp function test method, device, terminal and storage medium provided by the invention, by utilizing ipmi order
Destination server FRU information is obtained as comparison standard, smashclp is recycled to obtain destination server FRU information as test
Information, being compared with the standard that compares by will test information can be obtained the test result of smashclp function.The present invention can
It realizes the automatic test to smashclp function, improves the accuracy for obtaining FRU information.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below
There is attached drawing needed in technical description to be briefly described, it should be apparent that, for those of ordinary skill in the art
Speech, without creative efforts, is also possible to obtain other drawings based on these drawings.
Fig. 1 is the schematic flow chart of the method for the application one embodiment.
Fig. 2 is the schematic block diagram of the device of the application one embodiment.
Fig. 3 is a kind of structural schematic diagram of terminal provided in an embodiment of the present invention.
Specific embodiment
Technical solution in order to enable those skilled in the art to better understand the present invention, below in conjunction with of the invention real
The attached drawing in example is applied, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described implementation
Example is only a part of the embodiment of the present invention, instead of all the embodiments.Based on the embodiments of the present invention, this field is common
Technical staff's every other embodiment obtained without making creative work, all should belong to protection of the present invention
Range.
The Key Term occurred in the application is explained below.
Fig. 1 is the schematic flow chart of the method for the application one embodiment.Wherein, Fig. 1 executing subject can be one kind
Smashclp device for testing functions.
As shown in Figure 1, this method 100 includes:
Step 110, destination server FRU information is obtained as comparison standard using ipmi order;
Step 120, destination server FRU information is obtained as test information using smashclp;
Step 130, by the way that the test information and the standard that compares are compared acquisition smashclp functional test
As a result.
Optionally, as the application one embodiment, it is described using ipmi order obtain destination server FRU information as
Comparison standard includes:
It issues ipmi order and obtains FRU information;
Product Name is extracted from FRU information.
Optionally, as the application one embodiment, it is described using smashclp obtain destination server FRU information as
Testing information includes:
Destination server is logged in using expect script;
Into smash command mode;
Smashclp order is issued to the Product that destination server obtains destination server by expect script
Name。
Optionally, described to be compared by the way that information tested with the standard that compares as the application one embodiment
Obtaining smashclp functional test results includes:
Judge the test information and whether described to compare standard consistent:
It is then to determine that smashclp functional test passes through;
It is no, then determine that smashclp functional test does not pass through.
In order to facilitate the understanding of the present invention, below with the principle of smashclp function test method of the present invention, in conjunction with reality
Apply the process tested automatically in example smashclp function, to smashclp function test method provided by the invention do into
The description of one step.
Specifically, the smashclp function test method includes:
S1, destination server FRU information is obtained as comparison standard using ipmi order.
It issues ipmi order and obtains FRU information, extract ProductName
ipmitool–Ilanplus–H<ip>–U<username>–P<userpassword>fru print0。
S2, destination server FRU information is obtained using smashclp as test information.
Logged on on tested server using expect script ssh;
spawn ssh$username@$host
expect{"(yes/no)"{send"yes\n";expect"*password:"{send"$password\
n"}}"*password:"{send"$password\n"}}
Into smash command mode;
send"/usr/local/bin/smashclp"
It is sent in smashclp module using expect and collects FRU Product Name message command;
Send " fru--set PN Inspur n " # checks whether to collect successfully by echo message.If return information
Are as follows: Update FRU information Success!Then think to collect successfully.The information of collection is stored in file
In output.log, this document can be used for subsequent log analysis and compare, log_file output.log.
S3, by by the test information and it is described compare standard compare obtain smashclp functional test results.
FRU Product Name information and ipmitool that smashclp is got are got into FRU Product
Name information is compared, if unanimously, smashclp obtains the functional verification of FRU name of product and passes through, conversely, then test is tested
Card does not pass through.
If Fig. 2 shows, which includes:
Standard acquiring unit 210, the standard acquiring unit 210 are used to obtain destination server FRU using ipmi order
Information is as comparison standard;
Sample acquisition unit 220, the sample acquisition unit 220 are used to obtain destination server FRU using smashclp
Information is as test information;
As a result acquiring unit 230, the result acquiring unit 230 are used for by the way that the test information is compared mark with described
Standard, which compares, obtains smashclp functional test results.
Optionally, as the application one embodiment, the standard acquiring unit includes:
Data obtaining module is configured to issue ipmi order acquisition FRU information;
Content extraction module is configured to extract Product Name from FRU information.
Optionally, as the application one embodiment, the sample acquisition unit includes:
Target login module is configured to log in destination server using expect script;
Mode enters module, is configured to enter smash command mode;
Order issues module, is configured to expect script for smashclp order and is issued to destination server acquisition
The Product Name of destination server.
Optionally, as the application one embodiment, the result acquiring unit includes:
Consistent judgment module is configured to judge the test information and whether described to compare standard consistent;
By determination module, it is configured to determine that smashclp functional test passes through;
Mistake determination module is configured to determine that smashclp functional test does not pass through.
Fig. 3 is a kind of structural schematic diagram of terminal installation 300 provided in an embodiment of the present invention, which can be with
For executing smashclp function test method provided by the embodiments of the present application.
Wherein, which may include: processor 310, memory 320 and communication unit 330.These components
It is communicated by one or more bus, it will be understood by those skilled in the art that the structure of server shown in figure is not
The restriction to the application is constituted, it is also possible to hub-and-spoke configuration either busbar network, can also include more than illustrating
Or less component, perhaps combine certain components or different component layouts.
Wherein, which can be used for executing instruction for storage processor 310, and memory 320 can be by any class
The volatibility or non-volatile memories terminal or their combination of type are realized, such as static random access memory (SRAM), electricity
Erasable Programmable Read Only Memory EPROM (EEPROM), Erasable Programmable Read Only Memory EPROM (EPROM), programmable read only memory
(PROM), read-only memory (ROM), magnetic memory, flash memory, disk or CD.When executing instruction in memory 320
When being executed by processor 310, so that terminal 300 some or all of is able to carry out in following above method embodiment step.
Processor 310 is the control centre for storing terminal, utilizes each of various interfaces and the entire electric terminal of connection
A part by running or execute the software program and/or module that are stored in memory 320, and calls and is stored in storage
Data in device, to execute the various functions and/or processing data of electric terminal.The processor can be by integrated circuit
(Integrated Circuit, abbreviation IC) composition, such as the IC that can be encapsulated by single are formed, can also be by more of connection
The encapsulation IC of identical function or different function and form.For example, processor 310 can only include central processing unit
(Central Processing Unit, abbreviation CPU).In the application embodiment, CPU can be single operation core, can also
To include multioperation core.
Communication unit 330, for establishing communication channel, so that the storage terminal be allow to be led to other terminals
Letter.It receives the user data of other terminals transmission or sends user data to other terminals.
The application also provides a kind of computer storage medium, wherein the computer storage medium can be stored with program, the journey
Sequence may include step some or all of in each embodiment provided by the present application when executing.The storage medium can for magnetic disk,
CD, read-only memory (English: read-only memory, referred to as: ROM) or random access memory (English:
Random access memory, referred to as: RAM) etc..
Therefore, the application is recycled by obtaining destination server FRU information as comparison standard using ipmi order
Smashclp obtains destination server FRU information as test information, is compared i.e. by that will test information and compare standard
The test result of smashclp function can be obtained.The automatic test to smashclp function can be achieved in the present invention, improves acquisition
The accuracy of FRU information, the attainable technical effect of the present embodiment institute may refer to described above, and details are not described herein again.
It is required that those skilled in the art can be understood that the technology in the embodiment of the present application can add by software
The mode of general hardware platform realize.Based on this understanding, the technical solution in the embodiment of the present application substantially or
Say that the part that contributes to existing technology can be embodied in the form of software products, which is stored in
Such as USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory in one storage medium
The various media that can store program code such as (RAM, Random Access Memory), magnetic or disk, including it is several
Instruction is used so that a terminal (can be personal computer, server or second terminal, the network terminal etc.) is held
Row all or part of the steps of the method according to each embodiment of the present invention.
Same and similar part may refer to each other between each embodiment in this specification.Implement especially for terminal
For example, since it is substantially similar to the method embodiment, so being described relatively simple, related place is referring in embodiment of the method
Explanation.
In several embodiments provided herein, it should be understood that disclosed systems, devices and methods, it can be with
It realizes by another way.For example, the apparatus embodiments described above are merely exemplary, for example, the unit
It divides, only a kind of logical function partition, there may be another division manner in actual implementation, such as multiple units or components
It can be combined or can be integrated into another system, or some features can be ignored or not executed.Another point, it is shown or
The mutual coupling, direct-coupling or communication connection discussed can be through some interfaces, the indirect coupling of device or unit
It closes or communicates to connect, can be electrical property, mechanical or other forms.
The unit as illustrated by the separation member may or may not be physically separated, aobvious as unit
The component shown may or may not be physical unit, it can and it is in one place, or may be distributed over multiple
In network unit.It can select some or all of unit therein according to the actual needs to realize the mesh of this embodiment scheme
's.
It, can also be in addition, the functional units in various embodiments of the present invention may be integrated into one processing unit
It is that each unit physically exists alone, can also be integrated in one unit with two or more units.
Although by reference to attached drawing and combining the mode of preferred embodiment to the present invention have been described in detail, the present invention
It is not limited to this.Without departing from the spirit and substance of the premise in the present invention, those of ordinary skill in the art can be to the present invention
Embodiment carry out various equivalent modifications or substitutions, and these modifications or substitutions all should in covering scope of the invention/appoint
What those familiar with the art in the technical scope disclosed by the present invention, can easily think of the change or the replacement, answer
It is included within the scope of the present invention.Therefore, protection scope of the present invention is answered described is with scope of protection of the claims
It is quasi-.
Claims (10)
1. a kind of smashclp function test method, which is characterized in that the described method includes:
Destination server FRU information is obtained as comparison standard using ipmi order;
Destination server FRU information is obtained as test information using smashclp;
By the way that the test information and the standard that compares are compared acquisition smashclp functional test results.
2. the method according to claim 1, wherein described obtain destination server FRU letter using ipmi order
It ceases and includes: as comparison standard
It issues ipmi order and obtains FRU information;
Product Name is extracted from FRU information.
3. the method according to claim 1, wherein described obtain destination server FRU letter using smashclp
It ceases and includes: as test information
Destination server is logged in using expect script;
Into smash command mode;
Smashclp order is issued to the Product Name that destination server obtains destination server by expect script.
4. the method according to claim 1, wherein described carried out by that will test information and the standard that compares
Comparison obtains smashclp functional test results
Judge the test information and whether described to compare standard consistent:
It is then to determine that smashclp functional test passes through;
It is no, then determine that smashclp functional test does not pass through.
5. a kind of smashclp device for testing functions, which is characterized in that described device includes:
Standard acquiring unit is configured to obtain destination server FRU information as comparison standard using ipmi order;
Sample acquisition unit is configured to obtain destination server FRU information as test information using smashclp;
As a result acquiring unit is configured to the test information and the standard that compares comparing acquisition smashclp
Functional test results.
6. device according to claim 5, which is characterized in that the standard acquiring unit includes:
Data obtaining module is configured to issue ipmi order acquisition FRU information;
Content extraction module is configured to extract Product Name from FRU information.
7. device according to claim 5, which is characterized in that the sample acquisition unit includes:
Target login module is configured to log in destination server using expect script;
Mode enters module, is configured to enter smash command mode;
Order issues module, is configured to expect script for smashclp order and is issued to destination server acquisition target
The Product Name of server.
8. device according to claim 5, which is characterized in that the result acquiring unit includes:
Consistent judgment module is configured to judge the test information and whether described to compare standard consistent;
By determination module, it is configured to determine that smashclp functional test passes through;
Mistake determination module is configured to determine that smashclp functional test does not pass through.
9. a kind of terminal characterized by comprising
Processor;
The memory executed instruction for storage processor;
Wherein, the processor is configured to perform claim requires the described in any item methods of 1-4.
10. a kind of computer readable storage medium for being stored with computer program, which is characterized in that the program is executed by processor
Shi Shixian method for example of any of claims 1-4.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811603553.0A CN109710483A (en) | 2018-12-26 | 2018-12-26 | A kind of smashclp function test method, device, terminal and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811603553.0A CN109710483A (en) | 2018-12-26 | 2018-12-26 | A kind of smashclp function test method, device, terminal and storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN109710483A true CN109710483A (en) | 2019-05-03 |
Family
ID=66258440
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811603553.0A Withdrawn CN109710483A (en) | 2018-12-26 | 2018-12-26 | A kind of smashclp function test method, device, terminal and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109710483A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112101000A (en) * | 2020-09-17 | 2020-12-18 | 浪潮电子信息产业股份有限公司 | Information consistency test method, device, equipment and computer readable storage medium |
-
2018
- 2018-12-26 CN CN201811603553.0A patent/CN109710483A/en not_active Withdrawn
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112101000A (en) * | 2020-09-17 | 2020-12-18 | 浪潮电子信息产业股份有限公司 | Information consistency test method, device, equipment and computer readable storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109361562B (en) | Automatic testing method based on associated network equipment access | |
CN108768730B (en) | Method and device for operating intelligent network card | |
CN109510742A (en) | A kind of server network interface card remote test method, device, terminal and storage medium | |
CN109039829A (en) | A kind of network card performance testing method, apparatus, terminal and storage medium | |
CN106294222A (en) | A kind of method and device determining PCIE device and slot corresponding relation | |
CN102799504A (en) | Power supply testing system and method | |
CN110764980A (en) | Log processing method and device | |
CN109710505A (en) | A kind of disk failure prediction technique, device, terminal and storage medium | |
CN110162435A (en) | A kind of server PXE starting test method, system, terminal and storage medium | |
CN109408390A (en) | A kind of BMC login user stability test method, apparatus, terminal and storage medium | |
CN110557299A (en) | network transmission function batch test method, system, terminal and storage medium | |
CN104978266A (en) | Application test method and device | |
CN107612775A (en) | A kind of node two level connects the DC method of testings and system of server | |
CN109240865A (en) | A kind of AC test method, device, terminal and the storage medium of AEP memory | |
CN109800029A (en) | Batch sets method, apparatus, terminal and the storage medium of server B IOS parameter | |
CN109684166A (en) | Method, apparatus, terminal and the storage medium of automatic test Sensor log normalization | |
CN109446097A (en) | A kind of regression test case selection method, device, terminal and storage medium | |
CN109240847A (en) | EMS memory error report method, device, terminal and storage medium during a kind of POST | |
CN108712496A (en) | A kind of Port Mirroring method and device of OLT device | |
CN109815076A (en) | A kind of network interface card boot option detection method, system, terminal and storage medium | |
CN109788052A (en) | A kind of server configuration remote inquiry method, apparatus, terminal and storage medium | |
CN109491909A (en) | A kind of CPLD refreshes verification method, device, terminal and storage medium | |
CN109815070A (en) | A kind of HOST-BOX server stability test method, apparatus, terminal and storage medium | |
CN109918221A (en) | A kind of hard disk reports an error analytic method, system, terminal and storage medium | |
CN109710483A (en) | A kind of smashclp function test method, device, terminal and storage medium |
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 | ||
WW01 | Invention patent application withdrawn after publication |
Application publication date: 20190503 |
|
WW01 | Invention patent application withdrawn after publication |