circular files: minor additions and great interest ?
Hello,
To fulfill the purpose of user-transparent file compression, FiST looks very flexible indeed (that widescope project, which also covers the need for crypto, was unknown to me).
But as far as circular files are concerned, it looks natural to implement this at file level.
All we need in "struct stat" is a pair of extra attribute:
one which tells whether the file is circular (circ) and one which remembers the logical end-of-file (eof) and light modifications to system calls from the seek(), read(), write(), and truncate() families.
Besides, in order to allow the file to grow in size,
one could specify that this is accomplished by seeking to position eof+1 and writing there.
Assume we have the following file:
data: ABCDEFGH
descriptor: fd, currently at offset 5 (character F) circ=TRUE
eof=2 (file ends with character C)
read(fd,buf,4) should return 4 and set buf contents to "FGHA" read(fd,buf,8) should return 6 and set buf contents to "FGHABC" etc ...
I have the feeling that implementing circular files in the kernel requires minor alteration to the source. I may be wrong.
Anyway i hope kernel developers will like the idea, which can help by providing more stability and flexibility to heavily logging applications (syslogs, proxies, mail relays) and admins would not have to bother about disk space anymore !!!
Best regards
Phil
----- Fin du message transféré -----
-
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 4 lines · * [email protected] ([email protected]) [20040123 11:24]:
Anyway i hope kernel developers will like the idea, which can help by providing more stability and flexibility to heavily logging applications (syslogs, proxies, mail relays) and admins would not have to bother about disk space anymore !!!
Why bother mocking around in the kernel, when one can use a specific application (i.e. RRDtool or any other round-robin database) for the task? All the examples you have given are perfectly doable with RRDtool.
Peter
Signature · 7 lines
.+'''+. .+'''+. .+'''+. .+'''+. .+'' Kelemen Péter / \ / \ [email protected] .+' `+...+' `+...+' `+...+' `+...+' - To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html