1 <?xml version='
1.0'
?> <!--*- Mode: nxml; nxml-child-indent: 2; indent-tabs-mode: nil -*-->
2 <!DOCTYPE refentry PUBLIC
"-//OASIS//DTD DocBook XML V4.2//EN"
3 "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
6 SPDX-License-Identifier: LGPL-2.1+
8 This file is part of systemd.
10 Copyright 2015 Lennart Poettering
13 <refentry id=
"sd-bus-errors">
16 <title>sd-bus-errors
</title>
17 <productname>systemd
</productname>
21 <contrib>Developer
</contrib>
22 <firstname>Lennart
</firstname>
23 <surname>Poettering
</surname>
24 <email>lennart@poettering.net
</email>
30 <refentrytitle>sd-bus-errors
</refentrytitle>
31 <manvolnum>3</manvolnum>
35 <refname>sd-bus-errors
</refname>
36 <refname>SD_BUS_ERROR_FAILED
</refname>
37 <refname>SD_BUS_ERROR_NO_MEMORY
</refname>
38 <refname>SD_BUS_ERROR_SERVICE_UNKNOWN
</refname>
39 <refname>SD_BUS_ERROR_NAME_HAS_NO_OWNER
</refname>
40 <refname>SD_BUS_ERROR_NO_REPLY
</refname>
41 <refname>SD_BUS_ERROR_IO_ERROR
</refname>
42 <refname>SD_BUS_ERROR_BAD_ADDRESS
</refname>
43 <refname>SD_BUS_ERROR_NOT_SUPPORTED
</refname>
44 <refname>SD_BUS_ERROR_LIMITS_EXCEEDED
</refname>
45 <refname>SD_BUS_ERROR_ACCESS_DENIED
</refname>
46 <refname>SD_BUS_ERROR_AUTH_FAILED
</refname>
47 <refname>SD_BUS_ERROR_NO_SERVER
</refname>
48 <refname>SD_BUS_ERROR_TIMEOUT
</refname>
49 <refname>SD_BUS_ERROR_NO_NETWORK
</refname>
50 <refname>SD_BUS_ERROR_ADDRESS_IN_USE
</refname>
51 <refname>SD_BUS_ERROR_DISCONNECTED
</refname>
52 <refname>SD_BUS_ERROR_INVALID_ARGS
</refname>
53 <refname>SD_BUS_ERROR_FILE_NOT_FOUND
</refname>
54 <refname>SD_BUS_ERROR_FILE_EXISTS
</refname>
55 <refname>SD_BUS_ERROR_UNKNOWN_METHOD
</refname>
56 <refname>SD_BUS_ERROR_UNKNOWN_OBJECT
</refname>
57 <refname>SD_BUS_ERROR_UNKNOWN_INTERFACE
</refname>
58 <refname>SD_BUS_ERROR_UNKNOWN_PROPERTY
</refname>
59 <refname>SD_BUS_ERROR_PROPERTY_READ_ONLY
</refname>
60 <refname>SD_BUS_ERROR_UNIX_PROCESS_ID_UNKNOWN
</refname>
61 <refname>SD_BUS_ERROR_INVALID_SIGNATURE
</refname>
62 <refname>SD_BUS_ERROR_INCONSISTENT_MESSAGE
</refname>
63 <refname>SD_BUS_ERROR_MATCH_RULE_NOT_FOUND
</refname>
64 <refname>SD_BUS_ERROR_MATCH_RULE_INVALID
</refname>
65 <refname>SD_BUS_ERROR_INTERACTIVE_AUTHORIZATION_REQUIRED
</refname>
67 <refpurpose>Standard D-Bus error names
</refpurpose>
72 <funcsynopsisinfo>#include
<systemd/sd-bus.h
></funcsynopsisinfo>
74 <funcsynopsisinfo>#define SD_BUS_ERROR_FAILED
"org.freedesktop.DBus.Error.Failed"
75 #define SD_BUS_ERROR_NO_MEMORY
"org.freedesktop.DBus.Error.NoMemory"
76 #define SD_BUS_ERROR_SERVICE_UNKNOWN
"org.freedesktop.DBus.Error.ServiceUnknown"
77 #define SD_BUS_ERROR_NAME_HAS_NO_OWNER
"org.freedesktop.DBus.Error.NameHasNoOwner"
78 #define SD_BUS_ERROR_NO_REPLY
"org.freedesktop.DBus.Error.NoReply"
79 #define SD_BUS_ERROR_IO_ERROR
"org.freedesktop.DBus.Error.IOError"
80 #define SD_BUS_ERROR_BAD_ADDRESS
"org.freedesktop.DBus.Error.BadAddress"
81 #define SD_BUS_ERROR_NOT_SUPPORTED
"org.freedesktop.DBus.Error.NotSupported"
82 #define SD_BUS_ERROR_LIMITS_EXCEEDED
"org.freedesktop.DBus.Error.LimitsExceeded"
83 #define SD_BUS_ERROR_ACCESS_DENIED
"org.freedesktop.DBus.Error.AccessDenied"
84 #define SD_BUS_ERROR_AUTH_FAILED
"org.freedesktop.DBus.Error.AuthFailed"
85 #define SD_BUS_ERROR_NO_SERVER
"org.freedesktop.DBus.Error.NoServer"
86 #define SD_BUS_ERROR_TIMEOUT
"org.freedesktop.DBus.Error.Timeout"
87 #define SD_BUS_ERROR_NO_NETWORK
"org.freedesktop.DBus.Error.NoNetwork"
88 #define SD_BUS_ERROR_ADDRESS_IN_USE
"org.freedesktop.DBus.Error.AddressInUse"
89 #define SD_BUS_ERROR_DISCONNECTED
"org.freedesktop.DBus.Error.Disconnected"
90 #define SD_BUS_ERROR_INVALID_ARGS
"org.freedesktop.DBus.Error.InvalidArgs"
91 #define SD_BUS_ERROR_FILE_NOT_FOUND
"org.freedesktop.DBus.Error.FileNotFound"
92 #define SD_BUS_ERROR_FILE_EXISTS
"org.freedesktop.DBus.Error.FileExists"
93 #define SD_BUS_ERROR_UNKNOWN_METHOD
"org.freedesktop.DBus.Error.UnknownMethod"
94 #define SD_BUS_ERROR_UNKNOWN_OBJECT
"org.freedesktop.DBus.Error.UnknownObject"
95 #define SD_BUS_ERROR_UNKNOWN_INTERFACE
"org.freedesktop.DBus.Error.UnknownInterface"
96 #define SD_BUS_ERROR_UNKNOWN_PROPERTY
"org.freedesktop.DBus.Error.UnknownProperty"
97 #define SD_BUS_ERROR_PROPERTY_READ_ONLY
"org.freedesktop.DBus.Error.PropertyReadOnly"
98 #define SD_BUS_ERROR_UNIX_PROCESS_ID_UNKNOWN
"org.freedesktop.DBus.Error.UnixProcessIdUnknown"
99 #define SD_BUS_ERROR_INVALID_SIGNATURE
"org.freedesktop.DBus.Error.InvalidSignature"
100 #define SD_BUS_ERROR_INCONSISTENT_MESSAGE
"org.freedesktop.DBus.Error.InconsistentMessage"
101 #define SD_BUS_ERROR_MATCH_RULE_NOT_FOUND
"org.freedesktop.DBus.Error.MatchRuleNotFound"
102 #define SD_BUS_ERROR_MATCH_RULE_INVALID
"org.freedesktop.DBus.Error.MatchRuleInvalid"
103 #define SD_BUS_ERROR_INTERACTIVE_AUTHORIZATION_REQUIRED \
104 "org.freedesktop.DBus.Error.InteractiveAuthorizationRequired"</funcsynopsisinfo>
110 <title>Description
</title>
112 <para>In addition to the error names user programs define, D-Bus
113 knows a number of generic, standardized error names that are
116 <para>In addition to this list, in sd-bus, the special error
117 namespace
<literal>System.Error.
</literal> is used to map
118 arbitrary Linux system errors (as defined by
<citerefentry
119 project='man-pages'
><refentrytitle>errno
</refentrytitle><manvolnum>3</manvolnum></citerefentry>)
120 to D-Bus errors and back. For example, the error
121 <constant>EUCLEAN
</constant> is mapped to
122 <literal>System.Error.EUCLEAN
</literal> and back.
</para>
127 <term><varname>SD_BUS_ERROR_FAILED
</varname></term>
128 <listitem><para>A generic error indication. See the error
129 message for further details. This error name should be
130 avoided, in favor of a more expressive error
131 name.
</para></listitem>
135 <term><varname>SD_BUS_ERROR_NO_MEMORY
</varname></term>
136 <listitem><para>A memory allocation failed, and the requested
137 operation could not be completed.
</para></listitem>
141 <term><varname>SD_BUS_ERROR_SERVICE_UNKNOWN
</varname></term>
142 <listitem><para>The contacted bus service is unknown and
143 cannot be activated.
</para></listitem>
147 <term><varname>SD_BUS_ERROR_NAME_HAS_NO_OWNER
</varname></term>
148 <listitem><para>The specified bus service name currently has
149 no owner.
</para></listitem>
152 <term><varname>SD_BUS_ERROR_NO_REPLY
</varname></term>
153 <listitem><para>A message did not receive a reply. This error
154 is usually generated after a timeout.
</para></listitem>
157 <term><varname>SD_BUS_ERROR_IO_ERROR
</varname></term>
158 <listitem><para>Generic input/output error, for example when
159 accessing a socket or other I/O context.
</para></listitem>
162 <term><varname>SD_BUS_ERROR_BAD_ADDRESS
</varname></term>
163 <listitem><para>The specified D-Bus bus address string is
164 malformed.
</para></listitem>
167 <term><varname>SD_BUS_ERROR_NOT_SUPPORTED
</varname></term>
168 <listitem><para>The requested operation is not supported on
169 the local system.
</para></listitem>
172 <term><varname>SD_BUS_ERROR_LIMITS_EXCEEDED
</varname></term>
173 <listitem><para>Some limited resource has been
174 exhausted.
</para></listitem>
177 <term><varname>SD_BUS_ERROR_ACCESS_DENIED
</varname></term>
178 <listitem><para>Access to a resource has been denied due to security restrictions.
</para></listitem>
181 <term><varname>SD_BUS_ERROR_AUTH_FAILED
</varname></term>
182 <listitem><para>Authentication did not complete successfully.
</para></listitem>
185 <term><varname>SD_BUS_ERROR_NO_SERVER
</varname></term>
186 <listitem><para>Unable to connect to the specified server.
</para></listitem>
189 <term><varname>SD_BUS_ERROR_TIMEOUT
</varname></term>
190 <listitem><para>An operation timed out. Note that method calls
191 which timeout generate a
192 <varname>SD_BUS_ERROR_NO_REPLY
</varname>.
</para></listitem>
195 <term><varname>SD_BUS_ERROR_NO_NETWORK
</varname></term>
196 <listitem><para>No network available to execute requested network operation on.
</para></listitem>
199 <term><varname>SD_BUS_ERROR_ADDRESS_IN_USE
</varname></term>
200 <listitem><para>The specified network address is already being listened on.
</para></listitem>
203 <term><varname>SD_BUS_ERROR_DISCONNECTED
</varname></term>
204 <listitem><para>The connection has been terminated.
</para></listitem>
207 <term><varname>SD_BUS_ERROR_INVALID_ARGS
</varname></term>
208 <listitem><para>One or more invalid arguments have been passed.
</para></listitem>
211 <term><varname>SD_BUS_ERROR_FILE_NOT_FOUND
</varname></term>
212 <listitem><para>The requested file could not be found.
</para></listitem>
215 <term><varname>SD_BUS_ERROR_FILE_EXISTS
</varname></term>
216 <listitem><para>The requested file already exists.
</para></listitem>
219 <term><varname>SD_BUS_ERROR_UNKNOWN_METHOD
</varname></term>
220 <listitem><para>The requested method does not exist in the selected interface.
</para></listitem>
223 <term><varname>SD_BUS_ERROR_UNKNOWN_OBJECT
</varname></term>
224 <listitem><para>The requested object does not exist in the selected service.
</para></listitem>
227 <term><varname>SD_BUS_ERROR_UNKNOWN_INTERFACE
</varname></term>
228 <listitem><para>The requested interface does not exist on the selected object.
</para></listitem>
231 <term><varname>SD_BUS_ERROR_UNKNOWN_PROPERTY
</varname></term>
232 <listitem><para>The requested property does not exist in the selected interface.
</para></listitem>
235 <term><varname>SD_BUS_ERROR_PROPERTY_READ_ONLY
</varname></term>
236 <listitem><para>A write operation was requested on a read-only property.
</para></listitem>
239 <term><varname>SD_BUS_ERROR_UNIX_PROCESS_ID_UNKNOWN
</varname></term>
240 <listitem><para>The requested PID is not known.
</para></listitem>
243 <term><varname>SD_BUS_ERROR_INVALID_SIGNATURE
</varname></term>
244 <listitem><para>The specified message signature is not
249 <term><varname>SD_BUS_ERROR_INCONSISTENT_MESSAGE
</varname></term>
250 <listitem><para>The passed message does not validate
251 correctly.
</para></listitem>
254 <term><varname>SD_BUS_ERROR_MATCH_RULE_NOT_FOUND
</varname></term>
255 <listitem><para>The specified match rule does not exist.
</para></listitem>
258 <term><varname>SD_BUS_ERROR_MATCH_RULE_INVALID
</varname></term>
259 <listitem><para>The specified match rule is invalid.
</para></listitem>
262 <term><varname>SD_BUS_ERROR_INTERACTIVE_AUTHORIZATION_REQUIRED
</varname></term>
263 <listitem><para>Access to the requested operation is not
264 permitted. However, it might be available after interactive
265 authentication. This is usually returned by method calls
266 supporting a framework for additional interactive
267 authorization, when interactive authorization was not enabled
269 <citerefentry><refentrytitle>sd_bus_message_set_allow_interactive_authorization
</refentrytitle><manvolnum>3</manvolnum></citerefentry>
270 for the method call message.
</para></listitem>
278 <para>The various error definitions described here are available
279 as a shared library, which can be compiled and linked to with the
280 <constant>libsystemd
</constant> <citerefentry
281 project='die-net'
><refentrytitle>pkg-config
</refentrytitle><manvolnum>1</manvolnum></citerefentry>
286 <title>See Also
</title>
289 <citerefentry><refentrytitle>systemd
</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
290 <citerefentry><refentrytitle>sd-bus
</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
291 <citerefentry><refentrytitle>sd_bus_error
</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
292 <citerefentry><refentrytitle>sd_bus_message_set_allow_interactive_authorization
</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
293 <citerefentry project='man-pages'
><refentrytitle>errno
</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
294 <citerefentry project='die-net'
><refentrytitle>strerror
</refentrytitle><manvolnum>3</manvolnum></citerefentry>