This example shows how to embed a new file system into the virtual file system (VFS) that is provided in KasperskyOS Community Edition.
In this example, the Client
program tests the operation of file systems (ext2
, ext3
, ext4
) on block devices. To do so, the Client
queries the virtual file system (the FileVfs
program) via IPC, and FileVfs
in turn queries the block device via IPC.
The ext2
and ext3
file systems work with the default settings. The ext4
file system works if you disable extent
(mkfs.ext4 -O ^64bit,^extent /dev/foo
).
Example files
The code of the example and build scripts are available at the following path:
/opt/KasperskyOS-Community-Edition-<version>/examples/vfs_extfs
Building and running example
See Building and running examples section.
Preparing an SD card to run on Raspberry Pi 4 B
To run the vfs_extfs
example on Raspberry Pi 4 B, the SD card must have a bootable partition with the solution image as well as 3 additional partitions with the ext2
, ext3
and ext4
file systems, respectively.