Android equivalent of windows hosts file?

This is a discussion on Android equivalent of windows hosts file? within the Nexus One forums, part of the Google Phones category; I want to block some domains on my N1 in the same way I would in windows in the hosts file with 127.0.0.1 baddomain.com. Is ...

Results 1 to 9 of 9

Thread: Android equivalent of windows hosts file?

  1. #1
    Senior Member dd4005's Avatar
    Join Date
    Apr 2010
    Posts
    390

    Android equivalent of windows hosts file?

    I want to block some domains on my N1 in the same way I would in windows in the hosts file with 127.0.0.1 baddomain.com. Is that possible?

  2. Android.net is the premier Android Forum. Registered users do not see these ads. .

  3. #2
    jeh
    jeh is offline
    Junior Member jeh's Avatar
    Join Date
    Mar 2010
    Posts
    6
    Quote Originally Posted by dd4005 View Post
    I want to block some domains on my N1 in the same way I would in windows in the hosts file with 127.0.0.1 baddomain.com. Is that possible?
    the windows host file is equivalent of a unix /etc/hosts file. I imagine you could edit it if you were rooted.

    -j

  4. #3
    Senior Member dd4005's Avatar
    Join Date
    Apr 2010
    Posts
    390
    Quote Originally Posted by jeh View Post
    Quote Originally Posted by dd4005 View Post
    I want to block some domains on my N1 in the same way I would in windows in the hosts file with 127.0.0.1 baddomain.com. Is that possible?
    the windows host file is equivalent of a unix /etc/hosts file. I imagine you could edit it if you were rooted.

    -j
    Thanks. I'm trying to avoid getting rooted, after reading the downsides of it.

    Is there such a thing as a list of secret codes/modes that get you into any hidden menus?

  5. #4
    Senior Member FlyingsCool's Avatar
    Join Date
    Feb 2010
    Posts
    369
    Look for an app called "ES File Explorer" by EStrongs. It'll let you look at all your files on your N1. Once installed, hit the / button at the top, you'll see your etc directory in there and it'll let you edit your hosts file.

  6. #5
    Senior Member dd4005's Avatar
    Join Date
    Apr 2010
    Posts
    390
    Quote Originally Posted by FlyingsCool View Post
    Look for an app called "ES File Explorer" by EStrongs. It'll let you look at all your files on your N1. Once installed, hit the / button at the top, you'll see your etc directory in there and it'll let you edit your hosts file.
    Thanks, that sounds ideal. I've found it with a regular google search but can't find it via my phone in the market. I'm still a Nexus/Android noob, what places other than the market are there from which I can trust app downloads? The fact that it's not available in the market scares me a little.

  7. #6
    Senior Member FlyingsCool's Avatar
    Join Date
    Feb 2010
    Posts
    369
    just search the app store for "estrongs"

  8. #7
    Senior Member dd4005's Avatar
    Join Date
    Apr 2010
    Posts
    390
    Quote Originally Posted by FlyingsCool View Post
    just search the app store for "estrongs"
    Thanks a huge amount. I grabbed their task manager too. A pair of pretty cool apps.

    I gotta go look around this forum more and see if there's a list of the most-recommended apps. There's bound to be tons of 'em that I want but I don't know I want them yet

    edit: found the thread I needed for most recommended apps

  9. #8
    Junior Member abulfurqan's Avatar
    Join Date
    Apr 2010
    Posts
    1
    dd4005, were you able to modify your host file without rooting? I tried it the way FlyingsCool described, but i get file save error when I try to save it. I copied the file over to sd card and was able to modify it there. But when I cope/paste from the sd card back to etc folder, it doesn't do anything. I just wanted to know if I missed something and if you were able to figure it out. Thanks!

  10. #9
    Senior Member dd4005's Avatar
    Join Date
    Apr 2010
    Posts
    390
    Quote Originally Posted by abulfurqan View Post
    dd4005, were you able to modify your host file without rooting? I tried it the way FlyingsCool described, but i get file save error when I try to save it. I copied the file over to sd card and was able to modify it there. But when I cope/paste from the sd card back to etc folder, it doesn't do anything. I just wanted to know if I missed something and if you were able to figure it out. Thanks!
    Actually, I asked that question in advance of needing to do it. I always end up adding things to the hosts file on my computers that I want to block and figured I'd want to do it on my phone. I haven't needed to yet though.

    I did just try it though. I used that ES file explorer to get to /etc and edited the hosts file and like you I was unable to save it. This is where a chmod command would come in handy to set the properties. When I looked at the file properties in the ES file explorer, it shows it's read-only and it doesn't offer the ability to change that.

    We either need to root our phones, or find a better explorer that offers the ability to set it to be writeable. I personally don't want to root my phone, I haven't seen any advantages other than this for doing so yet. When they start to stack up I'll consider it.

    Something else I just thought of that might set it writeable for us is an ad blocker. They usually add a big list of domains to it and it might just leave it writeable.

Remove Ads

http://www.scramblerducati.org/

Sponsored Links

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Search tags for this page

android equivalent to hosts file

,

android host file

,
android hosts
,

android hosts file

,
android page file equivalent
,

android tablet hosts file

,
edit host file on android razr
,
host file tablet android
,
hosts android windows are they the samee
,

hosts file android tablet

,
hosts file equivalent android
,
hosts file on galaxy s4
,
nexus 7 edit hosts file
,

nexus 7 host file

,

nexus 7 hosts file

Click on a term to search our sites for related topics.
Android Forum