LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 12-18-2014, 05:50 PM   #1
Noony
LQ Newbie
 
Registered: Feb 2009
Distribution: Slackware
Posts: 18

Rep: Reputation: 0
ddns fails if dual booting between Linux and Windows


bind-9.3.2_P1 and dhcp-3.0.4
Home network with one server on Linux and ~25 client computers, all of which can dual boot between WinXP and Linux.

I've been using my ddns system for 11 years, and it's worked perfectly since then except for one annoying problem.

It works fine for clients that stay in WinXP and for clients that stay in Linux. If I reboot from WinXP to Linux, the Linux box does not get name service but does get an IP address. dhcpd issues the "...not mine" message. However, the record was definitely placed into the forward zone file by this dhcpd, so at least the claim of "...not mine" is a definite bug. The TXT string that looks like an md5 string is identical to the one that's stored in the leases file. The TXT string is also the same whether the lease is for the Windows system or for the Linux system.

For any particular client, the Windows system and the Linux system have the same hostname and the same MAC address, so I had thought that dhcpd would treat them both as one client. It doesn't treat them as the same client, but it also does not treat them as two clients.

When Linux shuts down, it releases it's lease, but Windows does not. So Windows always gets name service, but Linux only gets it if it boots after the windows' lease expires.

This problem could be fixed if I could do any one of the following:
1) Make dhcpd treat two systems on the same MAC address as the same client.
2) Make dhcpd treat two systems on the same MAC address as two separate clients.
3) Make WinXP release its lease during shut down.

Of course, #3 can be done manually with <ipconfig /release>, but I can't find any place in Windows to insert a command to be executed during shut down, and who can remember to do it in the heat of battle?
 
Old 12-19-2014, 02:26 PM   #2
allend
LQ 5k Club
 
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware64-15.0
Posts: 6,389

Rep: Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764Reputation: 2764
I use dnsmasq, which has this in dnsmasq.conf.
Quote:
# Send microsoft-specific option to tell windows to release the DHCP lease
# when it shuts down. Note the "i" flag, to tell dnsmasq to send the
# value as a four-byte integer - that's what microsoft wants. See
# http://technet2.microsoft.com/Window....mspx?mfr=true
 
Old 12-20-2014, 11:39 AM   #3
Noony
LQ Newbie
 
Registered: Feb 2009
Distribution: Slackware
Posts: 18

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by allend View Post
I use dnsmasq, which has this in dnsmasq.conf.
It looks like that's a solution, so I'm reading up on dnsmasq. So far it looks daunting with 2/3 of an infinite amount of options.

Since dnsmasq can send something to Windows to tell it to release on shutdown, then surely the ISC dhcp can do it too. Does anybody know if this is true and how to do it?
 
Old 12-20-2014, 06:15 PM   #4
Noony
LQ Newbie
 
Registered: Feb 2009
Distribution: Slackware
Posts: 18

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by Noony View Post
The TXT string is also the same whether the lease is for the Windows system or for the Linux system.
This part of my original post was an error. The string is different for Win & Linux.

In the leases file, I find that the "uid" is always 7 bytes for WinXP and 19 bytes for Linux. I finally found out that the TXT string is hashed from only the uid. Translating from octal, I found that the uid from Windows is just the MAC address prefixed with 01, and those same 7 bytes appear at the end of the 19-byte uid from Linux. I looked in dhcpcd.conf for clientid stuff and I found:

...
#clientid
...
duid
...

I moved the # from the duid to the clientid, and now both Linux and Windows issue the same "uid" string. That fixed the problem. Both systems are recognized as the same client and they get the same IP address.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Grub won't load windows - Dual booting Windows 8 and Linux Mint Canas Linux - Laptop and Netbook 7 01-26-2014 12:12 PM
dual-booting windows and linux, windows error-code: 0xC004E002 acoleman Linux - General 6 11-04-2011 06:30 PM
dual boot system booting in Redhat linux but not booting in Windows XP sumitra Linux - Newbie 3 03-24-2011 09:42 AM
[SOLVED] Dual booting windows and linux? David2010 Linux - Newbie 5 09-11-2010 02:37 PM
SuSE 9.1 / Windows XP suddenly dual booting fails ticker Linux - General 8 06-17-2004 04:44 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 07:12 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration