Name | Modified | Size | Downloads / Week |
---|---|---|---|
Parent folder | |||
README-0.2 | 2008-08-15 | 2.9 kB | |
powfs-0.2.tar.gz | 2008-08-15 | 91.7 kB | |
Totals: 2 Items | 94.7 kB | 0 |
General Information =================== POWfs (Process On Write filesystem) is an extension to the FUSE core that allows the user to execute user-defined commands immediately after a file is written to disk. You can download the source code releases from http://sourceforge.net/projects/powfs/ or alternatively you can use Subversion to get the very latest development version: svn checkout https://powfs.svn.sourceforge.net/svnroot/powfs/trunk Dependencies ============ FUSE core libraries and headers are needed. Installation ============ ./configure make make install You may also need to add '/usr/local/lib' to '/etc/ld.so.conf' and/or run ldconfig. For more details see the file 'INSTALL' How To Use ========== - Create a .powfs file in your home directory and create hidden file entries and directory handlers as described below. Hidden Files ============ - For each file you would like to hide from the mount, create an entry in .powfs in the following format using the real path: hidden.0=/etc/passwd hidden.1=/home/user/.powfs - Be sure to use consecutive indexes. Directory Handlers ================== - For each directory you would like to handle, create an entry in .powfs in the following format using real paths. handler.dir.0=/tmp handler.prg.0=/home/username/bin/script.sh handler.dir.1=/etc handler.prg.1=/usr/local/bin/anotherprog - This would set up two handlers. /home/username/bin/script.sh would execute immediately after each file is written to the /tmp/ directory. It will pass the program a single argument of the real path to the full filename. /usr/local/bin/anotherprog would execute any time a file in the /etc directory were executed. Lets say that /home/username/bin/script.sh had the following data #!/bin/sh mail -s "Updated file" root@localhost $1 With the configuration above, here is an example run. cd src ./powfs mountpoint touch mountpoint/tmp/blah This would send an email to root saying that the file /tmp/blah has been modified. Keep in mind that the mountpoint is simply a virtual mirror of the root filesystem. This means that files must be modified through "mountpoint" to trigger the handler. Possible Uses ============= - Be alerted immediately after anything in the /etc folder is modified - Process raw data files in realtime immediately after receipt. - Write files locally and move them to an archived network share when the file is closed. - Be notified by email each time a file is finished uploading to your FTP directory. - Verify that an automated report is complete immediately after it finishes - Automatically upload a new revision of a file to a remote computer each time the file is saved. Reporting bugs ============== Please send bug reports to the <powfs-devel@lists.sourceforge.net> mailing list. The list is open, you need not be subscribed to post.