mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-30 02:40:11 +01:00
dnsmasq: fix separation from system-wide dnsmasq
This disables loading the system-wide dnsmasq from /etc/dnsmasq.conf and defines to use the NMSTATEDIR device-unique dhcp-leasefile, preventing it from trampling over others, and isolating it to just the wifi-ap use. https://github.com/NetworkManager/NetworkManager/pull/156
This commit is contained in:
parent
7f2b7ee4cd
commit
b4116a6fe6
1 changed files with 6 additions and 1 deletions
|
|
@ -187,7 +187,7 @@ create_dm_cmd_line (const char *iface,
|
|||
* as the gateway or whatever. So tell dnsmasq not to use any config file
|
||||
* at all.
|
||||
*/
|
||||
nm_cmd_line_add_string (cmd, "--conf-file");
|
||||
nm_cmd_line_add_string (cmd, "--conf-file=/dev/null");
|
||||
|
||||
nm_cmd_line_add_string (cmd, "--no-hosts");
|
||||
nm_cmd_line_add_string (cmd, "--keep-in-foreground");
|
||||
|
|
@ -249,6 +249,11 @@ create_dm_cmd_line (const char *iface,
|
|||
|
||||
nm_cmd_line_add_string (cmd, "--dhcp-lease-max=50");
|
||||
|
||||
g_string_append (s, "--dhcp-leasefile=" NMSTATEDIR);
|
||||
g_string_append_printf (s, "/dnsmasq-%s.leases", iface);
|
||||
nm_cmd_line_add_string (cmd, s->str);
|
||||
g_string_truncate (s, 0);
|
||||
|
||||
g_string_append (s, "--pid-file=");
|
||||
g_string_append (s, pidfile);
|
||||
nm_cmd_line_add_string (cmd, s->str);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue