1

I'm trying to get Adaway to work on 7.1 beta on my Nexus 6P. Unfortunately, the flashable zip did not work to move the hosts out of system. Neither did the flashable hosts file. I tried some of the workarounds to move the hosts file through the terminal, and that did not work. Finally, there were some suggestions of having BusyBox installed, and it does not seem to want to work.

The phone I'm running is on 7.1 beta, encrypted, with stock recovery, and phh's superuser.

1 Answer 1

0

Plug your phone in, open up terminal, and open the shell

adb shell

Now execute the following. Pro tip: $ = non root, # root. If root, 'exit' to go back to non-root.

angler:/ $ su
angler:/data/data # rm /data/su/binds
angler:/data/data # exit
angler:/ $ su --bind --ls
angler:/ $ su --bind /data/hosts:/system/etc/hosts
angler:/ $ su --bind --ls
2000 /data/hosts => /system/etc/hosts

Double check to see if you have two hosts files

angler:/ $ su
angler:/data/data # ls -l /data/data/hosts /data/hosts /system/etc/hosts /su
ls: /su: No such file or directory
-rw-r--r-- 1 root root 2109504 2016-10-25 13:38 /data/data/hosts
-rw-r--r-- 1 root root 2109504 2016-10-25 13:37 /data/hosts
-rw-r--r-- 1 root root      56 2009-01-01 00:00 /system/etc/hosts

Remove the second hosts file

angler:/ $ su --bind '!system/etc/hosts'

Go to AdAway, Preferences, target location, select /data/hosts Apply AdBlocking, do not create symlink.

Reboot.

Open up AdAway, it should be enabled.

Sources:

  1. https://www.reddit.com/r/Nexus6P/comments/528mfs/help_with_adaway_on_android_n/d7js3sj/?context=10000
  2. https://www.reddit.com/r/Nexus6P/comments/59cm1u/how_do_you_get_adaway_to_update_the_hosts_file_on/

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .