KIOFuse: June in Review

The coding period has now extended over a month and quite a few improvements have been merged into KIOFuse. In my last post I mentioned the development of a KIO error to FUSE error mapping and 32 bit support.

However, interestingly enough it took quite a long time for the 32-bit support branch to be merged. This was because of a test that didn’t fail nor pass – it froze. The test suite would never finish and the process would only respond to SIGKILL. After days of debugging it was determined that fuse_notify_inval_* functions don’t play well when writeback caching is enabled and hence there is now a patch to disable it. Of course this will incur a performance hit as writes will go straight to KIOFuse, and hence straight to disk (although the kernel may cache our write requests to our own cache). Whilst this is unfortunate, seeming as most KIO slaves are network based, switching from a writeback caching policy to a writethrough one is unlikely to hamper performance too much.

In other news, KIOFuse can now handle SIGTERM, SIGINT and SIGHUP signals. Signal handlers can only call async-signal-safe functions. However in Qt there is a bit of hack one can perform, as inspired by this tutorial. Hence, in response to these signals, KIOFuse will flush all dirty nodes to disk, meaning no sudden data loss!

Mounts can now have their password changed.

The lookup function has now been optimised. Previously a lookup would call KIO::listDir, which was totally unnecessary – a KIO::stat would suffice and this is what the patch has switched to. It also increased the data buffer from 1MB to 14MB.

Unmount support has currently been postponed. It is proving problematic to implement reliably and unmounting only really provides a marginal benefit, so it is yet to be seen if we will implement it at all. The current WIP patch can be found here.

It has been decided that slaves that do not implement KIO::stat will not be supported. It’s a bit of a hassle to implement with extremely marginal benefit. There are only a few slaves that don’t implement KIO::stat, such as fonts and thumbnails.

An issue with KDE Connect not working properly has been fixed upstream. I haven’t 100% confirmed which patch has fixed this for us, but I’m placing my bets on this one.

Currently, the Google Drive API reports a size of zero for files that are not supported by GDrive, such as odt files , and their proprietary formats – i.e. Google Docs. Whilst we can update the size quite easily by downloading the file, the file turns out corrupted, and is only openable if the program has a repair option (such as LibreOffice). Unfortunately, I’ve not been able to find out why exactly this is happening, and have not come up with a fix. Currently this is being shelved and I hope to revisit it at a later date with a fresher mind.

We’d welcome anyone to use and test KIOFuse. Feel free to notify us on any bugs or performance issues by opening an issue and you can even contribute a patch if you wish!

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s