Re: Setting static ip base on NetworkManager



On 08/03/2010 07:58 AM, Edward_Doong wistron com wrote:
> Dear,
> could someone teach me how i can set static ip base on NM.
> (gateway , DNS etc......)
> 
> Now, if i don't use nm-applet to control NM.
> what can i do?
> i study NM DBus doc. But it doesn't define any Wifi or Wire staic ip.

Right, the DBus API spec describes (among other things) how to
add/replace/delete connections, but it doesn't discuss the contents of
the connection settings themselves. For that, you'd want to look at:
http://projects.gnome.org/NetworkManager/developers/settings-spec-08.html

I'd also recommend looking at the example code in the examples/python
directory in the sources of the N-M daemon. Here it is on git:
http://cgit.freedesktop.org/NetworkManager/NetworkManager/tree/examples/python

add-system-connecton.py does pretty much exactly what you want to do. :)

Other good resources:
- http://live.gnome.org/NetworkManager
- http://live.gnome.org/NetworkManagerConfiguration
- http://live.gnome.org/NetworkManager/SystemSettings
- The D-feet DBus debugger - https://fedorahosted.org/d-feet/
  I found it massively helpful when learning about NetworkManager and
  DBus in general.

Hope that helps!

Have a good one,
Daniel


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]