XFS : Project Progress

Hello, it’s been quite some time.

xfs version 5 superblock work is done now, a valid superblock is detected.

version 5 :

version 4 :

All testing done on fs_shell.

GSoC community bonding period ended and official coding period started, I think I should write a blog on my progress in community bonding period.

19 Likes

Hello everyone.

xfs version 5 Inodes work is done, we can now read and verify (checksums and other stuff) of inodes
(It known as inode version 3) while simultaneously not loosing support for inode version 1 & 2 ( xfs version 4).

I also finished short-form directory work, It was quite pain to get where on-disk headers are stored for short-form directories, It took me some time but I managed to get it work.

We can now read short-form directories fine :slight_smile:

I will push my next patch on gerrit probably after I get read support for all forms of directories (extent, leaf, B+tree).

Thanks.

21 Likes

Hello!

Block directories and leaf directories work is done now, we can read V5 block and leaf directories fine with checksums verification.

Block directory :

Leaf Directory :

For Node directories we don’t have proper read support for V4 too (We are not getting matching maps for entries) so as of now I am fixing that, simultaneously I will add V5 node directories support as well.

19 Likes

Hello everyone.

I completed all the remaining form of directories read support and files read support for xfs v5.

Node directories :

B+Tree directories :

Files :

It took me some time though because I needed to find some elegant way to handle both versions, once that was done I quickly finished remaining work as well.

I am happy to say we now have same basic read support for xfs version 5 as we had for version 4 :slight_smile: .

I will share more of my thoughts on blog (Its been a month since I made one) .

17 Likes

Great, nice work!

Will you also implement xfs_growfs to grow the filesystem, or is that beyond scope?

The Idea for now is to get stable read/write support, so growing filesystem is definitely beyond scope.

1 Like

Got it. Totally makes sense. Good luck with the write support.

1 Like

Hello!

Completed Leaf based attributes support for both Versions of XFS.

On V4 mounted File System, attributes are known as “attr2”

Screenshot 2022-08-29 at 7.49.57 PM

On V5 mounted File System, attributes are known as “attr3”

Screenshot 2022-08-29 at 7.50.58 PM

Woahh I wonder how much we can store in B+Tree based attributes, XFS does comes handy when we need to store really large number of attributes.
Though the value of attributes can’t be more than 64KB (basic directory block size).

Next task is to implement Node based attributes.

Thanks.

21 Likes

Hello everyone.

Completed Node based attributes support for both versions of XFS.

I randomly generated 1000 extended attributes for some testing, we are reading them fine.

Version 5 :

Screenshot 2022-09-02 at 1.15.59 AM

Version 4 :

Screenshot 2022-09-02 at 1.18.04 AM

Now we are remaining with just last format i.e B+Tree based xattrs.

Thanks.

24 Likes

Hey everyone.

Finished Symlinks support for XFS.

XFS stores symbolic link in two formats :

  • Local.
  • Extents.

I implemented both formats in my latest patch and that finishes all the work that is needed for symbolic links.

On V4 mounted xfs :

Screenshot 2022-09-05 at 6.55.18 PM

On V5 mounted xfs :

Screenshot 2022-09-05 at 6.57.03 PM

I implemented it with different API than other file systems on Haiku like ext2, btrfs to make our xfs code more elegant.
Anyways we are almost at the end of GSoC period now, I will finish remaining extended attributes work and then will prepare final report :slight_smile:

Thanks.

26 Likes

you mount this partition on /Testing? it is possible?

1 Like

Yes.
Something like :
mount - t xfs /boot/home/Desktop/attr.img /boot/home/Desktop/Testing

attr.img here is xfs file system image that I created from linux.

3 Likes

oh, and you can mount a volume in a folder too? this is new for me, i totally ignore that commad was on haiku too, btw great work with your xfs project.

1 Like

I haven’t tried that so it maybe possible.

Thanks!

1 Like

Is there a Windows driver also for XFS? That would be cool to be able to share files within e.g. Windows, Linux and Haiku.

1 Like

Hello!

I was trying to introduce Block Cache for xfs and there are some doubts I wanna ask.

There is CachedBlock.h which acts as an interface for block cache, so if I introduce that and cache the directory block, the next call to read_pos() for the block will not go to disk right?

Or is there some other function() to call the cached block?

Also, I can’t edit this thread name to remove [GSoC 22].
GSoC already ended for me so it would be nice if someone could remove it.

GSoC prefix removed.

1 Like

BTY @Mashijams the xfs driver has become dog slow lately since you’ve added the xattr, i guess it went unnoticed because you only tested it in the terminal, you can build the Qt filemanager below to test it with.

1 Like

Hmm I wonder what went wrong, since I Implemented xattrs independent of directories and files.

Let me test it and see if I could fix performance issues :slight_smile:

5 Likes