Android a2sd versions and technical explanations

Source: Internet
Author: User

From: http://como0925.pixnet.net/blog/post/29390286-%5Bandroid%5D%E9%97%9C%E6%96%BCapp2sd,a2sd,data2sd,a2sd%2B%E4%B9%8B%E9%96%93%E7%9A%84%E5%8D%80%E5%88%A5%E5%92%8C

First, let's take a look at these functions. All they mean application to the SD card, that is, the application will be installed on the card. Why do we need to do this? That is because the local memory of the hd2 original mobile machine is only 512 MB (the T version has 1 GB Rom space), and the Android (miui) the system is flushed into the mobile device. There are mainly a number of images using the local memory of the mobile device: 1,/system; 2,/data, 3; cache; 4./boot. These projects basically use MB of space. When we perform DAF recovery ing, in fact, it is the segmentation of these segments for M. The main difference is that the 512m space is/System and/data, however, the usage process of the/system is not long enough, as long as we leave enough space, it is okay to make sure that the total number of files in the ROM/system category of the machine can be copied to the/system partition, at present, the total number of miui/system object files is approximately 105.36 mb. To solve this problem, you may need to enter ding. I gave 128 MB, or MB, the earliest DAF recovery to/system has a space of 150 mb. If it is changed to 128 or, you can add more than MB of space to other zones, for example,/data (it is assumed that all the remaining space will be allocated to/data category ). /Data is the main component security location. In this case, all the parts except the component and component are stored in this directory. So this project can have at most less than MB of space (T edition has MB of space, so don't worry too much ), the m space will soon be used up when there are multiple hosts such as luxury cars. So in order to allow the program file to use the space of the SD card, various solutions of app2sd, a2sd, data2sd, and a2sd + are available. In fact, this is not a precedent for miui, this is also true for other Android phones. So let's talk about the features and regions of these four solutions separately:

(1) app2sd is an official solution of Google's official Android system. It is similar to WM, which places some of the main line files of the application program on the SD card, these files are stored on the FAT32 SD card. In this way, you do not need to partition the SD card. Instead, you just need to format the SD card as the FAT32 partition in windows, the missing point is that not all programs can be moved to the card, because some programs need to store content frequently and, in some cases, to save power, you may need to turn on the card for power supply, so it may cause problems in program operation. If you use a firmware file like 91 or a PC assistant to install the agent on the SD card, the desktop plug-in cannot run normally. This is also unacceptable to us, so basically players will not use this method.

(2) a2sd: in fact, there are two types of points in my search for webpages. One is a2sd, the other is app2sd, and the other is a2sd +. Through my analysis, a2sd is actually the app2sd of zookeeper. Therefore, we regard app2sd and a2sd as the official solution to use the SD card to store the program files. This is similar to the app2sd solution, which is basically not used by gamers.

(3) data2sd is similar to running Android on the card. This solution creates a data on the card. IMG file. In fact, this file is the data of the system/Data Partition. This solution is similar to the android method used to run on the card, only data. imgfile. Other files are stored on the mobile phone. Data. the imgfile is on the SD card of the FAT32 partition. In this way, the encrypted file is data. the size of the imgfile can be controlled freely from MB to 2 GB or even more than the limit, and there is no need to partition the SD card. But the problem is that data. in the FAT32 area of the SD card, similar issues such as Screen Copy still exist and cannot be avoided, when you enter the province mode, the SD card will be switched to the power supply, causing the entire body of the mobile phone to run normally. However, many of my friends use data. IMG is mainly because it is easier than just reading it. If you are a beginner and you are not sure about the area of my above tutorial, you can also use this method (this method is simple when we look at data2sd), but in my opinion this is not the best solution, even if it has many points of attention, its lack of points is also very slow. It is suggested that gamers should be used at the beginning of the proposal, but not gamers in the high school.

(4) a2sd +: the name indicates that a2sd + only has one more + than a2sd, but the technology is completely different. It uses andoird (Linux) but other regions to use the SD card. Because this partition is used by the hardware, although these partitions are on the SD card, Android regards this as a local memory hardware, you can see the mmcblk0p1, mmcblk0p2, and mmcblk0p3 files in the/dev/block object directory of the hypervisor, in fact, this is the hardware name of our FAT32, ext3, and swap partitions. We need to use the ext3 partition for the/data category, so what we use is to create a/SD-ext category so that it can be mounted) in the mmcblk0p2 (ext3) region, the app, app-private, and Dalvik-Cache are created under/SD-Ext, and then the link technology is used, the link technology is used to connect the category of the app, app-private, and Dalvik-Cache under the/data category to another category, any operation between the two links and the link object is performed in the Link object) to the three projects under the/SD-ext category, this process is actually done when the command a2sd reinstall and a2sd cachesd. A2sd reinstall copies/data/APP and/data/APP-private files to/SD-ext/APP and/SD respectively. -ext/APP-private, in this case, a2sd cachesd copies/data/Dalvik-Cache files to/SD-ext/Dalvik-Cache files, then, the Project LINK will go over. In this way, our program security is under the three categories of/data, in practice, the SD card ext3 partition space used by the/SD-ext object category is used, as a result, there are not many changes in the phone memory after the security program is found. So what are app, app-private, and Dalvik-cache? The app is the security location of our APK program. If you have an encrypted program, it will enter the app-Private category, dalvik-cache is the memory of the program. These three projects use the space occupied by the main program security, then we will still wonder why the mobile phone memory will remain small, but it will be slower. That is because when the security program is running, the/data category will also increase, but not too many. However, why can't the a2sd + technology link/data category to/SD-ext category, I think/data requires better stability and speed. If you link/data to the card, the screen may appear, in this case, I guess. I have moved/data/Data Pipeline to/SD-ext/data (my own project), and the system will be very uncertain, in addition, there are auto-scaling images. However, even if we have less than MB of phone memory (in fact, the size of the/Data Partition can be viewed in file management of the 91 or PC assistant ), however, the main program enters the app or app-Private category, and the stored data enters the Dalvik-Cache category, /data does not consume too much space, which is acceptable. This solution lacks technical skills. New users can understand and need to learn more knowledge (in practice, they will have a sense of accomplishment !). However, this feature applies to Android (Linux) technology. Because ext3 and swap do not recognize SD cards in different regions, due to insufficient power consumption, this solution is the most specific and does not involve the ext3 and swap partitions.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.