From mboxrd@z Thu Jan 1 00:00:00 1970 From: william Date: Wed, 27 Jul 2011 04:48:40 +0000 Subject: Re: udev rule matching using ENV Message-Id: <4E2F98A8.2040909@cobradevil.org> List-Id: References: <4E2F1236.8050500@cobradevil.org> In-Reply-To: <4E2F1236.8050500@cobradevil.org> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-hotplug@vger.kernel.org On 07/26/2011 10:35 PM, Kay Sievers wrote: > On Tue, Jul 26, 2011 at 21:18, william wrote: >> i am trying to create a udev rule which executes a script whenever a usb >> stick is removed with a particular uuid >> >> So i created 99-remove-usb.rules with the following contents >> >> IMPORT{program}="/usr/local/bin/usb-stick-uuid.sh" >> ACTION="remove", ENV{ID_FS_UUID}="ENV{MY_UUID}", >> But it does never match. > ENV{ID_FS_UUID}="$env{MY_UUID}" ? > no match with the $env{MY_UUID} When i remove this match so it will execute the script i do get the MY_UUID in the environment so i know it gets filled. Also visible when using: udevadm test --action=remove /block/sdb William > Kay > -- > To unsubscribe from this list: send the line "unsubscribe linux-hotplug" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html