Why does notify-send fail as root in RHEL 7 ?

Solution Verified - Updated -

Issue

  • Based on testing on Fedora 18, notify-send fails as root making it impossible to send notification to the user. This works on RHEL 6 so either notify-send should be fixed or similar functionality should be provided by some other means.
  • Fedora 18 BZ is https://bugzilla.redhat.com/show_bug.cgi?id=869268
  • All of the following work on RHEL 6 under GNOME when logged in as "testuser" (meaning that DISPLAY is properly set for each command):
$ notify-send test
$ su -
Password: 
# notify-send test
# su testuser -c "notify-send test"
  • Only the following work on F17:
$ notify-send test
$ su -
Password: 
# su testuser -c "notify-send test"
  • But under F18 sending notifications to the desktop user as root with notify-send does not work with either of the commands working on RHEL 6.

Environment

  • Red Hat Enterprise Linux 7

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.