Application storage method, device and cloud server
By distinguishing application types and storing them on different hard disk servers, the problems of waste of resources and poor user experience are solved, and the rational utilization of resources and the maximum satisfaction of user needs are achieved.
Patent Information
- Application Number
- CN202010931248.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-09-07
- Publication Date
- 2025-07-18
- Estimated Expiration
- 2040-09-07
AI Technical Summary
In the prior art, high-end and low-end hard disk servers cannot be used reasonably, resulting in waste of resources or poor user experience.
By obtaining the application's hard disk server properties, generating a network map, and monitoring the hard disk data reading amount of the initial running process, comparing the read amount with the threshold, determining the application type, and then moving the small data volume application to the low-speed hard disk server, and the large data volume application remains on the high-speed hard disk server.
It realizes rational use of resources, improves user experience and reduces hardware costs.
Smart Images

Figure CN112269653B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field of application program storage, and particularly to an application program storage method, apparatus, and cloud server. Background Art
[0002] Currently, in virtualization, all application programs are run without distinction, which may cause resource waste or poor user experience. For example, if all application programs are run on a server with high - configuration hardware, such as a server with high - configuration hardware like CPU, GPU, etc., although the running speed is fast and the user experience is good, it also leads to waste of server hardware resources and increases the hardware cost; conversely, if all application programs are run on a server with low - configuration hardware, although the hardware cost is reduced, due to the slow running speed, the program startup speed is slow and the waiting time is long, so the user experience is poor.
[0003] Therefore, the present disclosure provides a method, apparatus, and cloud server for storing application programs separately to rationally utilize high - configuration and low - configuration hard - disk servers. Summary of the Invention
[0004] The purpose of the present disclosure is to overcome the deficiencies of the prior art and provide an application program storage method, apparatus, and cloud server. The application program storage method can solve the problem in the prior art that high - configuration and low - configuration hard - disk servers cannot be rationally utilized.
[0005] According to a first aspect of an embodiment of the present disclosure, an application program storage method is provided. The method includes:
[0006] Obtain the attributes of the hard - disk server where the current application program is stored; wherein, the attributes of the hard - disk server where the application program is stored include the IP address of the storage hard - disk server of the application program, the storage path, and whether it is the first run.
[0007] Generate a network mapping on the running server of the current application program according to the IP address and storage path of the storage hard - disk server of the current application program; determine whether to monitor the hard - disk data read volume of the process corresponding to the current application program within a preset time according to whether the current application program is the first run.
[0008] If the current application program is the first run, monitor the hard - disk data read volume of the process corresponding to the current application program within a preset time.
[0009] Compare the hard - disk data read volume of the process corresponding to the current application program within a preset time with a preset threshold of the hard - disk data read volume of the application program to determine the type of the current application program.
[0010] Perform corresponding operations according to the type of the current application.
[0011] In one embodiment, comparing the amount of hard disk data read by the process corresponding to the current application within a preset time with a preset threshold of the amount of hard disk data read by the application to determine the type of the current application includes:
[0012] If the amount of hard disk data read by the process corresponding to the current application within a preset time is less than the preset threshold of the amount of hard disk data read by the application, determine that the current application is a small data volume application;
[0013] The performing corresponding operations according to the type of the current application includes:
[0014] According to a preset rule, move the small data volume application from the high-speed hard disk server to the low-speed hard disk server.
[0015] In one embodiment, the moving the small data volume application from the high-speed hard disk server to the low-speed hard disk server according to a preset rule includes:
[0016] Copy the program file of the small data volume application from the high-speed hard disk server to the low-speed hard disk server;
[0017] Lock the application location record table in the application record table, and update the storage hard disk server IP address and storage path of the small data volume application in the application location record table to the parameters of the low-speed hard disk server;
[0018] Release the application location record table in the application record table, and delete the program file of the small data volume application on the high-speed hard disk server.
[0019] In one embodiment, comparing the amount of hard disk data read by the process corresponding to the current application within a preset time with a preset threshold of the amount of hard disk data read by the application to determine the type of the current application includes:
[0020] If the amount of hard disk data read by the process corresponding to the current application within a preset time is not less than the preset threshold of the amount of hard disk data read by the application, determine that the current application is a large data volume application;
[0021] The performing corresponding operations according to the type of the current application includes:
[0022] Run the large data volume application on the high-speed hard disk server.
[0023] In one embodiment, the attributes of the hard disk server where the application is stored are stored in the application record table of the system.
[0024] According to a second aspect of the embodiments of the present disclosure, an application storage device is provided, and the device includes:
[0025] An acquisition module that acquires the attributes of the hard disk server where the current application is stored; the attributes of the hard disk server where the application is stored are stored in the application record table of the system, and include the IP address of the storage hard disk server of the application, the storage path, and whether it is the first run;
[0026] A processing module that generates a network mapping on the running server of the current application according to the IP address of the storage hard disk server and the storage path of the current application; and determines whether to monitor the hard disk data read volume of the process corresponding to the current application within a preset time according to whether the current application is the first run;
[0027] A monitoring module that, if the current application is the first run, monitors the hard disk data read volume of the process corresponding to the current application within a preset time;
[0028] A comparison module that compares the hard disk data read volume of the process corresponding to the current application within a preset time with a preset threshold of the hard disk data read volume of the application to determine the type of the current application;
[0029] An operation module that performs corresponding operations according to the type of the current application.
[0030] In one embodiment, the processing module includes:
[0031] A generation sub-module that generates a network mapping on the running server of the current application according to the IP address of the storage hard disk server and the storage path of the current application;
[0032] A determination sub-module that determines whether to monitor the hard disk data read volume of the process corresponding to the current application within a preset time according to whether the current application is the first run.
[0033] In one embodiment, the attributes of the hard disk server where the application is stored are stored in the application record table of the system.
[0034] According to a third aspect of the embodiments of the present disclosure, a cloud server is provided, and the cloud server includes:
[0035] A storage control module, and a storage resource pool connected to the storage control module;
[0036] The storage control module is used to obtain the attributes of the hard disk server stored by the current application; the attributes of the hard disk server stored by the application are stored in the application record table of the system, including the IP address of the storage hard disk server of the application, the storage path, and whether it is the first run.
[0037] The storage control module is also used to generate a network mapping on the running server of the current application according to the IP address and storage path of the storage hard disk server of the current application; determine whether to monitor the hard disk data read volume of the process corresponding to the current application within a preset time according to whether the current application is the first run.
[0038] If the current application is the first run, the storage control module is used to monitor the hard disk data read volume of the process corresponding to the current application within a preset time.
[0039] The storage control module is also used to compare the hard disk data read volume of the process corresponding to the current application within a preset time with the preset threshold of the hard disk data read volume of the application to determine the type of the current application.
[0040] The storage control module is also used to determine the storage location of the current application program in the storage resource pool according to the type of the current application program.
[0041] In one embodiment, the storage resource pool includes a high-speed hard disk server and a low-speed hard disk server.
[0042] An application program storage method provided by the present disclosure can store different types of application programs on hard disk servers with different resource configurations according to different characteristics of the application programs, thereby ensuring the reasonable utilization of resources and maximizing the user's usage requirements. Brief Description of the Drawings
[0043] The drawings herein are incorporated into the specification and form a part of the specification, showing embodiments consistent with the present disclosure and used together with the specification to explain the principles of the present disclosure.
[0044] Figure 1 It is a flowchart of an application program storage method provided by an embodiment of the present disclosure.
[0045] Figure 2 It is a flowchart of an application program storage method provided by an embodiment of the present disclosure.
[0046] Figure 3 It is an architecture diagram of an application program storage device provided by an embodiment of the present disclosure.
[0047] Figure 4 It is an architecture diagram of an application program storage device provided by an embodiment of the present disclosure.
[0048] Figure 5 It is a schematic diagram of a cloud server provided by an embodiment of the present disclosure. Detailed implementation manners
[0049] Here, exemplary embodiments will be described in detail, and examples thereof are shown in the drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The implementation manners described in the following exemplary embodiments do not represent all implementation manners consistent with the present disclosure. On the contrary, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.
[0050] When an application starts, it first needs to read the required program files from the hard disk into the memory, and the processing speed of this process depends on the type of the hard disk. The reading speed of a high-speed hard disk server is higher than that of a low-speed hard disk server. However, the cost of the corresponding high-speed hard disk server is greater than that of the low-speed hard disk server.
[0051] For the above reasons, in order to achieve the purpose of reasonable utilization and allocation of resources, the main principle of the present disclosure is:
[0052] For all applications, the storage location can be distinguished according to the size of the application (that is, the size of the data to be read to start the application). For a smaller application, since less data needs to be read, a low-speed hard disk server can meet the user experience, so the smaller application can be stored on the low-speed hard disk server. For a larger application, since more data needs to be read, if a low-speed hard disk server is used, it will cause longer data reading time and affect the user experience, so a high-speed hard disk server is used for storage to improve the user experience. In this way, a balance can also be achieved between the user experience and the hardware cost.
[0053] Figure 1 It is a flowchart of a method for storing an application provided by an embodiment of the present disclosure. As Figure 1 shown, the method includes:
[0054] Step 101, obtain the attributes of the hard disk server where the current application is stored; wherein, the attributes of the hard disk server where the application is stored include the IP address of the storage hard disk server of the application, the storage path, and whether it is the first run;
[0055] In one embodiment, the attributes of the hard disk server where the application is stored are stored in the application record table of the system.
[0056] It should be noted that all application programs are default stored on the high-speed hard disk server when they are initially stored. After the initial storage, the system will record four attributes in the application program record table of the system, namely the name of the current application program, the IP of the hard disk server where it is stored, the storage path of the application program, and whether it has been run.
[0057] Step 102: Generate a network mapping on the running server of the current application program according to the IP address and storage path of the storage hard disk server of the current application program; Determine whether to monitor the hard disk data read volume of the process corresponding to the current application program within a preset time according to whether the current application program is running for the first time.
[0058] Step 103: If the current application program is running for the first time, monitor the hard disk data read volume of the process corresponding to the current application program within a preset time.
[0059] Exemplarily, if the current application program is running for the first time, monitor the hard disk data read volume of the process corresponding to the current application program within 1 minute.
[0060] In this step, it is assumed that all application programs will start up within one minute when using the high-speed hard disk server.
[0061] Step 104: Compare the hard disk data read volume of the process corresponding to the current application program within a preset time with the preset threshold of the hard disk data read volume of the application program to determine the type of the current application program.
[0062] Step 105: Perform corresponding operations according to the type of the current application program.
[0063] In one embodiment, the comparing the hard disk data read volume of the process corresponding to the current application program within a preset time with the preset threshold of the hard disk data read volume of the application program to determine the type of the current application program includes:
[0064] If the hard disk data read volume of the process corresponding to the current application program within a preset time is less than the preset threshold of the hard disk data read volume of the application program, determine that the current application program is a small data volume application program.
[0065] The performing corresponding operations according to the type of the current application program includes:
[0066] According to the preset rules, move the small data volume application program from the high-speed hard disk server to the low-speed hard disk server.
[0067] In one embodiment, as Figure 2 shown, the moving the small data volume application program from the high-speed hard disk server to the low-speed hard disk server according to the preset rules includes:
[0068] Step 201: Copy the program file of the small data volume application from the high-speed hard disk server to the low-speed hard disk server;
[0069] Step 202: Lock the application location record table in the application record table, and update the storage hard disk server IP address and storage path of the small data volume application in the application location record table to the parameters of the low-speed hard disk server;
[0070] Step 203: Release the application location record table in the application record table, and delete the program file of the small data volume application on the high-speed hard disk server.
[0071] In this embodiment, if it is determined through comparison in step 104 that the application is a small data volume application, "hot migration" is required, that is, the current application is migrated from the high-speed hard disk server to the low-speed hard disk server in the way of "hot migration".
[0072] The specific implementation of hot migration is as follows: For example, if application A is determined to be a small data volume application and it needs to be migrated from the high-speed hard disk to the low-speed hard disk, then the program file of application A can be first copied from the high-speed hard disk to the low-speed hard disk. After the copying is completed, the application location record table in the application record table is temporarily locked. After the table is locked, the query operation is blocked and does not return results. The storage hard disk server IP and application storage path of application A in the application location record table are updated and modified to the actual parameters of the low-speed hard disk server. Then the lock of the application location record table is released. After the lock is released, real-time query can be performed. Finally, the program file of application A on the high-speed hard disk is deleted.
[0073] In one embodiment, comparing the hard disk data read volume of the process corresponding to the current application within a preset time with the preset threshold of the hard disk data read volume of the application to determine the type of the current application includes:
[0074] If the hard disk data read volume of the process corresponding to the current application within a preset time is not less than the preset threshold of the hard disk data read volume of the application, it is determined that the current application is a large data volume application;
[0075] Performing corresponding operations according to the type of the current application includes:
[0076] Run the large data volume application on the high-speed hard disk server.
[0077] In this embodiment, if it is determined through comparison in step 104 that the application is a large data volume application, the file of the application does not need to be migrated anymore because it is default in the present disclosure that the large data volume application is stored on the high-speed hard disk server.
[0078] Figure 3 The architecture diagram of an application storage device provided by an embodiment of the present disclosure. As Figure 3 shown, the device includes:
[0079] An acquisition module 301, a processing module 302, a monitoring module 303, a comparison module 304, and an operation module 305; wherein, the acquisition module 301 is used to acquire the attributes of the hard disk server where the current application is stored; the attributes of the hard disk server where the application is stored are stored in the application record table of the system, and it includes the IP address of the storage hard disk server of the application, the storage path, and whether it is the first run; the processing module 302 is used to generate a network mapping on the running server of the current application according to the IP address of the storage hard disk server and the storage path of the current application; and determine whether to monitor the hard disk data reading volume of the process corresponding to the current application within a preset time according to whether the current application is the first run; the monitoring module 303 is used to monitor the hard disk data reading volume of the process corresponding to the current application within a preset time when the current application is the first run; the comparison module 304 is used to compare the hard disk data reading volume of the process corresponding to the current application within a preset time with the preset threshold of the hard disk data reading volume of the application to determine the type of the current application; the operation module 305 is used to perform corresponding operations according to the type of the current application.
[0080] Figure 4 The architecture diagram of an application storage device provided by an embodiment of the present disclosure. As Figure 4 shown, the device includes: an acquisition module 401, a processing module 402, a monitoring module 403, a comparison module 404, and an operation module 405; wherein, the processing module 402 includes a generation sub-module 4021 and a determination sub-module 4022; wherein, the generation sub-module 4021 is used to generate a network mapping on the running server of the current application according to the IP address of the storage hard disk server and the storage path of the current application; the determination sub-module 4022 is used to determine whether to monitor the hard disk data reading volume of the process corresponding to the current application within a preset time according to whether the current application is the first run.
[0081] Figure 5 The schematic diagram of a cloud server provided by an embodiment of the present disclosure. As Figure 5 shown, the cloud server includes: a storage control module 501, and a storage resource pool 502 connected to the storage control module 501;
[0082] The storage control module 501 is used to obtain the attributes of the hard disk server stored by the current application; the attributes of the hard disk server stored by the application are stored in the application record table of the system, including the IP address of the storage hard disk server of the application, the storage path, and whether it is the first run.
[0083] The storage control module 501 is also used to generate a network mapping on the running server of the current application according to the IP address and storage path of the storage hard disk server of the current application; determine whether to monitor the hard disk data read volume of the process corresponding to the current application within a preset time according to whether the current application is the first run.
[0084] If the current application is the first run, the storage control module 501 is used to monitor the hard disk data read volume of the process corresponding to the current application within a preset time.
[0085] The storage control module 501 is also used to compare the hard disk data read volume of the process corresponding to the current application within a preset time with a preset threshold of the hard disk data read volume of the application to determine the type of the current application.
[0086] The storage control module 501 is also used to determine the storage location of the current application in the storage resource pool 502 according to the type of the current application.
[0087] In one embodiment, as Figure 5 shown, the storage resource pool 502 includes a high-speed hard disk server 5021 and a low-speed hard disk server 5022.
[0088] An application storage method provided by the present disclosure can store different types of applications on hard disk servers with different resource configurations according to different characteristics of the applications, so as to ensure the reasonable utilization of resources and maximize the satisfaction of user needs.
[0089] Those of ordinary skill in the art can understand that all or part of the steps of implementing the above method embodiments can be completed by hardware related to program instructions. The foregoing program can be pre-stored in a computer-readable storage medium. When the program is executed, it executes the steps including the above method embodiments; and the foregoing storage medium includes: various media such as ROM, RAM, magnetic disk, or optical disk that can store program codes.
[0090] Other embodiments of the present disclosure will be readily apparent to those skilled in the art in view of the specification and practice of the disclosure herein. The present disclosure is intended to cover any variations, uses, or adaptations of the present disclosure that follow the general principles of the present disclosure and include known common general knowledge or conventional technical means in the technical field not disclosed by the present disclosure. The specification and examples are only illustrative, and the true scope and spirit of the present disclosure are pointed out by the following claims.
[0091] It should be understood that the present disclosure is not limited to the exact structures described above and shown in the drawings, and various modifications and changes can be made without departing from its scope. The scope of the present disclosure is only limited by the appended claims.
Claims
1. A method for storing application programs, characterized in that, The method includes: Obtaining the attributes of the hard disk server stored by the current application; wherein, the attributes of the hard disk server stored by the application include the IP address of the storage hard disk server of the application, the storage path, and whether it is the first run; Generating a network mapping on the running server of the current application according to the IP address and storage path of the storage hard disk server of the current application; determining whether to monitor the hard disk data read volume of the process corresponding to the current application within a preset time according to whether the current application is the first run; If the current application is the first run, then monitor the hard disk data read volume of the process corresponding to the current application within a preset time; Comparing the hard disk data read volume of the process corresponding to the current application within a preset time with the preset threshold of the hard disk data read volume of the application to determine the type of the current application; Performing corresponding operations according to the type of the current application; The comparing the hard disk data read volume of the process corresponding to the current application within a preset time with the preset threshold of the hard disk data read volume of the application to determine the type of the current application includes: If the hard disk data read volume of the process corresponding to the current application within a preset time is not less than the preset threshold of the hard disk data read volume of the application, it is determined that the current application is a large data volume application; The performing corresponding operations according to the type of the current application includes: Running the large data volume application on a high-speed hard disk server.
2. The method according to claim 1, wherein The comparing the hard disk data read volume of the process corresponding to the current application within a preset time with the preset threshold of the hard disk data read volume of the application to determine the type of the current application includes: If the hard disk data read volume of the process corresponding to the current application within a preset time is less than the preset threshold of the hard disk data read volume of the application, it is determined that the current application is a small data volume application; The performing corresponding operations according to the type of the current application includes: Moving the small data volume application from the high-speed hard disk server to the low-speed hard disk server according to a preset rule.
3. The method according to claim 2, wherein The moving the small data volume application from the high-speed hard disk server to the low-speed hard disk server according to a preset rule includes: Copying the program file of the small data volume application from the high-speed hard disk server to the low-speed hard disk server; Locking the application location record table in the application record table and updating the storage hard disk server IP address and storage path of the small data volume application in the application location record table to the parameters of the low-speed hard disk server; Releasing the application location record table in the application record table and deleting the program file of the small data volume application on the high-speed hard disk server.
4. The method according to any one of claims 1-3, characterized in that The attributes of the hard disk server stored by the application are stored in the application record table of the system.
5. An application program storage device, characterized in that, The device includes: An acquisition module that acquires the attributes of the hard disk server stored by the current application; the attributes of the hard disk server stored by the application are stored in the application record table of the system, including the IP address of the storage hard disk server of the application, the storage path, and whether it is the first run; A processing module that generates a network mapping on the running server of the current application according to the IP address and storage path of the storage hard disk server of the current application; determines whether to monitor the hard disk data read volume of the process corresponding to the current application within a preset time according to whether the current application is the first run; A monitoring module that, if the current application is the first run, monitors the hard disk data read volume of the process corresponding to the current application within a preset time; A comparison module that compares the hard disk data read volume of the process corresponding to the current application within a preset time with the preset threshold of the hard disk data read volume of the application to determine the type of the current application; An operation module that performs corresponding operations according to the type of the current application; The comparison module is specifically used for: If the hard disk data read volume of the process corresponding to the current application within a preset time is not less than the preset threshold of the hard disk data read volume of the application, it is determined that the current application is a large data volume application; The operation module is specifically used for: Running the large data volume application on a high-speed hard disk server.
6. The device according to claim 5, characterized in that The processing module includes: A generation sub-module that generates a network mapping on the running server of the current application according to the IP address and storage path of the storage hard disk server of the current application; A determination sub-module that determines whether to monitor the hard disk data read volume of the process corresponding to the current application within a preset time according to whether the current application is the first run.
7. The device according to claim 5, wherein The attributes of the hard disk server stored by the application are stored in the application record table of the system.
8. A cloud server, characterized in that, The cloud server includes: A storage control module and a storage resource pool connected to the storage control module; The storage control module is used to acquire the attributes of the hard disk server stored by the current application; the attributes of the hard disk server stored by the application are stored in the application record table of the system, including the IP address of the storage hard disk server of the application, the storage path, and whether it is the first run; The storage control module is further used to generate a network mapping on the running server of the current application according to the IP address and storage path of the storage hard disk server of the current application; determines whether to monitor the hard disk data read volume of the process corresponding to the current application within a preset time according to whether the current application is the first run; If the current application is the first run, the storage control module is used to monitor the hard disk data read volume of the process corresponding to the current application within a preset time; The storage control module is further used to compare the hard disk data read volume of the process corresponding to the current application within a preset time with the preset threshold of the hard disk data read volume of the application to determine the type of the current application; The storage control module is further configured to determine the current storage location of the program in the storage resource pool according to the type of the current application program; Comparing the amount of hard disk data read by the process corresponding to the current application program within a preset time with a preset threshold of the amount of hard disk data read by the application program to determine the type of the current application program includes: If the amount of hard disk data read by the process corresponding to the current application program within a preset time is not less than the preset threshold of the amount of hard disk data read by the application program, it is determined that the current application program is a large-data-volume application program.
9. The cloud server according to claim 8, wherein, The storage resource pool includes a high-speed hard disk server and a low-speed hard disk server.
Citation Information
Patent Citations
Method for automatically realizing hierarchical storage and system for managing hierarchical storage
CN104102454A
Data storage method, device and equipment and storage medium
CN109960471A