[go: up one dir, main page]

CN107566518A - The method and apparatus of management equipment information during installation file - Google Patents

The method and apparatus of management equipment information during installation file Download PDF

Info

Publication number
CN107566518A
CN107566518A CN201710888779.9A CN201710888779A CN107566518A CN 107566518 A CN107566518 A CN 107566518A CN 201710888779 A CN201710888779 A CN 201710888779A CN 107566518 A CN107566518 A CN 107566518A
Authority
CN
China
Prior art keywords
server
address
physical location
location information
information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201710888779.9A
Other languages
Chinese (zh)
Other versions
CN107566518B (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.)
Zhengzhou Yunhai Information Technology Co Ltd
Original Assignee
Zhengzhou Yunhai Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhengzhou Yunhai Information Technology Co Ltd filed Critical Zhengzhou Yunhai Information Technology Co Ltd
Priority to CN201710888779.9A priority Critical patent/CN107566518B/en
Publication of CN107566518A publication Critical patent/CN107566518A/en
Application granted granted Critical
Publication of CN107566518B publication Critical patent/CN107566518B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Small-Scale Networks (AREA)
  • Computer And Data Communications (AREA)
  • Stored Programmes (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The invention discloses a kind of method and apparatus of the management equipment information during installation file.Methods described includes:After the request for cluster interior joint installation operation system is received, the physical location information of the server of each node and the MAC Address of network interface card are obtained;During Pre-boot Execution Environment PXE automatic installing operating system files, the IP address information that the server-assignment of each node arrives is recorded, and establish the corresponding relation of the MAC Address of the IP address of server and the network interface card of server;According to the physical location information of server and the corresponding relation of the MAC Address of network interface card, with reference to server IP address and server network interface card MAC Address corresponding relation, obtain the physical location information of server and the corresponding relation of the IP address of server;Preserve the physical location information of the server and the corresponding relation of IP address.

Description

在安装文件过程中管理设备信息的方法和装置Method and device for managing device information during file installation

技术领域technical field

本发明涉及信息处理领域,尤指一种在安装文件过程中管理设备信息的方法和装置。The invention relates to the field of information processing, in particular to a method and device for managing equipment information during file installation.

背景技术Background technique

PXE(Preboot eXecute Environment,预启动执行环境)工作于客户端/服务器Client/Server的网络模式,支持工作站通过网络从远端服务器下载映像,并由此支持通过网络启动操作系统,在启动过程中,终端要求服务器分配IP地址,再下载一个启动软件包到本机内存中执行,由这个启动软件包完成客户端基本软件设置,从而引导预先安装在服务器中的终端操作系统。PXE (Preboot eXecute Environment, pre-boot execution environment) works in the network mode of client/server Client/Server, supports the workstation to download the image from the remote server through the network, and thus supports the startup of the operating system through the network. During the startup process, The terminal requires the server to assign an IP address, and then downloads a startup software package to the local memory for execution. The startup software package completes the basic software settings of the client, thereby guiding the terminal operating system pre-installed in the server.

目前主流安装多节点或者集群操作系统的方法是,PXE启动配合kickstart进行无人值守安装,这种方法简单易行、可靠稳定。其中Kickstart是一种无人值守的安装方式。它的工作原理是在安装过程中记录典型的需要人工干预填写的各种参数,并生成一个名为ks.cfg的文件。如果在安装过程中,出现要填写参数的情况,安装程序首先会去查找Kickstart生成的文件,如果找到合适的参数,就采用所找到的参数;如果没有找到合适的参数,便需要安装者手工干预了。At present, the mainstream method of installing multi-node or cluster operating systems is to start PXE and kickstart for unattended installation. This method is simple, reliable and stable. Among them, Kickstart is an unattended installation method. It works by recording various parameters that typically require human intervention to fill in during the installation process, and generates a file called ks.cfg. If there is a need to fill in the parameters during the installation process, the installer will first search for the file generated by Kickstart, and if the appropriate parameters are found, the found parameters will be used; if no suitable parameters are found, the installer will need to manually intervene up.

上述方式不足之处在于,从使用者的角度不能通过物理位置来区分主机的IP等信息,为后续管理带来了不便。The disadvantage of the above method is that from the user's point of view, the IP and other information of the host cannot be distinguished through the physical location, which brings inconvenience to subsequent management.

发明内容Contents of the invention

为了解决上述技术问题,本发明提供了一种在安装文件过程中管理设备信息的方法和装置,能够通过物理位置来区分主机的IP,为后续管理带来便利。In order to solve the above technical problems, the present invention provides a method and device for managing device information in the process of installing files, which can distinguish the IP of the host through the physical location, and bring convenience for subsequent management.

为了达到本发明目的,本发明提供了一种在安装文件过程中管理设备信息的方法,包括:In order to achieve the purpose of the present invention, the present invention provides a method for managing device information during file installation, including:

在接收到为集群中节点安装操作系统的请求后,获取各节点的服务器的物理位置信息和网卡的MAC地址;After receiving the request to install the operating system for the nodes in the cluster, obtain the physical location information of the server of each node and the MAC address of the network card;

在预启动执行环境PXE自动安装操作系统文件的过程中,记录各节点的服务器分配到的IP地址信息,并建立服务器的IP地址和服务器的网卡的MAC地址的对应关系;In the process of automatically installing operating system files in the pre-start execution environment PXE, record the IP address information assigned to the server of each node, and establish the corresponding relationship between the IP address of the server and the MAC address of the network card of the server;

根据服务器的物理位置信息和网卡的MAC地址的对应关系,结合服务器的IP地址和服务器的网卡的MAC地址的对应关系,得到服务器的物理位置信息与服务器的IP地址的对应关系;According to the corresponding relationship between the physical location information of the server and the MAC address of the network card, in combination with the corresponding relationship between the IP address of the server and the MAC address of the network card of the server, the corresponding relationship between the physical location information of the server and the IP address of the server is obtained;

保存所述服务器的物理位置信息和IP地址的对应关系。The corresponding relationship between the physical location information of the server and the IP address is stored.

其中,所述方法还具有如下特点:在得到服务器的物理位置信息与服务器的IP地址的对应关系之前,所述方法还包括:Wherein, the method also has the following characteristics: before obtaining the correspondence between the physical location information of the server and the IP address of the server, the method also includes:

判断操作系统的安装操作是否成功;Determine whether the installation operation of the operating system is successful;

在操作系统安装成功后,再执行获取服务器的物理位置信息与服务器的IP地址的对应关系的操作。After the operating system is successfully installed, the operation of obtaining the correspondence between the physical location information of the server and the IP address of the server is performed.

其中,所述方法还具有如下特点:所述保存所述服务器的物理位置信息和IP地址的对应关系之后,所述方法还包括:Wherein, the method also has the following characteristics: after storing the correspondence between the physical location information of the server and the IP address, the method further includes:

根据所述服务器的物理位置信息和IP地址的对应关系,在服务器部署示意图中标记各个服务器的IP地址信息。According to the corresponding relationship between the physical location information of the server and the IP address, mark the IP address information of each server in the server deployment schematic diagram.

其中,所述方法还具有如下特点:所述保存所述服务器的物理位置信息和IP地址的对应关系之后,所述方法还包括:Wherein, the method also has the following characteristics: after storing the correspondence between the physical location information of the server and the IP address, the method further includes:

接收用户对物理位置信息的选择以及对该物理位置对应的服务器的管理请求;Receive the user's selection of the physical location information and the management request of the server corresponding to the physical location;

根据所述物理位置信息和IP地址的对应关系,确定用户管理的服务器的IP地址信息;According to the corresponding relationship between the physical location information and the IP address, determine the IP address information of the server managed by the user;

利用所述IP地址发送所述管理请求。The management request is sent using the IP address.

其中,所述方法还具有如下特点:所述保存所述服务器的物理位置信息和IP地址的对应关系之后,所述方法还包括:Wherein, the method also has the following characteristics: after storing the correspondence between the physical location information of the server and the IP address, the method further includes:

根据所述IP地址信息,获取所述IP地址的主机识别信息;Acquiring host identification information of the IP address according to the IP address information;

利用获取到的所述IP地址的主机识别信息,建立所述服务器的主机识别信息、物理位置信息和IP地址信息的对应关系。Using the acquired host identification information of the IP address, establish a correspondence relationship between the host identification information, physical location information, and IP address information of the server.

一种在安装文件过程中管理设备信息的装置,包括:A device for managing device information during file installation, comprising:

第一获取模块,用于在接收到为集群中节点安装操作系统的请求后,获取各节点的服务器的物理位置信息和网卡的MAC地址;The first obtaining module is used to obtain the physical location information of the server of each node and the MAC address of the network card after receiving the request for installing the operating system for the nodes in the cluster;

记录模块,用于在预启动执行环境PXE自动安装操作系统文件的过程中,记录各节点的服务器分配到的IP地址信息,并建立服务器的IP地址和服务器的网卡的MAC地址的对应关系;The recording module is used to record the IP address information assigned to the server of each node in the process of automatically installing the operating system file in the pre-start execution environment PXE, and establish the corresponding relationship between the IP address of the server and the MAC address of the network card of the server;

第一确定模块,用于根据服务器的物理位置信息和网卡的MAC地址的对应关系,结合服务器的IP地址和服务器的网卡的MAC地址的对应关系,得到服务器的物理位置信息与服务器的IP地址的对应关系;The first determining module is used to obtain the physical location information of the server and the IP address of the server according to the corresponding relationship between the physical location information of the server and the MAC address of the network card, in combination with the corresponding relationship between the IP address of the server and the MAC address of the network card of the server Correspondence;

保存模块,用于保存所述服务器的物理位置信息和IP地址的对应关系。A saving module, configured to save the correspondence between the physical location information of the server and the IP address.

其中,所述装置还具有如下特点:所述装置还包括:Wherein, the device also has the following characteristics: the device also includes:

判断模块,用于在得到服务器的物理位置信息与服务器的IP地址的对应关系之前,判断操作系统的安装操作是否成功;A judging module, used to judge whether the installation operation of the operating system is successful before obtaining the correspondence between the physical location information of the server and the IP address of the server;

其中,所述确定模块在操作系统安装成功后,再执行获取服务器的物理位置信息与服务器的IP地址的对应关系的操作。Wherein, after the operating system is successfully installed, the determining module executes the operation of obtaining the correspondence between the physical location information of the server and the IP address of the server.

其中,所述装置还具有如下特点:所述装置还包括:Wherein, the device also has the following characteristics: the device also includes:

标记模块,用于在保存所述服务器的物理位置信息和IP地址的对应关系之后,根据所述服务器的物理位置信息和IP地址的对应关系,在服务器部署示意图中标记各个服务器的IP地址信息。The marking module is configured to mark the IP address information of each server in the server deployment diagram according to the corresponding relationship between the physical location information of the server and the IP address after storing the corresponding relationship between the physical location information of the server and the IP address.

其中,所述装置还具有如下特点:所述装置还包括:Wherein, the device also has the following characteristics: the device also includes:

接收模块,用于在保存所述服务器的物理位置信息和IP地址的对应关系之后,接收用户对物理位置信息的选择以及对该物理位置对应的服务器的管理请求;The receiving module is used to receive the user's selection of the physical location information and a management request of the server corresponding to the physical location after saving the correspondence between the physical location information of the server and the IP address;

第二确定模块,用于根据所述物理位置信息和IP地址的对应关系,确定用户管理的服务器的IP地址信息;The second determination module is used to determine the IP address information of the server managed by the user according to the correspondence between the physical location information and the IP address;

发送模块,用于利用所述IP地址发送所述管理请求。A sending module, configured to use the IP address to send the management request.

其中,所述装置还具有如下特点:所述装置还包括:Wherein, the device also has the following characteristics: the device also includes:

第二获取模块,用于在保存所述服务器的物理位置信息和IP地址的对应关系之后,根据所述IP地址信息,获取所述IP地址的主机识别信息;The second obtaining module is used to obtain the host identification information of the IP address according to the IP address information after saving the correspondence between the physical location information of the server and the IP address;

建立模块,用于利用获取到的所述IP地址的主机识别信息,建立所述服务器的主机识别信息、物理位置信息和IP地址信息的对应关系。The establishment module is configured to use the obtained host identification information of the IP address to establish a correspondence between the server's host identification information, physical location information, and IP address information.

本发明提供的实施例,通过获取服务器的物理位置信息和网卡的MAC地址,在自动安装操作系统过程中,获取服务器的IP地址和服务器的网卡的MAC地址的对应关系,再将两个对应关系进行合并,得到服务器的物理位置信息和网卡的IP地址的对应关系,实现集群操作系统部署过程中物理与节点的绑定关系,便于根据物理位置识别主机,提高管理效率,无需要额外繁重的操作才能绑定节点信息,减少后期的管理成本。In the embodiment provided by the present invention, by obtaining the physical location information of the server and the MAC address of the network card, in the process of automatically installing the operating system, the corresponding relationship between the IP address of the server and the MAC address of the network card of the server is obtained, and then the two corresponding relationships Merge to obtain the corresponding relationship between the physical location information of the server and the IP address of the network card, realize the binding relationship between the physical and the node during the deployment of the cluster operating system, facilitate the identification of the host according to the physical location, improve management efficiency, and do not require additional heavy operations In order to bind the node information, reduce the later management cost.

本发明的其它特征和优点将在随后的说明书中阐述,并且,部分地从说明书中变得显而易见,或者通过实施本发明而了解。本发明的目的和其他优点可通过在说明书、权利要求书以及附图中所特别指出的结构来实现和获得。Additional features and advantages of the invention will be set forth in the description which follows, and in part will be apparent from the description, or may be learned by practice of the invention. The objectives and other advantages of the invention may be realized and attained by the structure particularly pointed out in the written description and claims hereof as well as the appended drawings.

附图说明Description of drawings

附图用来提供对本发明技术方案的进一步理解,并且构成说明书的一部分,与本申请的实施例一起用于解释本发明的技术方案,并不构成对本发明技术方案的限制。The accompanying drawings are used to provide a further understanding of the technical solution of the present invention, and constitute a part of the description, and are used together with the embodiments of the application to explain the technical solution of the present invention, and do not constitute a limitation to the technical solution of the present invention.

图1为本发明提供的在安装文件过程中管理设备信息的方法的流程图;Fig. 1 is a flowchart of a method for managing device information in the process of installing files provided by the present invention;

图2为本发明提供的在安装文件过程中管理设备信息的装置的结构图。FIG. 2 is a structural diagram of an apparatus for managing device information during file installation provided by the present invention.

具体实施方式detailed description

为使本发明的目的、技术方案和优点更加清楚明白,下文中将结合附图对本发明的实施例进行详细说明。需要说明的是,在不冲突的情况下,本申请中的实施例及实施例中的特征可以相互任意组合。In order to make the object, technical solution and advantages of the present invention more clear, the embodiments of the present invention will be described in detail below in conjunction with the accompanying drawings. It should be noted that, in the case of no conflict, the embodiments in the present application and the features in the embodiments can be combined arbitrarily with each other.

在附图的流程图示出的步骤可以在诸如一组计算机可执行指令的计算机系统中执行。并且,虽然在流程图中示出了逻辑顺序,但是在某些情况下,可以以不同于此处的顺序执行所示出或描述的步骤。The steps shown in the flowcharts of the figures may be performed in a computer system, such as a set of computer-executable instructions. Also, although a logical order is shown in the flowcharts, in some cases the steps shown or described may be performed in an order different from that shown or described herein.

图1为本发明提供的在安装文件过程中管理设备信息的方法的流程图。图1所示方法包括:FIG. 1 is a flowchart of a method for managing device information during file installation provided by the present invention. The methods shown in Figure 1 include:

步骤101、在接收到为集群中节点安装操作系统的请求后,获取各节点的服务器的物理位置信息和网卡的MAC地址;Step 101, after receiving a request to install an operating system for a node in the cluster, obtain the physical location information of the server of each node and the MAC address of the network card;

具体的,服务器的物理位置信息可以根据服务器的部署图来确定,服务器可以通过MAC地址来标记,在进行服务器部署过程中记录上述对应关系。Specifically, the physical location information of the server can be determined according to the deployment diagram of the server, the server can be marked by the MAC address, and the above corresponding relationship is recorded during the server deployment process.

步骤102、在预启动执行环境PXE自动安装操作系统文件的过程中,记录各节点的服务器分配到的IP地址信息,并建立服务器的IP地址和服务器的网卡的MAC地址的对应关系;Step 102, during the process of automatically installing operating system files in the pre-start execution environment PXE, record the IP address information assigned to the server of each node, and establish the corresponding relationship between the IP address of the server and the MAC address of the network card of the server;

具体的,在安装操作系统过程中,记录各服务器在PXE操作下分配得到的IP地址信息,并结合MAC地址,建立在系统安装过程中MAC地址和IP地址的对应关系;Specifically, in the process of installing the operating system, record the IP address information assigned by each server under the PXE operation, and combine the MAC address to establish the corresponding relationship between the MAC address and the IP address during the system installation process;

步骤103、根据服务器的物理位置信息和网卡的MAC地址的对应关系,结合服务器的IP地址和服务器的网卡的MAC地址的对应关系,得到服务器的物理位置信息与服务器的IP地址的对应关系;Step 103, according to the corresponding relationship between the physical location information of the server and the MAC address of the network card, in combination with the corresponding relationship between the IP address of the server and the MAC address of the network card of the server, obtain the corresponding relationship between the physical location information of the server and the IP address of the server;

具体的,由于步骤101和步骤102中记录的对应关系都以MAC地址来标记,因此,对两个对应关系进行合并,可以得到服务器物理位置与服务器的IP地址的对应关系。Specifically, since the correspondences recorded in step 101 and step 102 are marked with MAC addresses, the correspondence between the physical location of the server and the IP address of the server can be obtained by merging the two correspondences.

步骤104、保存所述服务器的物理位置信息和IP地址的对应关系。Step 104, storing the correspondence between the physical location information of the server and the IP address.

其中,对得到的对应关系进行保存,便于用户利用该对应关系进行后续服务器的管理。Wherein, the obtained corresponding relationship is saved, so that the user can use the corresponding relationship to manage the subsequent server.

本发明提供的方法实施例,通过获取服务器的物理位置信息和网卡的MAC地址,在自动安装操作系统过程中,获取服务器的IP地址和服务器的网卡的MAC地址的对应关系,再将两个对应关系进行合并,得到服务器的物理位置信息和网卡的IP地址的对应关系,实现集群操作系统部署过程中物理与节点的绑定关系,便于根据物理位置识别主机,提高管理效率,无需要额外繁重的操作才能绑定节点信息,减少后期的管理成本。In the method embodiment provided by the present invention, by obtaining the physical location information of the server and the MAC address of the network card, in the process of automatically installing the operating system, the corresponding relationship between the IP address of the server and the MAC address of the network card of the server is obtained, and then the two corresponding The relationship is merged to obtain the corresponding relationship between the physical location information of the server and the IP address of the network card, and realize the binding relationship between the physical and the node during the deployment of the cluster operating system, which is convenient for identifying the host according to the physical location, and improves management efficiency without additional heavy Operations can bind node information, reducing later management costs.

下面对本发明提供的方法实施例作进一步说明:The method embodiment provided by the present invention is described further below:

本发明中可以只对操作系统安装完成的服务器进行相关管理,对于操作系统安装失败的服务器不进行管理,因此在得到服务器的物理位置信息与服务器的IP地址的对应关系之前,所述方法还包括:In the present invention, only the server whose operating system has been installed can be managed, and the server whose operating system has failed to be installed is not managed. Therefore, before obtaining the corresponding relationship between the physical location information of the server and the IP address of the server, the method also includes :

判断操作系统的安装操作是否成功;Determine whether the installation operation of the operating system is successful;

在操作系统安装成功后,再执行获取服务器的物理位置信息与服务器的IP地址的对应关系的操作。After the operating system is successfully installed, the operation of obtaining the correspondence between the physical location information of the server and the IP address of the server is performed.

具体的,本发明提供的方法中,在获取到服务器的IP地址信息后,通过判断操作系统的安装操作是否成功,来判断是否需要对该服务器的IP地址和物理位置的对应关系,如果操作系统的安装操作成功,则表示该服务器能够运行,为后续便于对该服务器管理,就需要获取该IP地址和物理位置的对应关系;相反,如果操作系统的安装操作失败,则表示该服务器不能够工作,因此,还不需要进行后续的步骤。Specifically, in the method provided by the present invention, after obtaining the IP address information of the server, it is judged whether the corresponding relationship between the IP address and the physical location of the server is needed by judging whether the installation operation of the operating system is successful. If the installation operation of the operating system is successful, it means that the server can run. To facilitate the subsequent management of the server, it is necessary to obtain the corresponding relationship between the IP address and the physical location; on the contrary, if the installation operation of the operating system fails, it means that the server cannot work. , so no further steps are required.

其中,所述保存所述服务器的物理位置信息和IP地址的对应关系之后,所述方法还包括:Wherein, after storing the correspondence between the physical location information of the server and the IP address, the method further includes:

根据所述服务器的物理位置信息和IP地址的对应关系,在服务器部署示意图中标记各个服务器的IP地址信息。According to the corresponding relationship between the physical location information of the server and the IP address, mark the IP address information of each server in the server deployment schematic diagram.

具体的,为了方便用户对不同物理位置的服务器的管理,可以将IP地址信息标记在对应的物理位置上,直观显示给用户,方便用户对服务器根据显示的IP地址对特定的服务器进行管理。Specifically, in order to facilitate the user's management of servers in different physical locations, the IP address information can be marked on the corresponding physical location and displayed intuitively to the user, so that the user can manage the specific server according to the displayed IP address.

当然,也可以不将IP地址标记在服务器的部署图中,当用户对特定服务器进行管理时,根据用户选定的物理位置,自行确定该物理位置对应的IP地址,根据得到的IP地址完成对应管理操作。具体操作如下:Of course, it is also possible not to mark the IP address in the deployment diagram of the server. When the user manages a specific server, according to the physical location selected by the user, the IP address corresponding to the physical location is determined by the user, and the corresponding IP address is completed according to the obtained IP address. management operations. The specific operation is as follows:

在保存所述服务器的物理位置信息和IP地址的对应关系之后,接收用户对物理位置信息的选择以及对该物理位置对应的服务器的管理请求;After storing the correspondence between the physical location information of the server and the IP address, receiving the user's selection of the physical location information and a management request of the server corresponding to the physical location;

根据所述物理位置信息和IP地址的对应关系,确定用户管理的服务器的IP地址信息;According to the corresponding relationship between the physical location information and the IP address, determine the IP address information of the server managed by the user;

利用所述IP地址发送所述管理请求。The management request is sent using the IP address.

通过上述流程,用户可以根据物理位置完成对服务器的管理,无需关注服务器的IP地址,只需选中对应的服务位置,简化用户的操作,提供一种新的操作方式。Through the above process, users can complete the management of the server according to the physical location, without paying attention to the IP address of the server, and only need to select the corresponding service location, which simplifies the user's operation and provides a new operation mode.

当然,为了方便对服务器的资产信息的录入,还需要记录服务器的主机信息,因此,在所述保存所述服务器的物理位置信息和IP地址的对应关系之后,所述方法还包括:Of course, in order to facilitate the entry of the asset information of the server, it is also necessary to record the host information of the server. Therefore, after storing the correspondence between the physical location information and the IP address of the server, the method further includes:

根据所述IP地址信息,获取所述IP地址的主机识别信息;Acquiring host identification information of the IP address according to the IP address information;

利用获取到的所述IP地址的主机识别信息,建立所述服务器的主机识别信息、物理位置信息和IP地址信息的对应关系。Using the acquired host identification information of the IP address, establish a correspondence relationship between the host identification information, physical location information, and IP address information of the server.

其中,主机的识别信息可以为主机名、主机的硬件配置参数等。Wherein, the identification information of the host may be a host name, hardware configuration parameters of the host, and the like.

下面以应用实例对上述方法做以简单说明:The following is a brief description of the above method with an application example:

步骤1、获取各节点Server网卡的MAC地址,并记录与Server物理位置对应关系;Step 1. Obtain the MAC address of the server network card of each node, and record the corresponding relationship with the server's physical location;

步骤2、配置DHCP service,绑定IP-MAC对应关系;Step 2. Configure DHCP service and bind IP-MAC correspondence;

步骤3、配置kickstart环境,配置生效后开始安装过程;Step 3. Configure the kickstart environment, and start the installation process after the configuration takes effect;

步骤4、集群操作系统安装完成后确认Server IP、MAC及物理位置的对应关系是否符合预期;Step 4. After the cluster operating system is installed, confirm whether the corresponding relationship between Server IP, MAC and physical location meets expectations;

本发明应用实例提供的方法,主要目的是建立物理位置与系统信息绑定,从而减少、减少部署系统的实施人员重复、繁琐的绑定配置工作,提高管理效率,减低管理成本。The main purpose of the method provided by the application example of the present invention is to establish the binding of physical location and system information, thereby reducing and reducing the repetitive and tedious binding configuration work of the implementers of the deployment system, improving management efficiency and reducing management costs.

图2为本发明提供的在安装文件过程中管理设备信息的装置的结构图。图2所示装置包括:FIG. 2 is a structural diagram of an apparatus for managing device information during file installation provided by the present invention. The device shown in Figure 2 includes:

第一获取模块201,用于在接收到为集群中节点安装操作系统的请求后,获取各节点的服务器的物理位置信息和网卡的MAC地址;The first obtaining module 201 is used to obtain the physical location information of the server of each node and the MAC address of the network card after receiving the request for installing the operating system for the nodes in the cluster;

记录模块202,用于在预启动执行环境PXE自动安装操作系统文件的过程中,记录各节点的服务器分配到的IP地址信息,并建立服务器的IP地址和服务器的网卡的MAC地址的对应关系;The recording module 202 is used to record the IP address information assigned to the server of each node in the process of automatically installing the operating system file in the pre-start execution environment PXE, and establish the corresponding relationship between the IP address of the server and the MAC address of the network card of the server;

第一确定模块203,用于根据服务器的物理位置信息和网卡的MAC地址的对应关系,结合服务器的IP地址和服务器的网卡的MAC地址的对应关系,得到服务器的物理位置信息与服务器的IP地址的对应关系;The first determination module 203 is used to obtain the physical location information of the server and the IP address of the server in combination with the corresponding relationship between the IP address of the server and the MAC address of the network card of the server according to the corresponding relationship between the physical location information of the server and the MAC address of the network card. corresponding relationship;

保存模块204,用于保存所述服务器的物理位置信息和IP地址的对应关系。The saving module 204 is configured to save the correspondence between the physical location information of the server and the IP address.

在本发明提供的一个装置实施例中,所述装置还包括:In an embodiment of the device provided by the present invention, the device further includes:

判断模块,用于在得到服务器的物理位置信息与服务器的IP地址的对应关系之前,判断操作系统的安装操作是否成功;A judging module, used to judge whether the installation operation of the operating system is successful before obtaining the correspondence between the physical location information of the server and the IP address of the server;

其中,所述确定模块在操作系统安装成功后,再执行获取服务器的物理位置信息与服务器的IP地址的对应关系的操作。Wherein, after the operating system is successfully installed, the determining module executes the operation of obtaining the correspondence between the physical location information of the server and the IP address of the server.

在本发明提供的一个装置实施例中,所述装置还包括:In an embodiment of the device provided by the present invention, the device further includes:

标记模块,用于在保存所述服务器的物理位置信息和IP地址的对应关系之后,根据所述服务器的物理位置信息和IP地址的对应关系,在服务器部署示意图中标记各个服务器的IP地址信息。The marking module is configured to mark the IP address information of each server in the server deployment diagram according to the corresponding relationship between the physical location information of the server and the IP address after storing the corresponding relationship between the physical location information of the server and the IP address.

在本发明提供的一个装置实施例中,所述装置还包括:In an embodiment of the device provided by the present invention, the device further includes:

接收模块,用于在保存所述服务器的物理位置信息和IP地址的对应关系之后,接收用户对物理位置信息的选择以及对该物理位置对应的服务器的管理请求;The receiving module is used to receive the user's selection of the physical location information and a management request of the server corresponding to the physical location after saving the correspondence between the physical location information of the server and the IP address;

第二确定模块,用于根据所述物理位置信息和IP地址的对应关系,确定用户管理的服务器的IP地址信息;The second determination module is used to determine the IP address information of the server managed by the user according to the correspondence between the physical location information and the IP address;

发送模块,用于利用所述IP地址发送所述管理请求。A sending module, configured to use the IP address to send the management request.

在本发明提供的一个装置实施例中,所述装置还包括:In an embodiment of the device provided by the present invention, the device further includes:

第二获取模块,用于在保存所述服务器的物理位置信息和IP地址的对应关系之后,根据所述IP地址信息,获取所述IP地址的主机识别信息;The second obtaining module is used to obtain the host identification information of the IP address according to the IP address information after saving the correspondence between the physical location information of the server and the IP address;

建立模块,用于利用获取到的所述IP地址的主机识别信息,建立所述服务器的主机识别信息、物理位置信息和IP地址信息的对应关系。The establishment module is configured to use the obtained host identification information of the IP address to establish a correspondence between the server's host identification information, physical location information, and IP address information.

本发明提供的装置实施例,通过获取服务器的物理位置信息和网卡的MAC地址,在自动安装操作系统过程中,获取服务器的IP地址和服务器的网卡的MAC地址的对应关系,再将两个对应关系进行合并,得到服务器的物理位置信息和网卡的IP地址的对应关系,实现集群操作系统部署过程中物理与节点的绑定关系,便于根据物理位置识别主机,提高管理效率,无需要额外繁重的操作才能绑定节点信息,减少后期的管理成本。In the device embodiment provided by the present invention, by obtaining the physical location information of the server and the MAC address of the network card, in the process of automatically installing the operating system, the corresponding relationship between the IP address of the server and the MAC address of the network card of the server is obtained, and then the two corresponding The relationship is merged to obtain the corresponding relationship between the physical location information of the server and the IP address of the network card, and realize the binding relationship between the physical and the node during the deployment of the cluster operating system, which is convenient for identifying the host according to the physical location and improves management efficiency without additional heavy work Operations can bind node information, reducing later management costs.

本领域普通技术人员可以理解上述实施例的全部或部分步骤可以使用计算机程序流程来实现,所述计算机程序可以存储于一计算机可读存储介质中,所述计算机程序在相应的硬件平台上(如系统、设备、装置、器件等)执行,在执行时,包括方法实施例的步骤之一或其组合。Those of ordinary skill in the art can understand that all or part of the steps of the above-mentioned embodiments can be implemented using a computer program flow, the computer program can be stored in a computer-readable storage medium, and the computer program can be run on a corresponding hardware platform (such as system, device, device, device, etc.), and when executed, includes one or a combination of the steps of the method embodiment.

可选地,上述实施例的全部或部分步骤也可以使用集成电路来实现,这些步骤可以被分别制作成一个个集成电路模块,或者将它们中的多个模块或步骤制作成单个集成电路模块来实现。这样,本发明不限制于任何特定的硬件和软件结合。Optionally, all or part of the steps in the above embodiments can also be implemented using integrated circuits, and these steps can be fabricated into individual integrated circuit modules, or multiple modules or steps among them can be fabricated into a single integrated circuit module accomplish. As such, the present invention is not limited to any specific combination of hardware and software.

上述实施例中的各装置/功能模块/功能单元可以采用通用的计算装置来实现,它们可以集中在单个的计算装置上,也可以分布在多个计算装置所组成的网络上。The devices/functional modules/functional units in the above embodiments can be realized by general-purpose computing devices, and they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices.

上述实施例中的各装置/功能模块/功能单元以软件功能模块的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。上述提到的计算机可读取存储介质可以是只读存储器,磁盘或光盘等。When each device/functional module/functional unit in the above-mentioned embodiments is realized in the form of a software function module and sold or used as an independent product, it can be stored in a computer-readable storage medium. The computer-readable storage medium mentioned above may be a read-only memory, a magnetic disk or an optical disk, and the like.

以上所述,仅为本发明的具体实施方式,但本发明的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本发明揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本发明的保护范围之内。因此,本发明的保护范围应以权利要求所述的保护范围为准。The above is only a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Anyone skilled in the art can easily think of changes or substitutions within the technical scope disclosed in the present invention. Should be covered within the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope described in the claims.

Claims (10)

1.一种在安装文件过程中管理设备信息的方法,其特征在于,包括:1. A method for managing device information during file installation, characterized in that it comprises: 在接收到为集群中节点安装操作系统的请求后,获取各节点的服务器的物理位置信息和网卡的MAC地址;After receiving the request to install the operating system for the nodes in the cluster, obtain the physical location information of the server of each node and the MAC address of the network card; 在预启动执行环境PXE自动安装操作系统文件的过程中,记录各节点的服务器分配到的IP地址信息,并建立服务器的IP地址和服务器的网卡的MAC地址的对应关系;In the process of automatically installing operating system files in the pre-start execution environment PXE, record the IP address information assigned to the server of each node, and establish the corresponding relationship between the IP address of the server and the MAC address of the network card of the server; 根据服务器的物理位置信息和网卡的MAC地址的对应关系,结合服务器的IP地址和服务器的网卡的MAC地址的对应关系,得到服务器的物理位置信息与服务器的IP地址的对应关系;According to the corresponding relationship between the physical location information of the server and the MAC address of the network card, in combination with the corresponding relationship between the IP address of the server and the MAC address of the network card of the server, the corresponding relationship between the physical location information of the server and the IP address of the server is obtained; 保存所述服务器的物理位置信息和IP地址的对应关系。The corresponding relationship between the physical location information of the server and the IP address is stored. 2.根据权利要求1所述的方法,其特征在于,在得到服务器的物理位置信息与服务器的IP地址的对应关系之前,所述方法还包括:2. The method according to claim 1, wherein, before obtaining the correspondence between the physical location information of the server and the IP address of the server, the method further comprises: 判断操作系统的安装操作是否成功;Determine whether the installation operation of the operating system is successful; 在操作系统安装成功后,再执行获取服务器的物理位置信息与服务器的IP地址的对应关系的操作。After the operating system is successfully installed, the operation of obtaining the correspondence between the physical location information of the server and the IP address of the server is performed. 3.根据权利要求1所述的方法,其特征在于,所述保存所述服务器的物理位置信息和IP地址的对应关系之后,所述方法还包括:3. The method according to claim 1, wherein after storing the correspondence between the physical location information and the IP address of the server, the method further comprises: 根据所述服务器的物理位置信息和IP地址的对应关系,在服务器部署示意图中标记各个服务器的IP地址信息。According to the corresponding relationship between the physical location information of the server and the IP address, mark the IP address information of each server in the server deployment schematic diagram. 4.根据权利要求1或3所述的方法,其特征在于,所述保存所述服务器的物理位置信息和IP地址的对应关系之后,所述方法还包括:4. The method according to claim 1 or 3, wherein after storing the correspondence between the physical location information and the IP address of the server, the method further comprises: 接收用户对物理位置信息的选择以及对该物理位置对应的服务器的管理请求;Receive the user's selection of the physical location information and the management request of the server corresponding to the physical location; 根据所述物理位置信息和IP地址的对应关系,确定用户管理的服务器的IP地址信息;According to the corresponding relationship between the physical location information and the IP address, determine the IP address information of the server managed by the user; 利用所述IP地址发送所述管理请求。The management request is sent using the IP address. 5.根据权利要求1或3所述的方法,其特征在于,所述保存所述服务器的物理位置信息和IP地址的对应关系之后,所述方法还包括:5. The method according to claim 1 or 3, wherein after storing the correspondence between the physical location information and the IP address of the server, the method further comprises: 根据所述IP地址信息,获取所述IP地址的主机识别信息;Acquiring host identification information of the IP address according to the IP address information; 利用获取到的所述IP地址的主机识别信息,建立所述服务器的主机识别信息、物理位置信息和IP地址信息的对应关系。Using the acquired host identification information of the IP address, establish a correspondence relationship between the host identification information, physical location information, and IP address information of the server. 6.一种在安装文件过程中管理设备信息的装置,其特征在于,包括:6. A device for managing device information during file installation, characterized in that it comprises: 第一获取模块,用于在接收到为集群中节点安装操作系统的请求后,获取各节点的服务器的物理位置信息和网卡的MAC地址;The first obtaining module is used to obtain the physical location information of the server of each node and the MAC address of the network card after receiving the request for installing the operating system for the nodes in the cluster; 记录模块,用于在预启动执行环境PXE自动安装操作系统文件的过程中,记录各节点的服务器分配到的IP地址信息,并建立服务器的IP地址和服务器的网卡的MAC地址的对应关系;The recording module is used to record the IP address information assigned to the server of each node in the process of automatically installing the operating system file in the pre-start execution environment PXE, and establish the corresponding relationship between the IP address of the server and the MAC address of the network card of the server; 第一确定模块,用于根据服务器的物理位置信息和网卡的MAC地址的对应关系,结合服务器的IP地址和服务器的网卡的MAC地址的对应关系,得到服务器的物理位置信息与服务器的IP地址的对应关系;The first determining module is used to obtain the physical location information of the server and the IP address of the server according to the corresponding relationship between the physical location information of the server and the MAC address of the network card, in combination with the corresponding relationship between the IP address of the server and the MAC address of the network card of the server Correspondence; 保存模块,用于保存所述服务器的物理位置信息和IP地址的对应关系。A saving module, configured to save the correspondence between the physical location information of the server and the IP address. 7.根据权利要求6所述的装置,其特征在于,所述装置还包括:7. The device according to claim 6, further comprising: 判断模块,用于在得到服务器的物理位置信息与服务器的IP地址的对应关系之前,判断操作系统的安装操作是否成功;A judging module, used to judge whether the installation operation of the operating system is successful before obtaining the correspondence between the physical location information of the server and the IP address of the server; 其中,所述确定模块在操作系统安装成功后,再执行获取服务器的物理位置信息与服务器的IP地址的对应关系的操作。Wherein, after the operating system is successfully installed, the determining module executes the operation of obtaining the correspondence between the physical location information of the server and the IP address of the server. 8.根据权利要求6所述的装置,其特征在于,所述装置还包括:8. The device according to claim 6, further comprising: 标记模块,用于在保存所述服务器的物理位置信息和IP地址的对应关系之后,根据所述服务器的物理位置信息和IP地址的对应关系,在服务器部署示意图中标记各个服务器的IP地址信息。The marking module is configured to mark the IP address information of each server in the server deployment diagram according to the corresponding relationship between the physical location information of the server and the IP address after storing the corresponding relationship between the physical location information of the server and the IP address. 9.根据权利要求6或8所述的装置,其特征在于,所述装置还包括:9. The device according to claim 6 or 8, characterized in that the device further comprises: 接收模块,用于在保存所述服务器的物理位置信息和IP地址的对应关系之后,接收用户对物理位置信息的选择以及对该物理位置对应的服务器的管理请求;The receiving module is used to receive the user's selection of the physical location information and a management request of the server corresponding to the physical location after saving the correspondence between the physical location information of the server and the IP address; 第二确定模块,用于根据所述物理位置信息和IP地址的对应关系,确定用户管理的服务器的IP地址信息;The second determination module is used to determine the IP address information of the server managed by the user according to the correspondence between the physical location information and the IP address; 发送模块,用于利用所述IP地址发送所述管理请求。A sending module, configured to use the IP address to send the management request. 10.根据权利要求6或8所述的装置,其特征在于,所述装置还包括:10. The device according to claim 6 or 8, characterized in that the device further comprises: 第二获取模块,用于在保存所述服务器的物理位置信息和IP地址的对应关系之后,根据所述IP地址信息,获取所述IP地址的主机识别信息;The second obtaining module is used to obtain the host identification information of the IP address according to the IP address information after saving the correspondence between the physical location information of the server and the IP address; 建立模块,用于利用获取到的所述IP地址的主机识别信息,建立所述服务器的主机识别信息、物理位置信息和IP地址信息的对应关系。The establishment module is configured to use the obtained host identification information of the IP address to establish a correspondence between the server's host identification information, physical location information, and IP address information.
CN201710888779.9A 2017-09-27 2017-09-27 Method and apparatus for managing device information during file installation Active CN107566518B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710888779.9A CN107566518B (en) 2017-09-27 2017-09-27 Method and apparatus for managing device information during file installation

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710888779.9A CN107566518B (en) 2017-09-27 2017-09-27 Method and apparatus for managing device information during file installation

Publications (2)

Publication Number Publication Date
CN107566518A true CN107566518A (en) 2018-01-09
CN107566518B CN107566518B (en) 2021-03-19

Family

ID=60983194

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710888779.9A Active CN107566518B (en) 2017-09-27 2017-09-27 Method and apparatus for managing device information during file installation

Country Status (1)

Country Link
CN (1) CN107566518B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108519887A (en) * 2018-04-02 2018-09-11 青岛宇硕云联信息科技有限公司 A large amount of linux servers method for rapidly mounting, device, computer readable storage medium and terminal device
CN109067599A (en) * 2018-09-25 2018-12-21 山东浪潮云投信息科技有限公司 A kind of method and device for disposing cluster
CN110048895A (en) * 2019-04-25 2019-07-23 广州河东科技有限公司 Node equipment, hotel network setting method and system
CN113507388A (en) * 2021-07-08 2021-10-15 上海浦东发展银行股份有限公司 Equipment deployment configuration method and device, electronic equipment and storage medium
CN115333932A (en) * 2022-08-11 2022-11-11 北京蔚领时代科技有限公司 Automatic networking method of server, storage medium and electronic equipment

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1516841A (en) * 2001-06-15 2004-07-28 ƽ computer network
CN101043280A (en) * 2006-06-24 2007-09-26 华为技术有限公司 Method and system for positioning user location
CN101345659A (en) * 2008-08-27 2009-01-14 杭州华三通信技术有限公司 Network terminal control method and network terminal control system
CN101437327A (en) * 2008-12-04 2009-05-20 上海华为技术有限公司 Method, equipment and system for obtaining and sending public station data
CN104219101A (en) * 2014-10-08 2014-12-17 成都恒云世纪网络技术有限公司 System for implementing automatic configuration of equipment by mobile phone and implementation method of system

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1516841A (en) * 2001-06-15 2004-07-28 ƽ computer network
CN101043280A (en) * 2006-06-24 2007-09-26 华为技术有限公司 Method and system for positioning user location
CN101345659A (en) * 2008-08-27 2009-01-14 杭州华三通信技术有限公司 Network terminal control method and network terminal control system
CN101437327A (en) * 2008-12-04 2009-05-20 上海华为技术有限公司 Method, equipment and system for obtaining and sending public station data
CN104219101A (en) * 2014-10-08 2014-12-17 成都恒云世纪网络技术有限公司 System for implementing automatic configuration of equipment by mobile phone and implementation method of system

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108519887A (en) * 2018-04-02 2018-09-11 青岛宇硕云联信息科技有限公司 A large amount of linux servers method for rapidly mounting, device, computer readable storage medium and terminal device
CN109067599A (en) * 2018-09-25 2018-12-21 山东浪潮云投信息科技有限公司 A kind of method and device for disposing cluster
CN109067599B (en) * 2018-09-25 2021-06-18 浪潮云信息技术股份公司 A method and apparatus for deploying a cluster
CN110048895A (en) * 2019-04-25 2019-07-23 广州河东科技有限公司 Node equipment, hotel network setting method and system
CN110048895B (en) * 2019-04-25 2023-01-03 广州河东科技有限公司 Node equipment, hotel network setting method and system
CN113507388A (en) * 2021-07-08 2021-10-15 上海浦东发展银行股份有限公司 Equipment deployment configuration method and device, electronic equipment and storage medium
CN115333932A (en) * 2022-08-11 2022-11-11 北京蔚领时代科技有限公司 Automatic networking method of server, storage medium and electronic equipment
CN115333932B (en) * 2022-08-11 2024-04-19 北京蔚领时代科技有限公司 Automatic networking method of server, storage medium and electronic equipment

Also Published As

Publication number Publication date
CN107566518B (en) 2021-03-19

Similar Documents

Publication Publication Date Title
US9465625B2 (en) Provisioning of operating environments on a server in a networked environment
CN101325513B (en) Method, equipment and system for upgrading software
CN106886429B (en) A method and server for loading driver
WO2019184164A1 (en) Method for automatically deploying kubernetes worker node, device, terminal apparatus, and readable storage medium
CN110908753B (en) Intelligent fusion cloud desktop server, client and system
US20050283606A1 (en) Selecting a boot image
CN107566518A (en) The method and apparatus of management equipment information during installation file
US8332490B2 (en) Method, apparatus and program product for provisioning a computer system
US10917291B2 (en) RAID configuration
WO2019237584A1 (en) Container management method, device, computer apparatus, and storage medium
US20120124242A1 (en) Server and method for testing pxe function of network interface card
CN101344852A (en) A method, device and system for deploying WINDOWS enterprise edition operating system
CN101393524A (en) Firmware updating method and system
CN106873970B (en) Installation method and device of operating system
CN107634856B (en) A method and system for upgrading router firmware
CN112558993A (en) Operating system installation method, device, equipment and medium
CN107360042A (en) A kind of server management method and device
US20060155838A1 (en) Program installation system and method using the same
CN108881504A (en) A kind of hardware information automatic acquiring method and device
CN106776347A (en) A kind of virtualization system mirror image mounting test system and method
CN117499370A (en) Physical network card configuration method and device, electronic equipment and readable storage medium
CN116107824A (en) Method and device for detecting silk screen information of hard disk, storage medium and electronic device
CN109062580B (en) Virtual environment deployment method and deployment device
CN111209125B (en) A multi-process command line implementation method
CN114153472A (en) Bare metal server deployment method and device, electronic equipment and storage medium

Legal Events

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