Jump to content











Photo
* * * * * 1 votes

DHCP issues?


  • Please log in to reply
37 replies to this topic

#1 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 09 November 2011 - 01:42 PM

Hi,

I have now tried everything at least twice, and it simply seems that DHCP server could be broken.

After doing multiple checks, it seems that booting up Clonezilla requires three DHCP requests. If I bring second DHCP server in play, system passes two requests and hangs on third one. If I have only one (tftpd32) system hangs on second request. Does anyone have any protips how to fix this? The main issue seems to be that tftpd32 refuses to reply to requests and bootup process can't do anything about that.

Also user interface is buggy and loses values that need to be entered over and over again. Therefore it's also possible that clients reject invalid data delivered by tftpd32.

Any tips or help how to deal with this? Naturally I can boot from USB stick, and everything works as expected but getting PXE boot to work would be very very nice.

Could someone recommend me good free DHCP server which I could use instead of tfptd32's DHCP server?

- Thanks!

Best regards,
Sami Lehtinen

#2 madmax69

madmax69

    Member

  • Members
  • 41 posts
  •  
    United Kingdom

Posted 10 November 2011 - 12:37 AM

What version are you using and what settings?
I had some problems myself to start with but twiddling with the settings resolved the issues
Some clients seem to send invalid data to tftpd32

I have a downloadable, ready to run ISO demo on this page that you could compare settings on
It uses tftpd32 - v4.00 if I remember correctly
http://pxe.kerys.co....e-chainboot.htm

It's a turnkey Win32 ISO that you could perhaps use for diagnostics?

#3 RoyM

RoyM

    Frequent Member

  • .script developer
  • 358 posts
  • Interests:Component level repair, Micro-processor based equipment. Computer Repair + Custom Builds.
    (ie. Game Machines, Custom Firewalls\Smoothwalls)
    Network Penetration and testing, Including Wireless.
    Fishing, Hunting, Camping, Gaming.
  •  
    United States

Posted 10 November 2011 - 04:39 AM

http://pxe.kerys.co....e-chainboot.htm

Nice link madmax69, Thanks

RoyM

#4 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 10 November 2011 - 06:34 AM

What version are you using and what settings?

I'm Using latest stable clonezilla, pxelinux and tftpd32. I also tried older tftpd32 (3.33) to confirm that it hasn't got broken when they introduced IPv6 support.

I had some problems myself to start with but twiddling with the settings resolved the issues
Some clients seem to send invalid data to tftpd32

Might well be true. Because the addresses clients requested from DHCP server when sending request, were really strange. Like 0.80.1.49 or similar, it got my eye. But unfortunately I don't have enough experience about this configuration so I could tell if that's normal or not.

I have a downloadable, ready to run ISO demo on this page that you could compare settings on
It uses tftpd32 - v4.00 if I remember correctly
http://pxe.kerys.co....e-chainboot.htm

Excellent. I'll try that. I'll be back reporting what kind of results I get with it.

It's a turnkey Win32 ISO that you could perhaps use for diagnostics?

After thinking this issue over night. I thought that there are so many variables that I need to do something first that I can get system to work as expected. And then continue troubleshooting to locate the actual issue. Now I don't have working set, so it's hard to analyze exactly where the problem is. I thought that if required I'll set up Linux DHCP server just to confirm that the problem is DHCP. If it works or doesn't, then I know quite much more.

Thank you. I just trued to confirm that I'm not having some known issue here. Anyway, if someone has worked with this clonezilla set and it's latest Ubuntu image, does live-config upstart task hanging sound familiar? That's where it hangs if I'm having two DHCP servers.

I'll be back bit later. I also thought that I could put on my web-site one packet where everything is configured already. It seems that net is quite full of dicussions how to get this PXE stuff working and configuring servers etc. If there would be one ready packet containing everything required and sample configuration it could be helpful for many people who are in hurry or doesn't have required knownledge & skills. Just unzip this, start tftpd32 and clonezilla works with PXE boot.

Edited by Sami Lehtinen, 10 November 2011 - 06:38 AM.


#5 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 10 November 2011 - 07:55 AM

Confirmed, there is issue with TFTPD32 DHCP server. But there is also second issue with Clonezilla. If I use dhcpd from Linux, DHCP issue can be dealed with. But the second issue with clonezilla might be related to new upstart tasks and live config hangs. I'm trying to try older and newer pxelinux.0 files and also newer and older clonzeillas. To see if those make any difference with these issues. When I'm done with the analysis I'll post small report here with details.

#6 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 10 November 2011 - 08:57 AM

Now I got some more info.

1.2.10-14 stable shows login prompt after basic config
1.2.11-18 test shows login prompt after basic config
20110922 stable hangs with upstart live when doing init
20111108 test hangs with upstart live when doing init

What a joy.

And yes, if I'm not running secondary DNS server, without that all versions of pxelinux.0 hang with DHCP issues. I tried 4.00 and 4.10 versionf of pxelinux.0. I also can use only one DHCP server if it's running from linux server. It seems that workstations prefer routers DHCP offer and TFTPD32 dhcp offer is only used when PXE boot option is required.

So happy, enough challenge. ;)

After all this I decided to try: clonezilla-live-1.2.10-14-amd64.zip

Yup, same issue. There is no option to start clonezilla as there should be according documentation.

What I'm doing wrong? I assume this stuff should work on first try.

I also tried logins: user and pwd live and login root nopwd and login user pwd drbllive no success.

Quite interesting obstacle course. Any tips or thoughts? Yes, booting from usb stick or cd does work perfectly. So there is something wrong, maybe clonezillas live distributions just are way bad?

If someone is really interested about these issues, I did photograph every hang point and issue I experienced. I can deliverer photos.

- Thank you!

Images & short descriptions:
http://www.sendspace.com/file/477phw
or
https://s.sami-lehti...illa issues.zip

Edited by Sami Lehtinen, 10 November 2011 - 09:20 AM.


#7 madmax69

madmax69

    Member

  • Members
  • 41 posts
  •  
    United Kingdom

Posted 10 November 2011 - 11:01 AM

Ah yes, this rings a few bells. During my own experimentations learning a bit about PXE/GRUB booting I believe I also came across similar problems with CloneZilla and gave up for the time being. I've left tftpd32 running whilst experimenting with other distros such as TinyCore and it's accepted requests OK from other Linux distros so I suspect it's a combination of problems with the two packages. I was running tftpd32 4.00.

I did spend a lot of time faffing about with command line TCP/IP overrides on the problematic Linux distros and got absolutely no where. I vaguely recall coming across forums which mention that the IP allocation scripting on some Linux distros was severely broken but sadly didn't make any notes at the time.

So far I've not found a single problem with tftpd32 and any distro of Windows such as HBCD, Bart, UBCD4win etc. and it does seem (from my own experiences at least) to be a tftpd32/Linux interaction issue.

This thread mentions a similar issue and that they changed to haneWIN DHCP server
http://sourceforge.n...8/topic/4439830 (post #4)
http://www.hanewin.net/

I may have to revisit Clonezilla myself.

Hope this helps

#8 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 10 November 2011 - 11:19 AM

Thanks, I'll try haneWIN.

#9 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 10 November 2011 - 11:44 AM

haneWIN works as expected. So it does PXE boot and it also passes pxelinux.0 dhcp lookup. So it clearly works better than TFTPD32.

But it didn't solve ubuntu versions live-config hang. But now I think it's completely separate issue. So this DHCP / TFTPD32 issue is solved. Clonezilla issue remain.

- Thank you!

#10 madmax69

madmax69

    Member

  • Members
  • 41 posts
  •  
    United Kingdom

Posted 10 November 2011 - 12:44 PM

Glad you made some progress.

I just had a quick revisit of my config. I couldn't get it to boot at all in GRUB; and in PXELinux I ran into problems with the boot time ethernet config using TFTPD32. - hanging at "[12.956793] eth0: Media Link on 100mbps full-duplex". (which led me onto a long forum sniffing trail looking at problems with various Linux ethernet config scripts. Unfortunately I'm not an expert with Linux so drew a blank).

#11 madmax69

madmax69

    Member

  • Members
  • 41 posts
  •  
    United Kingdom

Posted 10 November 2011 - 08:38 PM

To underline your original issues with tftpd32. I experimented again with Clonezilla. It ignores any APPEND values to configure eth0 and I found the only way could boot was to exit tftpd32 sharply after vmlinuz and initrd had been downloaded. This caused config to fall back to my local firewall/router, grab a valid IP address and then continue to boot OK. With tftpd it always hangs with an error 2. To me this confirms the issues with tftpd32 DHCP and certain Linux distros.

I had tried:

append initrd=/clonezilla/initrd.img no-config ip=eth1:192.168.3.210:255.255.255.0:192.168.3.1:192.168.2.100 boot=live noswap nolocales edd=on nomodeset ocs_live_run="ocs-live-general" ocs_live_extra_param="" ocs_live_keymap="" ocs_live_batch="no" ocs_lang="" vga=788 nosplash fetch=http://192.168.3.178:8800/linux/clonezilla/filesystem.squashfs

(and config as well as no-config) but it still did an auto-DHCP

I had the same problems pxe booting GParted Linux via PXELinux

I also tried haneWIN but whilst the DHCP was ok the TFTP server seemed a bit 'iffy. Either that or I couldn't figure out the right options as it didn't seem to set the TFTP server root properly for GRUB to find it's menu module - also had *lots* of "get error 4 tftp" errors!

I wish I knew more about Linux!

#12 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 11 November 2011 - 06:30 AM

To underline your original issues with tftpd32. I experimented again with Clonezilla. It ignores any APPEND values to configure eth0 and I found the only way could boot was to exit tftpd32 sharply after vmlinuz and initrd had been downloaded. This caused config to fall back to my local firewall/router, grab a valid IP address and then continue to boot OK. With tftpd it always hangs with an error 2. To me this confirms the issues with tftpd32 DHCP and certain Linux distros.

I'm glad you were able to confirm that. Let's see if it could get fixed. Although there are workarounds. It would be interesting to know if this is flaw in pxelinux.0 or in tftpd32. I have to see if I have time and energy to checkout pxelinux.0 source. tftpd32 is seems to also be open sourced. It could be bit different and therefore interesting weekend task. I haven't been working with these projects, so I'm not exactly sure if there is bug / issue tracker somewhere. Also the author of tftpd32 seems to be reading this board at times, so maybe it could get fixed. I'm pretty sure the issue is very small technically.

append initrd=/clonezilla/initrd.img no-config ip=eth1:192.168.3.210:255.255.255.0:192.168.3.1:192.168.2.100 boot=live noswap nolocales edd=on nomodeset ocs_live_run="ocs-live-general" ocs_live_extra_param="" ocs_live_keymap="" ocs_live_batch="no" ocs_lang="" vga=788 nosplash fetch=http://192.168.3.178:8800/linux/clonezilla/filesystem.squashfs
I also tried haneWIN but whilst the DHCP was ok the TFTP server seemed a bit 'iffy. Either that or I couldn't figure out the right options as it didn't seem to set the TFTP server root properly for GRUB to find it's menu module - also had *lots* of "get error 4 tftp" errors!


I found out haneWIN to work here perfectly. It's TFTP server seemd to be much faster than tfpd32 even when using 64k anticipation window.

About my Clonezilla issues. Actually your answer gave pretty much the same answer I figured out last night. I went in my mind whole boot process through and though what could go wrong. Because the exactly same filesystem.squashfs didn't work when loaded using TFTP but did work perfectly when started from USB. I came to conclusion that there aren't too many places where you can enter any parameters for that. Then I were absolutely sure that the difference needs to be between syslinux.cfg (usb) and pxelinux.cfg/default (tftp) files. And that was it. If I would have tried the sample above it would have solved my problem also, even if you weren't replying to that second problem.

I'm currently running two DHCP servers with non-overlapping IP ranges in pre-install network and it seems to be working well. Therefore I don't need to shutdown tftpd32. We're cloning about 6-20 machines at time and therefore doing manual tricks like that isn't a good option at all. If it wouldn't work, it would be much better to use USB stick boot. I also added to USB stick syslinux.cfg config file default label this parameter "toram=filesystem.squashfs". Now USB stick needs to be attached to single machine for about 10 seconds and that's it. Then system is running completely from memory. You can stick it to next computer.

I guess that those DHCP issue threw me off a bit with this case. But now everything is clear and working.

If you or someone else got any questions, I'm glad to help.

- Thank you

Best regards,
Sami Lehtinen

Edit: I'll try to configure our Zyxel firewall to deliver required DHCP options. So I wouldn't need to use tftpd32 DHCP server at all. Yet another interesting challenge. After quick Googling it turned out that ZyWALLs got very limited DHCP server, so it isn't possible to add required options.

Edited by Sami Lehtinen, 11 November 2011 - 06:40 AM.


#13 madmax69

madmax69

    Member

  • Members
  • 41 posts
  •  
    United Kingdom

Posted 11 November 2011 - 04:00 PM

I had thought of hacking my US Robotics wireless router but as with your Zyxel one, although they probably run embedded Linux I couldn't find a way to easily set the DHCP boot options. Maybe there's a forum with router hacking somewhere.

I'll have a look at those option switches. I was actually experimenting with gPXE/HTTP booting using MicroApache rather than using TFTP. It works nicely but most of the Linux distros have a problem finding their file system. I'm confident that it's because I'm not supplying the correct arguments. The only one I've found which works easily is Tinycore Linux

HTTP scales better than TFTP as is discussed in this Google tech talk... (the iSCSI and AoE) demos look impressive too!)


#14 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 14 November 2011 - 07:33 AM

ZyWALL 35 runs ZyNOS. Support for DHCP options is non-existent with all(?) Zyxel models, even if with more expensive USG models.

Edited by Sami Lehtinen, 14 November 2011 - 07:34 AM.

  • madmax69 likes this

#15 patpat

patpat

    Member

  • Banned
  • 48 posts
  •  
    United States

Posted 16 November 2011 - 11:02 AM

Clonezilla used to have recent problems when performing PXE DHCP/proxyDHCP requests
http://sourceforge.n...8/topic/4642813

I'd like to know if you guys also have the same issues when using Serva
http://www.vercot.com/~serva/

#16 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 16 November 2011 - 11:17 AM

I'd like to know if you guys also have the same issues when using Serva


Thanks for the tip. I'll try it on Friday and report back.

#17 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 18 November 2011 - 07:52 AM

Serva is clearly fork of TFTPD or vice versa. So yes, it did suffer from exactly the same DHCP problem.

Edited by Sami Lehtinen, 18 November 2011 - 08:08 AM.


#18 patpat

patpat

    Member

  • Banned
  • 48 posts
  •  
    United States

Posted 18 November 2011 - 08:26 AM

(if you have the time) it would be handy if you can post a wireshark capture (pcap) of the failing run...

#19 patpat

patpat

    Member

  • Banned
  • 48 posts
  •  
    United States

Posted 16 January 2012 - 04:21 PM

try this testing version and see if the DHCP/Clonezilla issues are gone
http://www.vercot.co...sting.Build.rar

#20 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 27 January 2012 - 09:38 AM

try this testing version and see if the DHCP/Clonezilla issues are gone


Very nice! DHCP/Clonezilla issues are gone. - Thank you!

Except there is another minor problem. How ever I start the Serva32.exe first time, it always crashes and claims that it can't access serva.ini. I tried scheduler (after login), I tried Startup group (yes, working path is correct!). I tried cmd and lnk files in startup. Delay, cmd file with start command. But alas, all methods to start serva.exe after startup automatically failed. I need to do something about that. Yes, there is only one administrator account on test server, and I'm absolutely positive that that account got full access to all required paths and files. But I'm pretty sure that I can manage to get some working work-a-round for this.

- Thank you!

Best regards,
Sami Lehtinen

#21 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 27 January 2012 - 02:07 PM

There seem to be other minor compability issues with DHCP server, like...
Err: Requested address 0.0.0.0 not allocated; not in pool or already in use

Posted Image

For some reason this issue doesn't get resolved as usual. I had to release and renew (acquire) again. With other servers, issue get's resolved after a short while.

#22 patpat

patpat

    Member

  • Banned
  • 48 posts
  •  
    United States

Posted 30 January 2012 - 01:45 PM

The errors you mentioned on this thread are not Serva's nor Tftpd32 fault.
There are Godzilla's fault when making incorrect DHCP requests

i.e. a DHCP Request with “Your (client) IP address” = x.y.z.a --When it should have been 0.0.0.0--
A request like that does not follow RFC-2131 and Serva does not answer such a request (Tftpd32 does the same).
The "testing version" you tried bypasses that checking and you got it working, the next error you mention is also related.
haneWIN does not have this checking and you see that "it works as expected" but it's not really the case.

The proper way to solve this should be contacting the software coders and asking them to perform the
DCHPREQUEST following the RFC-2131


Other software affected by this problem

Clonezilla:
clonezilla-live-1.2.11-46-amd64
clonezilla-live-1.2.11-46-i686-pae
clonezilla-live-1.2.11-43-amd64
clonezilla-live-1.2.11-43-i686-pae

oneric branch:
clonezilla-live-20120111-oneiric
clonezilla-live-20120103-oneiric

precise branch:
clonezilla-live-20120111-precise
clonezilla-live-20120103-precise

gparted-live:
gparted-live-0.11.0-7
gparted-live-0.11.0-10

webconverger:
webc-10.2

xbmc:
xbmc-10.1-live

Best
Pat

#23 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 31 January 2012 - 07:34 AM

The errors you mentioned on this thread are not Serva's nor Tftpd32 fault.
There are Godzilla's fault when making incorrect DHCP requests


Yes, and there are other wonderfully annoying problems, with this solution too. It seems that some RTL 1GB adapters go "dead" immediately after loading pxelinux.0 file. Even if you boot computer to Windows, network adapter is still dead. Until you'll disconnect powersupply completely. Some of our techies almost sent batch of computers to warranty repair, before I confirmed that adapter is in some strange "dead" mode.

* I just can't stop loving strange and even stranger issues *

P.S. I'll write you email about "initial crash", it's not as serious as I initially thought it would be.

Edited by Sami Lehtinen, 31 January 2012 - 07:53 AM.


#24 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 11 February 2012 - 11:55 AM

I posted this question to Clonezilla Live support forum:
SourceForge - Clonezilla Live - Broken DHCP client?

Let's see if we get any discussion there and if and when issue gets hopefully resolved.
Yes, there is link back to this discussion so we don't need to repeat same discussion over again.

- Thank you

Best regards,
Sami Lehtinen

#25 Sami Lehtinen

Sami Lehtinen

    Newbie

  • Members
  • 22 posts
  •  
    Finland

Posted 11 March 2012 - 05:43 PM

I wish we would have here people who are more experienced with this stuff than Clonezilla guys. I'm also not exactly sure that it's Clonezilla at all, that's causing this problem. I hope this information could help to pinpoint the problem.

- Thank you!

Well, it didn't work out as well as I would have hoped. I have to confess that I clearly do not have enough experience with PXE boot process. So I can't easily confirm exactly where the problem is. But I have something pretty good. Which is also bit confusing.

1) I could easily repeat the DHCP issue.
2) Packet capture didn't reveal what I was expecting.
3) I couldn't (easily) pinpoint the exact hang point in process.

But I'm hope that someone with more experience than I, can do it based on information that I provide here. Some important factors to consider are.

1) From USB boot, all Clonzeilla versions worked without problems. Including DHCP address fetch when activating network features.
2) Network boot didn't work with any computer, when using serva32 or non-modified serva32 DHCP servers.
3) Hang point could be before anything related to Clonezilla project is being executed.
4) I have full DHCP network packet capture log.

It's very interesting that TFTPD log says that address 0.0.0.67 was requested. I couldn't see that IP address in DHCP packet, when using Microsoft Network Monitor. I did also take a look at raw packet data, and it didn't either reveal that address. But I haven't done job of exactly comparing DHCP packet structure with that data. I just know that there was only one match for 67 and it's port number, not IP address. So it could also sound viable that TFTPD would misparse the packets. But if it does that, it shoulnd't work properly with any other dhcp client. I just earlier said that TFPD works perfectly with all windows systems, bios dhcp and clonezillas DHCP when booting from USB.

From TFTPD TFTP log we can see that last file download using TFTP was: initrd.img after that some system starts DHCP client again and it hangs as we can see from the screenshot (ha, taken with camera). That's also where the final hang happens. IP address can't be fetched and that's it. Nothing happens after this point.

From TFPD server log, we can see that we received three DHCP requests. Which all were "invalid" and therefore ignored. So it can't be network card issue, even if it says on screen that it might be propable.

Packet capture, screenshot and tfpd32 logs are included in this packet: https://s.sami-lehti...b/dhcp-issue.7z

So what I now hope, is that someone more experienced with this stuff would simply say what the problem is and where it is. If required I can provide all configuration files.

- Thank you!

This is just why this topics subject does include the question mark. As said, we can easily circumvent this problem by using USB flash boot. But I generally prefer getting the real issue fixed than making work-a-rounds.

Best regards,
Sami Lehtinen






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users