inotify is cool, and really bugging me.

Dear Lazyweb,

Why doesn't inotifywatch /sys/kernel/uevent_seqnum work? I get no changes reported at all – and I've even tried using inotify in C adding a watch for IN_ALL_EVENTS. Maybe I'm being really stupid here, but inotify doesn't seem to work at all for sysfs. Help appreciated.

Thanks.

EDIT: Yes, I was being stupid. sysfs doesn't change the value until the file is read. Of course. poll to the rescue, except now that doesn't even work…

Published by

hughsie

Richard has over 10 years of experience developing open source software. He is the maintainer of GNOME Software, PackageKit, GNOME Packagekit, GNOME Power Manager, GNOME Color Manager, colord, and UPower and also contributes to many other projects and opensource standards. Richard has three main areas of interest on the free desktop, color management, package management, and power management. Richard graduated a few years ago from the University of Surrey with a Masters in Electronics Engineering. He now works for Red Hat in the desktop group, and also manages a company selling open source calibration equipment. Richard's outside interests include taking photos and eating good food.

One thought on “inotify is cool, and really bugging me.”

Comments are closed.