A method and device for configuring a disk
By obtaining and predicting the storage requirements of cloud server software under different numbers of concurrent users, and configuring appropriate disk sizes, the problem of insufficient or wasted software storage resources on cloud servers is solved, and efficient utilization of resources is achieved.
Patent Information
- Application Number
- CN201910735083.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2019-08-09
- Publication Date
- 2024-08-23
- Estimated Expiration
- 2039-08-09
AI Technical Summary
When installing software on a cloud server, the disk size configured in a common template cannot meet the storage requirements of different software under different numbers of concurrent users, resulting in insufficient or wasted resources.
By obtaining the storage resource requirements of the software to be installed under different numbers of concurrent users, predict the number of concurrent users, and configure the disk size of the cloud device according to the needs to avoid resource waste.
Ensure that the software has sufficient storage space to run, avoid wasting storage resources, and adapt to the actual needs of the software.
Smart Images

Figure CN112346649B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a method and device for a disk. Background Art
[0002] Elastic Compute Service (ECS) is a simple, efficient, secure, reliable, and elastically scalable computing service. With ECS, users can quickly create or release any number of cloud servers without purchasing hardware. Therefore, ECS has gradually replaced traditional servers created by physical machines and become the mainstream development target of servers.
[0003] At present, when installing stand-alone software on a cloud server, the cloud server's disk is generally configured according to a general template. In order to have enough storage space to ensure the normal operation of the software and not waste storage resources, the disk size in the general template is usually set to a moderate value. However, due to differences in the operating characteristics of each software and the number of concurrent users, the amount of data generated by the software under different operating conditions varies greatly. For software that generates more data, if the cloud server's disk is configured according to a general template, the storage resources cannot meet the software's demand for storage resources, and the software may not be able to run normally. For software that generates less data, if the cloud server's disk size is configured according to a general template, the configured storage resources will be much larger than the software's demand for storage resources, resulting in a waste of storage resources. Summary of the invention
[0004] In view of this, an embodiment of the present invention provides a method and apparatus for configuring a disk, which is used to ensure that there is enough storage space to ensure normal operation of software while avoiding wasting storage resources.
[0005] In order to achieve the above purpose, the embodiment of the present invention provides the following technical solutions:
[0006] In a first aspect, an embodiment of the present invention provides a method for configuring a disk, comprising:
[0007] Obtain the storage resources required by the software to be installed under different numbers of concurrent users;
[0008] Obtaining the number of concurrent users of the software to be installed;
[0009] Predicting the storage resources required by the software to be installed according to the number of concurrent users of the software to be installed and the storage resources required by the software to be installed under different numbers of concurrent users;
[0010] The disk of the cloud device where the software to be installed is installed is configured according to the storage resources required by the software to be installed.
[0011] As an optional implementation of the embodiment of the present invention, before obtaining the storage resources required by the software to be installed under different numbers of concurrent users, the method further includes:
[0012] determining, according to the running characteristics of the software to be installed, whether the storage resources required by the software to be installed are greater than a threshold value when the number of concurrent users is a first preset value;
[0013] If the number of concurrent users is the first preset value, and the storage resources required by the software to be installed are less than or equal to the threshold, the size of the disk of the cloud device on which the software to be installed is installed is configured to be the second preset value.
[0014] As an optional implementation of the embodiment of the present invention, the obtaining of storage resources required by the software to be installed under different numbers of concurrent users includes:
[0015] Obtaining the running information of the software to be installed after installation to form a big data resource pool;
[0016] The storage resources required by the software to be installed under different numbers of concurrent users are obtained according to the big data resource pool.
[0017] As an optional implementation of the embodiment of the present invention, the obtaining of storage resources required by the software to be installed under different numbers of concurrent users includes:
[0018] Obtaining the running information of the software to be installed in the test environment to form a big data resource pool;
[0019] The storage resources required by the software to be installed under different numbers of concurrent users are obtained according to the big data resource pool.
[0020] As an optional implementation of the embodiment of the present invention, the obtaining of storage resources required by the software to be installed under different numbers of concurrent users includes:
[0021] Obtaining the running information of the software to be installed after installation and the running information of the software to be installed in the test environment;
[0022] Combining the running information of the software to be installed after installation and the running information of the software to be installed in the test environment, forming a big data resource pool;
[0023] The storage resources required by the software to be installed under different numbers of concurrent users are obtained according to the big data resource pool.
[0024] As an optional implementation of the embodiment of the present invention, obtaining the number of concurrent users of the software to be installed includes:
[0025] The number of concurrent users of the software to be installed is predicted according to the number of users of the software to be installed and the running stage of the software to be installed, so as to obtain the number of concurrent users of the software to be installed.
[0026] In a second aspect, an embodiment of the present invention provides a device for configuring a disk, comprising:
[0027] A demand acquisition unit, used to acquire storage resources required by the software to be installed under different numbers of concurrent users;
[0028] A quantity acquisition unit, used to acquire the number of concurrent users of the software to be installed;
[0029] A prediction unit, configured to predict the storage resources required by the software to be installed according to the number of concurrent users of the software to be installed and the storage resources required by the software to be installed under different numbers of concurrent users;
[0030] The configuration unit is used to configure the disk of the cloud device where the software to be installed is installed according to the storage resources required by the software to be installed.
[0031] As an optional implementation of the embodiment of the present invention, the device further includes:
[0032] a determination unit, configured to determine, according to the running characteristics of the software to be installed, whether the storage resources required by the software to be installed are greater than a threshold value when the number of concurrent users is a first preset value;
[0033] The configuration unit is further configured to configure the disk size of the cloud device on which the software to be installed is installed to a second preset value when the number of concurrent users is a first preset value and the storage resources required by the software to be installed are less than or equal to the threshold.
[0034] As an optional implementation of the embodiment of the present invention, the demand acquisition unit is specifically used to obtain the running information of the software to be installed after installation to form a big data resource pool; and obtain the storage resources required by the software to be installed under different numbers of concurrent users based on the big data resource pool.
[0035] As an optional implementation of the embodiment of the present invention, the demand acquisition unit is specifically used to obtain the operation information of the software to be installed in a test environment to form a big data resource pool; and obtain the storage resources required by the software to be installed under different numbers of concurrent users based on the big data resource pool.
[0036] As an optional implementation of an embodiment of the present invention, the demand acquisition unit is specifically used to obtain the running information of the software to be installed after installation and the running information of the software to be installed in a test environment; combining the running information of the software to be installed after installation and the running information of the software to be installed in the test environment to form a big data resource pool; and obtaining the storage resources required by the software to be installed under different numbers of concurrent users based on the big data resource pool.
[0037] As an optional implementation of the embodiment of the present invention, the quantity acquisition unit is specifically used to predict the number of concurrent users of the software to be installed according to the number of users of the software to be installed and the running stage of the software to be installed, and acquire the number of concurrent users of the software to be installed.
[0038] In a third aspect, an embodiment of the present invention provides a device for configuring a disk, comprising: a memory and a processor, the memory being used to store a computer program; the processor being used to execute the method for configuring a disk described in the first aspect or any embodiment of the first aspect when calling the computer program.
[0039] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method for configuring a disk as described in the first aspect or any implementation of the first aspect is implemented.
[0040] The method for configuring a disk provided in an embodiment of the present invention first obtains the storage resources required by the software to be installed under different numbers of concurrent users and the number of concurrent users of the software to be installed, then predicts the storage resources required by the software to be installed according to the number of concurrent users of the software to be installed and the storage resources required by the software to be installed under different numbers of concurrent users, and finally configures the disk of the cloud device where the software to be installed is installed according to the storage resources required by the software to be installed. Since the method for configuring a disk provided in an embodiment of the present invention can predict the storage resources actually required by the software to be installed and configure the disk of the cloud device where the software to be installed is installed based on the storage resources actually required by the software to be installed, the disk configured for the cloud device can be adapted to the disk requirements of the software to be installed, and the problem of the disk configured for the cloud device being too large or too small will not occur. Therefore, the method for configuring a disk provided in an embodiment of the present invention can ensure that there is enough storage space to ensure the normal operation of the software while avoiding wasting storage resources. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] Figure 1 One of the flowcharts of the method for configuring a disk provided in an embodiment of the present invention;
[0042] Figure 2A second flowchart of a method for configuring a disk provided in an embodiment of the present invention;
[0043] Figure 3 One of the structural schematic diagrams of the device for configuring a disk provided in an embodiment of the present invention;
[0044] Figure 4 A second structural diagram of the device for configuring a disk provided in an embodiment of the present invention;
[0045] Figure 5 A schematic diagram of the hardware structure of a disk configuration device provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0046] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0047] The term "and / or" in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the previous and next associated objects are in an "or" relationship; in a formula, the character " / " indicates that the previous and next associated objects are in a "division" relationship. If not specified, "multiple" in this article refers to two or more.
[0048] In order to clearly describe the technical solutions of the embodiments of the present invention, in the embodiments of the present invention, the words "first", "second", etc. are used to distinguish between the same items or similar items with basically the same functions or effects. Those skilled in the art can understand that the words "first", "second", etc. do not limit the quantity and execution order.
[0049] In the embodiments of the present invention, words such as "exemplary" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design scheme described as "exemplary" or "for example" in the embodiments of the present invention should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a concrete way. In the embodiments of the present invention, unless otherwise specified, the meaning of "multiple" refers to two or more.
[0050] The execution subject of the method for configuring a disk provided in the embodiment of the present invention may be a device for configuring a disk. The specific device for configuring a disk may be a terminal device such as a mobile phone, a tablet computer, a laptop computer, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (PDA), a smart watch, a smart bracelet, etc., or the device for configuring a disk may also be other types of electronic devices, which is not limited in the embodiments of the present application.
[0051] The embodiment of the present invention provides a method for configuring a disk. Specifically, refer to Figure 1 As shown, the method for configuring a disk may include the following steps:
[0052] S11. Obtain storage resources required by the software to be installed under different numbers of concurrent users.
[0053] Specifically, the number of concurrent users in the embodiment of the present invention refers to the number of users who interact with the software to be installed at the same time.
[0054] As an optional implementation of the embodiment of the present invention, the implementation of the above step S11 (obtaining the storage resources required by the software to be installed under different numbers of concurrent users) may include the following steps a and b.
[0055] Step a: obtaining the running information of the software to be installed after installation to form a big data resource pool.
[0056] Step b: acquiring storage resources required by the software to be installed under different numbers of concurrent users according to the big data resource pool.
[0057] Specifically, the running information of the software to be installed after installation includes: the number of concurrent users of the software to be installed and the storage resources occupied when the software to be installed is running; based on multiple running information of multiple software to be installed, the corresponding relationship between the different numbers of concurrent users of the software to be installed and the required storage resources can be determined, and then the corresponding relationship between the different numbers of concurrent users of the software to be installed and the required storage resources can be combined into a big data resource pool.
[0058] As an optional implementation of the embodiment of the present invention, the implementation of the above step S11 (obtaining the storage resources required by the software to be installed under different numbers of concurrent users) may include the following steps I and II.
[0059] Step I: Obtain the running information of the software to be installed in the test environment to form a big data resource pool.
[0060] Specifically, in a test environment, the number of concurrent users can be set arbitrarily to read the storage resources occupied by the software to be installed under different concurrent users. For example, the number of concurrent users can be set to 10, 50, 100, 150 to obtain the storage resources occupied by the software to be installed when the number of concurrent users is 10, 50, 100, 150.
[0061] Step II: obtaining storage resources required by the software to be installed under different numbers of concurrent users according to the big data resource pool.
[0062] Similarly, the running information of the software to be installed in the test environment includes: the number of concurrent users of the software to be installed and the storage resources occupied when it is running; by obtaining the running information in multiple test environments, the correspondence between the different numbers of concurrent users of the software to be installed and the required storage resources can be determined, and then the correspondence between the different numbers of concurrent users of the software to be installed and the required storage resources can be combined into a big data resource pool.
[0063] As an optional implementation of the embodiment of the present invention, the implementation of the above step S11 (obtaining storage resources required by the software to be installed under different numbers of concurrent users) may include the following steps 1) and 4).
[0064] 1) Obtaining the running information of the software to be installed after installation.
[0065] 2) Obtaining the running information of the software to be installed in the test environment.
[0066] 3) Combining the running information of the software to be installed after installation and the running information of the software to be installed in the test environment, a big data resource pool is formed.
[0067] Specifically, a big data resource pool is formed by combining the running information of the software to be installed after installation and the running information of the software to be installed in a test environment, including the following situations:
[0068] 1. The operation information after installation does not include the storage resources required by the software to be installed when the number of concurrent users is x. In the test environment, when the number of concurrent users is x, the storage resources occupied by the software to be installed are M. Then, in the big data resource pool, the storage resources required by the software to be installed when the number of concurrent users is x are M.
[0069] 2. The operation information after installation includes that the storage resources occupied by the software to be installed when the number of concurrent users is y is N; the operation information in the test environment does not include the storage resources occupied by the software to be installed when the number of concurrent users is y, so the storage resources required by the software to be installed in the big data resource pool when the number of concurrent users is y is N.
[0070] 3. The running information of the software to be installed after installation includes that the storage resources occupied by the software to be installed when the number of concurrent users is z is P; in a test environment, when the number of concurrent users is z, the storage resources occupied by the software to be installed is Q, then the storage resources required in the big data resource pool when the number of concurrent users of the software to be installed is y can be (P+Q) / 2, or a*P+b*Q; wherein a and b are constants greater than 0 and less than 1, and a+b=1.
[0071] 4) Obtain storage resources required by the software to be installed under different numbers of concurrent users based on the big data resource pool.
[0072] S12: Obtain the number of concurrent users of the software to be installed.
[0073] That is, the number of users who simultaneously interact with the software to be installed is obtained.
[0074] As an optional implementation mode of the embodiment of the present invention, the above step S12 (obtaining the number of concurrent users of the software to be installed) may include:
[0075] The number of concurrent users of the software to be installed is predicted according to the number of users of the software to be installed and the running stage of the software to be installed, so as to obtain the number of concurrent users of the software to be installed.
[0076] Specifically, the number of users of the software to be installed can be provided by the enterprise or unit that will use the software to be installed. For example, if the user of the software to be installed is a certain unit, the number of employees of the unit is 300, and all employees of the unit will use the software to be installed, then the number of users of the software to be installed can be determined to be 300. Of course, the number of users of the software to be installed can also be predicted and obtained based on the applicable population of the software to be installed, etc., and the implementation method for obtaining the number of users of the software to be installed is not limited in the embodiment of the present invention.
[0077] Furthermore, the number of concurrent users may change at different stages of software operation. Therefore, when predicting the concurrent users of the software, taking the software operation stage as a reference factor can more accurately predict the number of concurrent users of the software.
[0078] It should be noted that, in some cases, the number of users of the software to be installed in the embodiments of the present invention is not equal to the number of concurrent users of the software to be installed. For example, the number of users of the software to be installed is determined to be 300 based on the number of employees in the unit who use the software to be installed. However, the unit implements a two-shift system with 150 employees in each shift. At this time, the number of concurrent users of the software to be installed should be predicted based on 150 people, which is not equal to the number of users of the software to be installed, 300.
[0079] S13: predicting storage resources required by the software to be installed according to the number of concurrent users of the software to be installed and the storage resources required by the software to be installed under different numbers of concurrent users.
[0080] For example, the storage resources required by the software to be installed in step S11 under different numbers of concurrent users are shown in Table 1 below:
[0081] Table 1
[0082] Number of concurrent users Storage requirements 10 50G 50 200G 100 350G 150 450G 200 500G 300 550G 1000 1000G
[0083] The number of concurrent users of the software to be installed obtained in step S12 is 100, and the storage resources required by the software to be installed are predicted to be 350G.
[0084] S14: configuring the disk of the cloud device where the software to be installed is installed according to the storage resources required by the software to be installed.
[0085] It should be noted that, the disk of the cloud device for installing the software to be installed is configured according to the storage resources required by the software to be installed. The size of the disk of the cloud device for installing the software to be installed can be configured to be equal to the storage resources required by the software to be installed, or the difference between the size of the disk of the cloud device for installing the software to be installed and the storage resources required by the software to be installed can be within a certain range.
[0086] The method for configuring a disk provided in an embodiment of the present invention first obtains the storage resources required by the software to be installed under different numbers of concurrent users and the number of concurrent users of the software to be installed, then predicts the storage resources required by the software to be installed according to the number of concurrent users of the software to be installed and the storage resources required by the software to be installed under different numbers of concurrent users, and finally configures the disk of the cloud device where the software to be installed is installed according to the storage resources required by the software to be installed. Since the method for configuring a disk provided in an embodiment of the present invention can predict the storage resources actually required by the software to be installed and configure the disk of the cloud device where the software to be installed is installed based on the storage resources actually required by the software to be installed, the disk configured for the cloud device can be adapted to the disk requirements of the software to be installed, and the problem of the disk configured for the cloud device being too large or too small will not occur. Therefore, the method for configuring a disk provided in an embodiment of the present invention can ensure that there is enough storage space to ensure the normal operation of the software while avoiding wasting storage resources.
[0087] As an optional implementation of the embodiment of the present invention, refer to Figure 2As shown, before the above step S11 (obtaining the storage resources required by the software to be installed under different numbers of concurrent users), the method for configuring the disk provided in the embodiment of the present invention further includes:
[0088] S21. Determine, according to the running characteristics of the software to be installed, whether the storage resources required by the software to be installed are greater than a threshold when the number of concurrent users is a first preset value.
[0089] Exemplarily, the first preset value may be 1.
[0090] Specifically, the running characteristics of the software to be installed may include: whether the software to be installed is query software, when the software to be installed is not query software, the amount of data generated by the user's operation, etc. For example: when the software to be installed is query software, when the software to be installed is used again, only logs will be generated, and no new data will be generated. Therefore, in this case, it can be determined that the storage resources required by the software to be installed are less than the threshold value; for another example: when the software to be installed is not query software, new data will be generated when the user operates, and the amount of data, therefore, in this case, it can be determined that when the number of concurrent users is the first preset value, the storage resources required by the software to be installed are greater than the threshold value.
[0091] Exemplarily, the threshold value may be set to one thousandth or one ten-thousandth of the storage resources of 1 unit of disk.
[0092] In the above step S21, if the storage resources required by the software to be installed are less than or equal to the threshold when the number of concurrent users is the first preset value, execute the following step S22; if the storage resources required by the software to be installed are greater than the threshold when the number of concurrent users is the first preset value, execute the above steps S11 to S14.
[0093] S22: configuring the disk size of the cloud device on which the software to be installed is installed to be a second preset value.
[0094] Specifically, the threshold and preset value in the embodiment of the present invention can be set according to the estimated number of concurrent users and the storage resources contained in one unit of disk when the disk is configured. For example: if the estimated number of concurrent users is 100 and the storage resources contained in one unit of disk are 50G, the threshold can be set to 0.5 and the second preset value can be set to 50G; for another example: if the estimated number of concurrent users is 1000 and the storage resources contained in one unit of disk are 100G, the threshold can be set to 0.1G and the second preset value can be set to 100G. That is, if one unit of disk can meet the disk requirements of the software to be installed when there are the most concurrent users, the disk of the software to be installed can be directly configured as one unit of disk.
[0095] In the above embodiment, it is first determined according to the running characteristics of the software to be installed whether the storage resources required by the software to be installed when the number of concurrent users is a first preset value is greater than a threshold value; if the storage resources required by the software to be installed when the number of concurrent users is the first preset value is less than or equal to the threshold value, the disk size of the cloud device on which the software to be installed is installed is directly configured to a second preset value; if the storage resources required by the software to be installed when the number of concurrent users is the first preset value is less than or equal to the threshold value, a small amount of storage resources can meet the disk requirements of the software to be installed when the number of concurrent users is the largest. At this time, the disk size of the cloud device on which the software to be installed is directly configured to the second preset value, which can avoid executing steps such as obtaining the storage resources required by the software to be installed under different numbers of concurrent users and obtaining the number of concurrent users of the software to be installed, while ensuring the running speed of the software and not wasting a lot of storage resources, thereby simplifying the method flow of configuring the disk.
[0096] The embodiment of the present application can divide the functional modules of the terminal device etc. according to the above method example. For example, each functional module can be divided according to each function, or two or more functions can be integrated into one module. The above integrated module can be implemented in the form of hardware or in the form of software functional modules. It should be noted that the division of modules in the embodiment of the present application is schematic and is only a logical function division. There may be other division methods in actual implementation.
[0097] In the case of integrated units, Figure 3 A possible structural diagram of a disk configuration device involved in the above embodiment is shown. The disk configuration device 300 includes:
[0098] A demand acquisition unit 31 is used to acquire storage resources required by the software to be installed under different numbers of concurrent users;
[0099] A quantity acquisition unit 32 is used to acquire the number of concurrent users of the software to be installed;
[0100] A prediction unit 33, configured to predict the storage resources required by the software to be installed according to the number of concurrent users of the software to be installed and the storage resources required by the software to be installed under different numbers of concurrent users;
[0101] The configuration unit 34 is used to configure the disk of the cloud device where the software to be installed is installed according to the storage resources required by the software to be installed.
[0102] As an optional embodiment of the present invention, refer to Figure 4 As shown, the device 300 for configuring a disk further includes:
[0103] A determination unit 35, configured to determine, according to the running characteristics of the software to be installed, whether the storage resources required by the software to be installed are greater than a threshold when the number of concurrent users is a first preset value;
[0104] The configuration unit 34 is further configured to configure the disk size of the cloud device for installing the software to be installed to a second preset value when the concurrent users are the first preset value and the storage resources required by the software to be installed are less than or equal to the threshold.
[0105] As an optional implementation method of the embodiment of the present invention, the demand acquisition unit 31 is specifically used to obtain the running information of the software to be installed after installation to form a big data resource pool; and obtain the storage resources required by the software to be installed under different numbers of concurrent users based on the big data resource pool.
[0106] As an optional implementation method of the embodiment of the present invention, the demand acquisition unit 31 is specifically used to obtain the operation information of the software to be installed in the test environment to form a big data resource pool; and obtain the storage resources required by the software to be installed under different numbers of concurrent users based on the big data resource pool.
[0107] As an optional implementation method of the embodiment of the present invention, the demand acquisition unit 31 is specifically used to obtain the running information of the software to be installed after installation and the running information of the software to be installed in a test environment; combine the running information of the software to be installed after installation and the running information of the software to be installed in the test environment to form a big data resource pool; obtain the storage resources required by the software to be installed under different numbers of concurrent users based on the big data resource pool.
[0108] As an optional implementation mode of the embodiment of the present invention, the quantity acquisition unit 32 is specifically used to predict the number of concurrent users of the software to be installed according to the number of users of the software to be installed and the running stage of the software to be installed, and obtain the number of concurrent users of the software to be installed.
[0109] The device for configuring a disk provided in an embodiment of the present invention includes: a demand acquisition unit, a quantity acquisition unit, a prediction unit and a configuration unit; wherein the demand acquisition unit can obtain the storage resources required by the software to be installed under different numbers of concurrent users, the quantity acquisition unit can obtain the number of concurrent users of the software to be installed, the prediction unit can predict the storage resources required by the software to be installed based on the number of concurrent users of the software to be installed and the storage resources required by the software to be installed under different numbers of concurrent users, and the configuration unit can configure the disk of the cloud device where the software to be installed is installed based on the storage resources required by the software to be installed. Since the device for configuring a disk provided in an embodiment of the present invention can predict the storage resources actually required by the software to be installed, and configure the disk of the cloud device where the software to be installed is installed based on the storage resources actually required by the software to be installed, the disk configured for the cloud device can be adapted to the disk requirements of the software to be installed, and there will be no problem of the disk configured for the cloud device being too large or too small. Therefore, the device for configuring a disk provided in an embodiment of the present invention can ensure that there is enough storage space to ensure the normal operation of the software while avoiding wasting storage resources.
[0110] Based on the same inventive concept, an embodiment of the present invention further provides a device for configuring a disk. Figure 5 A schematic diagram of the structure of a disk configuration device provided by an embodiment of the present invention, such as Figure 5 As shown, the apparatus for configuring a disk provided in this embodiment includes: a memory 51 and a processor 52, wherein the memory 51 is used to store a computer program; and the processor 52 is used to execute the method for configuring a disk described in the above method embodiment when calling the computer program.
[0111] The device for configuring a disk provided in this embodiment can execute the method for configuring a disk provided in the above method embodiment, and its implementation principle and technical effect are similar, which will not be described in detail here.
[0112] An embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the method for configuring a disk described in the above method embodiment is implemented.
[0113] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media that include computer-usable program code.
[0114] The processor may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.
[0115] The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.
[0116] Computer readable media include permanent and non-permanent, removable and non-removable storage media. Storage media can be implemented by any method or technology to store information, and the information can be computer-readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.
[0117] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for configuring a disk, characterized in that: include: Obtain the storage resources required by the software to be installed under different numbers of concurrent users; Obtaining the number of concurrent users of the software to be installed, wherein obtaining the number of concurrent users of the software to be installed includes: Predicting the number of concurrent users of the software to be installed according to the number of users of the software to be installed and the running stage of the software to be installed, and obtaining the number of concurrent users of the software to be installed; Predicting the storage resources required by the software to be installed according to the number of concurrent users of the software to be installed and the storage resources required by the software to be installed under different numbers of concurrent users; Configuring the disk of the cloud device where the software to be installed is installed according to the storage resources required by the software to be installed; Before obtaining the storage resources required by the software to be installed under different numbers of concurrent users, the method further includes: Determining, according to the running characteristics of the software to be installed, whether the storage resources required by the software to be installed is greater than a threshold when the number of concurrent users is a first preset value; If the storage resources required by the software to be installed are less than or equal to the threshold when the number of concurrent users is the first preset value, the size of the disk of the cloud device on which the software to be installed is installed is configured to be the second preset value.
2. The method according to claim 1, characterized in that The step of obtaining storage resources required by the software to be installed under different numbers of concurrent users includes: Obtaining the running information of the software to be installed after installation to form a big data resource pool; The storage resources required by the software to be installed under different numbers of concurrent users are obtained according to the big data resource pool.
3. The method according to claim 1, characterized in that The step of obtaining storage resources required by the software to be installed under different numbers of concurrent users includes: Obtaining the running information of the software to be installed in the test environment to form a big data resource pool; The storage resources required by the software to be installed under different numbers of concurrent users are obtained according to the big data resource pool.
4. The method according to claim 1, characterized in that: The step of obtaining storage resources required by the software to be installed under different numbers of concurrent users includes: Obtaining the running information of the software to be installed after installation and the running information of the software to be installed in the test environment; Combining the running information of the software to be installed after installation and the running information of the software to be installed in the test environment, forming a big data resource pool; The storage resources required by the software to be installed under different numbers of concurrent users are obtained according to the big data resource pool.
5. A device for configuring a disk, characterized in that: include: A demand acquisition unit, used to acquire storage resources required by the software to be installed under different numbers of concurrent users; The number acquisition unit is used to acquire the number of concurrent users of the software to be installed, wherein acquiring the number of concurrent users of the software to be installed includes: Predicting the number of concurrent users of the software to be installed according to the number of users of the software to be installed and the running stage of the software to be installed, and obtaining the number of concurrent users of the software to be installed; A prediction unit, configured to predict the storage resources required by the software to be installed according to the number of concurrent users of the software to be installed and the storage resources required by the software to be installed under different numbers of concurrent users; A configuration unit, configured to configure a disk of a cloud device for installing the software to be installed according to storage resources required by the software to be installed; The device also includes: a determining unit, configured to determine, according to the running characteristics of the software to be installed, whether the storage resources required by the software to be installed are greater than a threshold value when the number of concurrent users is a first preset value; The configuration unit is further configured to configure the disk size of the cloud device on which the software to be installed is installed to a second preset value when the number of concurrent users is a first preset value and the storage resources required by the software to be installed are less than or equal to the threshold.
6. A device for configuring a disk, characterized in that: include: A memory and a processor, wherein the memory is used to store a computer program; and the processor is used to execute the method for configuring a disk as described in any one of claims 1 to 4 when calling the computer program.
7. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method for configuring a disk as claimed in any one of claims 1 to 4 is implemented.
