คนผมลง CentOS6.3 แล้วใช้ wget อ่ะครับ แต่มันขึ้นว่า Failed:Name or service not known.
wget: unable to resolve host address … อ่ะครับ ต้องแก้ยังไงหรอครับ
set resolver ไม่ถูกต้องครับ ลอง
cat /etc/resolv.conf
มาดูครับ
มันออกเน็ตได้มั้ยล่ะครับเครื่องนั้น Error ก็บอกอยู่ว่าไม่สามารถเชื่อมต่อไปยังปลายทางได้ ไม่เครื่องปลายทางตายคุณก็ออกเน็ตไม่ได้ครับ ไม่ก็ DNS ผิดครับ
Sounds like a DNS issue. I’d manually check your config:
nano /etc/sysconfig/network-scripts/ifcfg-eth0
Make sure you have a valid DNS server address in there somewhere, if not simply add:
DNS1=(primary DNS server IP address)
DNS2=(secondary dns server IP - if any)
Also, whilst you’re there - you might want to check that ‘onboot=yes’ for eth0.
CentOS 6.0 seems to install with it defaulted off on boot.
Stop the firewall first. Always get that out of the way when troubleshooting network issues (whenever possible).
If you drop the firewall and your issue goes away, problem solved, if not, at least it’s out of the way for now.
- iptables -L see if there are any DROP rules that could be affecting outgoing packets
- Check to see if selinux is running and doing anything odd (/etc/selinux/config)
- what is the output of the following: route -n
- what does /etc/sysconfig/network-scripts/ifcfg-eth0 look like
- can you ping your gateway without issue?
Hopefully one of these will provide the bit of information you need to diagnose the issue.
:154218d4:
เอ่อ คือว่า ผมมือใหม่น่ะครับ ขอโทษจริงๆครับที่ต้องถาม และคือผมลองลงใน VMware อ่ะครับไม่ทราบว่าต้องตั้งipยังไง แต่ผมตั้งแบบนี้
pc
ip 192.168.0.79
mask 255.255.255.0
gw 192.168.0.254
dns 203.103.5.130
centos ใน vmware ผมตั้งเป็น
ip 192.168.0.80
mask 255.255.255.0
gw 192.168.0.254
dns 203.103.5.130
อ่ะครับ ผิดตรงไหน กรุณาบอกด้วยนะครับ
ขอบพระคุณครับ
set network ใน vmware เป็น bridge หรือเปล่า ต้องเลือกเป็น bridbe
ได้แล้วครับ อาจารย์ ตอนแรกที่ไม่ได้เพราะผมไปกำหนดไอพีให้มันก่อนหน้านั้นอ่ะครับ ขอบคุณมากๆครับ