VirtualBox

Opened 14 years ago

Last modified 8 years ago

#7385 closed defect

NAT PXE TFTP download fails when using external tftp server -> fixed in svn — at Version 19

Reported by: Luiz Angelo Daros de Luca Owned by:
Component: network/NAT Version: VirtualBox 3.2.8
Keywords: Cc:
Guest type: other Host type: Linux

Description (last modified by vasily Levchenko)

Hello,

I defined a external tftp server in my configuration

VBoxManage modifyvm "Diskless NAT" --nattftpfile1 /pxelinux.0

VBoxManage modifyvm "Diskless NAT" --nattftpserver1 10.9.1.31

When it boot using PXE, it fails to ack after the seconds tftp package is received. I tested with "3.2.6 OSE", compiled from source, and it passed this step.

With "3.2.6 OSE", I have another bug that pxelinux is unable to download its configuration and/or detect that a file is missing. Maybe, it also cannot receive packets but in a latter step.

I'll attach the wireshark traffic for the first case.

Change History (23)

by Luiz Angelo Daros de Luca, 14 years ago

Attachment: pxeloaderr.pcap added

traffic when pxe tries to download pxelinux.0 from external server

comment:1 by vasily Levchenko, 14 years ago

Does the same happens when you're try to download the same file to linux guest using any tftp client, like atftp?

comment:2 by Luiz Angelo Daros de Luca, 14 years ago

No problem with tftp client.

I used:

tftp mytftpserver -m binary -c get /pxelinux.0

Just the same VM, same tftp server, same file. I used "-m binary" but binary transfer is not necessary in this case.

I'll attach the pcap for this working case. It seems that there is something wrong in BIOS tftp client.

by Luiz Angelo Daros de Luca, 14 years ago

Attachment: vbox-tftp-ok.pcap added

traffic when a linux client inside the same vm downloads pxelinux.0 from external server.

in reply to:  2 comment:3 by vasily Levchenko, 14 years ago

Replying to luizluca:

No problem with tftp client.

thanks for investigation. I've been able reproduce the problem.

comment:4 by vasily Levchenko, 14 years ago

I've reproduced it with tftpd-hpa-5.0 server, when I've increased the verbosity i found the following message in the syslog

# grep tftpd: /var/log/syslog
Sep 23 11:23:33 ubuntu in.tftpd[24575]: tftp: client does not accept options

that message is correspond to code in tftpd.c

1505             if (ap_opcode == ERROR) {
1506                 syslog(LOG_WARNING,
1507                        "tftp: client does not accept options\n");
1508                 goto abort;
1509             }

so it looks like outage happens on PXE bootloader.

comment:5 by michaln, 14 years ago

The second packet trace is meaningless because the client did not use any options (specifically blocksize), so the behavior is quite different.

The TFTP transfer abort is intentional and not a bug. The real problem seems to be in the NAT layer. Probably unrelated to PXE.

comment:6 by vasily Levchenko, 14 years ago

Could you please check r32745 fixes issue for you?

comment:7 by Luiz Angelo Daros de Luca, 14 years ago

Sorry, as I said, I was unable to reproduce it using OSE version and I cannot compile the proprietary version. I'll need to wait for an official release.

However, the problem I mentioned with OSE wasn't fixed with this patch. I'll attach the net traffic to illustrate my problem. It seems that "File not found" msgs does not reach PXE client.

BTW, I'm using OSE compiled with debug flag.

comment:8 by Luiz Angelo Daros de Luca, 14 years ago

I forgot to say that I tested the patch against 3.2.8_OSE and not trunk as I was unable to compile it successfully (have I ever?).

in reply to:  8 comment:9 by vasily Levchenko, 14 years ago

Replying to luizluca:

I forgot to say that I tested the patch against 3.2.8_OSE and not trunk as I was unable to compile it successfully (have I ever?).

Ah, so you need two changesets to apply, r32744 and r32745.

comment:10 by Luiz Angelo Daros de Luca, 14 years ago

I got the same result in OSE (using both patches). This time, I didn't do a full rebuild (kmk clear/kmk) but just a simple kmk. It updated those files:

VirtualBox-3.2.8_OSE/out/linux.amd64/debug/lib/Drivers.a VirtualBox-3.2.8_OSE/out/linux.amd64/debug/bin/VBoxDD.so

Was it enough for the test? I also updated kernel modules

Looking at line number, socket.c changed alot. Maybe there is something more. I don't know PXE deeply inside but I guess the tftp client in use is pxelinux.0 after it is correcly loaded.

It does not receive any server answer after pxelinux.0 is loaded. Just like before the patch was applied.

by Luiz Angelo Daros de Luca, 14 years ago

Attachment: vbox-ose-pxe-problem.pcap added

Full net traffic. All tftp server msg, error or not, does not arrive in pxe client

comment:11 by vasily Levchenko, 14 years ago

Could you please upload your testcase (zip with your tftp data)? Please contact me vasily _dot_ levchenko _at_ oracle _dot_ com and I'll provide upload instructions to you.

comment:12 by vasily Levchenko, 14 years ago

Using pxelinux.0 you'd sent to me I was able to boot linux from remote tftp server. Could you please re-try with 3.2.10?

comment:13 by Luiz Angelo Daros de Luca, 13 years ago

Sorry, it is still not working. After the first packages (request, option, etc..) it receives the first data package. VM acks it. The server sends the second package but this one is never acked. The server keeps trying to send the second package every 5 seconds but without answer.

Maybe this is related to some problem in vboxnet* and my host machine. I'm using unmodified opensuse11.3 x86_64. Generally, my host machine uses a firewall with masq rules but, for this test, I disabled it.

comment:14 by vasily Levchenko, 13 years ago

Could you please attach the log, might be it contains some hints to reproduce the issue.

by Luiz Angelo Daros de Luca, 13 years ago

VM log

comment:15 by vasily Levchenko, 13 years ago

Could you please try VBox4.0 b1?

comment:16 by Luiz Angelo Daros de Luca, 13 years ago

I still does not work.

It downloaded the pxelinux.0 file and fails for the config file. It failed to receive any packet about the second file ("Error: file not found" or "Option Ack").

Is there anything I can do to help?

PS: I tried to answer by mail (trac@vi..) and it returned.

in reply to:  16 comment:17 by vasily Levchenko, 13 years ago

Replying to luizluca:

I still does not work.

Does it make any difference whether you select E1k or PCNET adapters? Are you able access from any linux guest this config file from any linux tftp client?

comment:18 by Luiz Angelo Daros de Luca, 13 years ago

I tested with all nic options. Only virtio-net does not load PXE (that is expected). The others, the problem is the same.

I booted this machine using a bridge connection into a rescue linux livecd. I copied tftp client into it. All tests I did with this tftp worked. I hot-switched net to NAT, got a new IP and repeated the tests. All of them worked. I tested the download process in the same command call, in isolated ones, with or without a missing file. Everything worked.

Only PXE tftp client that does not work with NAT.

comment:19 by vasily Levchenko, 12 years ago

Description: modified (diff)
Summary: NAT PXE TFTP download fails when using external tftp serverNAT PXE TFTP download fails when using external tftp server -> fixed in svn
Note: See TracTickets for help on using tickets.

© 2023 Oracle
ContactPrivacy policyTerms of Use