diff --git a/apphandler.cpp b/apphandler.cpp
index dd1d5aa..abf0bd3 100644
--- a/apphandler.cpp
+++ b/apphandler.cpp
@@ -195,7 +195,8 @@
     // Firmware revision is already implemented, so get it from appropriate position.
     r = mapper_get_service(bus, objname, &busname);
     if (r < 0) {
-        fprintf(stderr, "Failed to get bus name, return value: %s.\n", strerror(-r));
+        fprintf(stderr, "Failed to get %s bus name: %s\n",
+                objname, strerror(-r));
         goto finish;
     }
     r = sd_bus_get_property_string(bus,busname,objname,iface,"version", NULL, &ver);
@@ -284,7 +285,8 @@
     // Call Get properties method with the interface and property name
     r = mapper_get_service(bus, objname, &busname);
     if (r < 0) {
-        fprintf(stderr, "Failed to get bus name, return value: %s.\n", strerror(-r));
+        fprintf(stderr, "Failed to get %s bus name: %s\n",
+                objname, strerror(-r));
         goto finish;
     }
     r = sd_bus_call_method(bus,busname,objname,iface,
@@ -407,7 +409,8 @@
     // Get bus name
     r = mapper_get_service(bus, objname, &busname);
     if (r < 0) {
-        fprintf(stderr, "Failed to get bus name, return value: %s.\n", strerror(-r));
+        fprintf(stderr, "Failed to get %s bus name: %s\n",
+                objname, strerror(-r));
         goto finish;
     }
     // Set watchdog timer
@@ -473,7 +476,8 @@
     // Get bus name
     r = mapper_get_service(bus, objname, &busname);
     if (r < 0) {
-        fprintf(stderr, "Failed to get bus name, return value: %s.\n", strerror(-r));
+        fprintf(stderr, "Failed to get %s bus name: %s\n",
+                objname, strerror(-r));
         goto finish;
     }
     // Refresh watchdog
diff --git a/chassishandler.cpp b/chassishandler.cpp
index 0b503c7..a20d062 100644
--- a/chassishandler.cpp
+++ b/chassishandler.cpp
@@ -79,7 +79,8 @@
 
     r = mapper_get_service(bus, settings_object_name, &connection);
     if (r < 0) {
-        fprintf(stderr, "Failed to get connection, return value: %s.\n", strerror(-r));
+        fprintf(stderr, "Failed to get %s connection: %s\n",
+                settings_object_name, strerror(-r));
         goto finish;
     }
 
@@ -144,7 +145,8 @@
 
     r = mapper_get_service(bus, settings_object_name, &connection);
     if (r < 0) {
-        fprintf(stderr, "Failed to get connection, return value: %s.\n", strerror(-r));
+        fprintf(stderr, "Failed to get %s connection: %s\n",
+                settings_object_name, strerror(-r));
         goto finish;
     }
 
@@ -572,7 +574,8 @@
 	sd_bus *bus_type = ipmid_get_sd_bus_connection();
 	rc = mapper_get_service(bus_type, chassis_object_name, &busname);
 	if (rc < 0) {
-		fprintf(stderr, "Failed to get bus name, return value: %s.\n", strerror(-rc));
+		fprintf(stderr, "Failed to get %s bus name: %s\n",
+				chassis_object_name, strerror(-rc));
 	goto finish;
 	}
 	rc = sd_bus_call_method(bus_type,        		 // On the System Bus
diff --git a/host-services.c b/host-services.c
index 4c8fc7c..b0b12ae 100644
--- a/host-services.c
+++ b/host-services.c
@@ -45,7 +45,8 @@
     sd_bus *bus = ipmid_get_sd_bus_connection();
     rc = mapper_get_service(bus, object_name, &bus_name);
     if (rc < 0) {
-        fprintf(stderr, "Failed to get bus name, return value: %s.\n", strerror(-rc));
+        fprintf(stderr, "Failed to get %s bus name: %s\n",
+                object_name, strerror(-rc));
         goto finish;
     }
     rc = sd_bus_call_method(bus,             // In the System Bus
diff --git a/ipmid.cpp b/ipmid.cpp
index 9e267bc..84d37ea 100644
--- a/ipmid.cpp
+++ b/ipmid.cpp
@@ -274,7 +274,8 @@
 
     rc = mapper_get_service(bus, settings_host_object, &busname);
     if (rc < 0) {
-        fprintf(stderr, "Failed to get HOST busname: %s\n", strerror(-rc));
+        fprintf(stderr, "Failed to get %s busname: %s\n",
+                settings_host_object, strerror(-rc));
         goto cleanup;
     }
     rc = sd_bus_call_method(bus,
diff --git a/sensorhandler.cpp b/sensorhandler.cpp
index 6503db8..b3381f3 100644
--- a/sensorhandler.cpp
+++ b/sensorhandler.cpp
@@ -117,7 +117,8 @@
     int r;
     r = mapper_get_service(bus, objname, &busname);
     if (r < 0) {
-        fprintf(stderr, "Failed to get system manager busname: %s\n", strerror(-r));
+        fprintf(stderr, "Failed to get %s busname: %s\n",
+                objname, strerror(-r));
         goto final;
     }
 
@@ -136,7 +137,8 @@
 
     r = mapper_get_service(bus, str2, &str1);
     if (r < 0) {
-        fprintf(stderr, "Failed to get item busname: %s\n", strerror(-r));
+        fprintf(stderr, "Failed to get %s busname: %s\n",
+                str2, strerror(-r));
         goto final;
     }
 
diff --git a/storageaddsel.cpp b/storageaddsel.cpp
index 47328b0..87018e7 100644
--- a/storageaddsel.cpp
+++ b/storageaddsel.cpp
@@ -183,7 +183,8 @@
     mbus = ipmid_get_sd_bus_connection();
     r = mapper_get_service(mbus, object_name, &bus_name);
     if (r < 0) {
-        fprintf(stderr, "Failed to get connection, return value: %s.\n", strerror(-r));
+        fprintf(stderr, "Failed to get %s connection: %s\n",
+                object_name, strerror(-r));
         goto finish;
     }
     r = sd_bus_message_new_method_call(mbus,&m,
diff --git a/testaddsel.cpp b/testaddsel.cpp
index 9fd9d35..4023629 100644
--- a/testaddsel.cpp
+++ b/testaddsel.cpp
@@ -27,7 +27,8 @@
 
     r = mapper_get_service(bus, objname, &busname);
     if (r < 0) {
-        fprintf(stderr, "Failed to get busname: %s\n", strerror(-r));
+        fprintf(stderr, "Failed to get %s busname: %s\n",
+                objname, strerror(-r));
         goto final;
     }
 
@@ -110,4 +111,4 @@
     sd_bus_unref(bus);
 
 	return 0;
-}
\ No newline at end of file
+}
diff --git a/transporthandler.cpp b/transporthandler.cpp
index 01a79cb..32ed993 100644
--- a/transporthandler.cpp
+++ b/transporthandler.cpp
@@ -57,7 +57,8 @@
 
     r = mapper_get_service(bus, obj, &app);
     if (r < 0) {
-        fprintf(stderr, "Failed to get bus name, return value: %s.\n", strerror(-r));
+        fprintf(stderr, "Failed to get %s bus name: %s\n",
+                obj, strerror(-r));
         goto cleanup;
     }
     r = sd_bus_call_method(bus, app, obj, ifc, "GetAddress4", &error,
@@ -185,7 +186,8 @@
 
         r = mapper_get_service(bus, obj, &app);
         if (r < 0) {
-            fprintf(stderr, "Failed to get bus name, return value: %s.\n", strerror(-r));
+            fprintf(stderr, "Failed to get %s bus name: %s\n",
+                    obj, strerror(-r));
             goto finish;
         }
         r = sd_bus_call_method(bus, app, obj, ifc, "SetHwAddress", &error,
@@ -339,7 +341,8 @@
 
         r = mapper_get_service(bus, obj, &app);
         if (r < 0) {
-            fprintf(stderr, "Failed to get bus name, return value: %s.\n", strerror(-r));
+            fprintf(stderr, "Failed to get %s bus name: %s\n",
+                    obj, strerror(-r));
             goto cleanup;
         }
         r = sd_bus_call_method(bus, app, obj, ifc, "GetHwAddress", &error,
