Community discussions

MikroTik App
 
changeip
Forum Guru
Forum Guru
Topic Author
Posts: 3833
Joined: Fri May 28, 2004 5:22 pm

wireless station; dhcp-client

Thu May 31, 2007 1:44 am

3.0beta8

If a mikrotik wireless station is using dhcp-client when it's connected to an AP, and it disconnects and reconnects to another SSID, should DHCP release and renew automatically ? I'm finding that once a dhcp-client receives an address it doesn't bother to invalidate it when the ssid changes, unlike an ethernet interface that loses link state. Is this normal?

:if ( ([/int wireless monitor wlan-2400mhz as-value]->"status") != "connected-to-ess" ) do={ /ip dhcp-client renew wlan-2400mhz }

I'm having to use this script to make sure when I roam from home to the office I get the dhcp-client to release and renew the addy. Should dhcp-client see this interface down (!=connected-to-ess) and release it automatically ?

Sam
 
GotNet
Member
Member
Posts: 434
Joined: Fri May 28, 2004 7:52 pm
Location: Florida

Re: wireless station; dhcp-client

Thu May 31, 2007 2:06 am

I've had that issue for a while now and not just with the betas. I wrote a script to renew when the interface is "connected-to-ess".

Edit -> I see you also use the same script! On a side note, release does the same as renew. Why?
 
kblazk
Frequent Visitor
Frequent Visitor
Posts: 52
Joined: Sat Aug 21, 2004 12:19 am
Contact:

Re: wireless station; dhcp-client

Fri Dec 21, 2007 7:59 pm

how do i use this script, this is exactly what i need but it is not doing anything