CN113821387B - KVM function keep-alive test method, device, equipment and medium - Google Patents

KVM function keep-alive test method, device, equipment and medium Download PDF

Info

Publication number
CN113821387B
CN113821387B CN202110902548.5A CN202110902548A CN113821387B CN 113821387 B CN113821387 B CN 113821387B CN 202110902548 A CN202110902548 A CN 202110902548A CN 113821387 B CN113821387 B CN 113821387B
Authority
CN
China
Prior art keywords
attribute identifier
kvm
webpage
time period
page
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
CN202110902548.5A
Other languages
Chinese (zh)
Other versions
CN113821387A (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.)
Suzhou Inspur Intelligent Technology Co Ltd
Original Assignee
Suzhou Inspur Intelligent 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 Suzhou Inspur Intelligent Technology Co Ltd filed Critical Suzhou Inspur Intelligent Technology Co Ltd
Priority to CN202110902548.5A priority Critical patent/CN113821387B/en
Publication of CN113821387A publication Critical patent/CN113821387A/en
Application granted granted Critical
Publication of CN113821387B publication Critical patent/CN113821387B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/22Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
    • G06F11/2205Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing using arrangements specific to the hardware being tested
    • G06F11/2221Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing using arrangements specific to the hardware being tested to test input/output devices or peripheral units
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

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

Abstract

The invention provides a KVM function keep-alive test method, which comprises the following steps: sequentially acquiring a first attribute identifier and a second attribute identifier, wherein the first attribute identifier is an attribute identifier of a logged-in browser webpage, and the second attribute identifier is an attribute identifier of an opened KVM webpage; opening a webpage of a browser, waiting for a first time period, switching to a first attribute identifier, and waking up the webpage of the browser; switching to the second attribute identifier and waking up the KVM page; the alternate switching and awakening between the webpage and the KVM page are realized through the repeated switching between the first attribute identifier and the second attribute identifier in a preset second time period; after reaching the preset second time period, the invention also provides a KVM function keep-alive test device, equipment and medium, which effectively improves the reliability of the KVM function keep-alive test.

Description

KVM function keep-alive test method, device, equipment and medium
Technical Field
The invention relates to the field of KVM (keyboard video mouse) tests, in particular to a method, a device, equipment and a medium for testing the keep-alive of a KVM function.
Background
KVM stands for Keyboard (Keyboard), display (Video) and Mouse (Mouse), i.e. control of devices is achieved by a set of Keyboard, display and Mouse, which play an important role in remote scheduling and monitoring, and BMC (Baseboard Manager Controller, baseboard management controller) has VGA (Video Graphics Array ) interface, and the BMC supports virtual KVM functions, and can view the display of the server and operate by turning on the KVM.
The KVM session has a timeout mechanism, but the time-out is not performed during normal operation, and the KVM cannot be disconnected during normal use, otherwise normal use is affected, especially during the process of installing an OS (operating system), after the disconnection, the OS is failed to install. Therefore, in the normal use process of the KVM, a stable connection state needs to be maintained, and a certain pressure test needs to be performed in the test process.
The test scheme in the prior art only checks the stability of the KVM in the process of mounting the mirror image and installing the OS, lacks long-time KVM keep-alive test, and only can verify that the KVM is not disconnected in the process of installing the OS in the test process, cannot verify for a long time, thereby being unfavorable for improving the reliability of the KVM keep-alive test.
Disclosure of Invention
In order to solve the problems in the prior art, the invention innovatively provides a method, a device, equipment and a medium for testing the keep-alive of the KVM function, which effectively solve the problem of low reliability of the keep-alive test of the KVM caused by the prior art and effectively improve the reliability of the keep-alive test of the KVM function.
The first aspect of the present invention provides a KVM function keep-alive test method, including:
sequentially acquiring a first attribute identifier and a second attribute identifier, wherein the first attribute identifier is an attribute identifier of a logged-in browser webpage, and the second attribute identifier is an attribute identifier of an opened KVM webpage;
opening a webpage of a browser, waiting for a first time period, switching to a first attribute identifier, and waking up the webpage of the browser;
switching to the second attribute identifier and waking up the KVM page;
alternating switching and awakening between the webpage and the KVM page are realized through multiple switching between the first attribute identifier and the second attribute identifier in a preset second time period, wherein the second time period is longer than the first time period;
and outputting a test result after the preset second time period is reached.
Optionally, opening the browser, logging in the webpage of the browser, acquiring the attribute identifier of the webpage of the browser, and setting the acquired attribute identifier of the webpage of the browser as a first attribute identifier;
starting a KVM page, acquiring an attribute identifier of the KVM page, and setting the acquired attribute identifier of the KVM page as a second attribute identifier;
comparing whether the second attribute identifier is consistent with the first attribute identifier, if so, detecting whether the KVM page is normally opened, if so, acquiring the second attribute identifier again, comparing, and if not, failing to test; if the attribute identifiers are inconsistent, opening the webpage of the browser, waiting for a first time period, switching to the first attribute identifier, and waking up the webpage of the browser.
Optionally, the test result includes: the duration of each web page, the duration of each KVM page, whether there is a web page or an abnormal exit of KVM pages.
Further, if the duration of each webpage is not longer than the duration of the corresponding preset webpage, and the duration of each KVM page is not longer than the duration of the corresponding preset KVM page, and no abnormal exit condition of the webpage or the KVM page exists, the test is passed; if the duration of a certain webpage is longer than the duration of a corresponding preset webpage, and/or if the duration of a certain KVM (keyboard video mouse) page is longer than the duration of a corresponding preset KVM page, and/or if the webpage or the KVM page exits abnormally, the test fails.
Optionally, the method further comprises:
and stopping the test, reserving a test site and positioning a test problem when a test abnormal condition occurs in the test process, wherein the test abnormal condition comprises a web page or KVM page switching failure.
Optionally, the method further comprises:
and in a preset second time period, obtaining the memory information stored in the baseboard management controller and performing memory leakage test when waiting for the first time period each time.
Further, in a preset second time period, when waiting for the first time period each time, obtaining the memory information stored in the baseboard management controller, and performing the memory leakage test specifically includes:
when the preset second time period is reached, the memory information stored in the baseboard management controller is acquired in the second time period when the first time period is waited for each time, if the memory capacity acquired in the first time period is continuously waited for a plurality of times, the memory leakage exists, and if the memory capacity acquired in the first time period is not continuously waited for a plurality of times, the memory leakage does not exist.
A second aspect of the present invention provides a KVM function keep-alive test device, comprising:
the acquisition module sequentially acquires a first attribute identifier and a second attribute identifier, wherein the first attribute identifier is an attribute identifier of a logged-in browser webpage, and the second attribute identifier is an attribute identifier of an opened KVM webpage;
the first switching module opens the webpage of the browser, waits for a first time period, switches to the first attribute identifier, and wakes up the webpage of the browser;
the second switching module is used for switching to a second attribute identifier and waking up the KVM page;
the alternating switching module is used for realizing alternating switching and awakening between the webpage and the KVM page through multiple switching between the first attribute identifier and the second attribute identifier in a preset second time period, wherein the second time period is longer than the first time period;
and the output module outputs the test result after the preset second time period is reached.
A third aspect of the present invention provides an electronic device, comprising: a memory for storing a computer program; a processor for implementing the steps of a KVM function keep-alive test method according to the first aspect of the invention when executing the computer program.
A fourth aspect of the present invention provides a computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of a KVM function keep-alive test method according to the first aspect of the present invention.
The technical scheme adopted by the invention comprises the following technical effects:
1. according to the technical scheme, the alternating switching of the web pages and the KVM pages is realized through the switching of the first attribute identifier and the second attribute identifier, the problem of low reliability of the KVM keep-alive test caused by the prior art is effectively solved, and the reliability of the KVM function keep-alive test is effectively improved.
2. In the technical scheme of the invention, whether the KVM page is normally opened is detected by comparing whether the second attribute identifier is consistent with the first attribute identifier, if so, the second attribute identifier is acquired again, and the comparison is carried out, if not, the test fails; if the first attribute identifier is inconsistent with the second attribute identifier, opening the webpage of the browser, waiting for a first time period, switching to the first attribute identifier, and waking up the webpage of the browser, so that the accuracy of a test result is improved, and the problem of low test efficiency caused by the consistency of the second attribute identifier and the first attribute identifier is avoided.
3. The test result in the technical scheme of the invention comprises the following steps: the method comprises the steps of comprehensively detecting the duration of each webpage, the duration of each KVM (keyboard video mouse) page and whether the webpage or the KVM page abnormally exits or not; the method has the advantages that the problem that in the prior art, because the KVM session is overtime, the KVM cannot be disconnected in the process of only verifying the installation OS and cannot be verified for a long time due to the lack of a corresponding keep-alive method is avoided, and the reliability of the keep-alive test of the KVM function is further improved.
4. According to the technical scheme, the abnormal testing condition occurs in the testing process, the testing is stopped, the testing site is reserved, and the testing problem is positioned, wherein the abnormal testing condition comprises that the switching of the webpage or the KVM webpage fails, so that the problem is accurately positioned, the site is reserved, the problem that the abnormal problem is not reproduced due to the fact that the testing is continued is avoided, and the efficiency of confirming the problem and solving the problem on the research end is improved.
5. In the technical scheme of the invention, in the preset second time period, the memory information stored in the baseboard management controller is obtained and the memory leakage test is carried out each time the first time period is waited, so that the efficiency of the keep-alive test of the KVM function is further improved.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the invention as claimed.
Drawings
For a clearer description of embodiments of the invention or of the solutions of the prior art, reference will be made to the accompanying drawings, which are used in the description of the embodiments or of the prior art, and it will be obvious to those skilled in the art that other drawings can be obtained from these without inventive labour.
FIG. 1 is a schematic flow chart of a method according to an embodiment of the present invention;
FIG. 2 is a schematic flow chart of step S1 in a method according to an embodiment of the present invention;
FIG. 3 is a schematic flow chart of another method according to an embodiment of the present invention;
FIG. 4 is a schematic flow chart of another method according to an embodiment of the present invention;
FIG. 5 is a schematic flow chart of step S7 in a method according to an embodiment of the present invention;
FIG. 6 is a schematic structural diagram of a second embodiment of the present invention;
fig. 7 is a schematic structural diagram of a third device according to an embodiment of the present invention.
Detailed Description
In order to clearly illustrate the technical features of the present solution, the present invention will be described in detail below with reference to the following detailed description and the accompanying drawings. The following disclosure provides many different embodiments, or examples, for implementing different structures of the invention. In order to simplify the present disclosure, components and arrangements of specific examples are described below. Furthermore, the present invention may repeat reference numerals and/or letters in the various examples. This repetition is for the purpose of simplicity and clarity and does not in itself dictate a relationship between the various embodiments and/or configurations discussed. It should be noted that the components illustrated in the figures are not necessarily drawn to scale. Descriptions of well-known components and processing techniques and processes are omitted so as to not unnecessarily obscure the present invention.
Example 1
As shown in FIG. 1, the invention provides a KVM function keep-alive test method, which comprises the following steps:
s1, sequentially acquiring a first attribute identifier and a second attribute identifier, wherein the first attribute identifier is an attribute identifier of a logged-in browser webpage, and the second attribute identifier is an attribute identifier of an opened KVM webpage;
s2, opening a webpage of the browser, waiting for a first time period, switching to a first attribute identifier, and waking up the webpage of the browser;
s3, switching to a second attribute identifier and waking up the KVM page;
s4, alternately switching and waking up between the webpage and the KVM page is realized through multiple switching between the first attribute identifier and the second attribute identifier in a preset second time period, wherein the second time period is longer than the first time period;
s5, outputting a test result after the preset second time period is reached.
In step S1, as shown in fig. 2, step S1 specifically includes:
s11, opening a browser, logging in a webpage of the browser, acquiring an attribute identifier of the webpage of the browser, and setting the acquired attribute identifier of the webpage of the browser as a first attribute identifier;
s12, starting the KVM page, acquiring an attribute identifier of the KVM page, and setting the acquired attribute identifier of the KVM page as a second attribute identifier;
s13, comparing whether the second attribute identifier is consistent with the first attribute identifier, and if so, executing a step S14; if the judgment result is negative, executing the step S2;
s14, detecting whether the KVM page is normally opened, and if so, executing a step S15; if the judgment result is negative, executing the step S16;
s15, re-acquiring the second attribute identifier and re-executing the step S13;
s16, the test fails.
In steps S11-S16, the first attribute identifier and the second attribute identifier are handles, and each page window has an attribute, and the handle is used to identify the page window. Recording the attribute of each page window, wherein the newly opened window is not consistent with the original window attribute, so that whether the second attribute identifier is consistent with the first attribute identifier is compared, if so, the fact that the KVM page is not successfully opened is indicated, if so, whether the KVM page is normally opened is detected, if so, the second attribute identifier is acquired again, and the comparison is repeated; if not normally (successfully) turned on, the test fails, indicating that the KVM page cannot be normally turned on.
In steps S2-S4, the first time period may be 5 minutes and the second time period may be 48 hours, i.e., the first time period is much smaller than the second time period, so as to perform a long-time multiple test on the KVM function. Specific values of the first time period and the second time period can be flexibly adjusted according to actual situations, and the invention is not limited herein.
The wake-up of the KVM page may be performed by acquiring KVM button operation information, i.e., a double-click operation of a key or an input operation of an enter key, or may be performed by other means, which is not limited herein.
In step S5, the output test result may include: the duration of each webpage, the duration of each KVM page, and whether the webpage or the KVM page is in abnormal exit or not are the duration of each webpage in all first time periods, the duration of each KVM page in all first time periods, and whether the webpage or the KVM page is in abnormal exit or not in all first time periods.
If the duration of each webpage is not longer than the duration of the corresponding preset webpage and the duration of each KVM (keyboard video mouse) page is not longer than the duration of the corresponding preset KVM page and the condition that the webpage or the KVM page is abnormally exited does not exist, the test is passed; if the duration of a certain webpage is longer than the duration of a corresponding preset webpage, and/or if the duration of a certain KVM (keyboard video mouse) page is longer than the duration of a corresponding preset KVM page, and/or if the webpage or the KVM page exits abnormally, the test fails. The duration of the preset web page may be the same as or different from the duration of the preset KVM page, for example, may be 30s, and may be adjusted according to the actual situation, which is not limited in the present invention.
Preferably, the test result may also include a user login page condition, a KVM page opening condition, whether each page switch is successful (i.e. the KVM page is switched to the web page), whether each KVM page switch is successful (i.e. the web page is switched to the KVM page), a last KVM closing condition, a last web page closing condition, a user logout condition, and so on. The accuracy and reliability of the KVM functional keep-alive test can be further improved according to the test results.
Further, as shown in fig. 3, the embodiment of the present invention further provides a KVM function keep-alive testing method, which further includes:
s6, stopping the test when the abnormal test condition occurs in the test process, reserving the test site, and positioning the test problem, wherein the abnormal test condition comprises web page or KVM page switching failure.
In step S6, the conditions such as web page or KVM page switching failure occur in the testing process, that is, the web page switching failure or KVM page switching failure occurs, the testing is stopped, the testing site is reserved, the testing problem is located, the maintenance personnel can conveniently locate the testing problem according to the testing site condition, and the efficiency of solving the abnormal testing condition is improved.
Further, as shown in fig. 4, the embodiment of the present invention further provides a KVM function keep-alive testing method, which further includes:
and S7, in a preset second time period, obtaining the memory information stored in the baseboard management controller and performing memory leakage test when waiting for the first time period each time.
As shown in fig. 5, step S7 specifically includes:
s71, when a preset second time period is reached, acquiring memory information stored in a baseboard management controller acquired when the first time period is waited for each time in the second time period;
s72, judging whether the situation of memory capacity reduction acquired when waiting for the first time period continuously for a plurality of times exists, and if so, executing the step S73; if the judgment result is negative, executing step S74;
s73, memory leakage exists;
s74, no memory leak exists.
In step S71-S74, in a preset second time period, when waiting for a first time period, memory information stored in a Baseboard Management Controller (BMC), specifically top information, that is, information such as system running time, average load, CPU state, memory usage, and the like, can be checked through a top command in linux through SSH (Secure Shell) session connection, and whether memory leakage occurs can be determined through remaining memory information recorded in the waiting process in each first time period. Specifically, if there is a case where the memory capacity acquired while waiting for the first time period is reduced continuously a plurality of times, for example, the remaining memory capacity is 200M in the first time period waiting process for the first time, the remaining memory capacity is 190M in the second time period waiting process, and the remaining memory capacity is 186M in the third time period waiting process, memory leakage occurs; if 196M of the remaining memory capacity is obtained in the third waiting process of the first time period, no memory leakage occurs.
It should be noted that, in the technical solution of the present invention, steps S1 to S7 may be implemented by programming in hardware or software programming language, and the idea of programming corresponds to the steps, and may also be implemented in other manners, which is not limited herein.
According to the technical scheme, the alternating switching of the web pages and the KVM pages is realized through the switching of the first attribute identifier and the second attribute identifier, the problem of low reliability of the KVM keep-alive test caused by the prior art is effectively solved, and the reliability of the KVM function keep-alive test is effectively improved.
In the technical scheme of the invention, whether the KVM page is normally opened is detected by comparing whether the second attribute identifier is consistent with the first attribute identifier, if so, the second attribute identifier is acquired again, and the comparison is carried out, if not, the test fails; if the first attribute identifier is inconsistent with the second attribute identifier, opening the webpage of the browser, waiting for a first time period, switching to the first attribute identifier, and waking up the webpage of the browser, so that the accuracy of a test result is improved, and the problem of low test efficiency caused by the consistency of the second attribute identifier and the first attribute identifier is avoided.
The test result in the technical scheme of the invention comprises the following steps: the method comprises the steps of comprehensively detecting the duration of each webpage, the duration of each KVM (keyboard video mouse) page and whether the webpage or the KVM page abnormally exits or not; the method has the advantages that the problem that in the prior art, because the KVM session is overtime, the KVM cannot be disconnected in the process of only verifying the installation OS and cannot be verified for a long time due to the lack of a corresponding keep-alive method is avoided, and the reliability of the keep-alive test of the KVM function is further improved.
According to the technical scheme, the abnormal testing condition occurs in the testing process, the testing is stopped, the testing site is reserved, and the testing problem is positioned, wherein the abnormal testing condition comprises that the switching of the webpage or the KVM webpage fails, so that the problem is accurately positioned, the site is reserved, the problem that the abnormal problem is not reproduced due to the fact that the testing is continued is avoided, and the efficiency of confirming the problem and solving the problem on the research end is improved.
In the technical scheme of the invention, in the preset second time period, the memory information stored in the baseboard management controller is obtained and the memory leakage test is carried out each time the first time period is waited, so that the efficiency of the keep-alive test of the KVM function is further improved.
Example two
As shown in fig. 6, the technical solution of the present invention further provides a KVM function keep-alive test device, including:
the acquisition module 101 sequentially acquires a first attribute identifier and a second attribute identifier, wherein the first attribute identifier is an attribute identifier of a logged-in browser webpage, and the second attribute identifier is an attribute identifier of an opened KVM webpage;
the first switching module 102 opens a web page of the browser, waits for a first period of time, switches to the first attribute identifier, and wakes up the web page of the browser;
a second switch module 103 that switches to the second attribute identifier and wakes up the KVM page;
the alternate switching module 104 is configured to implement alternate switching and waking between the web page and the KVM page through multiple switching between the first attribute identifier and the second attribute identifier in a preset second time period, where the second time period is greater than the first time period;
and the output module 105 outputs the test result after the preset second time period is reached.
According to the technical scheme, the alternating switching of the web pages and the KVM pages is realized through the switching of the first attribute identifier and the second attribute identifier, the problem of low reliability of the KVM keep-alive test caused by the prior art is effectively solved, and the reliability of the KVM function keep-alive test is effectively improved.
In the technical scheme of the invention, whether the KVM page is normally opened is detected by comparing whether the second attribute identifier is consistent with the first attribute identifier, if so, the second attribute identifier is acquired again, and the comparison is carried out, if not, the test fails; if the first attribute identifier is inconsistent with the second attribute identifier, opening the webpage of the browser, waiting for a first time period, switching to the first attribute identifier, and waking up the webpage of the browser, so that the accuracy of a test result is improved, and the problem of low test efficiency caused by the consistency of the second attribute identifier and the first attribute identifier is avoided.
The test result in the technical scheme of the invention comprises the following steps: the method comprises the steps of comprehensively detecting the duration of each webpage, the duration of each KVM (keyboard video mouse) page and whether the webpage or the KVM page abnormally exits or not; the method has the advantages that the problem that in the prior art, because the KVM session is overtime, the KVM cannot be disconnected in the process of only verifying the installation OS and cannot be verified for a long time due to the lack of a corresponding keep-alive method is avoided, and the reliability of the keep-alive test of the KVM function is further improved.
According to the technical scheme, the abnormal testing condition occurs in the testing process, the testing is stopped, the testing site is reserved, and the testing problem is positioned, wherein the abnormal testing condition comprises that the switching of the webpage or the KVM webpage fails, so that the problem is accurately positioned, the site is reserved, the problem that the abnormal problem is not reproduced due to the fact that the testing is continued is avoided, and the efficiency of confirming the problem and solving the problem on the research end is improved.
In the technical scheme of the invention, in the preset second time period, the memory information stored in the baseboard management controller is obtained and the memory leakage test is carried out each time the first time period is waited, so that the efficiency of the keep-alive test of the KVM function is further improved.
Example III
As shown in fig. 7, the technical solution of the present invention further provides an electronic device, including: a memory 201 for storing a computer program; a processor 202 for implementing the steps as in embodiment one when executing the computer program.
The memory 201 in the embodiments of the present application is used to store various types of data to support the operation of the electronic device. Examples of such data include: any computer program for operating on an electronic device. It will be appreciated that memory 201 may be volatile memory or nonvolatile memory, and may include both volatile and nonvolatile memory. Wherein the nonvolatile Memory may be Read Only Memory (ROM), programmable Read Only Memory (PROM, programmable Read-Only Memory), erasable programmable Read Only Memory (EPROM, erasable Programmable Read-Only Memory), electrically erasable programmable Read Only Memory (EEPROM, electrically Erasable Programmable Read-Only Memory), magnetic random access Memory (FRAM, ferromagnetic random access Memory), flash Memory (Flash Memory), magnetic surface Memory, optical disk, or compact disk Read Only Memory (CD-ROM, compact Disc Read-Only Memory); the magnetic surface memory may be a disk memory or a tape memory. The volatile memory may be random access memory (RAM, random AccessMemory), which acts as external cache memory. By way of example, and not limitation, many forms of RAM are available, such as static random access memory (SRAM, static Random Access Memory), synchronous static random access memory (SSRAM, synchronous Static Random Access Memory), dynamic random access memory (DRAM, dynamic Random Access Memory), synchronous dynamic random access memory (SDRAM, synchronousDynamic Random Access Memory), double data rate synchronous dynamic random access memory (ddr sdram, double Data Rate Synchronous Dynamic Random Access Memory), enhanced synchronous dynamic random access memory (ESDRAM, enhanced Synchronous Dynamic Random Access Memory), synchronous link dynamic random access memory (SLDRAM, syncLink Dynamic Random Access Memory), direct memory bus random access memory (DRRAM, direct Rambus Random Access Memory). The memory 201 described in the embodiments of the present application is intended to comprise, without being limited to, these and any other suitable types of memory. The methods disclosed in the embodiments of the present application may be applied to the processor 202 or implemented by the processor 202. The processor 202 may be an integrated circuit chip with signal processing capabilities. In implementation, the steps of the above method may be performed by integrated logic circuitry in hardware in the processor 202 or by instructions in software. The processor 202 may be a general purpose processor, a DSP (Digital Signal Processing, meaning a chip capable of implementing digital signal processing techniques), or other programmable logic device, discrete gate or transistor logic device, discrete hardware components, or the like. Processor 202 may implement or perform the methods, steps, and logic blocks disclosed in embodiments of the present application. The general purpose processor may be a microprocessor or any conventional processor or the like. The steps of the method disclosed in the embodiments of the present application may be directly embodied in a hardware decoding processor or implemented by a combination of hardware and software modules in the decoding processor. The software modules may be located in a storage medium in the memory 201 and the processor 202 reads the program in the memory 201 to perform the steps of the method described above in connection with its hardware. The processor 202 implements corresponding flows in the methods of the embodiments of the present application when executing the program, and for brevity, will not be described in detail herein.
According to the technical scheme, the alternating switching of the web pages and the KVM pages is realized through the switching of the first attribute identifier and the second attribute identifier, the problem of low reliability of the KVM keep-alive test caused by the prior art is effectively solved, and the reliability of the KVM function keep-alive test is effectively improved.
In the technical scheme of the invention, whether the KVM page is normally opened is detected by comparing whether the second attribute identifier is consistent with the first attribute identifier, if so, the second attribute identifier is acquired again, and the comparison is carried out, if not, the test fails; if the first attribute identifier is inconsistent with the second attribute identifier, opening the webpage of the browser, waiting for a first time period, switching to the first attribute identifier, and waking up the webpage of the browser, so that the accuracy of a test result is improved, and the problem of low test efficiency caused by the consistency of the second attribute identifier and the first attribute identifier is avoided.
The test result in the technical scheme of the invention comprises the following steps: the method comprises the steps of comprehensively detecting the duration of each webpage, the duration of each KVM (keyboard video mouse) page and whether the webpage or the KVM page abnormally exits or not; the method has the advantages that the problem that in the prior art, because the KVM session is overtime, the KVM cannot be disconnected in the process of only verifying the installation OS and cannot be verified for a long time due to the lack of a corresponding keep-alive method is avoided, and the reliability of the keep-alive test of the KVM function is further improved.
According to the technical scheme, the abnormal testing condition occurs in the testing process, the testing is stopped, the testing site is reserved, and the testing problem is positioned, wherein the abnormal testing condition comprises that the switching of the webpage or the KVM webpage fails, so that the problem is accurately positioned, the site is reserved, the problem that the abnormal problem is not reproduced due to the fact that the testing is continued is avoided, and the efficiency of confirming the problem and solving the problem on the research end is improved.
In the technical scheme of the invention, in the preset second time period, the memory information stored in the baseboard management controller is obtained and the memory leakage test is carried out each time the first time period is waited, so that the efficiency of the keep-alive test of the KVM function is further improved.
Example IV
The present invention also provides a computer readable storage medium having a computer program stored thereon, which when executed by a processor, implements the steps as in the first embodiment.
For example comprising a memory 201 storing a computer program executable by a processor 202 to perform the steps of the method described above. The computer readable storage medium may be FRAM, ROM, PROM, EPROM, EEPROM, flash Memory, magnetic surface Memory, optical disk, or CD-ROM.
Those of ordinary skill in the art will appreciate that: all or part of the steps for implementing the above method embodiments may be implemented by hardware associated with program instructions, where the foregoing program may be stored in a computer readable storage medium, and when executed, the program performs steps including the above method embodiments; and the aforementioned storage medium includes: a removable storage device, ROM, RAM, magnetic or optical disk, or other medium capable of storing program code. Alternatively, the integrated units described above may be stored in a computer readable storage medium if implemented in the form of software functional modules and sold or used as a stand-alone product. Based on such understanding, the technical solutions of the embodiments of the present application may be essentially or partly contributing to the prior art, and the computer software product may be stored in a storage medium, and include several instructions to cause an electronic device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the methods described in the embodiments of the present application. And the aforementioned storage medium includes: a removable storage device, ROM, RAM, magnetic or optical disk, or other medium capable of storing program code.
According to the technical scheme, the alternating switching of the web pages and the KVM pages is realized through the switching of the first attribute identifier and the second attribute identifier, the problem of low reliability of the KVM keep-alive test caused by the prior art is effectively solved, and the reliability of the KVM function keep-alive test is effectively improved.
In the technical scheme of the invention, whether the KVM page is normally opened is detected by comparing whether the second attribute identifier is consistent with the first attribute identifier, if so, the second attribute identifier is acquired again, and the comparison is carried out, if not, the test fails; if the first attribute identifier is inconsistent with the second attribute identifier, opening the webpage of the browser, waiting for a first time period, switching to the first attribute identifier, and waking up the webpage of the browser, so that the accuracy of a test result is improved, and the problem of low test efficiency caused by the consistency of the second attribute identifier and the first attribute identifier is avoided.
The test result in the technical scheme of the invention comprises the following steps: the method comprises the steps of comprehensively detecting the duration of each webpage, the duration of each KVM (keyboard video mouse) page and whether the webpage or the KVM page abnormally exits or not; the method has the advantages that the problem that in the prior art, because the KVM session is overtime, the KVM cannot be disconnected in the process of only verifying the installation OS and cannot be verified for a long time due to the lack of a corresponding keep-alive method is avoided, and the reliability of the keep-alive test of the KVM function is further improved.
According to the technical scheme, the abnormal testing condition occurs in the testing process, the testing is stopped, the testing site is reserved, and the testing problem is positioned, wherein the abnormal testing condition comprises that the switching of the webpage or the KVM webpage fails, so that the problem is accurately positioned, the site is reserved, the problem that the abnormal problem is not reproduced due to the fact that the testing is continued is avoided, and the efficiency of confirming the problem and solving the problem on the research end is improved.
In the technical scheme of the invention, in the preset second time period, the memory information stored in the baseboard management controller is obtained and the memory leakage test is carried out each time the first time period is waited, so that the efficiency of the keep-alive test of the KVM function is further improved.
While the foregoing description of the embodiments of the present invention has been presented in conjunction with the drawings, it should be understood that it is not intended to limit the scope of the invention, but rather, it is intended to cover all modifications or variations within the scope of the invention as defined by the claims of the present invention.

Claims (9)

1. A KVM function keep-alive test method is characterized by comprising the following steps:
sequentially acquiring a first attribute identifier and a second attribute identifier, wherein the first attribute identifier is an attribute identifier of a logged-in browser webpage, and the second attribute identifier is an attribute identifier of an opened KVM webpage; the attribute identifier is a handle; the sequentially obtaining the first attribute identifier and the second attribute identifier specifically includes:
opening a browser, logging in a webpage of the browser, acquiring an attribute identifier of the webpage of the browser, and setting the acquired attribute identifier of the webpage of the browser as a first attribute identifier;
starting a KVM page, acquiring an attribute identifier of the KVM page, and setting the acquired attribute identifier of the KVM page as a second attribute identifier;
comparing whether the second attribute identifier is consistent with the first attribute identifier, if so, detecting whether the KVM page is normally opened, if so, acquiring the second attribute identifier again, comparing, and if not, failing to test; if the attribute identifiers are inconsistent, opening a webpage of the browser, waiting for a first time period, switching to the first attribute identifier, and waking up the webpage of the browser;
opening a webpage of a browser, waiting for a first time period, switching to a first attribute identifier, and waking up the webpage of the browser;
switching to the second attribute identifier and waking up the KVM page;
alternating switching and awakening between the webpage and the KVM page are realized through multiple switching between the first attribute identifier and the second attribute identifier in a preset second time period, wherein the second time period is longer than the first time period;
and outputting a test result after the preset second time period is reached.
2. The method for testing the keep-alive of the KVM function as recited in claim 1, wherein the test result comprises: the duration of each web page, the duration of each KVM page, whether there is a web page or an abnormal exit of KVM pages.
3. The method for testing the keep-alive of the KVM function according to claim 2, wherein if the duration of each webpage is not longer than the duration of the corresponding preset webpage, and the duration of each KVM webpage is not longer than the duration of the corresponding preset KVM webpage, and no abnormal exit condition of the webpage or the KVM webpage exists, the test is passed; if the duration of a certain webpage is longer than the duration of a corresponding preset webpage, and/or if the duration of a certain KVM (keyboard video mouse) page is longer than the duration of a corresponding preset KVM page, and/or if the webpage or the KVM page exits abnormally, the test fails.
4. A KVM function keep-alive test method according to any one of claims 1-3, further comprising:
and stopping the test, reserving a test site and positioning a test problem when a test abnormal condition occurs in the test process, wherein the test abnormal condition comprises a web page or KVM page switching failure.
5. A KVM function keep-alive test method according to any one of claims 1-3, further comprising:
and in a preset second time period, obtaining the memory information stored in the baseboard management controller and performing memory leakage test when waiting for the first time period each time.
6. The method for testing the keep-alive of a KVM function as claimed in claim 5, wherein the step of obtaining the memory information stored in the baseboard management controller for performing the memory leak test each time waiting for the first time period in the preset second time period comprises:
when the preset second time period is reached, the memory information stored in the baseboard management controller is acquired in the second time period when the first time period is waited for each time, if the memory capacity acquired in the first time period is continuously waited for a plurality of times, the memory leakage exists, and if the memory capacity acquired in the first time period is not continuously waited for a plurality of times, the memory leakage does not exist.
7. A KVM function keep-alive testing arrangement, characterized by that includes:
the acquisition module sequentially acquires a first attribute identifier and a second attribute identifier, wherein the first attribute identifier is an attribute identifier of a logged-in browser webpage, and the second attribute identifier is an attribute identifier of an opened KVM webpage; the attribute identifier is a handle; the sequentially obtaining the first attribute identifier and the second attribute identifier specifically includes:
opening a browser, logging in a webpage of the browser, acquiring an attribute identifier of the webpage of the browser, and setting the acquired attribute identifier of the webpage of the browser as a first attribute identifier;
starting a KVM page, acquiring an attribute identifier of the KVM page, and setting the acquired attribute identifier of the KVM page as a second attribute identifier;
comparing whether the second attribute identifier is consistent with the first attribute identifier, if so, detecting whether the KVM page is normally opened, if so, acquiring the second attribute identifier again, comparing, and if not, failing to test; if the attribute identifiers are inconsistent, opening a webpage of the browser, waiting for a first time period, switching to the first attribute identifier, and waking up the webpage of the browser;
the first switching module opens the webpage of the browser, waits for a first time period, switches to the first attribute identifier, and wakes up the webpage of the browser;
the second switching module is used for switching to a second attribute identifier and waking up the KVM page;
the alternating switching module is used for realizing alternating switching and awakening between the webpage and the KVM page through multiple switching between the first attribute identifier and the second attribute identifier in a preset second time period, wherein the second time period is longer than the first time period;
and the output module outputs the test result after the preset second time period is reached.
8. An electronic device, comprising: a memory for storing a computer program; a processor for implementing the steps of a KVM function keep-alive test method according to any one of claims 1 to 6 when executing the computer program.
9. A computer readable storage medium, wherein a computer program is stored on the computer readable storage medium, and when executed by a processor, the computer program implements the steps of a KVM function keep-alive test method according to any one of claims 1 to 6.
CN202110902548.5A 2021-08-06 2021-08-06 KVM function keep-alive test method, device, equipment and medium Active CN113821387B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110902548.5A CN113821387B (en) 2021-08-06 2021-08-06 KVM function keep-alive test method, device, equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110902548.5A CN113821387B (en) 2021-08-06 2021-08-06 KVM function keep-alive test method, device, equipment and medium

Publications (2)

Publication Number Publication Date
CN113821387A CN113821387A (en) 2021-12-21
CN113821387B true CN113821387B (en) 2023-07-18

Family

ID=78912960

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110902548.5A Active CN113821387B (en) 2021-08-06 2021-08-06 KVM function keep-alive test method, device, equipment and medium

Country Status (1)

Country Link
CN (1) CN113821387B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104035863A (en) * 2013-03-08 2014-09-10 腾讯科技(深圳)有限公司 Browser testing method and device
CN109240862A (en) * 2018-08-23 2019-01-18 郑州云海信息技术有限公司 A kind of method of outband management test b MC stability
CN110362488A (en) * 2019-07-12 2019-10-22 北京字节跳动网络技术有限公司 A kind of page test method, device, electronic equipment and storage medium
CN111010308A (en) * 2019-10-29 2020-04-14 苏州浪潮智能科技有限公司 KVM service test method and device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104035863A (en) * 2013-03-08 2014-09-10 腾讯科技(深圳)有限公司 Browser testing method and device
CN109240862A (en) * 2018-08-23 2019-01-18 郑州云海信息技术有限公司 A kind of method of outband management test b MC stability
CN110362488A (en) * 2019-07-12 2019-10-22 北京字节跳动网络技术有限公司 A kind of page test method, device, electronic equipment and storage medium
CN111010308A (en) * 2019-10-29 2020-04-14 苏州浪潮智能科技有限公司 KVM service test method and device

Also Published As

Publication number Publication date
CN113821387A (en) 2021-12-21

Similar Documents

Publication Publication Date Title
JP3831377B2 (en) Method and apparatus for analyzing power failure in a computer system
US8738965B2 (en) Test method and test device for restarting a computer based on a hardware information comparison and a restart count
US7356744B2 (en) Method and system for optimizing testing of memory stores
CN108376107A (en) A kind of method, apparatus, equipment and the storage medium of server failure detection
CN104850485A (en) BMC based method and system for remote diagnosis of server startup failure
US20060224723A1 (en) Data updating system and method
US20120041707A1 (en) Cold boot test system and method for electronic devices
US20140068350A1 (en) Self-checking system and method using same
JP2010086364A (en) Information processing device, operation state monitoring device and method
CN110457907B (en) Firmware program detection method and device
CN108874441B (en) Board card configuration method, device, server and storage medium
CN101441589A (en) Detection method of substrate management controller and server thereof
CN114816022B (en) Method, system and storage medium for monitoring server power supply abnormality
JP4886558B2 (en) Information processing device
CN113672306B (en) Server component self-checking abnormity recovery method, device, system and medium
TW201500919A (en) System and method of remote debugging BMC
US10691569B2 (en) System and method for testing a data storage device
CN113821387B (en) KVM function keep-alive test method, device, equipment and medium
CN111124774B (en) Method and related device for testing stability of server in starting process
KR101494000B1 (en) Method and system for power-on self testing after system off, and booting method the same
CN115098291A (en) Method, system, storage medium and equipment for recording system restart reason
JP6217086B2 (en) Information processing apparatus, error detection function diagnosis method, and computer program
CN114328138B (en) Data display method and device of server, server and storage medium
JP5053002B2 (en) Hardware monitoring unit
CN116820946B (en) Method and device for automatically testing compatibility of target software

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
GR01 Patent grant
GR01 Patent grant