PS: Recently in using HTML5 to do mobile development, using the Android emulator, request API, need to modify the host file, find data, find a solution, the steps to record down.
1. Use the cmd command to access the appropriate SDK's Tools folder
2. Execute emulator-avd avdname -partition-size command start simulator
3. Use the CD . (Return to previous level) into the Platform-tools directory
4. Execute the adb root command and wait for the prompt to succeed
5. Execute adb remount command
5. Execute the adb pull/system/etc/hosts command to find the hosts file in the current directory after success
6. Modify the Hosts file and execute the adb push hosts/system/etc/hosts command to push
7. Execute adb shell command, wait for prompt to succeed
8. Execute cat/system/etc/hosts command, view hosts content, confirm success
PS: There must be a space between the command and the path.
@zhnoah
Source: http://www.cnblogs.com/zhnoah/
This article is owned by me and the blog Park, Welcome to reprint, but without the consent of the author must retain this paragraph, and in the article page obvious location to the original
The right to pursue legal liability.
Modifying the host file of the Android emulator