CN114640709B - Edge node processing method, device and medium - Google Patents

Edge node processing method, device and medium Download PDF

Info

Publication number
CN114640709B
CN114640709B CN202210331126.1A CN202210331126A CN114640709B CN 114640709 B CN114640709 B CN 114640709B CN 202210331126 A CN202210331126 A CN 202210331126A CN 114640709 B CN114640709 B CN 114640709B
Authority
CN
China
Prior art keywords
edge node
state
connection state
current edge
started
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202210331126.1A
Other languages
Chinese (zh)
Other versions
CN114640709A (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 CN202210331126.1A priority Critical patent/CN114640709B/en
Publication of CN114640709A publication Critical patent/CN114640709A/en
Priority to PCT/CN2022/141658 priority patent/WO2023185136A1/en
Application granted granted Critical
Publication of CN114640709B publication Critical patent/CN114640709B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/54Presence management, e.g. monitoring or registration for receipt of user log-on information, or the connection status of the users
    • 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
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Stored Programmes (AREA)

Abstract

The invention discloses a processing method, a device and a medium of an edge node, which are suitable for the technical field of edge calculation. Determining the connection state of the current edge node according to the relation among the host name, the service certificate and the cluster node list; if the connection state is the state to be started, starting and registering the current edge node; if the connection state is the main body state to be started, starting a main body process of the current edge node; if the connection state is the state to be cleaned, deleting the service certificate; if the connection state is abnormal, stopping using the current edge node. By carrying out subsequent different processes according to different connection states, when the connection state is a state to be started, starting registration is carried out, when the connection state is other states, the edge node cannot start registration again, but processes according to the corresponding processes, and the problem that the connection state of the edge node cannot be determined and then the registration is repeated after blind starting is avoided.

Description

Edge node processing method, device and medium
Technical Field
The present invention relates to the field of edge computing technologies, and in particular, to a method, an apparatus, and a medium for processing an edge node.
Background
Along with the rapid increase of the number of the intelligent terminal devices of the internet, the traditional mode of centralized storage and calculation of the cloud computing center cannot meet the demands of the terminal devices on failure, capacity and computing capacity, the cloud computing capacity is sunk to the edge side and the device side, and unified delivery, operation and maintenance and management and control are carried out through the center, so that the cloud computing method is an important development trend of cloud computing.
Various edge container clusters are emerging under this trend, and the edge container clusters are one new node type (edge node) more than the traditional container management platform (kubernetes) container clusters. Fig. 1 is an application schematic diagram of a connection relationship between a management end and an edge management service, as shown in fig. 1, an edge node service is not a core service of kubernetes, but an edge node service is operated on an edge node, a database is started on the edge node, after the edge node service initially obtains data from the management end, the application data is stored in a local database, and in an actual application scene, the edge node is further out of connection due to the fact that network delay, fluctuation or network disconnection occurs frequently, so that the edge node has a certain autonomous capability.
The management of the edge node adopts a registration mechanism, the edge node service actively establishes contact with the edge management service after being started, the node is brought into a cluster node list by a management end after authentication, and the name of the node in the cluster node list is the host name of the node. Since the current connection state of the edge node cannot be known, the startup registration is performed every time the service of the edge node is started. For example: when the edge node is connected with one cluster, and the connection is established with the other cluster after the task is executed, due to the data of the previous cluster, when the edge node is started, the management end deletes the edge node, but the edge node service corresponding to the edge node is not deleted, the data of the previous cluster corresponding to the edge node originally needs to be deleted, but the connection is established again with the previous cluster at the moment, and the management end is repeatedly registered, so that the original purpose of deleting the node data is overcome.
Therefore, how to avoid re-registration of edge nodes is a need for a solution for those skilled in the art.
Disclosure of Invention
The invention aims to provide a processing method, a processing device and a processing medium for an edge node, which avoid repeated registration caused by blind starting of the edge node.
In order to solve the above technical problems, the present invention provides a method for processing an edge node, including:
acquiring a host name, a service certificate and a cluster node list corresponding to a current edge node;
determining the connection state of the current edge node according to the relation among the host name, the service certificate and the cluster node list;
if the connection state is the state to be started, starting and registering the current edge node;
if the connection state is the main body state to be started, starting a main body process of the current edge node;
if the connection state is the state to be cleaned, deleting the service certificate;
if the connection state is abnormal, stopping using the current edge node.
Preferably, determining the connection state of the current edge node according to the relationship among the hostname, the service certificate and the cluster node list includes:
when the existence of the service certificate is detected, judging whether the cluster node list contains a host name or not;
if the connection state is included, determining that the connection state is a main body state to be started;
if the connection state does not contain the current state, determining that the connection state is a state to be cleaned;
when the absence of the service certificate is detected, judging whether the cluster node list contains a host name or not;
if yes, determining that the connection state is an abnormal state;
if not, determining the connection state as the state to be started.
Preferably, after deleting the service certificate if the connection state is the state to be cleaned, the method further comprises:
and deleting the configuration information, the database and the log corresponding to the current edge node.
Preferably, if the connection state is a state to be started, the current edge node is started and registered, including:
generating a service certificate corresponding to the current edge node, starting a database and starting the registration of the current edge node to the management end.
Preferably, after determining the connection state of the current edge node, the method further comprises:
and unloading the driver corresponding to the current edge node so as to install the driver when the current edge node is started next time.
Preferably, obtaining the cluster node list includes:
and calling an interface by kube-apiserver of the cluster node corresponding to the access management end to obtain a cluster node list.
Preferably, the method further comprises:
and when the connection state is abnormal, outputting prompt information.
In order to solve the above technical problem, the present invention further provides a processing device for an edge node, including:
the acquisition module is used for acquiring a host name, a service certificate and a cluster node list corresponding to the current edge node;
the determining module is used for determining the connection state of the current edge node according to the relation among the host name, the service certificate and the cluster node list, triggering the starting registration module if the connection state is a to-be-started state, triggering the starting main body module if the connection state is a to-be-started main body state, triggering the deleting module if the connection state is a to-be-cleaned state, and triggering the stopping module if the connection state is an abnormal state;
the starting registration module is used for starting registration of the current edge node;
the main body starting module is used for starting a main body process of the current edge node;
the deleting module is used for deleting the service certificate;
and the stopping module is used for stopping using the current edge node.
In order to solve the above technical problem, the present invention further provides a processing device for an edge node, including:
a memory for storing a computer program;
a processor for implementing the steps of the method of processing an edge node as described above when executing a computer program.
In order to solve the above technical problem, the present invention further provides a computer readable storage medium, on which a computer program is stored, which when executed by a processor implements the steps of the edge node processing method as described above.
The invention provides a processing method of an edge node, which comprises the steps of obtaining a host name, a service certificate and a cluster node list corresponding to a current edge node; determining the connection state of the current edge node according to the relation among the host name, the service certificate and the cluster node list; if the connection state is the state to be started, starting and registering the current edge node; if the connection state is the main body state to be started, starting a main body process of the current edge node; if the connection state is the state to be cleaned, deleting the service certificate; if the connection state is abnormal, stopping using the current edge node. According to the method, the current connection state of the edge node is determined by acquiring the host name, the service certificate and the cluster node list corresponding to the current edge node, further different subsequent processes are determined according to different connection states, when the connection state is a state to be started, starting registration is performed, when the connection state is a state of a main body to be started, the main body process is started, when the connection state is a state to be cleaned, the service certificate is deleted, and when the connection state is an abnormal state, the current edge node is stopped. In summary, the edge node does not start registration again in the connection state except the state with the start, but processes according to the processes corresponding to the other states, so that the problem that the existing state of the edge node before the cluster is connected cannot be determined, and the registration is repeated after blind start is caused is avoided.
In addition, the invention also provides a processing device and a medium of the edge node, and the processing device and the medium have the same beneficial effects as the processing method of the edge node.
Drawings
For a clearer description of embodiments of the present invention, the drawings that are required to be used in the embodiments will be briefly described, it being apparent that the drawings in the following description are only some embodiments of the present invention, and other drawings may be obtained according to the drawings without inventive effort for those skilled in the art.
FIG. 1 is a schematic diagram of an application of a management end to edge management service connection;
fig. 2 is a flowchart of a processing method of an edge node according to an embodiment of the present invention;
fig. 3 is a block diagram of a processing device of an edge node according to an embodiment of the present invention;
fig. 4 is a block diagram of another processing apparatus for an edge node according to an embodiment of the present invention.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present invention, but not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by a person of ordinary skill in the art without making any inventive effort are within the scope of the present invention.
The core of the invention is to provide a processing method, a device and a medium for edge nodes, which avoid blind starting of the edge nodes and repeated registration caused by the blind starting of the edge nodes.
In order to better understand the aspects of the present invention, the present invention will be described in further detail with reference to the accompanying drawings and detailed description.
It should be noted that, the processing method of the edge node provided by the invention is performed before the edge node service is started, wherein the edge node service is in the edge cloud, and the edge node replaces the core service (kubrelet) of kubrenetes to perform the service of container management and status report, directly interacts with the edge management service, and judges the relationship between the current edge node and the cluster by acquiring the following information, and starts or processes the edge node in other process states according to the need.
Fig. 2 is a flowchart of a processing method of an edge node according to an embodiment of the present invention, where, as shown in fig. 2, the method includes:
s11: and acquiring a host name, a service certificate and a cluster node list corresponding to the current edge node.
It will be appreciated that the edge node service needs to establish a connection with the cluster of the management end before it starts. For example: the edge node C needs to be connected with the cluster B according to the distributed task, before connection, the connection state of the edge node C needs to be checked, whether connection is established with the cluster task before the cluster B, and whether unclean data after other clusters are connected exist or not is checked, so that when the edge node C is started to be connected with the cluster B in the unclean state, the edge node C is automatically registered to other clusters due to a starting mechanism of the edge node.
The host name of the current edge node, that is, the node host name of the edge node C at the local end, needs to be obtained, so as to facilitate comparison of the cluster node list. Judging whether the edge node is contained in the node list or not, and using a host name in the running process of the main body process of the subsequent edge node.
The service certificate is acquired, so that whether a local certificate file exists or not is conveniently checked, and it is required to be noted that the service certificate can be acquired only through the local edge node. If the connection state is obtained from the management end, the subsequent connection state of the edge node cannot be determined. The hostname and service certificate may be obtained through an Operating System (OS). And acquiring a cluster node list, namely acquiring a cluster node list corresponding to a target cluster which needs to be connected. The acquisition path of the cluster node list can be acquired through the management nodes deployed in kubernetes clusters, or can be directly acquired and distributed through a management end, and the invention is not particularly limited.
S12: and determining the connection state of the current edge node according to the relationship among the host name, the service certificate and the cluster node list.
And determining the connection state of the current edge node according to the relationship among the host name, the service certificate and the cluster node list acquired in the step S11, wherein whether the current edge node has the edge node service certificate or not and whether the current edge node has the cluster node list or not is determined.
Whether the edge node service certificate exists in the current edge node or not, if so, the local end is stated to be still provided with the service certificate of the target cluster corresponding to the connection establishment, and the edge node service is not destroyed.
Whether the host name corresponding to the current edge node exists in the cluster node list or not, if so, the management end is stated to not delete the current edge node.
The connection state of the current edge node is determined by combining the two determinations, and it can be understood that the order of the two determinations can be exchanged, whether the current edge node has an edge node service certificate is determined first, then whether the host name corresponding to the current edge node has a cluster node list is determined, and the determination mode is the same as the determination mode of determining whether the host name corresponding to the current edge node has the cluster node list and then determining whether the current edge node has the edge node service certificate.
S13: and if the connection state is the state to be started, starting and registering the current edge node.
When the connection state determined in step S12 is the to-be-started state, it is indicated that the edge node service certificate does not exist in the current edge node, and the hostname of the edge node service certificate does not exist in the cluster node list. Further explaining the situation that the current edge node has no connection with the target cluster before the edge node is unregistered. And initializing and starting the current edge node, acquiring a service certificate, starting edge node service, registering the current edge node to a management end, and starting a main process.
S14: and if the connection state is the main body state to be started, starting the main body process of the current edge node.
The other connection states except for the to-be-started state determined in step S12 include a to-be-started main body state, a to-be-cleaned state and an abnormal state, which indicate that the current edge node is connected with the target cluster before the current edge node is disconnected, or that the management end and the local end of the current edge node have the starting service program of the current edge node after the current edge node is disconnected, and the process states of the current edge node are different due to the combination of the two judging modes. The current edge node is processed according to different processes.
When the connection state is the main state to be started, the main process of the current edge node is started, and in the above embodiment, the edge node starting service includes registering and starting the main process, and the main process establishes long connection with the edge management service of the cluster management end, reports the state of the node and the container state on the node at regular time, and simultaneously receives the instruction and the execution program from the edge management service.
S15: and if the connection state is the state to be cleaned, deleting the service certificate.
When the connection state is the state to be cleaned, the service certificate needs to be deleted, so that the synchronism of data corresponding to the edge node starting service of the target cluster is ensured, and meanwhile, the edge node service is closed.
S16: if the connection state is abnormal, stopping using the current edge node.
When the connection state is abnormal, the current edge node is not used.
The invention provides a processing method of an edge node, which comprises the steps of obtaining a host name, a service certificate and a cluster node list corresponding to a current edge node; determining the connection state of the current edge node according to the relation among the host name, the service certificate and the cluster node list; if the connection state is the state to be started, starting and registering the current edge node; if the connection state is the main body state to be started, starting a main body process of the current edge node; if the connection state is the state to be cleaned, deleting the service certificate; if the connection state is abnormal, stopping using the current edge node. According to the method, the current connection state of the edge node is determined by acquiring the host name, the service certificate and the cluster node list corresponding to the current edge node, further different subsequent processes are determined according to different connection states, when the connection state is a state to be started, starting registration is performed, when the connection state is a state of a main body to be started, the main body process is started, when the connection state is a state to be cleaned, the service certificate is deleted, and when the connection state is an abnormal state, the current edge node is stopped. In summary, the edge node does not start registration again in the connection state except the state with the start, but processes according to the processes corresponding to the other states, so that the problem that the existing state of the edge node before the cluster is connected cannot be determined, and the registration is repeated after blind start is caused is avoided.
In the above embodiment, determining the connection state of the current edge node according to the relationship of the hostname, the service certificate, and the cluster node list in step S12 includes:
when the existence of the service certificate is detected, judging whether the cluster node list contains a host name or not;
if the connection state is included, determining that the connection state is a main body state to be started;
if the connection state does not contain the current state, determining that the connection state is a state to be cleaned;
when the absence of the service certificate is detected, judging whether the cluster node list contains a host name or not;
if yes, determining that the connection state is an abnormal state;
if not, determining the connection state as the state to be started.
Specifically, when the service certificate is detected to exist in the node, the fact that the edge node service of the local end aiming at the current edge node of the target cluster is not deleted is indicated, and whether the cluster node list contains a host name is further judged. If so, the node has been previously registered with the management end and has already performed the startup service. It may be noted that the start service includes two steps, registration and then start of the subject process. The current edge node is already registered and needs to enter the step of starting the subject process.
If not, the connection between the target cluster and the current edge node is established before the target cluster is indicated, but the management end has deleted the current edge node. In order to synchronize with the data of the target cluster in the subsequent connection, at this time, it is determined that the current connection state of the edge node is a state to be cleaned, and the data of the local end needs to be cleaned at the local end, and the edge node service is closed and deleted.
When the service certificate is detected not to exist in the node, the edge node service deletion of the current edge node of the local end aiming at the target cluster is indicated, and whether the cluster node list contains a host name is further judged. If the edge node is included, the edge node is registered to the management end before, but the related certificate of the edge node service at the local end is deleted, so that the edge node service cannot be started, the current connection state of the edge node is determined to be an abnormal state, and staff is required to intervene and maintain.
If the connection state of the current edge node is not the to-be-started state, the connection state of the current edge node is determined to be the to-be-started state if the connection state of the current edge node is not the to-be-started state, and the connection state of the current edge node is determined to be the to-be-started state.
It is only an preferred embodiment to first detect whether the service certificate exists in the node, and then determine whether the cluster node list includes a host name, or whether the cluster node list includes a host name, and then detect whether the service certificate exists in the node.
The connection state of the current edge node is determined according to the relation among the host name, the service certificate and the cluster node list, whether the service certificate exists in the node is detected firstly, whether the cluster node list contains the host name is judged, the connection states of the four current edge nodes are correspondingly determined respectively, and different processes of the current edge node are determined according to different connection states subsequently, so that blind starting of the edge node is avoided.
On the basis of the above embodiment, after deleting the service certificate if the connection state is the state to be cleaned, the method further includes:
and deleting the configuration information, the database and the log corresponding to the current edge node.
It can be understood that before the current edge node establishes a connection with the target cluster, the determined connection relationship is a state to be cleaned, the current edge node is connected with the target cluster before or is connected with other clusters, the management end deletes data at this time, but the local end has traces on the data of the connection between the other clusters and the target cluster, and the data is not deleted.
In order to facilitate the establishment of a connection of a target cluster, related data of other clusters, i.e. configuration information, databases and logs, from which the connection was previously established, needs to be deleted. In order to synchronize the edge node start-up service with the target cluster, the related data, i.e. the corresponding configuration information, database and log, of the connection established before the target cluster needs to be deleted.
If the connection state is the state to be cleaned, deleting the service certificate, the configuration information, the database and the log corresponding to the current edge node service. The connection between target clusters is convenient, and remote control operation cleaning is realized.
On the basis of the above embodiment, when the connection relationship is in the to-be-started state, performing start registration on the current edge node specifically includes:
generating a service certificate corresponding to the current edge node, starting a database and starting the registration of the current edge node to the management end.
Specifically, the state to be started indicates that the current edge node is not connected with the target cluster, and a service certificate corresponding to the current edge node needs to be generated, a database is started, the current edge node is started to be registered to the management end, and the method further comprises initializing configuration files and the like.
The method and the device initialize the current edge node, generate the service certificate corresponding to the current edge node, start the database and register the current edge node to the management end. The edge node service is further started, the problem of blind restarting of the edge node is solved, and registration is only required to be started when the connection state is a state to be started.
On the basis of the above embodiment, after determining the connection state of the current edge node, the method further includes:
and unloading the driver corresponding to the current edge node so as to install the driver when the current edge node is started next time.
It can be understood that the program related to the processing method of the edge node provided by the invention is an executable file, and does not need to be resident. Therefore, after the connection state is determined, the driver can be deleted, so that the driver can be installed again to release the memory when the edge node is started next time.
When the driver corresponding to the current edge node is installed, the installation process can be combined into the flow of node addition as a part of the service dependence of the edge node. When the management end starts the file transfer service (httpd), the dependency files required by the edge node service are issued for downloading, the edge management service generates a deployment command of the edge node service, a user copies the deployment command to the edge node for execution, the dependency files required by the edge node service are downloaded from the httpd service of the management end, and then the edge node service is started.
After the connection state of the current edge node is determined, the driver corresponding to the current edge node is unloaded so that the driver can be installed when the current edge node is started next time, and the container memory of the edge node is released.
In a specific embodiment, the obtaining the cluster node list in step S11 includes:
and calling an interface by kube-apiserver of the cluster node corresponding to the access management end to obtain a cluster node list.
Specifically, kube-apiserver is one of kubernetes core services, deployed on a management node of kubernetes cluster, and provides a set of hypertext transfer protocol/hypertext transfer protocol security (Hyper Text Transfer Protocol/Hyper Text Transfer Protocol Secure, HTTP/HTTPs) interfaces for external connection, where kubernetes belong to clustered deployment.
The kernel function of kube-apiserver is to provide various resource objects of kubernetes, such as the minimum unit (Pod) of kubernetes, the number (RC) of management pods, the addition, deletion, modification, search and other HTTP Rest interfaces, which become central hubs for data interaction and communication between the functional modules in the cluster, and are data buses and data centers of the whole system. The invention obtains the cluster node list through the kube-apiserver interface is only one preferable embodiment.
The cluster node list is obtained through the kube-apiserver interface, a complete cluster security mechanism is provided, storage operation in charge of cluster states is realized, and interaction and communication with other data are provided.
On the basis of the above embodiment, when the connection state is an abnormal state, it is indicated that the current edge node cannot be used, and the method further includes:
and when the connection state is an abnormal state, outputting prompt information.
Specifically, a prompt message is output to remind a worker and stop using the current edge node, and a repair mechanism is started. The setting of the prompt information is not particularly limited, and an alarm device can be arranged at the edge node to perform whistle, or a fault lamp is arranged, and the fault lamp flashes when an abnormal state occurs. Because the edge nodes are remotely connected, alarm information can be set at the management end to remind the staff of checking and repairing. Can be according to the actual situation.
When the connection state is an abnormal state, the embodiment outputs prompt information to remind workers to process.
The invention further discloses a processing device of the edge node corresponding to the method, and fig. 3 is a structural diagram of the processing device of the edge node provided by the embodiment of the invention. As shown in fig. 3, the processing device of the edge node includes:
an obtaining module 11, configured to obtain a hostname, a service certificate, and a cluster node list corresponding to a current edge node;
the determining module 12 is configured to determine a connection state of the current edge node according to a relationship among the hostname, the service certificate, and the cluster node list, trigger to start the registering module 13 if the connection state is a state to be started, trigger to start the main module 14 if the connection state is a state to be started, trigger to delete the module 15 if the connection state is a state to be cleaned, and trigger to stop the module 16 if the connection state is an abnormal state;
a start registration module 13, configured to perform start registration on a current edge node;
a start subject module 14 for starting a subject process of the current edge node;
a deletion module 15 for deleting the service certificate;
a stop module 16 for stopping the use of the current edge node.
Since the embodiments of the device portion correspond to the above embodiments, the embodiments of the device portion are described with reference to the embodiments of the method portion, and are not described herein.
The invention provides a processing device of an edge node, which comprises the steps of obtaining a host name, a service certificate and a cluster node list corresponding to a current edge node; determining the connection state of the current edge node according to the relation among the host name, the service certificate and the cluster node list; if the connection state is the state to be started, starting and registering the current edge node; if the connection state is the main body state to be started, starting a main body process of the current edge node; if the connection state is the state to be cleaned, deleting the service certificate; if the connection state is abnormal, stopping using the current edge node. The device determines the connection state of the current edge node by acquiring a host name, a service certificate and a cluster node list corresponding to the current edge node, further determines subsequent different processes according to different connection states, starts up and registers when the connection state is a state to be started, starts up the main process when the connection state is a state to be started up, deletes the service certificate when the connection state is a state to be cleaned up, and stops using the current edge node when the connection state is an abnormal state. In summary, the edge node does not start registration again in the connection state except the state with the start, but processes according to the processes corresponding to the other states, so that the problem that the existing state of the edge node before the cluster is connected cannot be determined, and the registration is repeated after blind start is caused is avoided.
Fig. 4 is a block diagram of another processing apparatus for an edge node according to an embodiment of the present invention, as shown in fig. 4, where the apparatus includes:
a memory 21 for storing a computer program;
a processor 22 for implementing the steps of the processing method of the edge node when executing the computer program.
The processing device of the edge node provided in this embodiment may include, but is not limited to, a smart phone, a tablet computer, a notebook computer, a desktop computer, or the like.
Processor 22 may include one or more processing cores, such as a 4-core processor, an 8-core processor, or the like, among others. The processor 22 may be implemented in hardware in at least one of a digital signal processor (Digital Signal Processor, DSP), a Field programmable gate array (Field-Programmable Gate Array, FPGA), a programmable logic array (Programmable Logic Array, PLA). The processor 22 may also include a main processor, which is a processor for processing data in an awake state, also referred to as a central processor (Central Processing Unit, CPU), and a coprocessor; a coprocessor is a low-power processor for processing data in a standby state. In some embodiments, the processor 22 may be integrated with an image processor (Graphics Processing Unit, GPU) for use in responsible for rendering and rendering of content required for display by the display screen. In some embodiments, the processor 22 may also include an artificial intelligence (Artificial Intelligence, AI) processor for processing computing operations related to machine learning.
Memory 21 may include one or more computer-readable storage media, which may be non-transitory. Memory 21 may also include high-speed random access memory, as well as non-volatile memory, such as one or more magnetic disk storage devices, flash memory storage devices. In this embodiment, the memory 21 is at least used for storing a computer program 211, where the computer program, when loaded and executed by the processor 22, is capable of implementing the relevant steps of the processing method of an edge node disclosed in any of the foregoing embodiments. In addition, the resources stored in the memory 21 may further include an operating system 212, data 213, and the like, and the storage manner may be transient storage or permanent storage. The operating system 212 may include Windows, unix, linux, among other things. The data 213 may include, but is not limited to, data related to the processing method of the edge node, etc.
In some embodiments, the processing device of the edge node may further include a display 23, an input/output interface 24, a communication interface 25, a power supply 26, and a communication bus 27.
It will be appreciated by those skilled in the art that the structure shown in fig. 4 is not limiting of the processing means of the edge node and may include more or fewer components than shown.
The processor 22 implements the processing method of the edge node provided in any of the above embodiments by calling instructions stored in the memory 21.
The invention provides a processing device of an edge node, which comprises the steps of obtaining a host name, a service certificate and a cluster node list corresponding to a current edge node; determining the connection state of the current edge node according to the relation among the host name, the service certificate and the cluster node list; if the connection state is the state to be started, starting and registering the current edge node; if the connection state is the main body state to be started, starting a main body process of the current edge node; if the connection state is the state to be cleaned, deleting the service certificate; if the connection state is abnormal, stopping using the current edge node. The device determines the connection state of the current edge node by acquiring a host name, a service certificate and a cluster node list corresponding to the current edge node, further determines subsequent different processes according to different connection states, starts up and registers when the connection state is a state to be started, starts up the main process when the connection state is a state to be started up, deletes the service certificate when the connection state is a state to be cleaned up, and stops using the current edge node when the connection state is an abnormal state. In summary, the edge node does not start registration again in the connection state except the state with the start, but processes according to the processes corresponding to the other states, so that the problem that the existing state of the edge node before the cluster is connected cannot be determined, and the registration is repeated after blind start is caused is avoided.
Further, the present invention also provides a computer readable storage medium having a computer program stored thereon, which when executed by the processor 22 implements the steps of the method for processing an edge node as described above.
It will be appreciated that the methods of the above embodiments, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored on a computer readable storage medium. Based on this understanding, the technical solution of the present invention may be embodied essentially or in part or all of the technical solution or in part in the form of a software product stored in a storage medium for performing all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
For an introduction to a computer readable storage medium provided by the present invention, please refer to the above method embodiment, the present invention is not described herein, and the method has the same advantages as the above method for processing an edge node.
The method, the device and the medium for processing the edge node provided by the invention are described in detail. In the description, each embodiment is described in a progressive manner, and each embodiment is mainly described by the differences from other embodiments, so that the same similar parts among the embodiments are mutually referred. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant points refer to the description of the method section. It should be noted that it will be apparent to those skilled in the art that various modifications and adaptations of the invention can be made without departing from the principles of the invention and these modifications and adaptations are intended to be within the scope of the invention as defined in the following claims.
It should also be noted that in this specification, relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.

Claims (9)

1. A method for processing an edge node, comprising:
acquiring a host name, a service certificate and a cluster node list corresponding to a current edge node;
determining the connection state of the current edge node according to the relation among the host name, the service certificate and the cluster node list;
if the connection state is a state to be started, starting and registering the current edge node;
if the connection state is the main body state to be started, starting a main body process of the current edge node;
if the connection state is a state to be cleaned, deleting the service certificate;
if the connection state is an abnormal state, stopping using the current edge node;
wherein the determining the connection state of the current edge node according to the relationship among the hostname, the service certificate and the cluster node list includes:
when the existence of the service certificate is detected, judging whether the cluster node list contains the host name or not;
if so, determining the connection state as the main body state to be started;
if not, determining the connection state as the state to be cleaned;
when the service certificate is detected to be absent, judging whether the cluster node list contains the host name or not;
if yes, determining the connection state as the abnormal state;
if not, determining the connection state as the state to be started.
2. The method according to claim 1, further comprising, after deleting the service certificate if the connection state is a state to be cleaned:
and deleting the configuration information, the database and the log corresponding to the current edge node.
3. The method for processing the edge node according to claim 2, wherein if the connection state is a state to be started, performing start-up registration on the current edge node includes:
generating the service certificate corresponding to the current edge node, starting the database and starting the current edge node to register to a management end.
4. A method of processing an edge node according to any one of claims 1 to 3, further comprising, after determining the connection state of the current edge node:
and unloading the driver corresponding to the current edge node so as to install the driver when the current edge node is started next time.
5. A method of processing an edge node according to claim 3, wherein obtaining the list of cluster nodes comprises:
and accessing a kube-apiserver calling interface of the cluster node corresponding to the management end to acquire the cluster node list.
6. The method of processing an edge node of claim 1, further comprising:
and outputting prompt information when the connection state is the abnormal state.
7. An edge node processing apparatus, comprising:
the acquisition module is used for acquiring a host name, a service certificate and a cluster node list corresponding to the current edge node;
the determining module is used for determining the connection state of the current edge node according to the relation among the host name, the service certificate and the cluster node list, triggering the starting registration module if the connection state is a state to be started, triggering the starting main body module if the connection state is a state to be started, triggering the deleting module if the connection state is a state to be cleaned, and triggering the stopping module if the connection state is an abnormal state;
the starting registration module is used for starting registration of the current edge node;
the starting main body module is used for starting the main body process of the current edge node;
the deleting module is used for deleting the service certificate;
the stopping module is used for stopping using the current edge node;
wherein the determining the connection state of the current edge node according to the relationship among the hostname, the service certificate and the cluster node list includes:
when the existence of the service certificate is detected, judging whether the cluster node list contains the host name or not;
if so, determining the connection state as the main body state to be started;
if not, determining the connection state as the state to be cleaned;
when the service certificate is detected to be absent, judging whether the cluster node list contains the host name or not;
if yes, determining the connection state as the abnormal state;
if not, determining the connection state as the state to be started.
8. An edge node processing apparatus, comprising:
a memory for storing a computer program;
a processor for implementing the steps of the method of processing an edge node according to any of claims 1 to 6 when executing said computer program.
9. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method of processing an edge node according to any of claims 1 to 6.
CN202210331126.1A 2022-03-31 2022-03-31 Edge node processing method, device and medium Active CN114640709B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202210331126.1A CN114640709B (en) 2022-03-31 2022-03-31 Edge node processing method, device and medium
PCT/CN2022/141658 WO2023185136A1 (en) 2022-03-31 2022-12-23 Method and apparatus for processing edge node, and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210331126.1A CN114640709B (en) 2022-03-31 2022-03-31 Edge node processing method, device and medium

Publications (2)

Publication Number Publication Date
CN114640709A CN114640709A (en) 2022-06-17
CN114640709B true CN114640709B (en) 2023-07-25

Family

ID=81952233

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210331126.1A Active CN114640709B (en) 2022-03-31 2022-03-31 Edge node processing method, device and medium

Country Status (2)

Country Link
CN (1) CN114640709B (en)
WO (1) WO2023185136A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114640709B (en) * 2022-03-31 2023-07-25 苏州浪潮智能科技有限公司 Edge node processing method, device and medium
CN117938617B (en) * 2024-03-19 2024-06-21 济南浪潮数据技术有限公司 Device management method, device, computer device and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111355610A (en) * 2020-02-25 2020-06-30 网宿科技股份有限公司 Exception handling method and device based on edge network
WO2021135545A1 (en) * 2020-06-30 2021-07-08 平安科技(深圳)有限公司 Kubernetes multi-cluster management system and method, terminal and storage medium
CN113225214A (en) * 2021-05-07 2021-08-06 浪潮软件科技有限公司 Method and device for cooperative management of edge CDN node and computer readable medium
CN113742031A (en) * 2021-08-27 2021-12-03 北京百度网讯科技有限公司 Node state information acquisition method and device, electronic equipment and readable storage medium
CN113946443A (en) * 2021-10-14 2022-01-18 上海明胜品智人工智能科技有限公司 Edge device management and active registration method and device and electronic device

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101471898B (en) * 2007-12-28 2011-12-28 华为技术有限公司 Protection method, system and virtual access edge node for access network
CN112087312B (en) * 2019-06-15 2023-02-03 华为云计算技术有限公司 Method, device and equipment for providing edge service
CN112187532A (en) * 2020-09-18 2021-01-05 北京浪潮数据技术有限公司 Node control method and system
CN114640709B (en) * 2022-03-31 2023-07-25 苏州浪潮智能科技有限公司 Edge node processing method, device and medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111355610A (en) * 2020-02-25 2020-06-30 网宿科技股份有限公司 Exception handling method and device based on edge network
WO2021135545A1 (en) * 2020-06-30 2021-07-08 平安科技(深圳)有限公司 Kubernetes multi-cluster management system and method, terminal and storage medium
CN113225214A (en) * 2021-05-07 2021-08-06 浪潮软件科技有限公司 Method and device for cooperative management of edge CDN node and computer readable medium
CN113742031A (en) * 2021-08-27 2021-12-03 北京百度网讯科技有限公司 Node state information acquisition method and device, electronic equipment and readable storage medium
CN113946443A (en) * 2021-10-14 2022-01-18 上海明胜品智人工智能科技有限公司 Edge device management and active registration method and device and electronic device

Also Published As

Publication number Publication date
WO2023185136A1 (en) 2023-10-05
CN114640709A (en) 2022-06-17

Similar Documents

Publication Publication Date Title
CN114640709B (en) Edge node processing method, device and medium
WO2018095414A1 (en) Method and apparatus for detecting and recovering fault of virtual machine
CN111225064A (en) Ceph cluster deployment method, system, device and computer-readable storage medium
CN111209265B (en) Database switching method and terminal equipment
CN113626286A (en) Multi-cluster instance processing method and device, electronic equipment and storage medium
CN112099825B (en) Method, device, equipment and storage medium for upgrading component
CN108628733B (en) Method and device for testing batch service processing operation
CN110209525B (en) Operating system restoration method and device
CN114416434B (en) Bare metal disk backup method and device and computer readable storage medium
CN114528350B (en) Cluster brain fracture processing method, device, equipment and readable storage medium
CN105930190B (en) A kind of program self-start method and device based on operating system
CN111090537B (en) Cluster starting method and device, electronic equipment and readable storage medium
CN110574006B (en) System and method for automatically synchronizing responses and conditions on a device
CN112667491B (en) Function test method and device for virtual machine
CN115174596A (en) Equipment remote copying method, device and medium
CN115130112A (en) Quick start-stop method, device, equipment and storage medium
CN115114284A (en) Table change processing method and system
CN111176959B (en) Early warning method, system and storage medium of cross-domain application server
CN110007934B (en) Distributed database deployment method and device
CN114153503A (en) BIOS control method, device and medium
CN113656378A (en) Server management method, device and medium
CN114519477A (en) Large data platform tenant management system, method, storage medium and electronic equipment
WO2018077088A1 (en) Application upgrading method and apparatus
WO2024061219A1 (en) Information updating method, apparatus and device, storage medium, and program product
CN116527761A (en) Database proxy service adding method, device, 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