News for hackers. Stuff that matters.
Re:Remove first 300M lines from 700 GB file on 1TB disk by magicalhippo on Tuesday September 22, 2020 @09:42AM (#24554278)
I've found it curious that so few (any?) file systems allow for non-aligned starting blocks. Ie keeping an offset into the initial block. That would make prepending files rather trivial, as well as trimming the start of files (hello log files).

Of course performance would suffer due to non-aligned access, but just as for regular files one could demand aligned access for optimal speed.

Re:Remove first 300M lines from 700 GB file on 1TB disk by yencabulator on Wednesday September 23, 2020 @07:46PM (#24573625)
Extent-based filesystems have no problem with that, and performance wouldn't be impacted either. The preserved tail of the first extent would have to copied / CoWed, that's it.

https://man7.org/linux/man-pages/man2/ioctl_ficlonerange.2.h...