Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
qemu - cant ping host secondary address
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
mrhe
n00b
n00b


Joined: 07 Aug 2012
Posts: 33
Location: Kraków

PostPosted: Fri Feb 19, 2016 5:42 pm    Post subject: qemu - cant ping host secondary address Reply with quote

Hi,

I have kvm server with one guest with 2 ethernet 10GB emulex card


eth3 and eth4 are 10GB and going to one switch witn one vlan
eth3 is add to br1 with no ip
tap1 is add to br1 with no ip
br1 no ip
tap1 is add for kvmguest

Code:

5: eth3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq master br1 portid 0100000000423831393530353139593131 state UP group default qlen 1000
    link/ether 00:00:c9:xx:xx:xx brd ff:ff:ff:ff:ff:ff
7: eth4: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq portid 0200000000423831393530353139593131 state UP group default qlen 1000
    link/ether 00:00:c9:xx:xx:xx brd ff:ff:ff:ff:ff:ff
    inet 172.17.4.38/24 scope global eth4
       valid_lft forever preferred_lft forever
    inet 172.17.4.39/24 scope global secondary eth4
       valid_lft forever preferred_lft forever
 


qemu scirpt to run guest :

Code:
 /usr/local/kvm25/bin/qemu-system-x86_64 -m 6096 -smp 4  -enable-kvm \
-vnc 172.17.10.xx:1  -vga std   -net none -D logFile.log \
-net nic,macaddr=aa:bb:cc:00:00:22,model=virtio,netdev=network1 -netdev tap,script=no,downscript=no,ifname=tap1,id=network1 \
-boot d \
-drive file=node5dev2.raw,index=0,media=disk,format=raw \
-daemonize


before that im creating br0 and br1 and tap0 and tap1
Code:
 # brctl show
bridge name     bridge id               STP enabled     interfaces
br1             8000.0000c9e51d5e       no              eth3
                                                                       tap1



Now my problem is in guest. When i try to ping 172.17.4.38 ist ok

Code:
ping 172.17.4.38
PING 172.17.4.38 (172.17.4.38) 56(84) bytes of data.
64 bytes from 172.17.4.38: icmp_seq=1 ttl=64 time=0.137 ms


but when in try to ping second addres timeout
Code:
ping 172.17.4.39
PING 172.17.4.39 (172.17.4.39) 56(84) bytes of data.
From 172.17.4.37: icmp_seq=1 Destination Host Unreachable



tcpdum on host see arp , and ip of guest is 172.17.4.37 host 172.17.4.38 and 4.39 . NO iptables on host and guest systems

Code:

 # tcpdump -i eth4 -n host 172.17.4.37
dropped privs to tcpdump
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on eth4, link-type EN10MB (Ethernet), capture size 262144 bytes
18:36:31.065896 ARP, Request who-has 172.17.4.39 tell 172.17.4.37, length 46
18:36:31.065900 ARP, Reply 172.17.4.39 is-at 00:00:c9:xx:xx:xx, length 28


what im doing wrong?
Back to top
View user's profile Send private message
szatox
Veteran
Veteran


Joined: 27 Aug 2013
Posts: 1746

PostPosted: Fri Feb 19, 2016 7:24 pm    Post subject: Reply with quote

You mentioned a VLAN, don't you accidentally block traffic with it?
Back to top
View user's profile Send private message
mrhe
n00b
n00b


Joined: 07 Aug 2012
Posts: 33
Location: Kraków

PostPosted: Fri Feb 19, 2016 9:00 pm    Post subject: Reply with quote

szatox wrote:
You mentioned a VLAN, don't you accidentally block traffic with it?

If it would be true I could not ping first addres of eth4 172.17.4.38 but its ok
Back to top
View user's profile Send private message
StifflerStealth
l33t
l33t


Joined: 03 Jul 2002
Posts: 968

PostPosted: Sat Feb 20, 2016 9:11 am    Post subject: Reply with quote

Hi,

Quote:
I have kvm server with one guest with 2 ethernet 10GB emulex card

The way this is worded, it sounds like is that the 2 ethernet cards are being passed to the quest.

However, but the rest of your post, it seems that you have two dual-port ethernet cards on the host. One of the ports is in a bridge and you want the guest to use that bridge to connect to the network?

Some switches do not allow talk-back to the same ethernet port. Since it's a VLan, that may explain why you can't ping one address. Is the the IP address owned by the host that is doing the bridging? I had trouble with this earlier and determined that the bridge was not set up right, but when used a different method, everything worked right.

However, if the actual VLan switch does not allow this talk-back, then another solution:
If you do have two dual-port ethernet cards on the host, which according to your numbers would be eth1-4, which means there's a eth0. Is eth0 used by the host? If not, you could passthrough the ethernet "card" (if it's a built on motherboard one then it's not really a card) to the guest for use directly. The host would no longer have control over it.

You may need to look at the VLan switch to see how it is set up for my first point about not allowing talk-back to the same ethernet port.

Jon
_________________
Nothing to read in this sig. Move along.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum