CN114741370A - Edge device resource integration method and device, electronic device and storage medium - Google Patents

Edge device resource integration method and device, electronic device and storage medium Download PDF

Info

Publication number
CN114741370A
CN114741370A CN202210399025.8A CN202210399025A CN114741370A CN 114741370 A CN114741370 A CN 114741370A CN 202210399025 A CN202210399025 A CN 202210399025A CN 114741370 A CN114741370 A CN 114741370A
Authority
CN
China
Prior art keywords
edge device
edge
file
storage file
storage
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.)
Pending
Application number
CN202210399025.8A
Other languages
Chinese (zh)
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.)
Instant Wulian Technology Beijing Co ltd
Original Assignee
Instant Wulian Technology Beijing 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 Instant Wulian Technology Beijing Co ltd filed Critical Instant Wulian Technology Beijing Co ltd
Priority to CN202210399025.8A priority Critical patent/CN114741370A/en
Publication of CN114741370A publication Critical patent/CN114741370A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/18File system types
    • G06F16/182Distributed file systems
    • G06F16/1824Distributed file systems implemented using Network-attached Storage [NAS] architecture
    • G06F16/183Provision of network file services by network file servers, e.g. by using NFS, CIFS
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5061Partitioning or combining of resources

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The present application relates to the field of computer technologies, and in particular, to a method and an apparatus for integrating edge device resources, an electronic device, and a storage medium. The method comprises the following steps: when a file storage request is detected, acquiring an occupied memory capacity value of a target storage file; acquiring edge device information, wherein the edge device information comprises the number of edge devices and a residual storage capacity value corresponding to each edge device; determining scheduling information based on the occupied memory capacity value of the target storage file and the edge device information, wherein the scheduling information comprises the number of fragments and a storage space value corresponding to each fragment; and based on the scheduling information, fragmenting the target storage file and sending the fragmented storage file to the corresponding edge device. The application has the effect of providing larger storage space by utilizing the edge device.

Description

Edge device resource integration method and device, electronic device and storage medium
Technical Field
The present application relates to the field of computer technologies, and in particular, to a method and an apparatus for integrating edge device resources, an electronic device, and a storage medium.
Background
With the rapid development of the internet of things and cloud computing, the types and the number of household intelligent terminal devices and edge devices such as a sweeping robot, an intelligent sound box, a routing switch and a router are gradually increased. Edge devices are physical devices applied to the data link layer and the network layer for providing access to an enterprise or service provider core network.
However, the storage capacity of the edge device is often limited by the configuration of the device itself, and only a storage space smaller than the storage size of the edge device itself can be provided. Therefore, how to utilize edge devices, providing larger storage space becomes a key issue.
Disclosure of Invention
In order to provide a larger storage space by utilizing edge devices, the application provides an edge device resource integration method, an edge device resource integration device, an electronic device and a storage medium.
In a first aspect, the present application provides a method for integrating edge device resources, which adopts the following technical solutions:
an edge device resource integration method comprises the following steps:
when a file storage request is detected, acquiring an occupied memory capacity value of a target storage file;
acquiring edge device information, wherein the edge device information comprises the number of edge devices and a residual storage capacity value corresponding to each edge device;
determining scheduling information based on the memory capacity value occupied by the target storage file and the edge device information, wherein the scheduling information comprises the number of fragments and a storage space value corresponding to each fragment;
and based on the scheduling information, fragmenting the target storage file and sending the fragmented storage file to the corresponding edge device.
By adopting the technical scheme, the occupied memory capacity value and the edge device information of the target storage file can be acquired, so that the number of the fragments and the storage space value corresponding to each fragment can be conveniently determined, the target storage file is divided into the corresponding number of the fragments according to the number of the fragments, and the corresponding storage space value is sent to the corresponding edge device according to each fragment, so that the edge devices of a plurality of small storage resources are integrated into a large resource device, the resource utilization rate is improved, and the edge device is utilized to provide a large storage space.
In another possible implementation manner, the obtaining the occupied memory capacity value of the target storage file when the file storage request is detected includes:
when a file storage request is detected, acquiring a file storage task queue;
determining the priority of a target storage file in a file storage queue;
and if the priority of the target storage file is higher than that of other storage files, acquiring the occupied memory capacity value of the target storage file.
By adopting the technical scheme, the file storage task queue can be obtained to obtain the priority of each storage file in the file storage task queue, the priority of the target storage file is determined, if the priority of the target storage file is higher than that of other storage files, the target storage file is preferentially stored, the occupied memory capacity value of the target storage file is obtained, the files are sequentially stored according to the file storage task queue, the efficiency of storing the files is improved, and the possibility of disordered sequence of the stored files is reduced.
In another possible implementation manner, the method further includes:
acquiring state information of edge equipment, wherein the state information of the edge equipment comprises an online state and an offline state;
the sending the fragmented storage file to the corresponding edge device includes:
and sending the fragmented storage file to the edge equipment in an online state based on the state information of the edge equipment.
By adopting the technical scheme, the state information of the edge device can be acquired, whether the edge device is in the online state or the offline state is judged, and the fragmented storage file is sent to the edge device in the online state, so that the possibility that the storage file is sent to the edge device in the offline state and cannot be received by the edge device in the offline state, which causes file storage failure, is reduced.
In another possible implementation manner, the fragmenting the target storage file based on the scheduling information, and sending the fragmented storage file to the corresponding edge device includes:
judging whether the number of the edge devices is larger than the number of the fragments or not based on the scheduling information and the edge device information;
if the number of the edge devices is larger than the number of the fragments, acquiring the position of each edge device;
and fragmenting the target storage file and sending the fragmented storage file to the edge equipment with a short distance.
By adopting the technical scheme, the relation between the number of the edge devices and the number of the fragments can be judged, whether the number of the edge devices is larger than the number of the fragments is judged, whether the idle devices for storing the files exist or not is judged, if the number of the edge devices is larger than the number of the fragments, the idle devices for storing the files for the first time are stored, the position of each edge device is obtained, the edge devices with the closer position distances are divided into a batch, the storage files after the fragments are sent to the edge devices with the closer position distances, and the possibility of storage failure of the storage files caused by weaker communication signals among the edge devices with the farther position distances is reduced.
In another possible implementation manner, the fragmenting the target storage file based on the scheduling information, and sending the fragmented storage file to the corresponding edge device, and then further includes:
when a target storage file calling request is detected, sending the target storage file calling request to an edge node;
and receiving the data returned by the edge node, and splicing to obtain a target storage file.
By adopting the technical scheme, when the target storage file calling request is detected, the electronic equipment sends the target storage file calling request to the edge nodes, and the edge nodes call the target storage file and return the target storage file to the electronic equipment, so that the target storage file calling request does not need to be sent to each edge node in sequence, the target storage file obtaining efficiency is improved, and after the electronic equipment receives data returned by the edge nodes, the data are spliced to obtain the target storage file, and then the complete target storage file is obtained.
In another possible implementation manner, the method further includes:
determining grade information of the edge device;
judging whether the edge equipment can provide services for the outside or not based on the grade information of the edge equipment;
the sending the fragmented storage file to the corresponding edge device includes:
and sending the fragmented storage file to an edge device capable of providing service to the outside.
By adopting the technical scheme, the grade information of the edge device can be determined, whether the edge device can provide services for the outside can be judged according to the grade information of the edge device, the fragmented storage file is sent to the edge device which can provide services for the outside, the storage file is not sent to the storage file which provides services for the inside, and therefore the success rate of the storage file is increased.
In another possible implementation manner, the obtaining the target storage file further includes:
judging whether the data stored by the edge node is called;
and if the data stored by the edge node is called, deleting the data stored by the edge node.
By adopting the technical scheme, whether the data stored in the edge node can be called can be judged, and if the data stored in the edge node is called, in order to enable the edge node to release a larger storage space, the edge node of the called data is deleted, so that the larger storage space is provided.
In a second aspect, the present application provides an edge device resource integration apparatus, which adopts the following technical solution:
an edge device resource integration apparatus, comprising:
the first acquisition module is used for acquiring the occupied memory capacity value of the target storage file when the file storage request is detected;
the second acquisition module is used for acquiring the edge device information, wherein the edge device information comprises the number of edge devices and a residual storage capacity value corresponding to each edge device;
a determining module, configured to determine scheduling information based on the value of the memory capacity occupied by the target storage file and the edge device information, where the scheduling information includes the number of fragments and a storage space value corresponding to each fragment;
and the sending module is used for fragmenting the target storage file based on the scheduling information and sending the fragmented storage file to the corresponding edge device.
By adopting the technical scheme, the first acquisition module can acquire the memory capacity occupied value of the target storage file, and the second acquisition module acquires the information of the edge device, so that the first determination module determines the number of the fragments and the storage space value corresponding to each fragment, the target storage file is divided into the corresponding number of the fragments according to the number of the fragments, and the transmission module transmits the corresponding storage file to the corresponding edge device according to the storage space value corresponding to each fragment, so that the edge devices of a plurality of small storage resources are integrated into a large resource device, the resource utilization rate is improved, and a larger storage space is provided by utilizing the edge device.
In a possible implementation manner, when the first obtaining module obtains the memory capacity occupied value of the target storage file when detecting the file storage request, the first obtaining module is specifically configured to:
when a file storage request is detected, acquiring a file storage task queue;
determining the priority of a target storage file in a file storage queue;
and if the priority of the target storage file is higher than that of other storage files, acquiring the occupied memory capacity value of the target storage file.
In one possible implementation, the apparatus further includes: a third obtaining module, wherein,
and the third acquisition module is used for acquiring the state information of the edge equipment, wherein the state information of the edge equipment comprises an online state and an offline state.
In a possible implementation manner, when sending the fragmented storage file to the corresponding edge device, the sending module is specifically configured to:
and sending the fragmented storage file to the edge equipment in an online state based on the state information of the edge equipment.
In a possible implementation manner, when sending the fragmented storage file to the corresponding edge device, the sending module is specifically configured to:
judging whether the number of the edge devices is larger than the number of the fragments or not based on the scheduling information and the edge device information;
if the number of the edge devices is larger than the number of the fragments, acquiring the position of each edge device;
and fragmenting the target storage file and sending the fragmented storage file to the edge equipment with a short distance.
In one possible implementation, the apparatus further includes: a request sending module and a obtaining module, wherein,
the request sending module is used for sending a target storage file calling request to the edge node when the target storage file calling request is detected;
and the obtaining module is used for receiving the data returned by the edge nodes and splicing the data to obtain the target storage file.
In one possible implementation, the apparatus further includes: a grade information determining module and a first judging module, wherein,
the grade information determining module is used for determining the grade information of the edge equipment;
and the first judging module is used for judging whether the edge equipment can provide services for the outside or not based on the grade information of the edge equipment.
In a possible implementation manner, when sending the fragmented storage file to the corresponding edge device, the sending module is specifically configured to:
and sending the fragmented storage file to an edge device capable of providing service to the outside.
In one possible implementation, the apparatus further includes: a second determination module and a deletion module, wherein,
the second judgment module is used for judging whether the data stored in the edge node is called;
and the deleting module is used for deleting the data stored by the edge node if the data stored by the edge node is called.
In a third aspect, the present application provides an electronic device, which adopts the following technical solutions:
an electronic device, comprising:
at least one processor;
a memory;
at least one application, wherein the at least one application is stored in the memory and configured to be executed by the at least one processor, the at least one application configured to: the above edge device resource integration method is executed.
In a fourth aspect, the present application provides a computer-readable storage medium, which adopts the following technical solutions:
a computer-readable storage medium, comprising: a computer program is stored which can be loaded by a processor and which performs the above-described edge device resource integration method.
To sum up, the application comprises the following beneficial technical effects:
1. the method can obtain the occupied memory capacity value of the target storage file and the edge device information so as to determine the number of fragments and the storage space value corresponding to each fragment, divide the target storage file into the corresponding number of fragments according to the number of fragments, and send the corresponding storage file to the corresponding edge device according to the storage space value corresponding to each fragment, so that a plurality of edge devices with smaller storage resources are integrated into a larger resource device, the resource utilization rate is improved, and a larger storage space is provided by utilizing the edge device;
2. the method and the device can acquire the state information of the edge device, judge whether the edge device is in an online state or an offline state, and send the fragmented storage file to the edge device in the online state, so that the possibility that the storage file is sent to the edge device in the offline state and cannot be received by the edge device in the offline state, which causes file storage failure, is reduced.
Drawings
Fig. 1 is a schematic flowchart illustrating a resource integration method of an edge device according to an embodiment of the present disclosure;
FIG. 2 is a block diagram of an edge device resource integration apparatus according to an embodiment of the present disclosure;
fig. 3 is a schematic diagram of an electronic device according to an embodiment of the present application.
Detailed Description
The present application is described in further detail below with reference to figures 1-3.
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments in the present application without making any creative effort belong to the protection scope of the present application.
An embodiment of the present application provides an edge device resource integration method, which is executed by a management server with reference to fig. 1, and includes:
step S101, when a file storage request is detected, acquiring the occupied memory capacity value of the target storage file.
For the embodiment of the application, the management server can directly receive a file storage request sent by a user or a user side, and when the file storage request is detected, a du (disk usage) command is called to check the memory capacity occupied value of a target storage file or a target storage folder.
Step S102, edge device information is acquired.
The edge device information includes the number of edge devices and a remaining storage capacity value corresponding to each edge device.
For the embodiment of the application, the edge device comprises a router and a routing switch, and in an intelligent home, the edge device further comprises a sweeping robot, a television set top box, an intelligent sound box and other devices, and the edge device can provide an entrance for an enterprise or a service provider core network.
The management server and each edge device establish communication connection in advance to determine the number of the edge devices. The management server obtains the remaining storage capacity value corresponding to each edge device, and may obtain the storage use condition of each edge device and the remaining storage capacity value corresponding to the edge device by calling a df (disk free) command.
Specifically, the remaining storage capacity value corresponding to each edge device is obtained, and configuration information set by a user may also be obtained, where the configuration information may include an available storage capacity value of each edge device, so as to directly determine the remaining storage capacity value corresponding to each edge device; the configuration information may also include an unavailable storage capacity value of each edge device, that is, in order to ensure normal operation of the edge device itself, the storage capacity value of the edge device cannot provide file storage service, and the remaining storage capacity value corresponding to each edge device is determined by subtracting the unavailable storage capacity value from the total storage capacity value of the edge device.
Step S103, determining scheduling information based on the occupied memory capacity value of the target storage file and the edge device information.
The scheduling information includes the number of slices and a storage space value corresponding to each slice.
For the embodiment of the application, the number of the fragments in the scheduling information is less than or equal to the number of the edge devices; the storage space value corresponding to each fragment is greater than one third of the minimum remaining storage capacity value in the edge device and is less than the minimum remaining storage capacity value in the edge device.
For example, the occupied memory capacity value of the target storage file is 4G, the number of edge devices is 8, and the remaining memory capacity values of the edge devices are 600MB, 800MB, 900MB, 1G, 2G, 1.5G, 2.4G, and 3G, respectively. Wherein the minimum remaining storage capacity value in the edge device is 600 MB. The corresponding storage space value of each slice is between 200MB and 600 MB. Specifically, in general, in order to reduce the possibility of the number of slices being too large or too small, the storage space value of each slice is between 100MB and 1 GB.
And step S104, based on the scheduling information, fragmenting the target storage file and sending the fragmented storage file to the corresponding edge device.
For the embodiment of the application, the target storage file is divided into the corresponding number of fragments based on the number of fragments in the scheduling information; and determining the storage value of the storage space allocated to each fragment based on the storage space value corresponding to each fragment in the scheduling information.
Further, the fragment storage includes uniform fragment storage and non-uniform fragment storage, and each edge device may store one fragment of the target storage file or multiple fragments of the target storage file according to the occupied memory capacity value of the target file and the edge device information.
Furthermore, because different edge devices have systems such as android, IOS, Windows, Linux, openWRT and the like, the edge device resource integration method provided by the application adopts a cross-platform mode and uses a set of codes to support various systems of the edge devices. Meanwhile, the method for integrating the edge device resources is suitable for debugging different systems, so that the research and development cost and the maintenance cost can be effectively saved.
It should be noted that fig. 1 is only one possible execution sequence, in this embodiment, step S101 may be executed before step S102, step S101 may be executed simultaneously with step S102, and step S101 may also be executed after step S102, which is not limited in this embodiment.
The embodiment of the application provides a method for integrating edge device resources, which can obtain a memory capacity occupied value of a target storage file and edge device information, so as to determine the number of fragments and a storage space value corresponding to each fragment, divide the target storage file into the corresponding number of fragments according to the number of fragments, and send the corresponding storage file to the corresponding edge device according to the storage space value corresponding to each fragment, thereby integrating a plurality of edge devices with smaller storage resources into larger resource devices, improving the resource utilization rate, and further providing larger storage space by using the edge devices.
In a possible implementation manner of the embodiment of the present application, the step S101 may specifically include a step S1011 (not shown), a step S1012 (not shown), and a step S1013 (not shown), wherein,
in step S1011, when the file storage request is detected, the file storage task queue is acquired.
For the embodiment of the present application, the file storage task queue may include a plurality of files to be stored, and may also include a plurality of fragments of one file to be stored. The management server receives the file storage request, a service program is deployed on the management server to receive the network request, the network request can be a file storage request or other requests, and the server program of the management server stores the network request into a file storage task queue.
Specifically, the file storage request may include an enqueue request and a dequeue request, and when the file storage request is an enqueue request, the target storage file request is stored in the file storage task queue; and when the file storage request is a dequeue request, namely the target storage file is completely stored, deleting the target storage file request from the file storage task queue.
Step S1012 determines the priority of the target storage file in the file storage queue.
For the embodiment of the application, the management server allocates the corresponding priority to each file in the file storage queue according to the preset rule. Generally, the priority of a file is assigned according to the time sequence corresponding to the file storage request, that is, the earlier the file storage request corresponding to the file is, the higher the priority of the file is. And determining the corresponding priority of the target storage file according to the importance degree of the target storage file.
In step S1013, if the priority of the target storage file is higher than that of other storage files, the occupied memory capacity value of the target storage file is obtained.
For the embodiment of the application, if the priority of the target storage file is higher than that of other storage files, and the management server preferentially stores the target storage file, the occupied memory capacity value of the target storage file is obtained.
In a possible implementation manner of the embodiment of the present application, the method further includes a step Sa (not shown in the figure), where the step Sa (not shown in the figure) may be performed before or after any step before the step S104, where,
and step Sa, acquiring the state information of the edge device.
The state information of the edge device comprises an online state and an offline state.
For the embodiment of the application, the edge devices are deployed with service programs, the service programs can monitor the state information of each edge device, and the state information of the edge devices includes uplink bandwidth, online state and offline state. Specifically, in order to obtain the state information of the edge in time, the service program may monitor the state information of the edge in real time, and send the state information of the edge device to the management server every 5 to 10 seconds, or send the state information of the edge device to the management server when it is monitored that the state information of the edge device changes.
A possible implementation manner of the embodiment of the present application, the sending the fragmented storage file to the corresponding edge device in step S104 may specifically include step S1041 (not shown in the figure), where,
step S1041, sending the fragmented storage file to the edge device in the online state based on the state information of the edge device.
For the embodiment of the application, the online edge device can store files, while the offline edge device cannot establish communication connection with the management server and cannot receive the stored files sent by the management server. The management server marks the edge device in the online state as a usable device based on the state information of the edge, and sends the storage device after fragmentation to the edge device in the online state. The offline-state edge device may have faults such as insufficient power and the like, and only sends the fragmented storage file to the online-state edge device, so as to reduce the possibility that the offline-state device cannot receive the fragmented storage file to slow down the file storage progress.
Further, after the management server sends the fragmented storage file to the edge device in the online state, the state information of the edge device is monitored in real time. And if the state information of the edge device is converted from the online state to the offline state, sending the fragmented storage file to other standby edge devices in the online state.
Further, when the service program monitors that the offline edge device is switched to the online state after the offline edge device is fully charged or the fault repair is completed, the management server reestablishes the communication connection with the edge device and sends the fragmented storage file to the online edge device.
In a possible implementation manner of the embodiment of the application, the step S104 may specifically include the step S104a (not shown), the step S104b (not shown), and the step S104c (not shown), wherein the step S104a (not shown) may be executed before the step S1041 (not shown), may also be executed after the step S1041 (not shown), or may also be executed simultaneously with the step S1041 (not shown), wherein,
step S104a, based on the scheduling information and the edge device information, determines whether the number of edge devices is greater than the number of slices.
For the embodiment of the application, the number of the edge devices may be equal to or greater than the number of the fragments, and if the number of the edge devices is equal to the number of the fragments, the fragmented storage files are respectively sent to the corresponding edge devices; if the number of the edge devices is larger than the number of the fragments, the existence of the idle edge devices is indicated.
Step S104b, if the number of edge devices is greater than the number of slices, obtain the location of each edge device.
For the embodiment of the application, the position of each edge device is obtained, and a positioning unit can be installed on each edge device in advance to determine the position of each edge device; the management server can also send a position request to each edge device, and determine the position of each edge device according to the position returned by each edge device or the time length of position information returned by each edge device.
Step S104c, the target storage file is fragmented, and the fragmented storage file is sent to the edge device with a short distance.
For the embodiment of the application, based on the position of each edge device, the edge devices are batched according to the positions, the edge devices with the closer positions are divided into the same batch, and the fragmented storage file is sent to the same batch of edge devices, so that the possibility that the storage file fails due to the fact that the edge devices are far away and communication connection is unstable is reduced.
In a possible implementation manner of the embodiment of the present application, step S104 further includes step S105 (not shown in the figure) and step S106 (not shown in the figure), wherein,
step S105, when the target storage file calling request is detected, the target storage file calling request is sent to the edge node.
For the embodiments of the present application, an edge node is a logical abstraction of the basic commonality capabilities of edge side multiple product forms, such as edge gateways, edge controllers, edge servers, and edge devices.
For one edge device, the number of edge nodes is multiple, when a target storage file calling request is detected, the management server randomly selects one edge node as a representative node, and the representative node can inquire and call the target storage file.
When the management server detects a target storage file retrieval request, the complete resource can be obtained as long as any edge node is connected. A representative node in the edge nodes calls a target storage file, and if the target storage file is complete, the target storage file is returned to the management server; if the target storage file is not complete, the representative node sends a target storage file calling request to the management node, the management node inquires the edge node where the target storage file is stored, and after the management node inquires the edge node, the node information where the target storage file is stored is returned to the representative node.
And step S106, receiving the data returned by the edge nodes, and splicing to obtain a target storage file.
For the embodiment of the application, after the edge node queries the target storage file, the fragment data of the storage file is acquired, and the management server splices the fragment data of the same storage file to obtain the complete target storage file. Specifically, the fragment data of the storage file may carry an identifier of the storage file to determine to which storage file each fragment data belongs, so that the fragment data of the same storage file can be spliced conveniently.
In a possible implementation manner of the embodiment of the present application, step S106 (not shown) is followed by step S107 (not shown) and step S108 (not shown), wherein,
step S107, it is determined whether the data stored in the edge node is called.
In step S108, if the data stored in the edge node is called, the data stored in the edge node is deleted.
For the embodiment of the application, because the storage capacity value of the edge device is limited, part of data in the edge node is deleted in time, and the storage capacity value of the edge device can be released, so that the edge device can provide better service.
The data stored in the edge node may need to be retrieved or may need to be stored in the edge node all the time. For the data needing to be called, after the data is called, the edge node does not need to store the data any more, and the management server deletes the data to release the storage capacity value of the edge device.
Further, if a part of the storage files in the edge node need to be stored in the edge node, such files are not deleted. When the remaining storage capacity value of the edge device is obtained, the occupied capacity value of such storage file is subtracted from the total storage capacity value of the edge device.
Further, after the stored file data is cleaned or saved, the service program of the edge device synchronizes the latest state to the management server, so that the management server can know the state information of the edge device in time.
In a possible implementation manner of the embodiment of the present application, the method further includes: step Sb (not shown) and step Sc (not shown), wherein the steps Sb (not shown) and Sc (not shown) can be performed after step S102, or can be performed after step S103, wherein,
and step Sb, determining the grade information of the edge equipment.
For the embodiment of the application, the management server determines the level information corresponding to the edge device according to the performance of the edge device. Determining the grade information of the edge device: the management server sends a configuration request to the edge device and receives configuration information returned by the edge device, wherein the configuration information comprises the type of the edge device, the value of the residual storage capacity of the edge device and the like.
And step Sc, judging whether the edge equipment can provide services for the outside or not based on the grade information of the edge equipment.
For the embodiment of the application, the grade information of the edge device is preliminarily determined according to the type of the edge device. Specifically, the equipment such as the floor sweeping robot and the intelligent sound box is in the third grade, the equipment such as the television set top box is in the second grade, and the equipment such as the router and the routing switch is in the first grade. And if the residual storage capacity value of the edge device is smaller, the corresponding grade of the device is also smaller according to the residual storage capacity value of the edge device.
In a possible implementation manner of the embodiment of the present application, the step S104 of sending the fragmented storage file to the corresponding edge device may specifically include a step S104d (not shown in the figure), where,
step S104d, the fragmented storage file is sent to an edge device that can provide services to the outside.
For the embodiment of the application, the edge devices are divided into two types which can provide services to the inside and can provide services to the outside according to the grade information of the edge devices.
The above embodiment describes a method for integrating edge device resources from the perspective of a method flow, and the following embodiment describes an apparatus for integrating edge device resources from the perspective of a virtual module or a virtual unit, and refer to fig. 2, which will be described in detail in the following embodiment.
The edge device resource integration apparatus 100 may specifically include: a first obtaining module 1001, a second obtaining module 1002, a determining module 1003 and a sending module 1004, wherein:
a first obtaining module 1001, configured to obtain an occupied memory capacity value of a target storage file when a file storage request is detected;
a second obtaining module 1002, configured to obtain edge device information, where the edge device information includes the number of edge devices and a remaining storage capacity value corresponding to each edge device;
a determining module 1003, configured to determine scheduling information based on the memory capacity occupied by the target storage file and the edge device information, where the scheduling information includes the number of segments and a storage space value corresponding to each segment;
a sending module 1004, configured to fragment the target storage file based on the scheduling information, and send the fragmented storage file to the corresponding edge device.
In a possible implementation manner of this embodiment, when detecting a file storage request, the first obtaining module 1001 is specifically configured to, when obtaining a value of memory capacity occupied by a target storage file:
when a file storage request is detected, acquiring a file storage task queue;
determining the priority of a target storage file in a file storage queue;
and if the priority of the target storage file is higher than that of other storage files, acquiring the occupied memory capacity value of the target storage file.
In a possible implementation manner of the embodiment of the present application, the apparatus 100 further includes: a third obtaining module, wherein,
and the third acquisition module is used for acquiring the state information of the edge equipment, wherein the state information of the edge equipment comprises an online state and an offline state.
In a possible implementation manner of the embodiment of the present application, when the sending module 1004 sends the fragmented storage file to the corresponding edge device, the sending module is specifically configured to:
and sending the fragmented storage file to the edge device in the online state based on the state information of the edge device.
In a possible implementation manner of the embodiment of the present application, when the sending module 1004 sends the fragmented storage file to the corresponding edge device, the sending module is specifically configured to:
judging whether the number of the edge devices is larger than the number of the fragments or not based on the scheduling information and the edge device information;
if the number of the edge devices is larger than the number of the fragments, acquiring the position of each edge device;
and fragmenting the target storage file and sending the fragmented storage file to the edge equipment with a short distance.
In a possible implementation manner of the embodiment of the present application, the apparatus 100 further includes: a request sending module and a obtaining module, wherein,
the request sending module is used for sending a target storage file calling request to the edge node when the target storage file calling request is detected;
and the obtaining module is used for receiving the data returned by the edge nodes and splicing the data to obtain the target storage file.
In a possible implementation manner of the embodiment of the present application, the apparatus 100 further includes: a grade information determining module and a first judging module, wherein,
the grade information determining module is used for determining the grade information of the edge equipment;
and the first judging module judges whether the edge equipment can provide services for the outside or not based on the grade information of the edge equipment.
In a possible implementation manner of the embodiment of the present application, when the sending module 1004 sends the fragmented storage file to the corresponding edge device, the sending module is specifically configured to:
and sending the fragmented storage file to an edge device capable of providing service to the outside.
In a possible implementation manner of the embodiment of the present application, the apparatus 100 further includes: a second determination module and a deletion module, wherein,
the second judgment module is used for judging whether the data stored in the edge node is called;
and the deleting module is used for deleting the data stored by the edge node if the data stored by the edge node is called.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
The embodiment of the present application also introduces an electronic device from the perspective of a physical apparatus, as shown in fig. 3, an electronic device 1100 shown in fig. 3 includes: a processor 1101 and a memory 1103. Wherein the processor 1101 is coupled to the memory 1103, such as by a bus 1102. Optionally, the electronic device 1100 may also include a transceiver 1104. It should be noted that the transceiver 1104 is not limited to one in practical applications, and the structure of the electronic device 1100 is not limited to the embodiment of the present application.
The Processor 1101 may be a CPU (Central Processing Unit), a general purpose Processor, a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array) or other Programmable logic device, a transistor logic device, a hardware component, or any combination thereof. Which may implement or perform the various illustrative logical blocks, modules, and circuits described in connection with the disclosure. The processor 1101 may also be a combination of computing functions, e.g., comprising one or more microprocessors, DSPs and microprocessors, and the like.
Bus 1102 may include a path that transfers information between the above components. The bus 1102 may be a PCI (Peripheral Component Interconnect) bus, an EISA (Extended Industry Standard Architecture) bus, or the like. The bus 1102 may be divided into an address bus, a data bus, a control bus, and the like. For ease of illustration, only one thick line is shown in FIG. 3, but this does not mean only one bus or one type of bus.
The Memory 1103 may be a ROM (Read Only Memory) or other type of static storage device that can store static information and instructions, a RAM (Random Access Memory) or other type of dynamic storage device that can store information and instructions, an EEPROM (Electrically Erasable Programmable Read Only Memory), a CD-ROM (Compact Disc Read Only Memory) or other optical Disc storage, optical Disc storage (including Compact Disc, laser Disc, optical Disc, digital versatile Disc, blu-ray Disc, etc.), a magnetic disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer, but is not limited to these.
The memory 1103 is used for storing application program codes for executing the present application, and the execution is controlled by the processor 1101. The processor 1101 is configured to execute application code stored in the memory 1103 to implement the content shown in the foregoing method embodiments.
It should be understood that, although the steps in the flowcharts of the figures are shown in order as indicated by the arrows, the steps are not necessarily performed in order as indicated by the arrows. The steps are not performed in the exact order shown and may be performed in other orders unless explicitly stated herein. Moreover, at least a portion of the steps in the flow chart of the figure may include multiple sub-steps or multiple stages, which are not necessarily performed at the same time, but may be performed at different times, which are not necessarily performed in sequence, but may be performed alternately or alternately with other steps or at least a portion of the sub-steps or stages of other steps.
The foregoing is only a partial embodiment of the present application, and it should be noted that, for those skilled in the art, various modifications and decorations can be made without departing from the principle of the present application, and these modifications and decorations should also be regarded as the protection scope of the present application.

Claims (10)

1. An edge device resource integration method, comprising:
when a file storage request is detected, acquiring an occupied memory capacity value of a target storage file;
acquiring edge device information, wherein the edge device information comprises the number of edge devices and a residual storage capacity value corresponding to each edge device;
determining scheduling information based on the memory capacity value occupied by the target storage file and the edge device information, wherein the scheduling information comprises the number of fragments and a storage space value corresponding to each fragment;
and based on the scheduling information, fragmenting the target storage file and sending the fragmented storage file to the corresponding edge device.
2. The method for integrating the resources of the edge device according to claim 1, wherein the obtaining the value of the occupied memory capacity of the target storage file when the file storage request is detected comprises:
when a file storage request is detected, acquiring a file storage task queue;
determining the priority of a target storage file in a file storage queue;
and if the priority of the target storage file is higher than that of other storage files, acquiring the occupied memory capacity value of the target storage file.
3. The edge device resource integration method of claim 1, further comprising:
acquiring state information of edge equipment, wherein the state information of the edge equipment comprises an online state and an offline state;
the sending the fragmented storage file to the corresponding edge device includes:
and sending the fragmented storage file to the edge equipment in an online state based on the state information of the edge equipment.
4. The method of claim 1, wherein the fragmenting a target storage file based on the scheduling information and sending the fragmented storage file to a corresponding edge device comprises:
judging whether the number of the edge devices is larger than the number of the fragments or not based on the scheduling information and the edge device information;
if the number of the edge devices is larger than the number of the fragments, acquiring the position of each edge device;
and fragmenting the target storage file and sending the fragmented storage file to the edge equipment with a shorter position distance.
5. The method for edge device resource integration according to claim 1, wherein the fragmenting a target storage file based on the scheduling information and sending the fragmented storage file to a corresponding edge device further comprises:
when a target storage file calling request is detected, sending the target storage file calling request to an edge node;
and receiving the data returned by the edge node, and splicing to obtain a target storage file.
6. The edge device resource integration method of claim 1, further comprising:
determining grade information of the edge device;
judging whether the edge equipment can provide service for the outside or not based on the grade information of the edge equipment;
the sending the fragmented storage file to the corresponding edge device includes:
and sending the fragmented storage file to an edge device capable of providing service to the outside.
7. The edge device resource integration method of claim 5, wherein obtaining the target storage file further comprises:
judging whether the data stored by the edge node is called;
and if the data stored by the edge node is called, deleting the data stored by the edge node.
8. An edge device resource integration apparatus, comprising:
the first acquisition module is used for acquiring the occupied memory capacity value of the target storage file when the file storage request is detected;
the second acquisition module is used for acquiring the edge device information, wherein the edge device information comprises the number of edge devices and a residual storage capacity value corresponding to each edge device;
a determining module, configured to determine scheduling information based on the value of the memory capacity occupied by the target storage file and the edge device information, where the scheduling information includes the number of fragments and a storage space value corresponding to each fragment;
and the sending module is used for fragmenting the target storage file based on the scheduling information and sending the fragmented storage file to the corresponding edge device.
9. An electronic device, comprising:
at least one processor;
a memory;
at least one application, wherein the at least one application is stored in the memory and configured to be executed by the at least one processor, the at least one application configured to: performing the edge device resource integration method of any one of claims 1 to 7.
10. A computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed in a computer, the computer is caused to execute the edge device resource integration method according to any one of claims 1 to 7.
CN202210399025.8A 2022-04-16 2022-04-16 Edge device resource integration method and device, electronic device and storage medium Pending CN114741370A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210399025.8A CN114741370A (en) 2022-04-16 2022-04-16 Edge device resource integration method and device, electronic device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210399025.8A CN114741370A (en) 2022-04-16 2022-04-16 Edge device resource integration method and device, electronic device and storage medium

Publications (1)

Publication Number Publication Date
CN114741370A true CN114741370A (en) 2022-07-12

Family

ID=82281741

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210399025.8A Pending CN114741370A (en) 2022-04-16 2022-04-16 Edge device resource integration method and device, electronic device and storage medium

Country Status (1)

Country Link
CN (1) CN114741370A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117785816A (en) * 2024-01-05 2024-03-29 柏域信息科技(上海)有限公司 Method, device, equipment and storage medium for file fragment storage

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109379448A (en) * 2018-12-27 2019-02-22 深圳市网心科技有限公司 A kind of file distribution dispositions method, device, electronic equipment and storage medium
CN110620828A (en) * 2019-10-31 2019-12-27 北京奇艺世纪科技有限公司 File pushing method, system, device, electronic equipment and medium
CN112311820A (en) * 2019-07-26 2021-02-02 腾讯科技(深圳)有限公司 Edge device scheduling method, connection method, device and edge device
CN113568884A (en) * 2021-09-26 2021-10-29 武汉四通信息服务有限公司 File management method and device, electronic equipment and storage medium
CN113986828A (en) * 2021-10-28 2022-01-28 浙江立元科技有限公司 Method and device for storing mass files, electronic equipment and storage medium
WO2022073194A1 (en) * 2020-10-09 2022-04-14 Citrix Systems, Inc. Data file replication to edge servers

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109379448A (en) * 2018-12-27 2019-02-22 深圳市网心科技有限公司 A kind of file distribution dispositions method, device, electronic equipment and storage medium
CN112311820A (en) * 2019-07-26 2021-02-02 腾讯科技(深圳)有限公司 Edge device scheduling method, connection method, device and edge device
CN110620828A (en) * 2019-10-31 2019-12-27 北京奇艺世纪科技有限公司 File pushing method, system, device, electronic equipment and medium
WO2022073194A1 (en) * 2020-10-09 2022-04-14 Citrix Systems, Inc. Data file replication to edge servers
CN113568884A (en) * 2021-09-26 2021-10-29 武汉四通信息服务有限公司 File management method and device, electronic equipment and storage medium
CN113986828A (en) * 2021-10-28 2022-01-28 浙江立元科技有限公司 Method and device for storing mass files, electronic equipment and storage medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117785816A (en) * 2024-01-05 2024-03-29 柏域信息科技(上海)有限公司 Method, device, equipment and storage medium for file fragment storage

Similar Documents

Publication Publication Date Title
US11729260B2 (en) Internet-of-things resource access system and method
CN107872402B (en) Global flow scheduling method and device and electronic equipment
CN111459750A (en) Private cloud monitoring method and device based on non-flat network, computer equipment and storage medium
EP3873066A1 (en) Method for managing resource state information, and resource downloading system
CN109547524B (en) User behavior storage method, device, equipment and storage medium based on Internet of things
US11102289B2 (en) Method for managing resource state information and system for downloading resource
CN106034137A (en) Intelligent scheduling method for distributed system, and distributed service system
CN111562889B (en) Data processing method, device, system and storage medium
KR20130065019A (en) System and method of resource management of centralized base station in mobile communication network
CN110830565A (en) Resource downloading method, device, system, electronic equipment and storage medium
CN113965519A (en) Flow control method, cluster resource guarantee method, equipment and storage medium
CN112698952A (en) Unified management method and device for computing resources, computer equipment and storage medium
CN112416594A (en) Micro-service distribution method, electronic equipment and computer storage medium
CN114741370A (en) Edge device resource integration method and device, electronic device and storage medium
CN115640169A (en) Method, system, device and storage medium for ensuring that a master cluster stops providing services
CN113965576B (en) Container-based big data acquisition method, device, storage medium and equipment
CN114296909A (en) Automatic node capacity expansion and reduction method and system according to kubernets event
CN105743696A (en) Cloud computing platform management method
CN114697266A (en) Virtual machine access method, terminal and storage medium
CN116860461A (en) Resource scheduling method, equipment and storage medium of K8s cluster
CN110798492B (en) Data storage method and device and data processing system
CN115412609B (en) Service processing method, device, server and storage medium
CN117014492A (en) Cloud desktop dynamic migration method, device, equipment and storage medium
CN110581873B (en) Cross-cluster redirection method and monitoring server
CN107483637B (en) NFS-based client link management method and device

Legal Events

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