Questions tagged [dbus]

D-Bus is a message bus system, which allows client programs to call procedures on a service - basically, the machine-local equivalent to XML-RPC and SOAP.

D-Bus is a message bus system, designed to provide ways for programs to communicate with each other. D-Bus uses remote procedures to allow a client to call methods on a "service", and is conceptually similar to XML-RPC and SOAP. D-Bus, however, is designed for use in applications running on a single system. The FAQ offers a comparison to other well known IPC systems, as well as other general questions.

D-Bus is, in addition to an implementation, a specification - the document itself is freely available. In addition, an Introduction To D-Bus gives a high-level overview of how D-Bus is designed.

D-Bus, although used on POSIX systems (usually Linux and the *BSDs), has been ported to Windows and has been officially added to the specification.

D-Bus related questions will typically be how do I accomplish [X] in D-Bus - D-Bus is technical enough that most any question relating to it will be on topic.

1376 questions
8
votes
1 answer

Connecting to systemd DBUS signals using gdbus-codegen

I am not able to receive systemd DBus signals when using gdbus-codegen generated manager proxy. But I am able to successfully call methods provided by systemd over DBus. I searched online and looked these links without much success. There aren't…
VJ-
  • 211
  • 2
  • 7
8
votes
4 answers

Using dbus-send to call GetAll

I tried my luck with: dbus-send --system --print-reply \ --dest=org.freedesktop.UDisks \ /org/freedesktop/UIDisks/devices/md0 \ org.freedesktop.DBus.Properties.GetAll \ string:"" If I'm using d-free and send "" as…
Friedrich
  • 5,916
  • 25
  • 45
8
votes
3 answers

Updated Bluez DBUS-API document?

I just tried to run a vala bluez example (found in the DbusClientSamples page) and I got this error: GDBus.Error:org.freedesktop.DBus.Error.UnknownObject: Method "DiscoverDevices" with signature "" on interface "org.bluez.Adapter" doesn't exist Is…
knocte
  • 16,941
  • 11
  • 79
  • 125
8
votes
3 answers

How to find methods exposed in a D-Bus interface

Question: Is there any way in which we can find out the methods (and their signatures) which are exposed in a D-Bus interface? Issue Description: In my phone, I am calling BlueZ methods using D-Bus to adapter interface, when checked on phone 2 of…
ashish
  • 1,384
  • 1
  • 12
  • 21
8
votes
1 answer

Can't get any replies to dbus-send

I am trying to create some scripts to discover and pair bluetooth devices on a embedded arch linux platform and seem unable to get any replies to dbus-send commands. The error message is pretty much always the same (method does not exist), however…
crankshaft
  • 2,607
  • 4
  • 45
  • 77
7
votes
1 answer

d-bus administration

I have created simple application using d-bus, it works on kubuntu but doesn't work on my embedded linux. When I run a qt application it says: Not connected to D-Bus server When I try to run dbus-monitor I got this error: Failed to open connection…
Daniil
  • 143
  • 3
  • 9
7
votes
1 answer

Compiling C program with dbus header files

I'm trying to compile a C program, with these headers: http://pastebin.com/SppCXb0U , on Ubuntu. At first I didn't have any luck at all, but after reading about pkg-config I crafted this line: gcc `pkg-config --cflags --libs dbus-1` `pkg-config…
Martin Hansen
  • 571
  • 4
  • 8
  • 14
7
votes
2 answers

Unable to autolaunch a dbus-daemon without a $DISPLAY for X11. NetBeans. Pi as remote host

I am trying to run the following example code using my NetBeans IDE: #include #include #include #include int main() { DBusConnection *connection = NULL; DBusError error; char buffer[1024]; …
Dan_R
  • 191
  • 1
  • 3
  • 14
7
votes
0 answers

Can an attacker exploit my /etc/machine-id?

I am writing software that needs to uniquely identify multiple different machines. I was planning on using /etc/machine-id to do this. While reading the docs for machine-id, I stumbled upon this passage: This ID uniquely identifies the host. It…
Cameron Sun
  • 423
  • 1
  • 4
  • 9
7
votes
1 answer

Detailed documentation for systemd's sd-bus

I have some project which uses libdbus for IPC. The goal is to use systemd's sd-bus instead of libdbus. There is documentation for sd-bus (here, here and etc), but that documentation doesn't cover all aspects of D-Bus specification implementation. I…
Yeheshuah
  • 1,216
  • 1
  • 13
  • 28
7
votes
1 answer

Is there any RPC framework with signal functionality as in DBus?

We are currently looking for RPC frameworks and were unable to find any with signal functionality unfortunately however we need it. We looked at gRPC, Apache Thrift, Cap-n-Proto and found that no one of them provide such functionality out of the box…
VP.
  • 15,509
  • 17
  • 91
  • 161
7
votes
1 answer

Register a "Hello World" DBus service, object and method using Python

I'm trying to export a DBus service named com.example.HelloWorld, with an object /com/example/HelloWorld, and method com.example.HelloWorld.SayHello that prints "hello, world" if the method is called using dbus-send --system --type=method_call…
sashoalm
  • 75,001
  • 122
  • 434
  • 781
7
votes
3 answers

sd-bus API, sd_bus_request_name returns Permission denied

bus APIs in systemd 221. When I request a name for an object in system bus it prints out an error saying "Permission denied". I am running the output file as root. The line "sd_bus_request_name(bus, "net.poettering.Calculator", 0)" throws an error…
portleJay
  • 71
  • 1
  • 2
7
votes
1 answer

Bluez auto reconnect devices

I am writing a library in C/C++ for a Bluetooth low energy device. So far I have been using the D-Bus interface exposed by Bluez and been able to discover, connect and communicate with the device. However, when the device disconnects either due to a…
prinsen
  • 748
  • 6
  • 16
7
votes
1 answer

Unable to autolaunch a dbus-daemon without a $DISPLAY for X11

I have a QT/C++ terminal application which binds to D-Bus, but when I attempt to bind on the session bus I'm getting the following error: "Unable to autolaunch a dbus-daemon without a $DISPLAY for X11" This is just a simple terminal application,…
RandomUser
  • 4,140
  • 17
  • 58
  • 94