That is very possible.  Good suggestion.  Does anyone have any suggestion
of how I should SIGHUP dnsmasq?
I've tried these without much luck:

kill -1 `pidof dnsmasq`;

kill -9 `pidof dnsmasq`;

kill -HUP `pidof dnsmasq`;

kill -SIGHUP `pidof dnsmasq`;

/etc/init.d/dnsmasq restart;


I even put a 5 second sleep after the HUP to try to give it time to start
back up.

Ideas?

Eric


On Thu, Jan 17, 2013 at 11:19 AM, richardvo...@gmail.com <
richardvo...@gmail.com> wrote:

> From your symptoms, I believe you aren't sending SIGHUP correctly, and
> dnsmasq picks up the change after a minute due to its /etc/hosts polling.
>
> dnsmasq uses multiple processes when seteuid behavior is enabled, so you
> might be signalling the wrong one.
>
>
> On Thu, Jan 17, 2013 at 11:51 AM, Eric Vance <epva...@gmail.com> wrote:
>
>> I'm using dnsmasq on an OpenWRT Router.
>>
>> I have the following set in /etc/dnsmasq.conf:
>>
>> local-ttl=0
>> cache-size=0
>>
>> I believe that tells the client not to cache the dns (which I've
>> confirmed) and it tells dnsmasq to not cache responses.
>>
>> Let's say I have this entry in my /etc/hosts file:
>>
>>  192.168.1.1    mydomain.com
>>
>> I have a cron job that changes this entry to this:
>>
>>  192.168.1.44    mydomain.com
>>
>> After the entry is changed in the hosts file I run this to hup:
>>
>>  kill -1 `pidof dnsmasq`;
>>
>> From my testing, after I change the ip and run the hup it takes about 30
>> - 60 seconds until the domain resolves to 192.168.1.44.  So, even after I
>> make the change the name still resolves to 192.168.1.1 for a minute.
>>
>> What am I doing wrong?  Is there a better way to do this?  Is there a
>> better way to Hup?  Am I missing an important setting?  Any help or
>> suggestions would be appreciated!
>>
>> Thanks!
>>
>> Eric
>>
>> _______________________________________________
>> Dnsmasq-discuss mailing list
>> Dnsmasq-discuss@lists.thekelleys.org.uk
>> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>>
>>
>
_______________________________________________
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss

Reply via email to