• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Help Android 7.0 - IP and Proxy setting will not persist

Hello,

Was not too sure where to post this so I thought I would start with the Lounge.

I am working on an Android device that needs to have a fixed IP as well as a proxy server address/port configured. I have configured these settings in the WiFi connection properties but if I restart the device or even turn off/on WiFi, the connection properties default back to DHCP and no proxy server. I have tried "forgetting" the WiFi and re-configuring it but this did not change anything The device is running OS v7.0.

Is this a bug in this Android version and is there a way to fix this?

Thanks,
Kevin
 
You cannot just set up a fixed IP address through your phone, you need to assign your phone its fixed IP address in your router settings menu. It's your router that determines what devices receive their IP addresses, either using DHCP, assigning them manually, or a combination of the two.
If you actually were able to just make an IP address on just your phone, that would greatly increase the chances of your phone creating a networking conflict in the event another device is using the same address. It's not a 'bug' in Android, it's something relative to any WiFi network you connect with.
Also, keep in mind that this assigned IP address will only apply to the particular WiFi network you're connected to. (... the issue being you cannot assume you have control over the router of every WiFi network you connect with).
 
Upvote 0
Hi svim,

Yes, I am aware of how the IP addresses work. I have a WiFi router setup with the appropriate IP range. The issue is not one of IP conflicts, it is the Android device IP setting not being persistent.

Another example is where I use DHCP for the IP but configure a proxy server and port in the advanced settings. This is fine until I turn off WiFi and turn it back on again. Once I do, the prosy server settings are no longer configured.

-Kevin
 
Upvote 0
You cannot just set up a fixed IP address through your phone
Why not?
you need to assign your phone its fixed IP address in your router settings menu.
Why?

:thinking:

I'm just thinking out loud here, okay? On Linux proper, it's a trivial task to assign a computer its own IP address--on the computer. I assigned static IP addresses to all my computers, and never even looked at the router's settings.

I know that Android, though a Linux, is not exactly like Linux proper, but something like this issue seems doable...to me. :)
 
Upvote 0
Why not?

Why?

:thinking:

I'm just thinking out loud here, okay? On Linux proper, it's a trivial task to assign a computer its own IP address--on the computer. I assigned static IP addresses to all my computers, and never even looked at the router's settings.

I know that Android, though a Linux, is not exactly like Linux proper, but something like this issue seems doable...to me. :)

So you either have your Linux box set up to also be your LAN's DHCP server, which further pushes this thread off topic, or you just set your IP address using the OS's network stack to use whichever IP address it was being provided (by your router). If any device could just use whichever fixed IP address its user preferred, than that creates a big conflict issue since the likelihood of one, two, or more devices also using that same IP address. One of the basic functions of a router is to only assign each device its own, unique IP address (it's even part of the name -- 'route' traffic packets to the proper connecting devices).

But the topic should go back to the OP's query and why the 'advanced' WiFi settings aren't being saved.
OK, let's drop the whole fixed IP idea.
Why would the Android OS not preserve the proxy server setting when WiFi is switched off and back on?
Try setting up a guest network in your router, leaving all its initial settings as their defaults and when you connect your mobile device to that WiFi network see if the advanced settings get saved from session to session.
 
Upvote 0
All I can say, @svim, is that I picked which IP address to assign to which computer, and that was that. For example, my main laptop is 192.168.1.123, while my second-oldest desktop is 192.168.1.108.

Of course they're tied to my home network, but isn't that what the OP wants to do with theirs? Since it's so easy on Linux, it seems like it should be on Android, too. *shrug*
 
Upvote 0
All I can say, @svim, is that I picked which IP address to assign to which computer, and that was that. For example, my main laptop is 192.168.1.123, while my second-oldest desktop is 192.168.1.108.
Of course they're tied to my home network, but isn't that what the OP wants to do with theirs? Since it's so easy on Linux, it seems like it should be on Android, too. *shrug*
Don't know what else to comment on. You're interpreting this as opinion but it's not, a typical consumer LAN, or as the OP has revealed, a lab setting, is based on established (most for decades now) networking principles. Whether you opt to believe in them is of course up to you.


Leaving the defaults is not an option, this is a lab environment with specific requirements for IP addressing. However, as a diagnostic step, I will give this a try and report back on the results. Still questioning why this would have any impact on the persistence of the proxy settings but. . .
OK, given the local network is a fixed issue, just some random thoughts:
-- Does this mobile device also have a VPN service installed? Or a non-root firewall? Or an ad-blocker? (i.e. anything that requires an outbound or a local VPN service)
-- Is any anti-virus/anti-malware app installed?
-- If you look through this mobile device's Settings menu, is there any option referring to 'Reset default networks' or 'Network settings reset' or anything similar? This will reset all network related settings back to their defaults so it will wipe any saved WiFi networks, Bluetooth pairings, adjustments to cellular, etc. so it's something of a last resort option as far as networking. And it might not have anything to do with why advanced WiFi alterations aren't being saved.
 
Upvote 0
Don't know what else to comment on. You're interpreting this as opinion but it's not, a typical consumer LAN, or as the OP has revealed, a lab setting, is based on established (most for decades now) networking principles. Whether you opt to believe in them is of course up to you.
I'm kind of puzzled. There's no opinion involved in anything I've said--any Linux user can easily set their computers' IP addresses, on each computer, not the router. That's fact! I'm not sure what you think there's to believe in, or not. Fact is good enough for me.
 
Upvote 0
OK, given the local network is a fixed issue, just some random thoughts:
-- Does this mobile device also have a VPN service installed? Or a non-root firewall? Or an ad-blocker? (i.e. anything that requires an outbound or a local VPN service)
-- Is any anti-virus/anti-malware app installed?
-- If you look through this mobile device's Settings menu, is there any option referring to 'Reset default networks' or 'Network settings reset' or anything similar? This will reset all network related settings back to their defaults so it will wipe any saved WiFi networks, Bluetooth pairings, adjustments to cellular, etc. so it's something of a last resort option as far as networking. And it might not have anything to do with why advanced WiFi alterations aren't being saved.

-No VPN, firewall or ad-blocker service installed. The device is new out of the box.
-No AV or anti-malware installed.
-I reset the network settings to defaults and re-configured the WiFi connection and the proxy server settings still do not persist.
 
Upvote 0
I'm kind of puzzled. There's no opinion involved in anything I've said--any Linux user can easily set their computers' IP addresses, on each computer, not the router. That's fact! I'm not sure what you think there's to believe in, or not. Fact is good enough for me.
Perhaps reading up on some basics and fundamental networking will clear things up:
https://www.bleepingcomputer.com/tutorials/ip-addresses-explained/
(the above is a dated article but still relevant)
https://www.cnet.com/how-to/home-networking-explained-part-1-heres-the-url-for-you/
 
Upvote 0
-No VPN, firewall or ad-blocker service installed. The device is new out of the box.
-No AV or anti-malware installed.
-I reset the network settings to defaults and re-configured the WiFi connection and the proxy server settings still do not persist.

Given this device appears to be pretty much a plain vanilla install I wouldn't think this has anything to do with this issue but is the proxy server setting using port 8080? Perhaps changing to a different (open) port will allow the settings changes to actually hold in between sessions.
This PortDroid app might help reveal some relevant details:
https://play.google.com/store/apps/details?id=com.stealthcopter.portdroid
 
Upvote 0
Yes, perhaps it will--for someone who doesn't know how to change their IP addresses... ;)
Or those who prefer to have a fully functional, stable, and manageable local network in the home or workplace. In a work or educational setting this is often done by an IT department or someone designated to be manage the LAN; in a home setting if you've never delved into your router settings menus than the odds of using just the router's default settings as is will increase the likelihood of security and privacy vulnerabilities.
 
Upvote 0
I really don't know how we've veered this far OT, @svim! I'm very familiar with router settings, and have security I defy anyone to breach.

As the highest paid [non-owner] employee at two consecutive companies, my security was legendary.

And in 35 years of computing, I have yet to encounter one intrusion, one virus, one malware, one privacy breach, etc.

I don't know why stating that I assign static IP addresses to the computers on my network turned me into an ignorant imbecile...
 
Upvote 0

BEST TECH IN 2023

We've been tracking upcoming products and ranking the best tech since 2007. Thanks for trusting our opinion: we get rewarded through affiliate links that earn us a commission and we invite you to learn more about us.

Smartphones