hosts - Desire Q&A, Help & Troubleshooting

I have a question, i need to edit my hosts file
I have find 2 hosts files, the first in /etc and the other one in /system/etc
What the difference ?
When i tried to edit with root explorer the file disappear in the folder after saving !
When i reboot the device the file is back again but not modified

Related

[Q] Edit hosts file

Hello,
After reading theads about this universal problem.
I'm still looking for a solution to edit hosts file.
I don't want to pay for root explorer app (sorry).
I've tried AdFree but it adds only "127.0.0.1 localhost"
is there a way to edit this f*** file. I've a hosts file to use but no possibilies to use it...
If someone can help me, (s)he will be very kind....
re Hello,
I've seen a thead a patch to make a link to a file on the sdcard (I don't know where on the forum exactly)
Is there someone to help me ?
I recently have been looking into changing my own hosts file. I use Astro with the root option enabled to copy the hosts file in /system/etc/ to my SD card. With Astro you can change file extensions. Rename your SD copy to hosts.txt and you can edit it with ThinkFree. As for copying that back over, I'm not sure if it's as direct. I would suggest using an Android terminal to do the edits because you can edit without having to use ADB (I found all this out through other threads). Make sure you're root(ed) as well (su command). Also you might have to reboot after copying over your new file. My PC has trouble with my hosts file.
Basically what I've seen is that there's a line in the file that the device can't "understand" (or find) perhaps. My PC file has a couple groups of sites that I copied from a website (after checking for loopback). All in all there was a box or something somewhere because the encoding wasn't the right one. (If you add the .txt extension on the device ThinkFree will ask you what encoding. I use the suggested but that's probably my issue on my PC.) My PC kept making a new, blank copy of my hosts and turning my custom one into an iCal file (?).
Hope this helps a little, even though you're only adding one line...
Sent from my SPH-M910 using Tapatalk
Hello
Thanks for the info.
I've manage to do a link to a hosts file located in the sdcard using adb when I'm in recovery mode.
Now When I use AdFree, the app can update without problem the file
Lol you could do adb shell
cd /etc/
cat hosts
and see what it outputs. If it's wrong just do echo urlhere 127.0.0.1 >> hosts
Indirect said:
Lol you could do adb shell
cd /etc/
cat hosts
and see what it outputs. If it's wrong just do echo urlhere 127.0.0.1 >> hosts
Click to expand...
Click to collapse
It's Ok,
when I do this, it outputs all the adress associated with 127.0.0.1
It displays the content of /sdcard/etc/hosts file.
Easy Host File
I have been able to change my hosts file with no paid apps,adb, or recovery. This will work with Astro or ES File Explorer.
Find and download the hosts file you wish to use; I use mvps. If you want to edit it or add entries do so now. To save it with no file extension on Windows under tools-->folder options enable "show file extensions for known types". Control click and select "rename"; rename "hosts.txt" as "hosts". Window will warn you about changing the extension but clear the warning. Copy this to the root of your sdcard.
On your rooted phone open your file manager (Astro or ES) and click menu. Allow root permission. You will see a legend that says your app has been granted superuser privileges. Navigate to sdcard and copy your desired hosts file. Go to root directory and paste the new file in /system/etc. You will get a warning that files will be overwritten/folders merged. Allow. Now you're done, easy money!
---------- Post added at 06:21 PM ---------- Previous post was at 06:15 PM ----------
To avoid a "blank" you have to show file types for known extensions. Editing is easy in Notepad++. This way you can add new annoyances at will. There's no place like 127.0.0.1!
I Understand the good side of your method.
Just a question. Can we do a link (ln -s....) via ADB with the original recovery ( the unrooted one) ?

[Q] Unable to Edit System Files Using any File Explorer

So this is a problem I've had basically since day one with my Nexus 7. No matter what file explorer I use, I can not edit anything in the root directories. Unable to save build.prop edits for example. I am assuming it is a permission thing but I have no idea exactly what I am doing wrong or how to fix it. Any help is appreciated.
Sent from my Nexus 7 using Tapatalk
Are you rooted? If you are - check to see if you are in read only mode in your file manager(s)
Besides requiring root, apps like ES File Explorer need to have root access turned on. Root Explorer needs a directory mounted as R/W.
Best practice, anyway, is to copy a file (especially build.prop) to a regular directory under /sdcard, edit it there, rename the original, then copy back the modified file.
I managed to figure it out. Was using cm file explorer and root browser. Got root browser working by changing permissions on the system folder.
I always copy files into the internal storage before editing. Thanks for the replies.
Sent from my Nexus 7 using Tapatalk

How to edit an xml file in the system\etc folder?

Hi,
I am trying to edit the "mixer_path" file in the system/etc folder in order to solve the problem with the noise in the headphone jack.
The phone is rooted and running CM12.1 and when I try to save the file after editing, it says it can't save the file. Even if I copy the file to another folder and try editing it there (with ES editor)
What should I do? (the permission were set to -rw-r-r- or 644.
Thanks in advance!
Wagnerian said:
Hi,
I am trying to edit the "mixer_path" file in the system/etc folder in order to solve the problem with the noise in the headphone jack.
The phone is rooted and running CM12.1 and when I try to save the file after editing, it says it can't save the file. Even if I copy the file to another folder and try editing it there (with ES editor)
What should I do? (the permission were set to -rw-r-r- or 644.
Thanks in advance!
Click to expand...
Click to collapse
Push file to PC and edit it there?
Well, now I've edited the file accordingly but the phone won't play any track, or any sound at all, for that matter. Doesn't ring etc'... S:
Have any idea why?
So I installed CM12.1 again to fix the problem, but now when I copied the file from system\etc to somewhere on the sdcard, I can't see it when I open the folder on the computer. How come?

Cannot Mount System/etc

Hi.
I was trying to edit my hosts file for adblocking and it seems that i cannot mount the folder for r/w.
I have tried to use adaway and it fails to apply the hosts file.
So i tried to do it manually using FX file explorer and i cannot mount system/etc.
Any help would be good

Can´t delete or write files in sdcard/download

Hi guys, I can´t delete or copy new files in sdcard/download.
For example when I delete a picture in DCIM it works.
I´m rooted and installed ES File Explorer, activated the root explorer and checked the permissions. It says RW right for the download folder.
Any ideas?
Thanks..
ROM? Kernel?

Categories

Resources