CN116192626A - Device access method and device, computer readable storage medium and electronic device - Google Patents

Device access method and device, computer readable storage medium and electronic device Download PDF

Info

Publication number
CN116192626A
CN116192626A CN202310102089.1A CN202310102089A CN116192626A CN 116192626 A CN116192626 A CN 116192626A CN 202310102089 A CN202310102089 A CN 202310102089A CN 116192626 A CN116192626 A CN 116192626A
Authority
CN
China
Prior art keywords
target
bmc
internet protocol
management controller
baseboard management
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.)
Granted
Application number
CN202310102089.1A
Other languages
Chinese (zh)
Other versions
CN116192626B (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 CN202310102089.1A priority Critical patent/CN116192626B/en
Publication of CN116192626A publication Critical patent/CN116192626A/en
Application granted granted Critical
Publication of CN116192626B publication Critical patent/CN116192626B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • H04L41/0813Configuration setting characterised by the conditions triggering a change of settings
    • H04L41/0816Configuration setting characterised by the conditions triggering a change of settings the condition being an adaptation, e.g. in response to network events
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/09Mapping addresses
    • H04L61/25Mapping addresses of the same type
    • H04L61/2503Translation of Internet protocol [IP] addresses
    • 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)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer And Data Communications (AREA)

Abstract

The embodiment of the application provides a device access method and device, a computer readable storage medium and an electronic device, wherein the method comprises the following steps: receiving a configuration instruction sent by first equipment, wherein the first equipment is connected with target Baseboard Management Controller (BMC) equipment which is arranged in a target server; responding to a configuration instruction, and configuring an address mapping relation, wherein the address mapping relation comprises a mapping relation between an Internet protocol address of a target Baseboard Management Controller (BMC) device and an Internet protocol address of the target device, the target device is arranged in a target server, and the target device is connected with the target Baseboard Management Controller (BMC) device; and sending the address mapping relation to the first device to instruct the first device to access the target device according to the address mapping relation. By the method and the device, the problem of high access error probability and high maintenance cost of the equipment in the related technology is solved, and the effects of reducing workload and reducing error probability are achieved.

Description

Device access method and device, computer readable storage medium and electronic device
Technical Field
The embodiment of the application relates to the field of computers, in particular to a device access method and device, a computer readable storage medium and electronic equipment.
Background
The management of other intelligent devices by the baseboard management controller (Baseboard Management Controller, abbreviated as BMC) needs to acquire information by modifying codes and firstly associating with the device, and when other applications send information to the BMC, the BMC sends the information to other applications, and when other applications want to send information to the device, the BMC sends the information to the BMC first, and the BMC processes the information and then sends the information to the device. The BMC obtains the information of the device by modifying the code, which causes the problems of large workload, high error probability and high maintenance cost.
Disclosure of Invention
The embodiment of the application provides a device access method and device, a computer readable storage medium and electronic equipment, so as to at least solve the problems of high access error probability and high maintenance cost of the device in the related technology.
According to one embodiment of the present application, there is provided a device access method including: receiving a configuration instruction sent by a first device, wherein the first device is connected with a target Baseboard Management Controller (BMC) device, and the target baseboard management controller BMC device is arranged in a target server; responding to the configuration instruction, and configuring an address mapping relation, wherein the address mapping relation comprises a mapping relation between an internet protocol address of the target Baseboard Management Controller (BMC) device and an internet protocol address of target device, the target device is arranged in the target server, and the target device is connected with the target Baseboard Management Controller (BMC) device; and sending the address mapping relation to the first device so as to instruct the first device to access the target device according to the address mapping relation.
According to another embodiment of the present application, there is provided a device access method including: sending a configuration instruction to a target Baseboard Management Controller (BMC) device, wherein the target baseboard management controller BMC device is arranged in a target server and is connected with a first device; receiving an address mapping relation sent by the target Baseboard Management Controller (BMC) device, wherein the address mapping relation is configured by the target Baseboard Management Controller (BMC) device in response to the configuration instruction, the address mapping relation comprises a mapping relation between an internet protocol address of the target Baseboard Management Controller (BMC) device and an internet protocol address of the target device, the target device is arranged in the target server, and the target device is connected with the target Baseboard Management Controller (BMC) device; and accessing the target equipment according to the address mapping relation.
According to another embodiment of the present application, there is provided a device access apparatus including: the first receiving module is used for receiving a configuration instruction sent by first equipment, wherein the first equipment is connected with target Baseboard Management Controller (BMC) equipment which is arranged in a target server; the first response module is used for responding to the configuration instruction and configuring an address mapping relation, wherein the address mapping relation comprises a mapping relation between an internet protocol address of the target Baseboard Management Controller (BMC) device and an internet protocol address of target device, the target device is arranged in the target server, and the target device is connected with the target Baseboard Management Controller (BMC) device; the first sending module is used for sending the address mapping relation to the first device so as to instruct the first device to access the target device according to the address mapping relation.
In an exemplary embodiment, the first response module includes: a first obtaining unit, configured to obtain an internet protocol address of the target device; a first configuration unit, configured to configure the determined interface identification information in an internet protocol address of the target device, to obtain a target internet protocol address of the target device; and the first configuration unit is used for configuring the internet protocol address of the target equipment and the target internet protocol address in the same network segment to obtain the address mapping relation.
In an exemplary embodiment, the above apparatus further includes: and the third sending module is used for sending the internet protocol address of the target device to other BMC devices in other servers to instruct the other BMC devices to configure the address mapping relation when the target server is a child server of the other servers before responding to the configuration instruction to configure the address mapping relation.
In an exemplary embodiment, the above apparatus further includes: and the third receiving module is used for receiving the abnormality prompt information sent by the target interface under the condition that the abnormality occurs when the Internet protocol address of the target device is acquired before the address mapping relation is configured in response to the configuration instruction.
According to another embodiment of the present application, there is provided a device access apparatus including: the second sending module is used for sending a configuration instruction to target Baseboard Management Controller (BMC) equipment, wherein the target baseboard management controller BMC equipment is arranged in a target server and is connected with the first equipment; a second receiving module, configured to receive an address mapping relationship sent by the target baseboard management controller BMC device, where the address mapping relationship is configured by the target baseboard management controller BMC device in response to the configuration instruction, where the address mapping relationship includes a mapping relationship between an internet protocol address of the target baseboard management controller BMC device and an internet protocol address of a target device, where the target device is set in the target server, and where the target device is connected to the target baseboard management controller BMC device; and the first access module is used for accessing the target equipment according to the address mapping relation.
In an exemplary embodiment, the first access module includes: a first parsing unit, configured to parse an internet protocol address of the target baseboard management controller BMC device and a target internet protocol address of the target device from the address mapping relationship, where the target internet protocol address includes the internet protocol address of the target device and interface identification information; a first determining unit, configured to determine a connection relationship between the target baseboard management controller BMC device and the target device based on an internet protocol address of the target baseboard management controller BMC device; a second determining unit configured to determine the target device to be accessed based on the interface identification information; and the first access unit is used for accessing the target equipment according to the internet protocol address of the target equipment.
In an exemplary embodiment, the first access module includes: a second parsing unit, configured to determine that the target server is a sub-server of another server when the ip address of the target baseboard management controller BMC device, the target ip address of the target device, and the ip addresses of the other BMC devices are parsed from the address mapping relationship, where the target ip address includes the ip address of the target device and interface identification information; and the second access unit is used for accessing the target device through the internet protocol address of the other BMC device, the internet protocol address of the target baseboard management controller BMC device, the interface identification information and the internet protocol address of the target device.
In an exemplary embodiment, the above apparatus further includes: the first acquisition module is used for acquiring the operation information of the target equipment after the target equipment is accessed according to the address mapping relation; and the first monitoring module is used for monitoring the operation condition of the target equipment based on the operation information.
According to a further embodiment of the present application, there is also provided a computer readable storage medium having stored therein a computer program, wherein the computer program is arranged to perform the steps of any of the method embodiments described above when run.
According to a further embodiment of the present application, there is also provided an electronic device comprising a memory having stored therein a computer program and a processor arranged to run the computer program to perform the steps of any of the method embodiments described above.
According to the method and the device, as the configuration instruction sent by the first device is received, the first device is connected with the target Baseboard Management Controller (BMC) device, and the target baseboard management controller BMC device is arranged in the target server; responding to a configuration instruction, and configuring an address mapping relation, wherein the address mapping relation comprises a mapping relation between an Internet protocol address of a target Baseboard Management Controller (BMC) device and an Internet protocol address of the target device, the target device is arranged in a target server, and the target device is connected with the target Baseboard Management Controller (BMC) device; and sending the address mapping relation to the first device to instruct the first device to access the target device according to the address mapping relation. In the method, the target baseboard management controller BMC device configures the address mapping relation between the target baseboard management controller BMC device and the target device, the first device can acquire the internet protocol address of the first device by acquiring the address mapping relation from the target baseboard management controller BMC device, can directly access the target device, and does not need to acquire the information of the device by modifying codes through the target baseboard management controller BMC device, so that the workload is reduced, and the error probability is also reduced. Therefore, the problems of high access error probability and high maintenance cost of the equipment in the related technology can be solved, and the effects of reducing the workload and lowering the error probability are achieved.
Drawings
Fig. 1 is a hardware block diagram of a mobile terminal of a device access method according to an embodiment of the present application;
FIG. 2 is a flow chart diagram of a device access method according to an embodiment of the present application;
FIG. 3 is a block diagram of a structure between a BMC device and a server according to an embodiment of the present application;
FIG. 4 is a block diagram of the architecture between a BMC device and multiple servers according to an embodiment of the present application;
FIG. 5 is a second flowchart of a device access method according to an embodiment of the present application;
FIG. 6 is a block diagram of a device access apparatus according to an embodiment of the present application;
fig. 7 is a block diagram of a device access apparatus according to an embodiment of the present application.
Detailed Description
Embodiments of the present application will be described in detail below with reference to the accompanying drawings in conjunction with the embodiments.
It should be noted that the terms "first," "second," and the like in the description and claims of the present application and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order.
The method embodiments provided in the embodiments of the present application may be performed in a mobile terminal, a computer terminal or similar computing device. Taking the mobile terminal as an example, fig. 1 is a block diagram of a hardware structure of the mobile terminal of a device access method according to an embodiment of the present application. As shown in fig. 1, a mobile terminal may include one or more (only one is shown in fig. 1) processors 102 (the processor 102 may include, but is not limited to, a microprocessor MCU or a processing device such as a programmable logic device FPGA) and a memory 104 for storing data, wherein the mobile terminal may also include a transmission device 106 for communication functions and an input-output device 108. It will be appreciated by those skilled in the art that the structure shown in fig. 1 is merely illustrative and not limiting of the structure of the mobile terminal described above. For example, the mobile terminal may also include more or fewer components than shown in fig. 1, or have a different configuration than shown in fig. 1.
The memory 104 may be used to store a computer program, for example, a software program of application software and a module, such as a computer program corresponding to a device access method in the embodiment of the present application, and the processor 102 executes the computer program stored in the memory 104, thereby performing various functional applications and data processing, that is, implementing the method described above. Memory 104 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include memory remotely located relative to the processor 102, which may be connected to the mobile terminal via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The transmission device 106 is used to receive or transmit data via a network. Specific examples of the network described above may include a wireless network provided by a communication provider of the mobile terminal. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, simply referred to as NIC) that can connect to other network devices through a base station to communicate with the internet. In one example, the transmission device 106 may be a Radio Frequency (RF) module, which is configured to communicate with the internet wirelessly.
In this embodiment, a device access method is provided, fig. 2 is a flowchart of a device access method according to an embodiment of the present application, and as shown in fig. 2, the flowchart includes the following steps:
step S202, receiving a configuration instruction sent by a first device, wherein the first device is connected with a target Baseboard Management Controller (BMC) device, and the target baseboard management controller BMC device is arranged in a target server;
step S204, an address mapping relation is configured in response to the configuration instruction, wherein the address mapping relation comprises a mapping relation between an Internet protocol address of the target Baseboard Management Controller (BMC) device and an Internet protocol address of the target device, the target device is arranged in the target server, and the target device is connected with the target Baseboard Management Controller (BMC) device;
step S206, the address mapping relation is sent to the first device, so that the first device is instructed to access the target device according to the address mapping relation.
In this embodiment, the first device may be an external device, for example, an out-of-band management host (including a computer interacting with a server), and is connected to the server through a network cable. The target device may be a device in a server, such as a central processing unit, memory, sensor, network card, heat sink device, etc. When the target device is a central processing unit, the first device acquires temperature information of the central processing unit by accessing the central processing unit, and monitors the temperature, so that the running condition of the central processing unit is judged.
As shown in fig. 3, the out-of-band management host is connected to the BMC device through a network cable, and the BMC is connected to a device in the target server through a universal serial bus (Universal Serial Bus, abbreviated as USB). The address of the BMC device is eth:100.2.126.55 the address of the target device is usb0:192.168.31.1. The mapping relationship between the internet protocol address of the target baseboard management controller BMC device and the internet protocol address of the target device includes: eth:100.2.126.55 and usb0:192.168.31.100.BMC will eth:100.2.126.55 and usb0:192.168.31.100 to the first device.
In this embodiment, the BMC device merely serves as a bridge for transmitting information between the first device and the target device. The information is not acquired, stored, and forwarded. The mapping relation is only used for transmitting the mapping relation to the first device, so that the workload of the BMC device can be reduced.
The main execution body of the above steps may be a controller, a processor, a monitoring component, etc., for example, a BMC device in a server (mainly used for monitoring the operation condition of a device in the server), but is not limited thereto.
Through the steps, as the configuration instruction sent by the first device is received, the first device is connected with the target Baseboard Management Controller (BMC) device, and the target Baseboard Management Controller (BMC) device is arranged in the target server; responding to a configuration instruction, and configuring an address mapping relation, wherein the address mapping relation comprises a mapping relation between an Internet protocol address of a target Baseboard Management Controller (BMC) device and an Internet protocol address of the target device, the target device is arranged in a target server, and the target device is connected with the target Baseboard Management Controller (BMC) device; and sending the address mapping relation to the first device to instruct the first device to access the target device according to the address mapping relation. In the method, the target baseboard management controller BMC device configures the address mapping relation between the target baseboard management controller BMC device and the target device, the first device can acquire the internet protocol address of the first device by acquiring the address mapping relation from the target baseboard management controller BMC device, can directly access the target device, and does not need to acquire the information of the device by modifying codes through the target baseboard management controller BMC device, so that the workload is reduced, and the error probability is also reduced. Therefore, the problems of high access error probability and high maintenance cost of the equipment in the related technology can be solved, and the effects of reducing the workload and lowering the error probability are achieved.
In one exemplary embodiment, configuring the address mapping relationship in response to a configuration instruction includes: acquiring an internet protocol address of a target device; the determined interface identification information is configured in the Internet protocol address of the target equipment to obtain the target Internet protocol address of the target equipment; and configuring the Internet protocol address of the target equipment and the target Internet protocol address in the same network segment to obtain an address mapping relation. In this embodiment, the configuration instruction is sent by the first device to the BMC device, for example, when the first device needs to obtain the running information of the processor in the target server, the configuration instruction is sent to the BMC device, and after receiving the configuration instruction, the BMC device starts to configure the address mapping relationship between the configuration instruction and the target device. As shown in fig. 3, the out-band management host needs to access a target device in a server, and the BMC device adds interface identification information after the internet protocol address of the target device, which may be usb0:192.168.31.100, for example. The value of the interface identification information is not limited and may be a number of a preceding device. The interface identification information may also be port information, which is an interface through which data is transferred between a computer and other devices (e.g., a printer, mouse, keyboard, or monitor), between networks, or between other directly connected computers. By setting the interface identification information in the address mapping relation, the first device can skip the BMC device to directly access the target device, so that the workload of the BMC device is reduced, and the access speed of the device is increased.
In one exemplary embodiment, in response to the configuration instruction, prior to configuring the address mapping relationship, the method further comprises: in the case that the target server is a child of the other server, the internet protocol address of the target device is sent to the other BMC devices in the other servers to instruct the other BMC devices to configure the address mapping relationship. In the present embodiment, as shown in fig. 4, a plurality of servers are included, the server 1 is a parent node of the server 2-server n, and if the target server is a server in the server 2-server n, it is necessary to access the target server through the server 1. I.e. the address mapping relation, the internet protocol address of the BMC device in the server 1 needs to be added. For example, in the case where the target server is the server 2, when the address mapping relationship is configured, the BMC in the server 2 needs to send the internet protocol address to the BMC device in the server 1 to configure, and the manner in which the BMC device in the server 1 configures the address mapping relationship is the same as in the above embodiment. After the BMC device in the server 1 completes the address mapping relationship, the address mapping relationship needs to be sent to the out-of-band management host. The out-of-band management host takes the BMC equipment in the server 1 and the BMC equipment in the server 2 as bridges through the address mapping relation, and directly accesses the equipment in the server 2. Through the embodiment, the aim of directly accessing the devices in the server can be achieved by configuring the address mapping relation of the BMC devices in the servers, so that the code modification and maintenance workload of the BMC is reduced to the greatest extent, and the complexity of BMC management is reduced.
In one exemplary embodiment, in response to the configuration instruction, prior to configuring the address mapping relationship, the method further comprises: and under the condition that the abnormality occurs when the Internet protocol address of the target equipment is acquired, receiving the abnormality prompt information sent by the target interface. In this embodiment, before configuring the address mapping relationship, the BMC device needs to determine what type of device the target device is, for example, in the case that the target device is a type a device, the BMC device obtains the IP address of the target device, and configures the internet protocol address of the target device and the internet protocol address of the BMC device in a network segment. In the absence of the target device, the USB interface returns a message that the device is absent. By judging the target equipment, the accuracy of determining the address mapping relation can be increased.
In this embodiment, a device access method is provided, and fig. 5 is a second flowchart of the device access method according to an embodiment of the present application, as shown in fig. 5, where the flowchart includes the following steps:
step S502, a configuration instruction is sent to a target Baseboard Management Controller (BMC) device, wherein the target baseboard management controller BMC device is arranged in a target server and is connected with a first device;
Step S504, receiving an address mapping relation sent by a target Baseboard Management Controller (BMC) device, wherein the address mapping relation is configured by the target Baseboard Management Controller (BMC) device in response to a configuration instruction, the address mapping relation comprises a mapping relation between an Internet protocol address of the target Baseboard Management Controller (BMC) device and an Internet protocol address of the target device, the target device is arranged in a target server, and the target device is connected with the target Baseboard Management Controller (BMC) device;
step S506, accessing the target equipment according to the address mapping relation.
In this embodiment, the first device may be an external device, for example, an out-of-band management host (including a computer interacting with a server), and is connected to the server through a network cable. The target device may be a device in a server, such as a central processing unit, memory, sensor, network card, heat sink device, etc. When the target device is a central processing unit, the first device acquires temperature information of the central processing unit by accessing the central processing unit, and monitors the temperature, so that the running condition of the central processing unit is judged.
As shown in fig. 3, the out-of-band management host is connected to the BMC device through a network cable, and the BMC is connected to a device in the target server through a universal serial bus (Universal Serial Bus, abbreviated as USB). The address of the BMC device is eth:100.2.126.55 the address of the target device is usb0:192.168.31.1. The mapping relationship between the internet protocol address of the target baseboard management controller BMC device and the internet protocol address of the target device includes: eth:100.2.126.55 and usb0:192.168.31.100.BMC will eth:100.2.126.55 and usb0:192.168.31.100 to the first device.
In this embodiment, the BMC device merely serves as a bridge for transmitting information between the first device and the target device. The information is not acquired, stored, and forwarded. The mapping relation is only used for transmitting the mapping relation to the first device, so that the workload of the BMC device can be reduced.
The main execution body of the above steps may be a controller, a processor, a monitoring component, etc., for example, a BMC device in a server (mainly used for monitoring the operation condition of a device in the server), but is not limited thereto.
Through the steps, as a configuration instruction is sent to the target Baseboard Management Controller (BMC) equipment, wherein the target Baseboard Management Controller (BMC) equipment is arranged in the target server, and the target Baseboard Management Controller (BMC) equipment is connected with the first equipment; receiving an address mapping relation sent by target Baseboard Management Controller (BMC) equipment, wherein the address mapping relation is configured by the target Baseboard Management Controller (BMC) equipment in response to a configuration instruction, the address mapping relation comprises a mapping relation between an Internet protocol address of the target Baseboard Management Controller (BMC) equipment and an Internet protocol address of the target equipment, the target equipment is arranged in a target server, and the target equipment is connected with the target Baseboard Management Controller (BMC) equipment; and accessing the target equipment according to the address mapping relation. In the method, the target baseboard management controller BMC device configures the address mapping relation between the target baseboard management controller BMC device and the target device, the first device can acquire the internet protocol address of the first device by acquiring the address mapping relation from the target baseboard management controller BMC device, can directly access the target device, and does not need to acquire the information of the device by modifying codes through the target baseboard management controller BMC device, so that the workload is reduced, and the error probability is also reduced. Therefore, the problems of high access error probability and high maintenance cost of the equipment in the related technology can be solved, and the effects of reducing the workload and lowering the error probability are achieved.
In one exemplary embodiment, accessing a target device according to an address mapping relationship includes: resolving an internet protocol address of a target Baseboard Management Controller (BMC) device and a target internet protocol address of the target device from the address mapping relation, wherein the target internet protocol address comprises the internet protocol address of the target device and interface identification information; determining a connection relationship between the target baseboard management controller BMC device and the target device based on an Internet protocol address of the target baseboard management controller BMC device; determining a target device to be accessed based on the interface identification information; the target device is accessed according to the internet protocol address of the target device. The interface identification information in this embodiment may also be port information, which is an interface through which data is transferred between a computer and other devices (e.g., a printer, mouse, keyboard, or monitor), between networks, or between other directly connected computers. By setting the interface identification information in the address mapping relation, the first device can skip the BMC device to directly access the target device, so that the workload of the BMC device is reduced, and the access speed of the device is increased.
In one exemplary embodiment, accessing a target device according to an address mapping relationship includes: under the condition that the Internet protocol address of the target baseboard management controller BMC device, the target Internet protocol address of the target device and the Internet protocol addresses of other BMC devices are analyzed from the address mapping relation, determining that the target server is a sub-server of other servers, wherein the target Internet protocol address comprises the Internet protocol address of the target device and interface identification information; and accessing the target device through the internet protocol address of the other BMC device, the internet protocol address of the target baseboard management controller BMC device, the interface identification information and the internet protocol address of the target device. In the present embodiment, as shown in fig. 4, a plurality of servers are included, the server 1 is a parent node of the server 2-server n, and if the target server is a server in the server 2-server n, it is necessary to access the target server through the server 1. I.e. the address mapping relation, the internet protocol address of the BMC device in the server 1 needs to be added. For example, in the case where the target server is the server 2, when the address mapping relationship is configured, the BMC in the server 2 needs to send the internet protocol address to the BMC device in the server 1 to configure, and the manner in which the BMC device in the server 1 configures the address mapping relationship is the same as in the above embodiment. After the BMC device in the server 1 completes the address mapping relationship, the address mapping relationship needs to be sent to the out-of-band management host. The out-of-band management host takes the BMC equipment in the server 1 and the BMC equipment in the server 2 as bridges through the address mapping relation, and directly accesses the equipment in the server 2. According to the embodiment, the aim of directly accessing the devices in the servers can be achieved by configuring the address mapping relation of the BMC devices in the plurality of servers, so that the workload of the BMC devices in each server is reduced.
In one exemplary embodiment, after accessing the target device according to the address mapping relationship, the method further comprises: acquiring operation information of target equipment; the operating condition of the target device is monitored based on the operating information. In this embodiment, before configuring the address mapping relationship, the BMC device needs to determine what type of device the target device is, for example, in the case that the target device is a type a device, the BMC device obtains the IP address of the target device, and configures the internet protocol address of the target device and the internet protocol address of the BMC device in a network segment. In the absence of the target device, the USB interface returns a message that the device is absent. By judging the target equipment, the accuracy of determining the address mapping relation can be increased.
From the description of the above embodiments, it will be clear to a person skilled in the art that the method according to the above embodiments may be implemented by means of software plus the necessary general hardware platform, but of course also by means of hardware, but in many cases the former is a preferred embodiment. Based on such understanding, the technical solution of the present application may be embodied essentially or in a part contributing to the prior art in the form of a software product stored in a storage medium (such as ROM/RAM, magnetic disk, optical disk), comprising several instructions for causing a terminal device (which may be a mobile phone, a computer, a server, or a network device, etc.) to perform the method described in the embodiments of the present application.
The embodiment also provides a device access apparatus, which is used to implement the foregoing embodiments and preferred embodiments, and is not described in detail. As used below, the term "module" may be a combination of software and/or hardware that implements a predetermined function. While the means described in the following embodiments are preferably implemented in software, implementation in hardware, or a combination of software and hardware, is also possible and contemplated.
Fig. 6 is a block diagram of a device access apparatus according to an embodiment of the present application, as shown in fig. 6, including:
the first receiving module 62 is configured to receive a configuration instruction sent by a first device, where the first device is connected to a target baseboard management controller BMC device, and the target baseboard management controller BMC device is set in a target server;
a first response module 64, configured to respond to the configuration instruction, and configure an address mapping relationship, where the address mapping relationship includes a mapping relationship between an internet protocol address of the target baseboard management controller BMC device and an internet protocol address of a target device, where the target device is set in the target server, and the target device is connected to the target baseboard management controller BMC device;
A first sending module 66, configured to send the address mapping relationship to the first device, so as to instruct the first device to access the target device according to the address mapping relationship.
In an exemplary embodiment, the first response module includes:
a first obtaining unit, configured to obtain an internet protocol address of the target device;
a first configuration unit, configured to configure the determined interface identification information in an internet protocol address of the target device, to obtain a target internet protocol address of the target device;
and the first configuration unit is used for configuring the internet protocol address of the target equipment and the target internet protocol address in the same network segment to obtain the address mapping relation.
In an exemplary embodiment, the above apparatus further includes: and the third sending module is used for sending the internet protocol address of the target device to other BMC devices in other servers to instruct the other BMC devices to configure the address mapping relation when the target server is a child server of the other servers before responding to the configuration instruction to configure the address mapping relation.
In an exemplary embodiment, the above apparatus further includes: and the third receiving module is used for receiving the abnormality prompt information sent by the target interface under the condition that the abnormality occurs when the Internet protocol address of the target device is acquired before the address mapping relation is configured in response to the configuration instruction.
Fig. 7 is a block diagram of a second configuration of a device access apparatus according to an embodiment of the present application, as shown in fig. 7, the apparatus includes:
a second sending module 72, configured to send a configuration instruction to a target baseboard management controller BMC device, where the target baseboard management controller BMC device is set in a target server, and the target baseboard management controller BMC device is connected to the first device;
a second receiving module 74, configured to receive an address mapping relationship sent by the target baseboard management controller BMC device, where the address mapping relationship is configured by the target baseboard management controller BMC device in response to the configuration instruction, and the address mapping relationship includes a mapping relationship between an internet protocol address of the target baseboard management controller BMC device and an internet protocol address of a target device, where the target device is set in the target server, and the target device is connected to the target baseboard management controller BMC device;
A first accessing module 76, configured to access the target device according to the address mapping relationship.
In an exemplary embodiment, the first access module includes:
a first parsing unit, configured to parse an internet protocol address of the target baseboard management controller BMC device and a target internet protocol address of the target device from the address mapping relationship, where the target internet protocol address includes the internet protocol address of the target device and interface identification information;
a first determining unit, configured to determine a connection relationship between the target baseboard management controller BMC device and the target device based on an internet protocol address of the target baseboard management controller BMC device;
a second determining unit configured to determine the target device to be accessed based on the interface identification information;
and the first access unit is used for accessing the target equipment according to the internet protocol address of the target equipment.
In an exemplary embodiment, the first access module includes:
a second parsing unit, configured to determine that the target server is a sub-server of another server when the ip address of the target baseboard management controller BMC device, the target ip address of the target device, and the ip addresses of the other BMC devices are parsed from the address mapping relationship, where the target ip address includes the ip address of the target device and interface identification information;
And the second access unit is used for accessing the target device through the internet protocol address of the other BMC device, the internet protocol address of the target baseboard management controller BMC device, the interface identification information and the internet protocol address of the target device.
In an exemplary embodiment, the above apparatus further includes: the first acquisition module is used for acquiring the operation information of the target equipment after the target equipment is accessed according to the address mapping relation;
and the first monitoring module is used for monitoring the operation condition of the target equipment based on the operation information.
It should be noted that each of the above modules may be implemented by software or hardware, and for the latter, it may be implemented by, but not limited to: the modules are all located in the same processor; alternatively, the above modules may be located in different processors in any combination.
Embodiments of the present application also provide a computer readable storage medium having a computer program stored therein, wherein the computer program is arranged to perform the steps of any of the method embodiments described above when run.
In one exemplary embodiment, the computer readable storage medium may include, but is not limited to: a usb disk, a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a removable hard disk, a magnetic disk, or an optical disk, or other various media capable of storing a computer program.
Embodiments of the present application also provide an electronic device comprising a memory having stored therein a computer program and a processor arranged to run the computer program to perform the steps of any of the method embodiments described above.
In an exemplary embodiment, the electronic device may further include a transmission device connected to the processor, and an input/output device connected to the processor.
Specific examples in this embodiment may refer to the examples described in the foregoing embodiments and the exemplary implementation, and this embodiment is not described herein.
It will be appreciated by those skilled in the art that the modules or steps of the application described above may be implemented in a general purpose computing device, they may be concentrated on a single computing device, or distributed across a network of computing devices, they may be implemented in program code executable by computing devices, so that they may be stored in a storage device for execution by computing devices, and in some cases, the steps shown or described may be performed in a different order than that shown or described herein, or they may be separately fabricated into individual integrated circuit modules, or multiple modules or steps of them may be fabricated into a single integrated circuit module. Thus, the present application is not limited to any specific combination of hardware and software.
The foregoing description is only of the preferred embodiments of the present application and is not intended to limit the same, but rather, various modifications and variations may be made by those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the principles of the present application should be included in the protection scope of the present application.

Claims (12)

1. A method of device access, comprising:
receiving a configuration instruction sent by a first device, wherein the first device is connected with a target Baseboard Management Controller (BMC) device, and the target baseboard management controller BMC device is arranged in a target server;
responding to the configuration instruction, and configuring an address mapping relation, wherein the address mapping relation comprises a mapping relation between an Internet protocol address of the target Baseboard Management Controller (BMC) device and an Internet protocol address of the target device, the target device is arranged in the target server, and the target device is connected with the target Baseboard Management Controller (BMC) device;
and sending the address mapping relation to the first equipment so as to instruct the first equipment to access the target equipment according to the address mapping relation.
2. The method of claim 1, wherein configuring an address mapping in response to the configuration instruction comprises:
acquiring an internet protocol address of the target device;
configuring the determined interface identification information in the Internet protocol address of the target equipment to obtain the target Internet protocol address of the target equipment;
and configuring the Internet protocol address of the target equipment and the target Internet protocol address in the same network segment to obtain the address mapping relation.
3. The method of claim 1, wherein prior to configuring an address mapping in response to the configuration instruction, the method further comprises:
and if the target server is a sub-server of other servers, sending the Internet protocol address of the target device to other BMC devices in the other servers to instruct the other BMC devices to configure the address mapping relation.
4. The method of claim 1, wherein prior to configuring an address mapping in response to the configuration instruction, the method further comprises:
and under the condition that the abnormality occurs when the Internet protocol address of the target equipment is acquired, receiving the abnormality prompt information sent by the target interface.
5. A method of device access, comprising:
sending a configuration instruction to a target Baseboard Management Controller (BMC) device, wherein the target baseboard management controller BMC device is arranged in a target server and is connected with a first device;
receiving an address mapping relation sent by the target Baseboard Management Controller (BMC) device, wherein the address mapping relation is configured by the target Baseboard Management Controller (BMC) device in response to the configuration instruction, the address mapping relation comprises a mapping relation between an Internet protocol address of the target Baseboard Management Controller (BMC) device and an Internet protocol address of the target device, the target device is arranged in the target server, and the target device is connected with the target Baseboard Management Controller (BMC) device;
and accessing the target equipment according to the address mapping relation.
6. The method of claim 5, wherein accessing the target device according to the address mapping relationship comprises:
resolving an internet protocol address of the target Baseboard Management Controller (BMC) device and a target internet protocol address of the target device from the address mapping relation, wherein the target internet protocol address comprises the internet protocol address of the target device and interface identification information;
Determining a connection relationship between the target baseboard management controller BMC device and the target device based on an internet protocol address of the target baseboard management controller BMC device;
determining the target equipment to be accessed based on the interface identification information;
and accessing the target equipment according to the Internet protocol address of the target equipment.
7. The method of claim 5, wherein accessing the target device according to the address mapping relationship comprises:
under the condition that the Internet protocol address of the target Baseboard Management Controller (BMC) equipment, the target Internet protocol address of the target equipment and the Internet protocol addresses of other BMC equipment are resolved from the address mapping relation, determining that the target server is a sub-server of other servers, wherein the target Internet protocol address comprises the Internet protocol address of the target equipment and interface identification information;
and accessing the target device through the internet protocol address of the other BMC device, the internet protocol address of the target baseboard management controller BMC device, the interface identification information and the internet protocol address of the target device.
8. The method of claim 5, wherein after accessing the target device according to the address mapping relationship, the method further comprises:
acquiring the operation information of the target equipment;
and monitoring the operation condition of the target equipment based on the operation information.
9. A device access apparatus, comprising:
the first receiving module is used for receiving a configuration instruction sent by first equipment, wherein the first equipment is connected with target Baseboard Management Controller (BMC) equipment which is arranged in a target server;
the first response module is used for responding to the configuration instruction and configuring an address mapping relation, wherein the address mapping relation comprises a mapping relation between an Internet protocol address of the target Baseboard Management Controller (BMC) device and an Internet protocol address of target equipment, the target equipment is arranged in the target server, and the target equipment is connected with the target Baseboard Management Controller (BMC) device;
and the first sending module is used for sending the address mapping relation to the first equipment so as to instruct the first equipment to access the target equipment according to the address mapping relation.
10. A device access apparatus, comprising:
the second sending module is used for sending a configuration instruction to target Baseboard Management Controller (BMC) equipment, wherein the target baseboard management controller BMC equipment is arranged in a target server and is connected with the first equipment;
the second receiving module is configured to receive an address mapping relation sent by the target Baseboard Management Controller (BMC) device, where the address mapping relation is configured by the target Baseboard Management Controller (BMC) device in response to the configuration instruction, the address mapping relation includes a mapping relation between an internet protocol address of the target Baseboard Management Controller (BMC) device and an internet protocol address of the target device, the target device is set in the target server, and the target device is connected with the target Baseboard Management Controller (BMC) device;
and the first access module is used for accessing the target equipment according to the address mapping relation.
11. A computer readable storage medium, characterized in that the computer readable storage medium has stored therein a computer program, wherein the computer program, when being executed by a processor, realizes the steps of the method as claimed in any one of claims 1 to 4 or the steps of the method as claimed in any one of claims 5 to 8.
12. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor, when executing the computer program, implements the steps of the method as claimed in any one of claims 1 to 4 or the steps of the method as claimed in any one of claims 5 to 8.
CN202310102089.1A 2023-02-10 2023-02-10 Device access method and device, computer readable storage medium and electronic device Active CN116192626B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310102089.1A CN116192626B (en) 2023-02-10 2023-02-10 Device access method and device, computer readable storage medium and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310102089.1A CN116192626B (en) 2023-02-10 2023-02-10 Device access method and device, computer readable storage medium and electronic device

Publications (2)

Publication Number Publication Date
CN116192626A true CN116192626A (en) 2023-05-30
CN116192626B CN116192626B (en) 2024-06-14

Family

ID=86443897

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310102089.1A Active CN116192626B (en) 2023-02-10 2023-02-10 Device access method and device, computer readable storage medium and electronic device

Country Status (1)

Country Link
CN (1) CN116192626B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116860339A (en) * 2023-07-06 2023-10-10 合芯科技(苏州)有限公司 Method, device and equipment for starting server based on MAC address information

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140173062A1 (en) * 2012-12-13 2014-06-19 Level 3 Communications, Llc Devices And Methods Supporting Content Delivery With Delivery Services Having Dynamically Configurable Log Information
US20140351537A1 (en) * 2013-05-23 2014-11-27 International Business Machines Corporation Mapping a source workload pattern for a source storage system to a target workload pattern for a target storage system
CN110224996A (en) * 2019-05-20 2019-09-10 深圳壹账通智能科技有限公司 Network Access Method, device, computer equipment and the storage medium of application program
CN112838952A (en) * 2021-01-04 2021-05-25 联想(北京)有限公司 Data transmission method of baseboard management controller, BMC, server and medium
CN113347020A (en) * 2021-04-29 2021-09-03 上海淇玥信息技术有限公司 Domain name service disaster recovery method, system, device and medium
CN113708957A (en) * 2021-08-03 2021-11-26 中移(杭州)信息技术有限公司 Configuration method, terminal device and medium for server BMC
CN115442231A (en) * 2022-08-31 2022-12-06 苏州浪潮智能科技有限公司 Method, device, equipment and medium for managing white list information of switch

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140173062A1 (en) * 2012-12-13 2014-06-19 Level 3 Communications, Llc Devices And Methods Supporting Content Delivery With Delivery Services Having Dynamically Configurable Log Information
US20140351537A1 (en) * 2013-05-23 2014-11-27 International Business Machines Corporation Mapping a source workload pattern for a source storage system to a target workload pattern for a target storage system
CN110224996A (en) * 2019-05-20 2019-09-10 深圳壹账通智能科技有限公司 Network Access Method, device, computer equipment and the storage medium of application program
CN112838952A (en) * 2021-01-04 2021-05-25 联想(北京)有限公司 Data transmission method of baseboard management controller, BMC, server and medium
CN113347020A (en) * 2021-04-29 2021-09-03 上海淇玥信息技术有限公司 Domain name service disaster recovery method, system, device and medium
CN113708957A (en) * 2021-08-03 2021-11-26 中移(杭州)信息技术有限公司 Configuration method, terminal device and medium for server BMC
CN115442231A (en) * 2022-08-31 2022-12-06 苏州浪潮智能科技有限公司 Method, device, equipment and medium for managing white list information of switch

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116860339A (en) * 2023-07-06 2023-10-10 合芯科技(苏州)有限公司 Method, device and equipment for starting server based on MAC address information
CN116860339B (en) * 2023-07-06 2024-02-27 合芯科技(苏州)有限公司 Method, device and equipment for starting server based on MAC address information

Also Published As

Publication number Publication date
CN116192626B (en) 2024-06-14

Similar Documents

Publication Publication Date Title
CN108566290B (en) Service configuration management method, system, storage medium and server
US10333771B2 (en) Diagnostic monitoring techniques for server systems
JP2021521528A (en) Task processing method, equipment and system
CN107809383B (en) MVC-based path mapping method and device
US20100205600A1 (en) Simulation method for realizing large batches and different kinds of baseboard management controllers using a single server
US20050066218A1 (en) Method and apparatus for alert failover
CN116192626B (en) Device access method and device, computer readable storage medium and electronic device
CN116719700B (en) Method and device for monitoring hardware partition of server host system
CN113890879B (en) Load balancing method and device for data access, computer equipment and medium
CN111246406A (en) Short message sending method, system, storage medium and terminal equipment
CN110245759A (en) A kind of method for inspecting, system, server and equipment
CN107332813A (en) A kind of ACL collocation methods, ACL configuration equipment and server
CN116886490A (en) Server inspection method and device and computer readable storage medium
CN112511621A (en) Data transmission method and device, storage medium, and electronic device
CN116578316A (en) Firmware updating method, device, server and storage medium of equipment
CN109981725B (en) Communication method across security domains, server and readable storage medium
CN116070210A (en) Method and device for determining abnormal progress and virus checking and killing method
CN111371601A (en) Server configuration method, device, equipment and computer readable storage medium
CN113032054A (en) Service execution method, device, storage medium and electronic device
CN116886445B (en) Processing method and device of filtering result, storage medium and electronic equipment
CN112769889B (en) Service data pushing method and device, storage medium and electronic device
CN117493065B (en) Method and device for processing processor information, storage medium and electronic equipment
CN116455809A (en) Method, device, equipment and storage medium for processing data after link abnormality
CN112165465A (en) Data processing method and device for outgoing third-party platform and electronic device
CN115633018A (en) Device registration method, device, storage medium and electronic device

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