Linux Hotplug development
 help / color / mirror / Atom feed
From: Kay Sievers <kay.sievers@vrfy.org>
To: linux-hotplug@vger.kernel.org
Subject: Re: Starting with udev
Date: Thu, 11 Mar 2010 09:33:49 +0000	[thread overview]
Message-ID: <ac3eb2511003110133y3ae10887q7ce488a783ac6318@mail.gmail.com> (raw)
In-Reply-To: <20100311095534.637ab0a7@tosh-l20.laptop>

On Thu, Mar 11, 2010 at 09:55, Salvatore De Paolis <iwkse@claws-mail.org> wrote:
> i'm really new with udev and i was following the writing udev rules to
> understand how it works.
>
> What i wanted to do, is to mount and execute a script once a usb device is
> plugged.
> To test this, i found the line:
>
> KERNEL="sd*", ACTION="add", RUN+="/usr/bin/notify-send test test"
>
> I wrote this in a file called 90-test.rules under /etc/udev/rules.d and
> restarted udev plugged the usb device and nothing happened.

Udev runs at the system-level as root, it can not talk to your user
session where the notification would appear. You have to subscribe to
events from your user session, and not put system-wide rules into
udev, to get events in your session.

Kay

  reply	other threads:[~2010-03-11  9:33 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-11  8:55 Starting with udev Salvatore De Paolis
2010-03-11  9:33 ` Kay Sievers [this message]
2010-03-12 15:39 ` Salvatore De Paolis
2010-03-12 15:53 ` Kay Sievers
2010-03-12 16:57 ` Salvatore De Paolis

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ac3eb2511003110133y3ae10887q7ce488a783ac6318@mail.gmail.com \
    --to=kay.sievers@vrfy.org \
    --cc=linux-hotplug@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox