Handy DBus Tricks
I've been experimenting a bit with DBus, first with X Input Hotpluging, then with Network Manager stuff. A common message I've been getting is:
Of course, org.freedesktop.NetworkManager can be anything, it was different when I got that message for X Input Hotplug. The question I had was, how can I tell which services ARE provided. Mailing list to the rescue! This a result of calling ListNames on my machine:]
Also, if you have any raw messages you want to send or any functions you want to call, just use dbus-send. This information was gathered from another Mailing list post. Here is another example:
I don't know yet how to pass arguments. If anyone knows, feel free to leave your comments, and thanks in advance.
Error org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.NetworkManager was not provided by any .service files
Of course, org.freedesktop.NetworkManager can be anything, it was different when I got that message for X Input Hotplug. The question I had was, how can I tell which services ARE provided. Mailing list to the rescue! This a result of calling ListNames on my machine:]
# dbus-send --system --print-reply --reply-timeout=2000 --type=method_call --dest=org.freedesktop.DBus /org/freedesktop/DBus org.freedesktop.DBus.ListNames
method return sender=org.freedesktop.DBus -> dest=:1.21
array [
string "org.freedesktop.DBus"
string ":1.9"
string ":1.21"
string "org.bluez"
string "org.freedesktop.NetworkManager"
string "com.redhat.dhcp"
string ":1.0"
string ":1.1"
string ":1.2"
string "org.freedesktop.Hal"
string ":1.3"
string ":1.16"
string ":1.4"
string ":1.5"
]
Also, if you have any raw messages you want to send or any functions you want to call, just use dbus-send. This information was gathered from another Mailing list post. Here is another example:
# dbus-send --system --print-reply --reply-timeout=2000 --type=method_call --dest=org.freedesktop.NetworkManager /org/freedesktop/NetworkManager org.freedesktop.NetworkManager.getWirelessEnabled
I don't know yet how to pass arguments. If anyone knows, feel free to leave your comments, and thanks in advance.
2 Comments:
At May 26, 2008 at 5:02 AM , Unknown said...
dbus-send --system --type=method_call --print-reply --dest=org.system /org/system/device/display/ org.system.device.set_brightness double:value
At November 9, 2009 at 1:37 PM , Tommy said...
This exact error is displayed by a graphic splash when I try to run my Dell laptop recovery media creator. The application worked in Linux Ubuntu 9.04, preinstalled by Dell. Current OS: Linux Ubuntu 9.10
Post a Comment
Subscribe to Post Comments [Atom]
<< Home