Page 1 of 1

XP host wireless network with CentOS guest

Posted: 11. Sep 2009, 17:26
by tecbox77
Can someone suggest how to configure networking with VirtualBox 3.0.6 using XP host with wireless NIC and CentOS 5.3 guest?

I tried Bridged Networking with a static IP on the guest and it seemed to work sporadically. However, a simple ping from the guest would work one minute and would get no response a few minutes later. When I tried to set networking up with NAT I did not get any network connection.

Thanks.

Re: XP host wireless network with CentOS guest

Posted: 11. Sep 2009, 20:26
by vbox4me2
Are you sure the WIFI is stable at moments the Guest cannot ping? a Guest uses, emulated, whatever the Host uses.

Re: XP host wireless network with CentOS guest

Posted: 12. Sep 2009, 01:20
by tecbox77
Yes, the WiFi is still stable when the guest can not ping for I can still ping the same IP and surf the internet from the host during this time. The curious thing is I can still ping my gateway (192.168.0.1) from my guest when I am unable to ping IP's outside my gateway from my guest. However, if I try to ping the same IP moments later it will work.

Here's a trace during the time pings fail:
# strace ping 4.2.2.1
execve("/bin/ping", ["ping", "4.2.2.1"], [/* 35 vars */]) = 0
brk(0) = 0x2b674297c000
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b6739e2a000
uname({sys="Linux", node="linuxlap2.local.com", ...}) = 0
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=76015, ...}) = 0
mmap(NULL, 76015, PROT_READ, MAP_PRIVATE, 3, 0) = 0x2b6739e2b000
close(3) = 0
open("/lib64/libresolv.so.2", O_RDONLY) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\2402`\3651\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=92736, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b6739e3e000
mmap(NULL, 2181864, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b673a02b000
mprotect(0x2b673a03c000, 2097152, PROT_NONE) = 0
mmap(0x2b673a23c000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x11000) = 0x2b673a23c000
mmap(0x2b673a23e000, 6888, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x2b673a23e000
close(3) = 0
open("/lib64/libc.so.6", O_RDONLY) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0p\332\201\3521\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=1713160, ...}) = 0
mmap(NULL, 3494168, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b673a240000
mprotect(0x2b673a38c000, 2097152, PROT_NONE) = 0
mmap(0x2b673a58c000, 20480, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x14c000) = 0x2b673a58c000
mmap(0x2b673a591000, 16664, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x2b673a591000
close(3) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b673a596000
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b673a597000
arch_prctl(ARCH_SET_FS, 0x2b673a596af0) = 0
mprotect(0x2b673a58c000, 16384, PROT_READ) = 0
mprotect(0x2b673a23c000, 4096, PROT_READ) = 0
mprotect(0x2b673a029000, 4096, PROT_READ) = 0
munmap(0x2b6739e2b000, 76015) = 0
socket(PF_INET, SOCK_RAW, IPPROTO_ICMP) = 3
getuid() = 0
setuid(0) = 0
socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 4
connect(4, {sa_family=AF_INET, sin_port=htons(1025), sin_addr=inet_addr("4.2.2.1")}, 16) = 0
getsockname(4, {sa_family=AF_INET, sin_port=htons(49970), sin_addr=inet_addr("192.168.0.16")}, [16]) = 0
close(4) = 0
setsockopt(3, SOL_RAW, ICMP_FILTER, ~(ICMP_ECHOREPLY|ICMP_DEST_UNREACH|ICMP_SOURCE_QUENCH|ICMP_REDIRECT|ICMP_TIME_EXCEEDED|ICMP_PARAMETERPROB), 4) = 0
setsockopt(3, SOL_IP, IP_RECVERR, [1], 4) = 0
setsockopt(3, SOL_SOCKET, SO_SNDBUF, [324], 4) = 0
setsockopt(3, SOL_SOCKET, SO_RCVBUF, [65536], 4) = 0
getsockopt(3, SOL_SOCKET, SO_RCVBUF, [8136691022580285440], [4]) = 0
brk(0) = 0x2b674297c000
brk(0x2b674299d000) = 0x2b674299d000
fstat(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 2), ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b6739e2b000
write(1, "PING 4.2.2.1 (4.2.2.1) 56(84) by"..., 45PING 4.2.2.1 (4.2.2.1) 56(84) bytes of data.
) = 45
setsockopt(3, SOL_SOCKET, SO_TIMESTAMP, [1], 4) = 0
setsockopt(3, SOL_SOCKET, SO_SNDTIMEO, "\1\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", 16) = 0
setsockopt(3, SOL_SOCKET, SO_RCVTIMEO, "\1\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", 16) = 0
getpid() = 11334
rt_sigaction(SIGINT, {0x2b6739bf67b0, [], SA_RESTORER|SA_INTERRUPT, 0x2b673a270280}, NULL, 8) = 0
rt_sigaction(SIGALRM, {0x2b6739bf67b0, [], SA_RESTORER|SA_INTERRUPT, 0x2b673a270280}, NULL, 8) = 0
rt_sigaction(SIGQUIT, {0x2b6739bf67c0, [], SA_RESTORER|SA_INTERRUPT, 0x2b673a270280}, NULL, 8) = 0
gettimeofday({1252711913, 998882}, NULL) = 0
ioctl(1, SNDCTL_TMR_TIMEBASE or TCGETS, {B38400 opost isig icanon echo ...}) = 0
ioctl(1, TIOCGWINSZ, {ws_row=24, ws_col=141, ws_xpixel=0, ws_ypixel=0}) = 0
gettimeofday({1252711914, 38577}, NULL) = 0
gettimeofday({1252711914, 38743}, NULL) = 0
sendmsg(3, {msg_name(16)={sa_family=AF_INET, sin_port=htons(0), sin_addr=inet_addr("4.2.2.1")}, msg_iov(1)=[{"\10\0\6@F,\0\1\352\335\252J\0\0\0\0W\227\0\0\0\0\0\0\20\21\22\23\24\25\26\27"..., 64}], msg_controllen=0, msg_flags=0}, 0) = 64
recvmsg(3, 0x7fff70eb42f0, 0) = -1 EAGAIN (Resource temporarily unavailable)
gettimeofday({1252711915, 50256}, NULL) = 0
gettimeofday({1252711915, 50690}, NULL) = 0

Re: XP host wireless network with CentOS guest

Posted: 12. Sep 2009, 13:26
by vbox4me2
In the QuickClick FAQ is a link to dns/router issues I've wrote about before.

Re: XP host wireless network with CentOS guest

Posted: 12. Sep 2009, 16:52
by tecbox77
Thanks for your response vbox4me2!

I read the page Bridge/NAT Routing issues and it didn't seem to help.

My problem is I can access the host and the internet from the guest, however pinging the internet from the guest is sporadic. I can literally ping an internet IP and cancel the ping and re-run the ping and I get no response.
[root@linuxlap1 ~]# ping 4.2.2.2
PING 4.2.2.2 (4.2.2.2) 56(84) bytes of data.
64 bytes from 4.2.2.2: icmp_seq=2 ttl=53 time=24.2 ms
64 bytes from 4.2.2.2: icmp_seq=3 ttl=53 time=39.0 ms

--- 4.2.2.2 ping statistics ---
3 packets transmitted, 2 received, 33% packet loss, time 2000ms
rtt min/avg/max/mdev = 24.272/31.674/39.076/7.402 ms
[root@linuxlap1 ~]#
[root@linuxlap1 ~]# ping 4.2.2.2
PING 4.2.2.2 (4.2.2.2) 56(84) bytes of data.

--- 4.2.2.2 ping statistics ---
105 packets transmitted, 0 received, 100% packet loss, time 104861ms

[root@linuxlap1 ~]#
During the time ping appears to hang, wireshark shows responses being received:
No.     Time        Source                Destination           Protocol Info
      1 0.000000    192.168.0.15          4.2.2.2               ICMP     Echo (ping) request

Frame 1 (98 bytes on wire, 98 bytes captured)
Ethernet II, Src: CadmusCo_6c:a4:cc (08:00:27:6c:a4:cc), Dst: Netgear_5c:8f:91 (00:09:5b:5c:8f:91)
Internet Protocol, Src: 192.168.0.15 (192.168.0.15), Dst: 4.2.2.2 (4.2.2.2)
Internet Control Message Protocol

No.     Time        Source                Destination           Protocol Info
      2 0.034541    4.2.2.2               192.168.0.15          ICMP     Echo (ping) reply

Frame 2 (98 bytes on wire, 98 bytes captured)
Ethernet II, Src: Netgear_5c:8f:91 (00:09:5b:5c:8f:91), Dst: CadmusCo_6c:a4:cc (08:00:27:6c:a4:cc)
Internet Protocol, Src: 4.2.2.2 (4.2.2.2), Dst: 192.168.0.15 (192.168.0.15)
Internet Control Message Protocol

No.     Time        Source                Destination           Protocol Info
      3 0.999319    192.168.0.15          4.2.2.2               ICMP     Echo (ping) request

Frame 3 (98 bytes on wire, 98 bytes captured)
Ethernet II, Src: CadmusCo_6c:a4:cc (08:00:27:6c:a4:cc), Dst: Netgear_5c:8f:91 (00:09:5b:5c:8f:91)
Internet Protocol, Src: 192.168.0.15 (192.168.0.15), Dst: 4.2.2.2 (4.2.2.2)
Internet Control Message Protocol

No.     Time        Source                Destination           Protocol Info
      4 1.033211    4.2.2.2               192.168.0.15          ICMP     Echo (ping) reply

Frame 4 (98 bytes on wire, 98 bytes captured)
Ethernet II, Src: Netgear_5c:8f:91 (00:09:5b:5c:8f:91), Dst: CadmusCo_6c:a4:cc (08:00:27:6c:a4:cc)
Internet Protocol, Src: 4.2.2.2 (4.2.2.2), Dst: 192.168.0.15 (192.168.0.15)
Internet Control Message Protocol
My settings are as follows:
Guest:
# route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.0.0     *               255.255.255.0   U     0      0        0 eth0
default         192.168.0.1     0.0.0.0         UG    0      0        0 eth0

Host
IP - 192.168.0.8
NetMask - 255.255.255.0
GW - 192.168.0.1
DNS - 192.168.0.1

Guest
IP - 192.168.0.15
NetMask - 255.255.255.0
GW - 192.168.0.1
DNS - 192.168.0.1
I'm using the Bridged Adapter with the Intel Pro/1000 MT Desktop adapter bridged to Intel Wireless WiFi 4965AGN.

Thanks again for your help.

Re: XP host wireless network with CentOS guest

Posted: 12. Sep 2009, 17:07
by Perryg
I would try a different Virtual Network adapter. Some work better than others depending on the OS.
I use the PCnet-FAST III for most of my Linux Distros, and the Intel for the Windows OSes.
This more than likely will force a change in the CentOS config, but easy enough to repair.

Re: XP host wireless network with CentOS guest

Posted: 12. Sep 2009, 18:19
by tecbox77
Thanks for the suggestion. I've tried every one of the Adapter Types available in VB and got the same result with each.

Re: XP host wireless network with CentOS guest

Posted: 12. Sep 2009, 18:58
by Perryg
Is this a USB wireless adapter?
If so have you defined a filter for it in the guest settings? Make sure that it is NOT defined because this would cause the problem you are describing.
Other than that I have no more clues to give you. You may need to create a ticket in bugtracker. Link is below my post. You will need to setup an account there and be sure to include your log file and a complete description of the problem as well as the model of the wireless adapter.

Re: XP host wireless network with CentOS guest

Posted: 12. Sep 2009, 20:42
by vbox4me2
Do a tracert to each point in the line to your ISP's first DNS, when that works use nslookup to see if any DNS works. If one step doesn't work you'll know where to look.

Re: XP host wireless network with CentOS guest

Posted: 13. Sep 2009, 02:08
by tecbox77
@PerryG...no this is a not a USB wireless card it is a built-in. Looks like I may have to file a bug report.

@vbox4me2..Not sure if this is what you are looking for ?
[root@linuxlap1 ~]# tracert 68.87.73.246
traceroute to 68.87.73.246 (68.87.73.246), 30 hops max, 40 byte packets
 1  192.168.0.1 (192.168.0.1)  12.689 ms  12.735 ms  15.193 ms
 2  * * *
 3  68.85.139.81 (68.85.139.81)  50.810 ms  51.535 ms  51.508 ms
 4  68.85.67.174 (68.85.67.174)  52.519 ms  54.757 ms  54.718 ms
 5  68.85.67.177 (68.85.67.177)  51.777 ms  51.746 ms  54.131 ms
 6  68.85.67.182 (68.85.67.182)  51.340 ms  20.111 ms  24.646 ms
 7  68.85.130.21 (68.85.130.21)  40.004 ms  40.862 ms  41.244 ms
 8  ge-1-40-ur03.manassascc.va.bad.comcast.net (68.86.253.17)  40.747 ms  40.710 ms  40.815 ms
 9  cns.manassaspr.va.dc02.comcast.net (68.87.73.246)  42.637 ms  42.973 ms  42.931 ms
[root@linuxlap1 ~]# tracert 68.86.253.17
traceroute to 68.86.253.17 (68.86.253.17), 30 hops max, 40 byte packets
 1  * * *
 2  * * *
 3  * * *
 4  * * *
 5  * 68.85.67.177 (68.85.67.177)  52.850 ms  56.815 ms
 6  68.85.67.182 (68.85.67.182)  73.530 ms  25.115 ms  35.314 ms
 7  * * *
 8  * * *
 9  * * *
10  * * *
11  * * *
12  * * *
13  * * *
14  * * *
15  * * *
16  * * *
17  * * *
18  * * *
19  * * *
20  * * *
21  * * *
22  * * *
23  * * *
24  * * *
25  * * *
26  * * *
27  * * *
28  * * *
29  * * *
30  * * *
[root@linuxlap1 ~]# tracert 68.85.130.21
traceroute to 68.85.130.21 (68.85.130.21), 30 hops max, 40 byte packets
 1  192.168.0.1 (192.168.0.1)  3.794 ms  2.908 ms  2.333 ms
 2  * * *
 3  68.85.139.81 (68.85.139.81)  40.327 ms  41.010 ms  40.866 ms
 4  68.85.67.174 (68.85.67.174)  41.865 ms  41.762 ms  41.375 ms
 5  68.85.67.177 (68.85.67.177)  58.876 ms  58.776 ms  20.279 ms
 6  68.85.67.182 (68.85.67.182)  24.523 ms  39.845 ms  40.073 ms
 7  68.85.130.21 (68.85.130.21)  41.600 ms  41.556 ms  41.513 ms
[root@linuxlap1 ~]# tracert 68.85.67.182
traceroute to 68.85.67.182 (68.85.67.182), 30 hops max, 40 byte packets
 1  192.168.0.1 (192.168.0.1)  13.361 ms  12.491 ms  12.646 ms
 2  * * *
 3  68.85.139.81 (68.85.139.81)  48.558 ms  58.719 ms  58.529 ms
 4  68.85.67.174 (68.85.67.174)  58.319 ms  21.785 ms  36.809 ms
 5  68.85.67.177 (68.85.67.177)  53.532 ms  53.476 ms  53.432 ms
 6  68.85.67.182 (68.85.67.182)  54.373 ms  54.299 ms  54.257 ms
[root@linuxlap1 ~]# tracert 68.85.67.177
traceroute to 68.85.67.177 (68.85.67.177), 30 hops max, 40 byte packets
 1  192.168.0.1 (192.168.0.1)  3.115 ms  3.081 ms  3.036 ms
 2  * * *
 3  68.85.139.81 (68.85.139.81)  42.281 ms  42.245 ms  42.180 ms
 4  68.85.67.174 (68.85.67.174)  42.138 ms  42.099 ms  42.059 ms
 5  68.85.67.177 (68.85.67.177)  42.018 ms  53.396 ms  53.356 ms
[root@linuxlap1 ~]# tracert 68.85.67.174
traceroute to 68.85.67.174 (68.85.67.174), 30 hops max, 40 byte packets
 1  192.168.0.1 (192.168.0.1)  3.339 ms  5.737 ms  5.677 ms
 2  * * *
 3  68.85.139.81 (68.85.139.81)  43.225 ms  43.176 ms  43.126 ms
 4  68.85.67.174 (68.85.67.174)  43.063 ms  42.962 ms  42.911 ms
[root@linuxlap1 ~]# tracert 68.85.139.81
traceroute to 68.85.139.81 (68.85.139.81), 30 hops max, 40 byte packets
 1  192.168.0.1 (192.168.0.1)  3.370 ms  2.979 ms  14.720 ms
 2  68.85.139.81 (68.85.139.81)  43.116 ms  43.075 ms  43.034 ms
[root@linuxlap1 ~]# tracert 68.86.253.17
traceroute to 68.86.253.17 (68.86.253.17), 30 hops max, 40 byte packets
 1  192.168.0.1 (192.168.0.1)  13.358 ms  13.187 ms  17.049 ms
 2  * * *
 3  68.85.139.81 (68.85.139.81)  52.319 ms  52.287 ms  52.246 ms
 4  68.85.67.174 (68.85.67.174)  59.703 ms  59.662 ms  59.626 ms
 5  68.85.67.177 (68.85.67.177)  59.572 ms  59.538 ms  59.498 ms
 6  68.85.67.182 (68.85.67.182)  59.411 ms  19.278 ms  25.575 ms
 7  * * *
 8  * * *
 9  * * *
10  * * *
11  * * *
12  * * *
13  * * *
14  * * *
15  * * *
16  * * *
17  * * *
18  * * *
19  * * *
20  * * *
21  * * *
22  * * *
23  * * *
24  * * *
25  * * *
26  * * *
27  * * *
28  * * *
29  * * *
30  * * *
[root@linuxlap1 ~]#

[root@linuxlap1 ~]# nslookup http://www.google.com 68.87.73.246
Server:         68.87.73.246
Address:        68.87.73.246#53

Non-authoritative answer:
http://www.google.com  canonical name = http://www.l.google.com.
Name:   http://www.l.google.com
Address: 64.233.169.103
Name:   http://www.l.google.com
Address: 64.233.169.104
Name:   http://www.l.google.com
Address: 64.233.169.147
Name:   http://www.l.google.com
Address: 64.233.169.99

Re: XP host wireless network with CentOS guest

Posted: 13. Sep 2009, 12:47
by vbox4me2
Look at number 1 and 2(empty), though a dns (68.87.73.246) is working, is this DNS configured on your WAN side? do a trace to this dns from the Host and a Guest, the path must be the same and should not contain any empty hops.

Re: XP host wireless network with CentOS guest

Posted: 13. Sep 2009, 23:45
by tecbox77
Yes, this DNS is configured on my WAN side. Below are the traces from each node.

Trace from HOST (XP):
C:\>tracert 68.87.73.246

Tracing route to cns.manassaspr.va.dc02.comcast.net [68.87.73.246]
over a maximum of 30 hops:

  1     2 ms     1 ms     1 ms  192.168.0.1
  2     *        *        *     Request timed out.
  3    10 ms     9 ms     9 ms  68.85.139.81
  4    18 ms     9 ms    16 ms  68.85.67.174
  5    16 ms     9 ms     9 ms  68.85.67.177
  6    10 ms     9 ms     9 ms  68.85.67.182
  7    10 ms     9 ms     9 ms  68.85.130.21
  8    11 ms     9 ms    28 ms  ge-1-40-ur03.manassascc.va.bad.comcast.net [68.86.253.17]
  9    13 ms    14 ms    11 ms  cns.manassaspr.va.dc02.comcast.net [68.87.73.246]

Trace complete.
Trace from GUEST (CentOS 5.3):
[root@linuxlap1 ~]# tracert 68.87.73.246
traceroute to 68.87.73.246 (68.87.73.246), 30 hops max, 40 byte packets
 1  * * *
 2  * * *
 3  * * *
 4  * * *
 5  * 68.85.67.177 (68.85.67.177)  60.242 ms  67.347 ms
 6  68.85.67.182 (68.85.67.182)  80.192 ms  22.472 ms  19.565 ms
 7  68.85.130.21 (68.85.130.21)  22.076 ms  24.445 ms  36.594 ms
 8  ge-1-40-ur03.manassascc.va.bad.comcast.net (68.86.253.17)  35.678 ms  25.910 ms  34.162 ms
 9  cns.manassaspr.va.dc02.comcast.net (68.87.73.246)  25.814 ms  35.075 ms  24.603 ms
However, after further diagnosis, this appears to be a Linux issue and NOT a VB issue. I have another non-virutalized Linux node (CentOS 5.2) on my network and it encounters the same problem that I am experiencing with the VB Linux node. In addition, the non-virtualized Linux node that is experiencing the same problem is utilizing a wired connection and NOT a wireless connection.

I really wouldn't expect this to be expected behavior. Does anyone else get no response if they ping an outside IP and cancel the ping and immediately re-issue the same ping?

Thanks again for your help !!