Jump to content


 


Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.


Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.

Photo

Win7 DNS settings lost on restart


  • Please log in to reply
23 replies to this topic

#1 NickWUK

NickWUK

  • Members
  • 19 posts
  • OFFLINE
  •  
  • Local time:10:49 PM

Posted 23 May 2017 - 05:49 PM

Very often I find that when my Win7 PC is restarted the IPv4 DNS settings are lost, and some times this can occur without restarting. The PC is setup with a fixed IP because it's running a local web server, I don't want to use DHCP because I want the PC to always have the same IP. Also I set the alternative DNS to 8.8.8.8, but all these setting often get wiped and reset to automatically assign IP. Any ideas why please?

 

I have a Zyxel VMG 1312-B10A router and in the DNS section I have both Google's 8.8.8.8 and Opendns' 208.67.222.222 DNS IPs set.


Edited by Chris Cosgrove, 23 May 2017 - 06:14 PM.
Moved from Win 7 to Networking.


BC AdBot (Login to Remove)

 


#2 GoofProg

GoofProg

  • Banned
  • 224 posts
  • OFFLINE
  •  
  • Gender:Male
  • Local time:02:49 PM

Posted 23 May 2017 - 09:33 PM

So I assume you go to the network adapter settings and assign your DNS services.  You know if it points to your router and your router points to the DNS addresses that are desired then there is no problem.  Your router just does the dns services... I guess even if DHCP is not on.



#3 NickWUK

NickWUK
  • Topic Starter

  • Members
  • 19 posts
  • OFFLINE
  •  
  • Local time:10:49 PM

Posted 24 May 2017 - 04:05 AM

I've had situations where the PC is set to point to the router/default gateway without the DNS 8.8.8.8 being set and it won't find sites until I do set that IP as an alternative DNS. But the main issue is that the fixed IP setting gets wiped; If you change settings then you expect them to stay in place.



#4 fraserspur

fraserspur

  • Members
  • 16 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Australia
  • Local time:08:49 AM

Posted 24 May 2017 - 07:09 AM

It's a very basic I know, but have you checked if DHCP is on in the router and if it is, that the IP address you are allocating to the WIN 7 PC isn't already allocated to another machine? 

 

You could also try allocating a static lease in the router for the  WIN 7 PC, then if the addressing on the PC is set to automatic the router will allocate the address you want in  any case. 

 

You could also enter the static DNS server addresses into the router, that way they are also automatically allocated even if WIN 7 PC is set to autoconfig, but they will also be allocated to any other machine that connects using DHCP.



#5 Kilroy

Kilroy

  • BC Advisor
  • 3,408 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Launderdale, MN
  • Local time:04:49 PM

Posted 24 May 2017 - 12:48 PM

If you set up a reservation on your DHCP server you can essentially set a static IP address and leave the machine set to DHCP.  The way it works is that you set it up by the machine's MAC address and when that MAC address requests an IP address it is always given the same address.



#6 Guest_Aaron_Warrior_*

Guest_Aaron_Warrior_*

  • Guests
  • OFFLINE
  •  

Posted 24 May 2017 - 06:00 PM

Attached File  fixed.JPG   49.69KB   0 downloads

 

Is this the screen where you are attempting to save your "static" internal/local IP Address? FYI, typically the phrase "IP Address" refers to your "outside" or "outward facing" IP Address.  Usually when reading things online the local IP's are called "local" or "internal".  I just want to make certain you aren't trying to set your computer's local IP at your router, or whatever.

 

It's possible the information isn't being saved because it will not allow you to have to different DNS servers at the same time. My point is that there may be a flaw in the data you are attempting to save, so it isn't being saved.  Also, if there is an internal IP Address conflict, example another device is trying to use the same IP, this might cause the problem.  Finally, if your IP is outside the range, the data may not stick.  Example what if your DHCP server's (router, cable modem or whatever) local IP range is outside the one you are trying to make static.


Edited by Aaron_Warrior, 24 May 2017 - 06:03 PM.


#7 NickWUK

NickWUK
  • Topic Starter

  • Members
  • 19 posts
  • OFFLINE
  •  

Posted 25 May 2017 - 03:58 AM

It's a very basic I know, but have you checked if DHCP is on in the router and if it is, that the IP address you are allocating to the WIN 7 PC isn't already allocated to another machine? 
 
You could also try allocating a static lease in the router for the  WIN 7 PC, then if the addressing on the PC is set to automatic the router will allocate the address you want in  any case. 
 
You could also enter the static DNS server addresses into the router, that way they are also automatically allocated even if WIN 7 PC is set to autoconfig, but they will also be allocated to any other machine that connects using DHCP.

 
Yes DHCP is on, the IP pool was set in the router to 10.0.0.4 - 10.0.0.20 and the static IP is 10.0.0.3, which I know is not being used by any other device. I've now changed the IP range to 10.0.0.3 - 10.0.0.20 and in the tabbed section called 'Static DHCP' In 'Home Networking' I've now added a new static lease for 10.0.0.3 with the Mac address of the Win7 PC and set to Active.
 
The google and opendns ips were already set in the DNS section, however I noticed there was also a place to set static dns server IPs under the 'LAN Setup' tab (where the IP pool is defined) so I've also added those dns server IPs there too.
 
 

If you set up a reservation on your DHCP server you can essentially set a static IP address and leave the machine set to DHCP.  The way it works is that you set it up by the machine's MAC address and when that MAC address requests an IP address it is always given the same address.

 
Yes, now done.
 

attachicon.giffixed.JPG
 
Is this the screen where you are attempting to save your "static" internal/local IP Address? FYI, typically the phrase "IP Address" refers to your "outside" or "outward facing" IP Address.  Usually when reading things online the local IP's are called "local" or "internal".  I just want to make certain you aren't trying to set your computer's local IP at your router, or whatever.
 
It's possible the information isn't being saved because it will not allow you to have to different DNS servers at the same time. My point is that there may be a flaw in the data you are attempting to save, so it isn't being saved.  Also, if there is an internal IP Address conflict, example another device is trying to use the same IP, this might cause the problem.  Finally, if your IP is outside the range, the data may not stick.  Example what if your DHCP server's (router, cable modem or whatever) local IP range is outside the one you are trying to make static.


Yes that was the screen I was entering details, it was the local IP. This screen and the advanced section indicate that it should accept two dns server ips. There's no IP conflict between device boxes but there has in the past been a conflict between two network adaptors on the same PC, but I thought I'd made the system forget the extra NA. The static IP was outside the DHCP pool, however I've now included it and setup a static lease for 365 days.

 

 

Thank you all for your guidance. Sounds like in the past some interaction between router DHCP and PC networking has caused settings to dynamically change. Now I've setup a static lease on the router, I'll reboot the router and see how it works.



#8 fraserspur

fraserspur

  • Members
  • 16 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Australia
  • Local time:10:49 PM

Posted 25 May 2017 - 07:19 AM

I think you should assign a static address outside of the range that DHCP uses, just to be sure that DHCP doesn't assign it to another device, though it depends on the routers firmware.  Try that if you still have problems.



#9 Guest_Aaron_Warrior_*

Guest_Aaron_Warrior_*

  • Guests
  • OFFLINE
  •  

Posted 25 May 2017 - 02:16 PM

I think you should assign a static address outside of the range that DHCP uses, just to be sure that DHCP doesn't assign it to another device, though it depends on the routers firmware.  Try that if you still have problems.

I second this good idea.

 

I also think your "10.x.x.x." IP address range is very, very weird.  Why are you using such a strange range?



#10 NickWUK

NickWUK
  • Topic Starter

  • Members
  • 19 posts
  • OFFLINE
  •  
  • Local time:08:49 AM

Posted 25 May 2017 - 04:30 PM

I think you should assign a static address outside of the range that DHCP uses, just to be sure that DHCP doesn't assign it to another device, though it depends on the routers firmware.  Try that if you still have problems.

 

Does an Ip with static lease need to be outside the DHCP address pool?

 

 

I think you should assign a static address outside of the range that DHCP uses, just to be sure that DHCP doesn't assign it to another device, though it depends on the routers firmware.  Try that if you still have problems.

I second this good idea.

 

I also think your "10.x.x.x." IP address range is very, very weird.  Why are you using such a strange range?

 

 

The address range is for historic reasons, a previous router used 10.x.x.x by default so I've continued to use it as this IP has been set in many places elswhere.



#11 Guest_Aaron_Warrior_*

Guest_Aaron_Warrior_*

  • Guests
  • OFFLINE
  •  

Posted 25 May 2017 - 04:50 PM

I kind of mentally "stepped back" from this thread and looked at it "big picture" and now I wonder if some device on your network thinks it's the DHCP Server and it is doing all this stuff attempting to be in control.



#12 fraserspur

fraserspur

  • Members
  • 16 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Australia

Posted 25 May 2017 - 06:25 PM

 

I think you should assign a static address outside of the range that DHCP uses, just to be sure that DHCP doesn't assign it to another device, though it depends on the routers firmware.  Try that if you still have problems.

 

Does an Ip with static lease need to be outside the DHCP address pool?

 

Yes it should, what you've done is possibly okay but it depends on the router firmware.

 

I think you should assign a static address outside of the range that DHCP uses, just to be sure that DHCP doesn't assign it to another device, though it depends on the routers firmware.  Try that if you still have problems.

I second this good idea.

 

I also think your "10.x.x.x." IP address range is very, very weird.  Why are you using such a strange range?

 

 

The address range is for historic reasons, a previous router used 10.x.x.x by default so I've continued to use it as this IP has been set in many places elswhere.

 

The 10.0.0.0 to 10.255.255.255 address range is within the standard allocation for private IP addresses, so it's fine.   Some ISP's (Telstra) allocate this range on the routers they supply.



#13 NickWUK

NickWUK
  • Topic Starter

  • Members
  • 19 posts
  • OFFLINE
  •  
  • Local time:10:49 PM

Posted 30 May 2017 - 04:41 AM

Seems to be working ok with 10.0.0.3 setup in the router with a static lease and the PC set to automatically detect settings.



#14 Guest_Aaron_Warrior_*

Guest_Aaron_Warrior_*

  • Guests
  • OFFLINE
  •  

Posted 30 May 2017 - 01:24 PM

Seems to be working ok with 10.0.0.3 setup in the router with a static lease and the PC set to automatically detect settings.

 

What do you think was the problem?  What did you do to fix it?



#15 NickWUK

NickWUK
  • Topic Starter

  • Members
  • 19 posts
  • OFFLINE
  •  

Posted 01 June 2017 - 03:58 PM

I don't know what was interfering with the IPv4 settings, but letting the router manage the IP with a fixed IP lease and setting the PC DNS to auto-detect seems to work.






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users