Posts

Showing posts with the label xubuntu

Using DBus on Xubuntu 8 04

Using DBus on Xubuntu 8 04 This post is obsolete has been superseded by my 2012 dbus tutorial series. DBus is a system that permits different applications to exchange information. Tutorial Reference Other Reference. Sometimes, DBus crashes upon restart from a suspend or hibernation. These bash commands will help you figure out if it has crashed, and how to restart it. $ps -e | grep `cat /var/run/dbus/pid` # Confirm if DBus is running by checking for the PID number in the list of live processes. # If DBus is running, this will return the process number. # If not, it will return nothing. $sudo rm /var/run/dbus/pid # Remove the stale pid file so DBus can be restarted. $sudo dbus-daemon # Start DBus again. A python script uses DBus to see if the network connection is available by asking Network Manager: #! /usr/bin/env python import dbus bus = dbus.SystemBus() item = org.freedesktop.NetworkManager eth0_path = /org/freedesktop/NetworkManager/Devices/eth0 eth1_path = /org/freedesktop/Net...