* Alter a sysfs attribute??
@ 2008-09-14 17:48 Jay Otis
2008-09-15 9:08 ` Alan Jenkins
0 siblings, 1 reply; 2+ messages in thread
From: Jay Otis @ 2008-09-14 17:48 UTC (permalink / raw)
To: linux-hotplug
Hello all, I am using Ubuntu Hardy and I need to change the
"max_sectors" attribute of my usb device on boot but RUN+="/bin/echo
1024 > /sys/block/%k/device/max_sectors" does not seem to change the
value. I've tried su -... and su username -c... the command runs from
a root terminal and from a startup script in init.d just not from udev
:s
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Alter a sysfs attribute??
2008-09-14 17:48 Alter a sysfs attribute?? Jay Otis
@ 2008-09-15 9:08 ` Alan Jenkins
0 siblings, 0 replies; 2+ messages in thread
From: Alan Jenkins @ 2008-09-15 9:08 UTC (permalink / raw)
To: linux-hotplug
Jay Otis wrote:
> Hello all, I am using Ubuntu Hardy and I need to change the
> "max_sectors" attribute of my usb device on boot but RUN+="/bin/echo
> 1024 > /sys/block/%k/device/max_sectors" does not seem to change the
> value. I've tried su -... and su username -c... the command runs from
> a root terminal and from a startup script in init.d just not from udev
> :s
Redirection is a shell function. udev does not automatically run
commands through a shell.
Try
RUN+="/bin/sh -c echo 1024 > /sys/block/%k/device/max_sectors"
Regards
Alan
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-09-15 9:08 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-09-14 17:48 Alter a sysfs attribute?? Jay Otis
2008-09-15 9:08 ` Alan Jenkins
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).