-
What is a "hosts" file? Where is it? Is it safe to manually edit it?
That's it unless you want to know why I am considering editing my "hosts" file.
-
I think it's basically a shortcut to the normal DNS. Instead of looking 'out there' the computer looks first at the Hosts file for the actual address of a site or another machine on the web/LAN.
No problem editing them at all, although it's been a while since I did. I'd suggest making a copy of the one you now have, just in case you mess up the edited one, of course. Any text editor should work fine, stay away from a word processor or just make sure it can save a pure text file ( no suffix needed ).
Many places/forums share Hosts files from different people, they'll work on any computer that can use them. People spend time creating sets of sites that they like and upload them to those that might also like them. Actually, I think you can also add sites/addresses that you don't want anyone to visit ( like a child? ).
-
Interesting listen.

http://www.twit.tv/security_now/the_hosts_file
http://www.twit.tv/SN
-
Thanks bunches ABD and kelly. I learned something new today. I'm gonna leave it be ... especially since I can't seem to find it on my machine.
-
Well it's invisible I believe kimmer.

http://en.wikipedia.org/wiki/Hosts_file
Maybe you shouldn't play with it.
-
it's in /etc
Finder...GO...Go to folder...
type in: /etc
press enter
to edit it...if you change your mind...you may have to be root.
but you can double-click it and read it in TextEdit.
Mine looks like this:
CODE
##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost
-
kps, thanks. I may find it and make a copy and open it just to see it with my eyes.
kelly, I think it's invisible for good reason. From what I heard in that broadcast I could make a mess of things if I edited willy-nilly. I'll just wait for the DNS servers to catch up with the one boards move. I don't have any pressing "admin" questions anyhow.
-
I think with the development of better ad-blocking software and the increased speeds for many to access the net, need for these host files has diminished. Seems they tended to become used more for stopping access to more sites than speed it up for a few.
-
QUOTE(kimmer @ Mar 1 2007, 02:13 AM) [snapback]120524[/snapback]
Thanks bunches
ABD and
kelly. I learned something new today. I'm gonna leave it be ... especially since I can't seem to find it on my machine.

As others have already said, it lives in /etc.
It's just a simple text file; you can edit it easily with any text editor. If you start putting all kinds of things in there, you may interfere with your ability to surf the Web, but if you do, it's no big deal; you can always just go back and remove any changes you make if you screw something up.
Playing with the hosts file can be a good way to learn about how the Internet works. The hosts file is just a directory of names and IP addresses: "this name means this IP address, that name means that IP address." It's straightforward and painless to edit, and easy to undo any mistakes you make.
When you deal with IP addresses, there are a couple of addresses that are "special." The one that you should learn is 127.0.0.1, which means "this computer." If you set something's IP address to 127.0.0.1 in the hosts file, that means your computer will only look on itself to find that Web site, and will not look on the Internet. That is why you can block ads from being seen by setting the advertiser's address to 127.0.0.1 in the hosts file. The computer will say "Hmm, I'm looking for a banner ad on doubleclick.net. Let's see. Doubleclick.net is 127.0.0.1. Let me look on this computer...nope, can't find it, so I just won't show that banner, and I'll move on."
-
QUOTE
The computer will say "Hmm, I'm looking for a banner ad on doubleclick.net. Let's see. Doubleclick.net is 127.0.0.1. Let me look on this computer...nope, can't find it, so I just won't show that banner, and I'll move on."
Can I make the computer be quiet by using "0.0.0.0" or even "0"?
-
QUOTE(Xairbusdriver @ Mar 1 2007, 08:05 PM) [snapback]120581[/snapback]
Can I make the computer be quiet by using "0.0.0.0" or even "0"?

Yep. Any non-routeable IP address will do. I generally don't use 0.0.0.0, because it's reserved for the "default network route," and I have heard apocryphally that it can cause problems with some routers, though I don't know if that's actually the case or not.
-
QUOTE(tacit @ Mar 1 2007, 10:36 AM) [snapback]120571[/snapback]
When you deal with IP addresses, there are a couple of addresses that are "special." The one that you should learn is 127.0.0.1, which means "this computer."
Yes, this I knew. Yeah for me. I've got one thing down. LOL!
QUOTE
If you set something's IP address to 127.0.0.1 in the hosts file, that means your computer will only look on itself to find that Web site, and will not look on the Internet. That is why you can block ads from being seen by setting the advertiser's address to 127.0.0.1 in the hosts file. The computer will say "Hmm, I'm looking for a banner ad on doubleclick.net. Let's see. Doubleclick.net is 127.0.0.1. Let me look on this computer...nope, can't find it, so I just won't show that banner, and I'll move on."
So I can actually block - totally block certain very annoying advertisers? Now this sounds interesting.
I may yet have to try this out. Just for kicks. Yes, playing with things is a good way to learn.
Today I learned a small bit about "bash" and "cpanel" and "scripts" and my head is spinning from it all.
Thanks for the good lessons.
-
QUOTE(kimmer @ Mar 2 2007, 01:53 AM) [snapback]120603[/snapback]

So I can actually block - totally block certain very annoying advertisers?
Yep! Find the URL that is serving up the ads, and put that URL in your hosts file with 127.0.0.1 as the IP address. Ta-da, goodby ads!
-
LOL! I tried it. I love it!!!!!!
Thanks for the tip!!!!!!