Solaris 10: Not able to ping an IP address from another server

solarissolaris-10

I have a Solaris server which has 2 interfaces. I wanted to use the same shared interface but make it respond to multiple IP addresses. So I used the following command:

ifconfig vmxnet3s1:1 10.20.20.20 netmask 255.255.255.255

Then I added this IP address to the /etc/hosts file and restarted the network by executing:

svcadm restart network/physical

But when I try to ping this new IP address from another server, it reports "no answer from 10.20.20.20".

Both the server (the one from which I am pinging and the one on which I added an IP address) are on the same LAN.

Output of ifconfig -a:

bash-3.00# ifconfig -a

lo0: flags=2001000849<UP,LOOPBACK,RUNNING,MULTICAST,IPv4,VIRTUAL> mtu 8232 index 1
        inet 127.0.0.1 netmask ff000000

vmxnet3s0: flags=1000843<UP,BROADCAST,RUNNING,MULTICAST,IPv4> mtu 1500 index 2
        inet 135.25.154.232 netmask ffffff00 broadcast 135.25.154.255
        ether 0:50:56:b2:58:f0

vmxnet3s1: flags=1000843<UP,BROADCAST,RUNNING,MULTICAST,IPv4> mtu 1500 index 3
        inet 135.182.130.195 netmask ffffff00 broadcast 135.182.130.255
        ether 0:50:56:b2:64:43

vmxnet3s1:1: flags=1000843<UP,BROADCAST,RUNNING,MULTICAST,IPv4> mtu 1500 index 3
        inet 10.20.20.20 netmask ff000000 broadcast 10.255.255.255

Is there anything more that needs to be done?

Best Answer

First your netmask does not seem right:

ifconfig vmxnet3s1:1 10.20.20.20 netmask 255.255.255.255

so I'm assuming it's a 255.255.255.0, but you can change it as you wish.

Second, make sure the interface is UP, i would try with something like this:

ifconfig vmxnet3s1:1 plumb up
ifconfig vmxnet3s1:1 10.20.20.20 netmask 255.255.255.0 up

Then try again pinging it from a machine in the same subnet, that is 10.20.20.0/24

If that works you can make the configuration persistent configuring:

echo "10.20.20.0 255.255.255.0" >> /etc/netmasks
echo "10.20.20.20 myhostname_in_10.20.20.20" >> /etc/hosts
echo "myhostname_in_10.20.20.20" > /etc/hostname.vmxnet3s1:1
svcadm restart network/physical

Hope this helps

Related Topic