Saturday, April 9, 2016

Should 127.0.0.1 and ::1 both be included in /etc/hosts file?



I am new to unmanaged VPS servers and in addition IPv6. Is it necessary to include 127.0.0.1 AND ::1 for localhost in /etc/hosts files for IPv6 enabled servers, or is ::1 alone enough?


Answer



Yes, 127.0.0.1 should be left. IPv6 is enabled, but IPv4 is still used.


No comments:

Post a Comment

linux - How to SSH to ec2 instance in VPC private subnet via NAT server

I have created a VPC in aws with a public subnet and a private subnet. The private subnet does not have direct access to external network. S...