[Pkg-utopia-maintainers] Bug#615082: Bug#615082: Bug#615082: Acknowledgement (network-manager: dnsmasq exited with error: Configuration problem)
simon at thekelleys.org.uk
Sat Feb 26 08:42:36 UTC 2011
On 26/02/11 00:06, Dan Williams wrote:
> On Fri, 2011-02-25 at 20:25 +0000, Simon Kelley wrote:
>> On 25/02/11 20:03, Michael Biebl wrote:
>>> Am 25.02.2011 20:45, schrieb Simon Kelley:
>>>> On 25/02/11 19:29, Michael Biebl wrote:
>>>>> Am 25.02.2011 18:58, schrieb Simon Kelley:
>>>>> Is there maybe a nicer way to tell dnsmasq to *not* read the global
>>>>> configuration file?
>>>> Ah, I hadn't read up in the source code to that part.
>>>> It's completely unnecessary:
>>>> dnsmasq --conf-file
>>>> suppresses reading the default configuration file. Just stop adding the
>>>> junk filename (which never did anything, anyway) and dnsmasq will no
>>>> longer complain.
>>> Perfect, thanks for your input. Seems like the way to go then.
>>> Just to be sure: Can I rely on dnsmasq --conf-file to work on versions< 2.57?
>> You can.
>>> Is there a minimum version when this behaviour was introduced?
>> There must be and I'm not sure exactly which it is, but I just checked
>> 2.39 which is four years old, and this behaviour was in then.
>>> I can only assume Dan added this hack (back then) for a reason.
>> My guess is that it arises from unclear documentation rather than lack
>> of functionality.
> I just added it because I ran into a problem at one point (and somebody
> else did too) where a package installed global dnsmasq config file had
> some conflicting options with what NM spawns dnsmasq with. Since NM
> sends all the arguments on the command-line, because they change
> depending on your IP connection and because we can't guarantee what's in
> the global config file, I did this hack. I was not aware of leaving off
> the config file name.
> We can and should fix it though. Just one question: does the
> "--conf-file" have to be at the end of the arg list, or is dnsmasq smart
> enough to know that something that comes after it that starts with "--"
> is an argument? I'd expect this to be the case, but just checking.
--conf-file doesn't have to be at the end of the list. This is all
controlled by getopt_long(), which supports conventional short options
or long options
as far as getopt-long is concerned, in
the filename has nothing to do with --conf-file, its just another bit of
the argument list, not associated with a switch: the argument to
--conf-file is empty.
What has changed in 2.57 is that it complains about arguments not
associated with a switch, since they have no function in dnsmasq and
their presence indicates likely confusion of this type.
More information about the Pkg-utopia-maintainers