Safari seems to ignore my /etc/hosts file
My /etc/hosts file contains this:
# 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
fe80::1%lo0 localhost
127.0.0.1 youtube.com
When I run the command traceroute youtube.com I receive the expected results (youtube.com is resolved to 127.0.0.1):
traceroute to youtube.com (127.0.0.1), 64 hops max, 52 byte packets
1 localhost (127.0.0.1) 0.272 ms 0.118 ms 0.063 ms
However, when I type youtube.com in Chrome or Safari, my browser doesn't establish a connection with 127.0.0.1 but instead with another IP address. I would have expected Chrome and Safari to resolve youtube.com to 127.0.0.1.
Why are Safari and Chrome seemingly ignoring my /etc/hosts file?
MacBook Air, OS X Mountain Lion (10.8.5)