How to set static IP without specifying gateway - Android Q&A, Help & Troubleshooting

I'm trying to set up a Wifi with a static IP but NO gateway or DNS but until I enter a gateway and DNS the save button remains greyed out.
From a networking perspective, you should be able to have a Wifi connection without a gateway (This is true for all devices with multiple network connections) so that it uses an alternative connection (Mobile data in this case) but for some reason the Android devs seem to think otherwise.
The network I'm connecting to has no internet connection (Used for local connectivity only) so I need the phone to still use my mobile connection whilst connected. As Android turns off mobile data when connected to Wifi I was hoping I could leave the gateway blank to force it to use it's mobile connection when connected to this network but I can't
How can I either have mobile data on for just 1 SSID or save a connection with no gateway so it does use mobile (I tried 0.0.0.0 to no avail)?
Phone is a rooted HTC One M8 running Android 4.4.4

Related

[Q] WiFi: DHCP request although static IP configured

I face a strange behavior while connecting to WiFi.
When I configure the WiFi settings to use a static IP at home with a Speedport router from Telekom everything works fine. I get a connection imediately. (Security credentials are WPA2-PSK/AES).
But when I try to connect to a Cisco environment (1142 access points with 5508 controller with the same security credentials as at home) after PSK authentication the phone start with DHCP requests instead of using the configured static IP and I don't get a connection.
First I thought it was of the ROM or the device but I tried different ROMs (stocks and customs) and different devices (Defy and Galaxy S). Everytime the same thing.
A laptop or an iPhone can connect without any problem using a static IP.
It seems that the controller or AP sends something to the phone telling it to ignore the staic IP settings...
Strange!!!

[Q] Unable to connect to my external IP while on wifi?

I don't know if its this new ****ty 3in1 router Comcast has forced on us recently or what but I cannot connect to my external IP on my phone while on my own wifi network. For example Transdroid; I use my external IP as the server so that when I'm swapping in and out of 3G/wifi I'm not having to keep changing it. However now, it will only connect to the server when I'm on 3G, not wifi. If I change the IP to a local address, then it connects on wifi but obviously not 3G. Not really sure what the deal is and it's not only Transdroid that has this problem. Emit, my VNC applications and a couple others are having the same issue. Just doesn't want to connect to my own external ip address while I'm on my network. Makes no sense. Any ideas?
Your router probably doesn't support NAT reflection (or it's disabled). NAT reflection is basically a set a firewall rules that redirects connections to your external IP to the respective internal IP. For example:
Your external IP is 111.222.333.444
Your internal IP is 192.168.0.10
Your forwarded port is, say, 80
1) When you connect from your own WIFI with NAT reflection enabled (by default on most routers), this is what happens:
You connect to 111.222.333.444 on port 80. Your router tells your phone that the actual IP is 192.168.0.10 and it should connect to that instead.
2) When you connect from your own WIFI with NAT reflection disabled, this is what happens:
You connect to 111.222.333.444 on port 80. Your router tries to connect to that IP and as you know, when you connect to anything on the internet, only the external IP is visible. So, the router sees that both the source IP and the destination IP are 111.222.333.444. The router doesn't know how to handle this.
Try to see if there's a configuration option for this in the router's web interface. You may need to unplug the router afterwards. I hope this helps

[Q] WiFi connection w/o DHCP service

Occasionally I want to connect to a WiFi network that doesn't have a decent DHCP service. I can connect to the AP but I do not get an IP number, DNS server and so on.
Is there a way (an app, maybe) that allows manual configuration of a WiFI connection?
I'm running UrukDroid on Archos 101IT.
Under advanced wifi settings you can manually configure your connection. No need for a special app.
divx118

[Q] Android unable to connect to my Wi-Fi network - Windows can

I am in university halls of residence. I have setup a Wi-Fi hotspot in my room using a generic router by connecting from the ethernet out port in the wall to a ethernet LAN port and disabling DHCP on the router.
This works perfectly for my Windows 7 laptop. It connects to the router and then to the uni internet without issues. However, although my Samsung Galaxy S3 (International i9300) can detect the network, if I just try to connect to the network as I would any other it gets stuck when obtaining an IP address. After messing around with it for a bit i found that I could get the phone to connect by going into the advanced settings and choosing "static" instead of "DCHP". I don't know what I was really meant to enter for IP Address, gateway, subnet, DNS 1 and DNS 2.
The router has the IP of 192.168.1.1 when i connect it directly to my laptop via ethernet so I tried that as the gateway, I set the IP address to something like 192.168.1.14 (So that it was similar but different), I set the subnet to 255.255.255.0 and the DNS servers I used google's (8.8.8.8 and 8.8.4.4). This got me connected to the router but there doesn't appear to be any internet connection.
I therefore thought that I had entered wrong information for the network (I was only guessing after all). Therefore I went into ipconfig in Windows and copied the default gateway and DNS servers and used a similar IP address (Last number different). I had the same issue.
Does anyone have any suggestions?
I only want Wi-Fi in my room for mobile.

Use Android phone as Internet gateway (Not WiFi hotspot)

Just wondering if it is possible to setup Android 4 phone as internet gateway without enabling WiFi tethering?
Use case:
Connect the phone to my WiFi home network.
Set phone in gateway mode (ipv4 forwarding?)
On any other PC in my home network set default gateway to phone IP
In theory Android at this stage would handle outgoing connections for that particular PC.
On the grand scale what I'm thinking about is this:
I have multiple phones that have unlimited 4g plans on them, every time I come back home, phone joins the WiFi network and starts acting as a gateway. On my main routing box (pfSense) I setup multiple gateways (for each phone) and a load balancer. So every time phone appears, gateway changes to UP state in pfSense -> Load Balancing is using that phone as well. When I leave my house, pfSense detects that gateway is unreachable -> removes it from list of load balancers.
Did you ever find a solution, this is exactly what I want to do.

Categories

Resources