I've been searching a while for an answer to this but I can't find the solution and my problem is quite specific.
Basically I want to create an additional and seamless WiFi access point on my Raspberry PI (2 with WiFi dongle). I have setup hostapd and dnsmasq services as below and they work perfectly if a client manually connects directly to my PI. However if a client, which is initially connected to the WiFi of my main router, goes out of WiFi range of my main router the client will correctly switch to the access point on my Raspberry PI (it has an identical SSID as my main router) but it then loses internet connectivity because it doesn't accept the IP address supplied by the dnsmasq service on the Raspberry PI.
How can I force clients to re-negotiate the IP address with the new access point it switched to? I'm only assuming that is the problem of the lost connectivity because on the client I can see it is connected to my RPI access point but it has the wrong IP address. It might be a routing problem instead but I don't know.
I cannot use bridging unfortunately because later I want to be able to add a guest WiFi access point using a virtual interface. I've tried that and it works except again for the roaming problem described above.
Hopefully I've made myself clear and provided enough information.