覆盖ip
echo "127.0.5.1 www.hknaruto.com" > /etc/hosts
追加ip
echo "127.0.5.1 www.hknaruto.com" >> /etc/hostsecho "127.0.5.1 www.hknaruto.com" | /etc/hosts
更换ip
sed -i 's/[0-9\.]\+[ ]\+www.hknaruto.com/127.0.0.2 www.hknaruto.com/g' /etc/hosts
替换www.hknaruto.com的ip改成127.0.0.2