CN108829541A - Dilatation detection method, electronic device and computer readable storage medium - Google Patents
Dilatation detection method, electronic device and computer readable storage medium Download PDFInfo
- Publication number
- CN108829541A CN108829541A CN201810612231.6A CN201810612231A CN108829541A CN 108829541 A CN108829541 A CN 108829541A CN 201810612231 A CN201810612231 A CN 201810612231A CN 108829541 A CN108829541 A CN 108829541A
- Authority
- CN
- China
- Prior art keywords
- image file
- electronic device
- target
- dilatation
- target image
- 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
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/14—Error detection or correction of the data by redundancy in operation
- G06F11/1402—Saving, restoring, recovering or retrying
- G06F11/1446—Point-in-time backing up or restoration of persistent data
Abstract
A kind of dilatation detection method, electronic device and computer readable storage medium, wherein the dilatation detection method includes:The size of target image file and the capacity of target partition in electronic device are obtained respectively, wherein the target image file is by the processed image file of dilatation, and the target partition is the subregion to load the target image file;Calculate the difference between the capacity of the target partition and the size of the target image file;If the difference is not in preset error range, outputting alarm information, to prompt the target image file dilatation to fail.Scheme provided by the present application can be used to verify the validity of dilatation, realize the fool-proof design to dilatation.
Description
Technical field
This application involves electronic technology field more particularly to a kind of dilatation detection methods, electronic device and computer-readable
Storage medium.
Background technique
Current each cell phone manufacturer would generally use the different size of storage of a plurality of different companies in mobile phone production process
Device (such as embedded multi-media card (Embedded Multi Media Card, EMMC), embedded storage card (Embedded
Mutil Chip Package, EMCP), Common Flash Memory storage card (Universal Flash Storage, UFS) etc.), so that
The mobile phone of same model can have the configuration versions of different memory spaces (such as there are 4GB+128GB and 6GB by OPPO R15
Two configuration versions of+128GB), meet the needs of different user.
For the mobile phone of same model difference memory space, before mobile phone factory, it will usually go to solve using dilatation mechanism
image file due to different storage space ( for exampleuserdata.imgimage file ) size difference problem.So
And there is no carry out fool-proof design to this link of dilatation in the prior art.
Summary of the invention
The embodiment of the present application provides a kind of dilatation detection method, electronic device and computer readable storage medium, can be used to
The validity of dilatation is verified, realizes the fool-proof design to dilatation.
The embodiment of the present application first aspect provides a kind of dilatation detection method, including:
The size of target image file and the capacity of target partition in electronic device are obtained respectively, wherein the target
Image file is by the processed image file of dilatation, and the target partition is point to load the target image file
Area;
Calculate the difference between the capacity of the target partition and the size of the target image file;
If the difference is not in preset error range, outputting alarm information, to prompt the target image file
Dilatation failure.
The embodiment of the present application second aspect provides a kind of electronic device, including:
Acquiring unit, for obtaining the capacity of the size of target image file and target partition in electronic device respectively,
Wherein, the target image file is by the processed image file of dilatation, and the target partition is to load the target
The subregion of image file;
Computing unit, for calculating the difference between the capacity of the target partition and the size of the target image file
Value;
Alarm Unit is used for when the difference is not in preset error range, outputting alarm information, described in prompt
Target image file dilatation failure.
The embodiment of the present application third aspect provides another electronic device, including:It memory, processor and is stored in described
It is real when the processor executes the computer program on memory and the computer program that can run on the processor
The dilatation detection method that existing above-mentioned the embodiment of the present application first aspect provides.
The embodiment of the present application fourth aspect provides a kind of computer readable storage medium, is stored thereon with computer program,
When the computer program is executed by processor, the dilatation detection method that above-mentioned the embodiment of the present application first aspect provides is realized.
Therefore application scheme is by obtaining the size and target partition of target image file in electronic device
Capacity, and the difference between the capacity of the target partition and the size of the target image file is calculated, and in the difference not pre-
If error range in when, outputting alarm information, so that related personnel is able to know that the target image file does not expand actually
Rongcheng function, and then it is able to the validity of verifying dilatation, realize the fool-proof design to dilatation.
Detailed description of the invention
Fig. 1 is dilatation detection method one embodiment flow diagram provided by the present application;
Fig. 2 is another embodiment flow diagram of dilatation detection method provided by the present application;
Fig. 3 is dilatation detection method one embodiment provided by the present application interaction schematic diagram;
Fig. 4 is electronic device one embodiment structural schematic diagram provided by the present application;
Fig. 5 is another example structure schematic diagram of electronic device provided by the present application.
Specific embodiment
To enable present invention purpose, feature, advantage more obvious and understandable, below in conjunction with the application
Attached drawing in embodiment, the technical scheme in the embodiment of the application is clearly and completely described, it is clear that described reality
Applying example is only some embodiments of the present application, and not all embodiments.Based on the embodiment in the application, those skilled in the art
Member's every other embodiment obtained without making creative work, shall fall in the protection scope of this application.
The embodiment of the present application provides a kind of dilatation detection method, which is applied to electronic device, the electronics
Device can be the equipment of the mountable application programs such as smart phone, tablet computer, wearable device, the behaviour of above-mentioned electronic device
Making system can be ios, android, windows system or other operating systems, be not construed as limiting herein.
Referring to Fig. 1, the dilatation detection method mainly includes the following steps that:
Step 101 obtains the size of target image file and the capacity of target partition in electronic device respectively;
Wherein, above-mentioned target image file is by the processed image file of dilatation, and above-mentioned target partition is to load
The subregion of above-mentioned target image file.
It is illustrated by taking Android system as an example below:
In Android system, after the compiling of android source code, generated at out/target/product/generic
Three image files:Ramdisk.img ( namely the root file mirroring ) ,system.img ( namely the system image file ) ,
Userdata.img ( namely the user data image file ) ,and their corresponding directory treesroot,system,data.Wherein,
Ramdisk.imgnamely root file system,system.imgincluding the main package,library and other documents,userdata.imgincluding
Some user data.The target image file that step 101 refers to can be the either image file of above three image file, this
Place is without limitation.
For the ease of when electronic device dispatches from the factory, can in electronic device pre-installed applications program or data (such as picture number
According to, video data etc.), it generally requires during electronic device initializing, by preset user data image file (in order to retouch
convenient description,the following can be referred to asuserdata.img ) load toramdiskin the file systemdata ( namely the data ) under the list.
specifically,can be loaded in the order of loading set in the default partition table,whenramdisk.img,system.imgand other non
after the user data image file is loaded into the corresponding directory of the electronic device,pre-generateduserdata.imgimage file
It is loaded under the respective directories of electronic device.The mesh that the i.e. above-mentioned target image file of the target partition that step 101 refers to is loaded
Subregion where recording, for example, above-mentioned target, which is divided into, specially to be used when above-mentioned target image file is user data image file
User data subregion.
In the embodiment of the present application, dilatation processing refers to the size for increasing the image file not loaded using dilatation instruction.Example
such asandroidin the system,system.imganduserdata.imgusually implementExt4 ( the fourth generation extended file system )
Format building, therefore, it is possible to use resize2fs order carries out dilatation processing to the image file not loaded.
It should be noted that, although target image file is processed by dilatation, it is not intended that target image file energy
Enough dilatation successes (such as it is possible that because the reasons such as process occupation problem, target partition remaining space deficiency cause dilatation to fail),
It finds in practical applications, even if target image file is handled by dilatation and prompts dilatation success, the reality of the target image file
Border size is also possible to not change.That is, the target image file may also even if target image file is processed by dilatation
Original size is kept, and the situation can detect that by dilatation detection method provided by the embodiments of the present application.
Optionally, step 101 includes:Receive from control equipment (such as personal computer (Personal Computer,
PC test instruction);Above-mentioned test instruction instruction under, respectively obtain electronic device in target image file size and
The capacity of target partition.Certainly, in the embodiment of the present application, the execution of step 101 can also be triggered under other opportunitys, for example,
It can start to be handled by dilatation in above-mentioned target image file and wait the execution for triggering step 101 after preset duration, the application
The trigger timing of step 101 is not defined in embodiment.
Difference between step 102, the capacity for calculating above-mentioned target partition and the size of above-mentioned target image file;
The main purpose for carrying out dilatation to target image file is to be able to enable the usable range of target image file
It is enough to cover entire target partition as far as possible.Therefore, in the embodiment of the present application, calculate above-mentioned target partition capacity and above-mentioned target
Difference between the size of image file, so as to know above-mentioned target partition capacity and above-mentioned target image file size it
Between difference.
For example, setting the capacity of above-mentioned target partition as sizea, the size of above-mentioned target image file is sizeb, then
Step 102 is the capacity and above-mentioned target image file for showing as calculating above-mentioned target partition by formula sizea-sizeb
Difference between size.
If step 103, above-mentioned difference be not in preset error range, outputting alarm information, to prompt above-mentioned target
Image file dilatation failure;
In the embodiment of the present application, an error range is preset, when above-mentioned difference is not in above-mentioned error range, can be sentenced
The fixed above-mentioned non-dilatation of target image file is successful, at this time outputting alarm information, so that related personnel knows the target image file
Dilatation failure.
Optionally, if step 101 is triggered under the instruction of the test instruction from control equipment, in step 102
Later, above-mentioned difference can be returned to above-mentioned control equipment, so that above-mentioned control equipment judges above-mentioned difference whether above-mentioned
In error range, and above-mentioned warning information is exported when determining that above-mentioned difference is in above-mentioned error range.Under this application scenarios,
Step 103 can be shown as:If above-mentioned difference not in preset error range, is believed by above-mentioned control equipment outputting alarm
Breath, to prompt above-mentioned target image file dilatation to fail.
In the embodiment of the present application, when above-mentioned control equipment detects above-mentioned difference in above-mentioned error range, show above-mentioned
Target image file dilatation success, can not export indication signal, alternatively, can also export to be above-mentioned target mirror image at this time
The successful indication signal of file dilatation, herein without limitation.
Therefore the embodiment of the present application passes through the size and target partition of target image file in acquisition electronic device
Capacity, and calculate the difference between the capacity of the target partition and the size of the target image file, and do not exist in the difference
When in preset error range, outputting alarm information, so that related personnel is able to know the target image file actually not
Dilatation success, and then it is able to the validity of verifying dilatation, realize the fool-proof design to dilatation.
Another embodiment of the application provides a kind of dilatation detection method, which is applied to electronic device, should
Electronic device can be the equipment of the mountable application programs such as smart phone, tablet computer, wearable device, above-mentioned electronic device
Operating system can be ios, android, windows system or other operating systems, be not construed as limiting herein.The application is implemented
Dilatation detection method in example is to realize producing line fool proof, that is, the dilatation detection method to be applied to the production in electronic device
In line, so that Automatic sieve finds the electronic device and outputting alarm information of dilatation failure, the electronic device is avoided to be flowed into user
In hand.
Referring to Fig. 2, the dilatation detection method mainly includes the following steps that:
Step 201, when electronic device is moved to a default station on the production line of the electronic device, obtain electronics respectively
The capacity of the size of target image file and target partition in device;
In the embodiment of the present application, a station is set on the production line of electronic device for having to the dilatation of the electronic device
Effect property is detected.Above-mentioned default station is arranged in after the station for initializing the electronic device, to ensure target image file
It is processed before the electronic device is moved to above-mentioned default station by dilatation.
Wherein, above-mentioned target image file is by the processed image file of dilatation, and above-mentioned target partition is to load
The subregion of above-mentioned target image file.
In the embodiment of the present application, dilatation processing refers to the size for increasing the image file not loaded using dilatation instruction.Example
such asandroidin the system,system.imganduserdata.imgusually implementExt4 ( the fourth generation extended file system )
Format building, therefore, it is possible to use resize2fs order carries out dilatation processing to the image file not loaded.
It should be noted that, although target image file is processed by dilatation, it is not intended that target image file energy
Enough dilatation successes (such as it is possible that because the reasons such as process occupation problem, target partition remaining space deficiency cause dilatation to fail),
It finds in practical applications, even if target image file is handled by dilatation and prompts dilatation success, the reality of the target image file
Border size is also possible to not change.That is, the target image file may also even if target image file is processed by dilatation
Original size is kept, and the situation can detect that by dilatation detection method provided by the embodiments of the present application.
Optionally, when electronic device is moved to a default station on the production line of the electronic device, by control equipment (example
Such as PC) to one test instruction of above-mentioned electronic device transmission, " mesh in acquisition electronic device respectively is executed to trigger above-mentioned electronic device
The movement of the size of mark image file and the capacity of target partition ".In this scenario, step 201 includes:It receives from control
The test of equipment instructs;Above-mentioned test instruction instruction under, respectively obtain electronic device in target image file size with
And the capacity of target partition.
Difference between step 202, the capacity for calculating above-mentioned target partition and the size of above-mentioned target image file;
It is to enable the usable range of target image file to use up to the main purpose that target image file carries out dilatation
Entire target partition may be covered.Therefore, in the embodiment of the present application, the capacity and above-mentioned target mirror image of above-mentioned target partition are calculated
Difference between the size of file, to know between the capacity of above-mentioned target partition and the size of above-mentioned target image file
Difference.
For example, setting the capacity of above-mentioned target partition as sizea, the size of above-mentioned target image file is sizeb, then
Step 202 is the capacity and above-mentioned target image file for showing as calculating above-mentioned target partition by formula sizea-sizeb
Difference between size.
If step 203, above-mentioned difference be not in preset error range, outputting alarm information, to prompt above-mentioned target
Image file dilatation failure;
In the embodiment of the present application, an error range is preset, when above-mentioned difference is not in above-mentioned error range, can be sentenced
The fixed above-mentioned non-dilatation of target image file is successful, at this time outputting alarm information, so that related personnel knows the target image file
Dilatation failure.
Optionally, an indicator light and/or buzzer are set on above-mentioned default station, when above-mentioned difference is not in above-mentioned error
When in range, pass through above-mentioned indicator light and/or buzzer outputting alarm information.
Optionally, if step 201 is triggered under the instruction of the test instruction from control equipment (such as PC),
After step 202, above-mentioned difference can be returned to above-mentioned control equipment, so that whether above-mentioned control equipment judges above-mentioned difference
Above-mentioned warning information is exported in above-mentioned error range, and when determining that above-mentioned difference is in above-mentioned error range.It applies herein
Under scene, step 203 can be shown as:If above-mentioned difference is not in preset error range, defeated by above-mentioned control equipment
Warning information out, to prompt above-mentioned target image file dilatation to fail.
In the embodiment of the present application, when above-mentioned control equipment detects above-mentioned difference in above-mentioned error range, show above-mentioned
Target image file dilatation success, can not export indication signal, alternatively, can also export to be above-mentioned target mirror image at this time
The successful indication signal of file dilatation, herein without limitation.
Therefore in the embodiment of the present application, when a default work on the production line that electronic device is moved to the electronic device
When position, by obtaining the size of target image file and the capacity of target partition in electronic device, and the target partition is calculated
Capacity and the target image file size between difference, and when the difference is not in preset error range, output
Warning information so that related personnel is able to know the target image file actually not dilatation success, and then is able to verifying and expands
The validity of appearance realizes the producing line fool-proof design to dilatation.
The dilatation detection method in the embodiment of the present application is described with a concrete application scene below, should use
Jing Zhong, above-mentioned dilatation detection method are applied in the line production system of electronic device, the line production system include electronic device and
With the control equipment of the electronic device communication connection.Interaction schematic diagram as shown in Figure 3, the dilatation detection method include:
Step 301, electronic device receive the test instruction from control equipment;
In the embodiment of the present application, it can set when a default station on the production line that electronic device is moved to the electronic device
When, above-mentioned control equipment sends above-mentioned test instruction to above-mentioned electronic device.
The default station is arranged in after the station of the initialization electronic device, to ensure target image file in the electricity
Sub-device is processed before being moved to above-mentioned default station by dilatation.
Step 302, above-mentioned test instruction instruction under, above-mentioned electronic device obtains target mirror in the electronic device respectively
As the size of file and the capacity of target partition;
Wherein, above-mentioned target image file is by the processed image file of dilatation, and above-mentioned target partition is to load
The subregion of above-mentioned target image file.
In the embodiment of the present application, dilatation processing refers to the size for increasing the image file not loaded using dilatation instruction.Example
such asandroidin the system,system.imganduserdata.imgusually implementExt4 ( the fourth generation extended file system )
Format building, therefore, it is possible to use resize2fs order carries out dilatation processing to the image file not loaded.
It should be noted that, although target image file is processed by dilatation, it is not intended that target image file energy
Enough dilatation successes (such as it is possible that because the reasons such as process occupation problem, target partition remaining space deficiency cause dilatation to fail),
It finds in practical applications, even if target image file is handled by dilatation and prompts dilatation success, the reality of the target image file
Border size is also possible to not change.That is, the target image file may also even if target image file is processed by dilatation
Original size is kept, and the situation can detect that by dilatation detection method provided by the embodiments of the present application.
Step 303, above-mentioned electronic device calculate above-mentioned target partition capacity and above-mentioned target image file size it
Between difference;
It is to enable the usable range of target image file to use up to the main purpose that target image file carries out dilatation
Entire target partition may be covered.Therefore, in the embodiment of the present application, the capacity and above-mentioned target mirror image of above-mentioned target partition are calculated
Difference between the size of file, to know between the capacity of above-mentioned target partition and the size of above-mentioned target image file
Difference.
Above-mentioned difference is sent to above-mentioned control equipment by step 304, above-mentioned electronic device.
Step 305, above-mentioned control equipment detect above-mentioned difference whether in above-mentioned error range, and are determining above-mentioned difference
306 are entered step when not in above-mentioned error range;307 are entered step when determining that above-mentioned difference is in above-mentioned error range.
Step 306, outputting alarm information, to prompt above-mentioned target image file dilatation to fail.
Step 307 terminates to the dilatation testing process of above-mentioned electronic device.
Fig. 4 provides a kind of electronic device for the embodiment of the present application.The electronic device can be used for realizing above-mentioned Fig. 1 to Fig. 3 institute
Show the dilatation detection method that embodiment provides.As shown in figure 4, the electronic device mainly includes:
Acquiring unit 401, for obtaining the size of target image file and the appearance of target partition in electronic device respectively
Amount, wherein the target image file is by the processed image file of dilatation, and the target partition is to load the mesh
Mark the subregion of image file;
Computing unit 402, for calculating between the capacity of the target partition and the size of the target image file
Difference;
Alarm Unit 403 is used for when the difference is not in preset error range, outputting alarm information, with prompt
The target image file dilatation failure.
Optionally, acquiring unit 401 is specifically used for:When one is pre- on the production line that electronic device is moved to the electronic device
If when station, obtaining the size of target image file and the capacity of target partition in electronic device respectively.Wherein, the target
Image file is processed before the electronic device is moved to the default station by dilatation.
Optionally, acquiring unit 401 includes:
Receiving unit, for receiving the test instruction from control equipment;
Sub- acquiring unit, for obtaining target image file in electronic device respectively under the instruction of the test instruction
Size and target partition capacity.
Optionally, the electronic device in the embodiment of the present application further includes:
Transmission unit, for the difference to be sent to the control equipment, to trigger described in the control equipment judgement
Difference exports the warning information when determining that the difference is in the error range whether in the error range.
Optionally, the target image file is specially user data image file, and the target partition is specially user
Data subregion;Acquiring unit 401 is specifically used for:The size of user data image file and user in electronic device are obtained respectively
The capacity of data subregion.
It should be noted that the division of each functional module is only to lift in the embodiment of the exemplary electronic device of figure 4 above
Example explanation, can according to need in practical application, such as the convenient of realization of configuration requirement or software of corresponding hardware considers,
And be completed by different functional modules above-mentioned function distribution, i.e., the internal structure of electronic device is divided into different function moulds
Block, to complete all or part of the functions described above.Moreover, in practical applications, the corresponding function in the present embodiment
Module can be by corresponding hardware realization, can also execute corresponding software by corresponding hardware and complete.This specification provides
Each embodiment all can apply foregoing description principle, repeat no more below.
The detailed process of the respective function of each Implement of Function Module, refers to above-mentioned figure in electronic device provided in this embodiment
1 to particular content described in Fig. 3 any embodiment, and details are not described herein again.
Therefore divided in the embodiment of the present application by obtaining the size and target of target image file in electronic device
The capacity in area, and calculate the difference between the capacity of the target partition and the size of the target image file, and the difference not
When in preset error range, outputting alarm information, so that related personnel is able to know the target image file actually simultaneously
Non- dilatation success, and then it is able to the validity of verifying dilatation, realize the fool-proof design to dilatation.
The embodiment of the present application provides a kind of electronic device, referring to Fig. 5, the electronic device includes:
Memory 501, processor 502 and it is stored in the computer journey that can be run on memory 501 and on processor 502
Sequence when processor 502 executes the computer program, realizes dilatation described in earlier figures 1 to any shown embodiment of the method for Fig. 3
Detection method.
Further, which further includes:
At least one input equipment 503 and at least one output equipment 504.
Above-mentioned memory 501, processor 502, input equipment 503 and output equipment 504, are connected by bus 505.
Wherein, input equipment 503 concretely camera, touch panel, physical button or mouse etc..Output equipment
504 concretely display screens.
Memory 501 can be high random access memory body (RAM, Random Access Memory) memory,
It can be non-labile memory (non-volatile memory), such as magnetic disk storage.Memory 801 is for storing one
Group executable program code, processor 802 are coupled with memory 801.
Further, the embodiment of the present application also provides a kind of computer readable storage medium, the computer-readable storages
Medium can be in the electronic device being set in the various embodiments described above, which can be earlier figures 5
Memory in illustrated embodiment.It is stored with computer program on the computer readable storage medium, which is held by processor
Dilatation detection method described in earlier figures 1 to Fig. 3 either method embodiment is realized when row.Further, which can deposit
Storage media can also be USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), RAM, magnetic or disk
Etc. the various media that can store program code.
In several embodiments provided herein, it should be understood that disclosed device and method can pass through it
Its mode is realized.For example, the apparatus embodiments described above are merely exemplary, for example, the division of the module, only
Only a kind of logical function partition, there may be another division manner in actual implementation, such as multiple module or components can be tied
Another system is closed or is desirably integrated into, or some features can be ignored or not executed.Another point, it is shown or discussed
Mutual coupling, direct-coupling or communication connection can be through some interfaces, the INDIRECT COUPLING or logical of device or module
Letter connection can be electrical property, mechanical or other forms.
The module as illustrated by the separation member may or may not be physically separated, aobvious as module
The component shown may or may not be physical module, it can and it is in one place, or may be distributed over multiple
On network module.Some or all of the modules therein can be selected to realize the mesh of this embodiment scheme according to the actual needs
's.
It, can also be in addition, can integrate in a processing module in each functional module in each embodiment of the application
It is that modules physically exist alone, can also be integrated in two or more modules in a module.Above-mentioned integrated mould
Block both can take the form of hardware realization, can also be realized in the form of software function module.
If the integrated module is realized in the form of software function module and sells or use as independent product
When, it can store in a computer readable storage medium.Based on this understanding, the technical solution of the application is substantially
The all or part of the part that contributes to existing technology or the technical solution can be in the form of software products in other words
It embodies, which is stored in a readable storage medium storing program for executing, including some instructions are used so that a meter
It calculates machine equipment (can be personal computer, server or the network equipment etc.) and executes each embodiment the method for the application
All or part of the steps.And readable storage medium storing program for executing above-mentioned includes:USB flash disk, mobile hard disk, ROM, RAM, magnetic or disk etc.
The various media that can store program code.
It should be noted that for the various method embodiments described above, describing for simplicity, therefore, it is stated as a series of
Combination of actions, but those skilled in the art should understand that, the application is not limited by the described action sequence because
According to the application, certain steps can use other sequences or carry out simultaneously.Secondly, those skilled in the art should also know
It knows, the embodiments described in the specification are all preferred embodiments, and related actions and modules might not all be this Shen
It please be necessary.
In the above-described embodiments, it all emphasizes particularly on different fields to the description of each embodiment, there is no the portion being described in detail in some embodiment
Point, it may refer to the associated description of other embodiments.
The above are retouching to message informing method provided herein, electronic device and computer readable storage medium
It states, for those skilled in the art, according to the thought of the embodiment of the present application, can in specific embodiments and applications
There is change place, to sum up, the contents of this specification should not be construed as limiting the present application.
Claims (10)
1. a kind of dilatation detection method, which is characterized in that including:
The size of target image file and the capacity of target partition in electronic device are obtained respectively, wherein the target mirror image
File is by the processed image file of dilatation, and the target partition is the subregion to load the target image file;
Calculate the difference between the capacity of the target partition and the size of the target image file;
If the difference is not in preset error range, outputting alarm information, to prompt the target image file dilatation
Failure.
2. dilatation detection method according to claim 1, which is characterized in that described to obtain target mirror in electronic device respectively
As the size of file and the capacity of target partition are:
When electronic device is moved to a default station on the production line of the electronic device, target in electronic device is obtained respectively
The size of image file and the capacity of target partition;
Wherein, the target image file is processed before the electronic device is moved to the default station by dilatation.
3. dilatation detection method according to claim 1 or 2, which is characterized in that described to obtain mesh in electronic device respectively
The size of mark image file and the capacity of target partition include:
Receive the test instruction from control equipment;
Under the instruction of the test instruction, the size and target partition of target image file in electronic device are obtained respectively
Capacity.
4. dilatation detection method according to claim 3, which is characterized in that the capacity for calculating the target partition with
After difference between the size of the target image file, further include:
The difference is sent to the control equipment, determines the difference whether in the error to trigger the control equipment
In range, and the warning information is exported when determining that the difference is in the error range.
5. dilatation detection method according to claim 1 or 2, which is characterized in that the target image file is specially to use
User data image file, the target partition are specially user data subregion;
The size of target image file and the capacity of target partition are in the electronic device of acquisition respectively:
The size of user data image file and the capacity of user data subregion in electronic device are obtained respectively.
6. a kind of electronic device, which is characterized in that including:
Acquiring unit, for obtaining the capacity of the size of target image file and target partition in electronic device respectively, wherein
The target image file is by the processed image file of dilatation, and the target partition is to load the target mirror image text
The subregion of part;
Computing unit, for calculating the difference between the capacity of the target partition and the size of the target image file;
Alarm Unit is used for the outputting alarm information, to prompt the target when the difference is not in preset error range
Image file dilatation failure.
7. electronic device according to claim 6, which is characterized in that
The acquiring unit is specifically used for:When electronic device is moved to a default station on the production line of the electronic device,
The size of target image file and the capacity of target partition in electronic device are obtained respectively;
Wherein, the target image file is processed before the electronic device is moved to the default station by dilatation.
8. electronic device according to claim 6 or 7, which is characterized in that the acquiring unit includes:
Receiving unit, for receiving the test instruction from control equipment;
Sub- acquiring unit, for it is described test instruction instruction under, respectively obtain electronic device in target image file it is big
Small and target partition capacity.
9. a kind of electronic device, including:It memory, processor and is stored on the memory and can transport on the processor
Capable computer program, which is characterized in that when the processor executes the computer program, realize in claim 1 to 5 and appoint
Method described in meaning one.
10. a kind of computer readable storage medium, is stored thereon with computer program, which is characterized in that the computer program
When being executed by processor, method described in any one of claim 1 to 5 is realized.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810612231.6A CN108829541A (en) | 2018-06-14 | 2018-06-14 | Dilatation detection method, electronic device and computer readable storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810612231.6A CN108829541A (en) | 2018-06-14 | 2018-06-14 | Dilatation detection method, electronic device and computer readable storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108829541A true CN108829541A (en) | 2018-11-16 |
Family
ID=64141942
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810612231.6A Pending CN108829541A (en) | 2018-06-14 | 2018-06-14 | Dilatation detection method, electronic device and computer readable storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108829541A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110222019A (en) * | 2019-05-08 | 2019-09-10 | 安克创新科技股份有限公司 | The method of adjustment and device that file system is taken up space |
CN110321334A (en) * | 2019-05-24 | 2019-10-11 | 平安银行股份有限公司 | The method and device of database auto-partition dilatation |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104615657A (en) * | 2014-12-31 | 2015-05-13 | 天津南大通用数据技术股份有限公司 | Expanding and shrinking method for distributed cluster with nodes supporting multiple data fragments |
CN105224419A (en) * | 2015-09-24 | 2016-01-06 | 青岛海信移动通信技术股份有限公司 | User data mirror image loading method, device and terminal in a kind of Android system |
CN106250207A (en) * | 2016-07-27 | 2016-12-21 | 汉柏科技有限公司 | A kind of virtual machine dilatation processing method and processing device |
CN107133331A (en) * | 2017-05-11 | 2017-09-05 | 郑州云海信息技术有限公司 | The automatic expansion method of database and device realized based on shell scripts |
-
2018
- 2018-06-14 CN CN201810612231.6A patent/CN108829541A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104615657A (en) * | 2014-12-31 | 2015-05-13 | 天津南大通用数据技术股份有限公司 | Expanding and shrinking method for distributed cluster with nodes supporting multiple data fragments |
CN105224419A (en) * | 2015-09-24 | 2016-01-06 | 青岛海信移动通信技术股份有限公司 | User data mirror image loading method, device and terminal in a kind of Android system |
CN106250207A (en) * | 2016-07-27 | 2016-12-21 | 汉柏科技有限公司 | A kind of virtual machine dilatation processing method and processing device |
CN107133331A (en) * | 2017-05-11 | 2017-09-05 | 郑州云海信息技术有限公司 | The automatic expansion method of database and device realized based on shell scripts |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110222019A (en) * | 2019-05-08 | 2019-09-10 | 安克创新科技股份有限公司 | The method of adjustment and device that file system is taken up space |
CN110222019B (en) * | 2019-05-08 | 2023-12-19 | 安克创新科技股份有限公司 | Method and device for adjusting space occupied by file system |
CN110321334A (en) * | 2019-05-24 | 2019-10-11 | 平安银行股份有限公司 | The method and device of database auto-partition dilatation |
CN110321334B (en) * | 2019-05-24 | 2024-03-19 | 平安银行股份有限公司 | Method and device for automatic partition capacity expansion of database |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108073519B (en) | Test case generation method and device | |
CN109597677A (en) | Method and apparatus for handling information | |
CN107608609B (en) | Event object sending method and device | |
CN111176739A (en) | System starting method, device, equipment and storage medium | |
CN106095528B (en) | A method of detection virtual machine drive | |
JP6283096B2 (en) | Program test service | |
CN108829541A (en) | Dilatation detection method, electronic device and computer readable storage medium | |
CN110516447A (en) | A kind of method and apparatus of identification terminal simulator | |
CN108459906B (en) | Method and device for scheduling VCPU (virtual host processor unit) thread | |
US11366800B2 (en) | System and method to automate validating media redirection in testing process | |
CN109460187B (en) | Verification method and verification terminal for data consistency of qcow2 file | |
US20120054560A1 (en) | Verifying correctness of processor transactions | |
CN114064079A (en) | Packing method and device of algorithm application element, equipment and storage medium | |
CN110515671A (en) | Initial method, apparatus for initializing, terminal device and readable storage medium storing program for executing | |
CN110261758B (en) | Device under test verification device and related product | |
CN115599618B (en) | Register dynamic change-allocation verification method and device, storage medium and processor | |
CN107491316A (en) | Extended method, device and the electronic equipment of baseboard management controller | |
CN113272785B (en) | Method for mounting file system, terminal equipment and storage medium | |
US20080215806A1 (en) | Access control management | |
CN114675978A (en) | Operation framework of algorithm application element, data processing method, equipment and storage medium | |
CN108415656B (en) | Display control method, device, medium and electronic equipment in virtual scene | |
CN115063913B (en) | Identity information input method and device based on optical character recognition and related equipment | |
CN112580086A (en) | Access protection method, device, equipment and storage medium for configuration file | |
CN110134639A (en) | A kind of facility information storage location recognition methods and device | |
CN112527571A (en) | CPU instruction set coverage rate calculation 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 | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20181116 |
|
RJ01 | Rejection of invention patent application after publication |