0

I want to give static ip of both my windows server and linux server but when I do this then my default gateway shows Destination Host Unreachable in linux when I ping it in linux.

my windows server settings are

  • ipv4 address 192.168.1.68
  • ipv4 subnet 255.255.255.0
  • ipv4 default gateway 192.168.1.1

and my linux server settings are

eth0 Link encap:Ethernet HWaddr 00:0C:29:6B:E9:8A
inet addr:192.168.178.128 Bcast:192.168.178.255 Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:fe6b:e98a/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:44949 errorsBlush | :O droppedBlush | :O overrunsBlush | :O frameBlush | :O
TX packets:34250 errorsBlush | :O droppedBlush | :O overrunsBlush | :O carrierBlush | :O
collisionsBlush | :O txqueuelen:1000
RX bytes:30998896 (29.5 MiB) TX bytes:1860368 (1.7 MiB)


lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:231 errorsBlush | :O droppedBlush | :O overrunsBlush | :O frameBlush | :O
TX packets:231 errorsBlush | :O droppedBlush | :O overrunsBlush | :O carrierBlush | :O
collisionsBlush | :O txqueuelenBlush | :O
RX bytes:23426 (22.8 KiB) TX bytes:23426 (22.8 KiB)
  • i gave these settings to my windows machine ipv4 address 192.168.1.68 ipv4 subnet 255.255.255.0 ipv4 default gateway 192.168.1.1 and these settings to my linux server ip address 192.168.1.128 Netmask 255.255.255.0 gateway 192.168.1.1 but when i ping gateway in linux server then it shows destination host unreachable and also when i ping google.com in linux then it shows host unreachable. tell me the solution what i do now to solve this problem... – Waleed Bin Arshad Mar 17 '15 at 10:00
  • 1
    obviously linux host is a vmware, what type is network interface in vmware settings ? – Archemar Mar 17 '15 at 10:05
  • 4
    The IP address on eth0 is 192.168.178.128. You said it should be 192.168.1.128. You need either to fix your requirements or your interface IP address. – roaima Mar 17 '15 at 10:06
  • You must 2 interface if the Linux system is VM. interface 1 should be NAT and interface 2 should be host only network network. – Mongrel Mar 15 '16 at 7:57
  • Can you paste the contents of /etc/sysconfig/network-scripts/ifcfg-eth0 ? In particular you want there to be a line that say's DEFROUTE=yes – Gravy Sep 29 '16 at 21:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.