$linuxjunkies
>

busctl(1)

Introspect and interact with D-Bus message bus system and services.

UbuntuDebianFedoraArch

Synopsis

busctl [OPTIONS...] COMMAND [NAME...]

Description

busctl is a utility for introspecting and interacting with D-Bus, the system and session message buses used by systemd and many Linux services. It allows you to list services, objects, interfaces, and methods; call methods; get/set properties; and monitor bus activity.

D-Bus is an inter-process communication (IPC) system that enables applications to communicate with each other and the system. busctl provides command-line access to this functionality without needing to write code.

Common options

FlagWhat it does
-s, --systemConnect to the system message bus (default)
-u, --userConnect to the user (session) message bus
-H, --host=HOSTConnect to bus on remote host via SSH
--no-pagerDo not pipe output into a pager
-j, --json=SHORT|PRETTY|OFFOutput results as JSON instead of formatted text
--verboseShow detailed output with additional information
-q, --quietSuppress output
--address=ADDRESSConnect to D-Bus at the given address instead of system/user bus

Examples

List all services currently available on the system message bus

busctl list

Show all interfaces, methods, properties, and signals for systemd's main object

busctl introspect org.freedesktop.systemd1 /org/freedesktop/systemd1

Display the entire object tree for the systemd service

busctl tree org.freedesktop.systemd1

Call the GetUnit method to retrieve the path for a service object

busctl call org.freedesktop.systemd1 /org/freedesktop/systemd1 org.freedesktop.systemd1.Manager GetUnit s test.service

Get the Version property from systemd's manager interface

busctl get-property org.freedesktop.systemd1 /org/freedesktop/systemd1 org.freedesktop.systemd1.Manager Version

Set a boolean property on a D-Bus object

busctl set-property org.freedesktop.DBus /org/freedesktop/DBus org.freedesktop.DBus.Properties TimedOut b true

Monitor all messages to and from the specified service in real-time

busctl monitor org.freedesktop.systemd1

Introspect the notification service on the user (session) message bus

busctl -u introspect org.freedesktop.Notifications /org/freedesktop/Notifications

Related commands