----- Original Message ----- From: "Dan Williams" <d...@redhat.com>
To: "Peter Foulkes" <peter.foul...@nilpanic.co.uk>
Cc: <networkmanager-list@gnome.org>
Sent: Tuesday, March 30, 2010 9:05 PM
Subject: Re: DHCP Range in Network Manager


On Tue, 2010-03-23 at 21:41 +0000, Peter Foulkes wrote:
On Tue, 2009-09-22 at 15:41 -0500, Andy Ringsmuth wrote:

> My question is this - the default range IP range dished out by
> NetworkManager is 10.42.43.10 to 10.42.43.254.
>
> I would like to change that to 192.168.1.10 to 192.168.1.99 but for
> the life of me I cannot figure out what to change to make that happen.

And Dan Williams replied:
>Nope, it's currently hardcoded for user-created "shared" networks.
>Didn't really see a great need to change it at the time I did connection
>sharing last year.  Mind sharing your use-case here?  I'm curious.

If I wanted to change the hardcoded IP would it just be a case of changing the single reference to 10.42.43.1 that I can find in src/nm_device.c to the
range to suit my requirements?

...
 guint32 start = (guint32) ntohl (0x0a2a2b01); /* 10.42.43.1 */
 guint32 count = 0;
...

Yup, that would be the place.  To fix this for real, we allow users
modify shared connections in the connection editor, then maybe add some
keys to NMSettingIP4Config for "shared subnet" and "shared netmask".

Dan


Thank you Dan for confirming that. I've made the change and it works perfectly for my configuration now.

If someone did decide to allow users to modify shared connections in the connection editor can I suggest it's done as an almost hidden feature. The simplicity of the shared connection option at present is beautiful. I think it's safe to say that 99% of users do not need to even know nevermind change the IP settings being used to create the shared connection.

Peter



_______________________________________________
NetworkManager-list mailing list
NetworkManager-list@gnome.org
http://mail.gnome.org/mailman/listinfo/networkmanager-list

Reply via email to