3

I'm having trouble setting up static routing. My target machine 192.168.1.36 has a loopback address of 192.168.46.1 255.255.255.255 which I am trying to ping from another device in the network 192.168.1.28.

On 192.168.1.36 I can ping the loopback and the source machine.

From the source machine 192.168.1.28 I have added the following static route:

route add -net 192.168.46.1 netmask 255.255.255.255 gw 192.168.1.36 dev ens3

However I cannot ping 192.168.46.1 despite being able to ping 192.168.1.36.

There are no firewall rules in place blocking ICMP.

Any help appreciated.

1

In Linux a loopback adapter is valid only inside of its owner. You can't ping or communicate it from remote devices (You can remote access to loopback on Cisco devices)

  • Ah right didn't know that (my background is Cisco). However I created the loopback as I was having issues pinging a VM 192.168.56.1 and created the loopback to see if I could prove the issue to the static routes or the VM. Again I can ping the VM from its host 192.168.1.32 but not from another device on the 192.168.1.0 subnet – FoxyNPF Apr 3 '17 at 11:38
  • You can use bridge port in VMware configuration of your virtual machine to enable pining of it from any other devices in your network. – SuB Apr 3 '17 at 11:43
  • I'm using VirtualBox with a Host only adapter, I'm running cuckoo sandbox which is a bit of a nightmare to configure so don't want to start messing with the network settings of the VM. I find it weird that the host can ping the guest VM bit no other device can. – FoxyNPF Apr 3 '17 at 12:33
  • 1
    using NAT adapter and adding static route to other devices may solve the problem. There is an bug in Windows version of VBox which you can't ping Guest from Host when using NAT interface. I don't know this problem exists with Linux too. – SuB Apr 4 '17 at 5:51

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.