Lines Matching full:file
10 zonefs is a very simple file system exposing each zone of a zoned block device
11 as a file. Unlike a regular POSIX-compliant file system with native zoned block
15 of the file (append only writes).
18 than to a full-featured POSIX file system. The goal of zonefs is to simplify
20 raw block device file accesses with a richer file API, avoiding relying on
21 direct block device file ioctls which may be more obscure to developers. One
24 by allowing SSTables to be stored in a zone file similarly to a regular file
26 of the higher level construct "one file is one zone" can help reducing the
62 by sub-directories. This file structure is built entirely using zone information
72 and populates the mount point with a static file tree solely based on this
73 information. File sizes come from the device zone type and write pointer
77 device storing the super block is never exposed as a zone file by zonefs. If
91 be exposed as a file as it will be used to store the zonefs super block. For
109 contain files named "0", "1", "2", ... The file numbers also represent
112 All read and write operations to zone files are not allowed beyond the file
119 The number of blocks of a file as reported by stat() and fstat() indicates the
120 capacity of the zone file, or in other words, the maximum file size.
130 constraint for these files beyond the file size limit mentioned above.
136 the file's zone write pointer position relative to the zone start sector.
138 Sequential zone files can only be written sequentially, starting from the file
141 start offset not corresponding to the end of the file, or to the end of the last
158 zone is reset to rewind the file zone write pointer position to the start of
159 the zone, or up to the zone capacity, in which case the file's zone is
168 aggregated into a single larger file instead of the default one file per zone.
169 * File ownership: The owner UID and GID of zone files is by default 0 (root)
171 * File access permissions: the default 640 access permissions can be changed.
201 enforces sequential file write for sequential zones, unaligned write errors
222 but only if the file zone is still in a good condition and there is no
223 inconsistency between the file inode size and its zone write pointer position.
231 Zonefs minimal I/O error recovery may change a file size and file access
234 * File size changes:
235 Immediate or delayed write errors in a sequential zone file may cause the file
237 the file zone. For instance, the partial failure of a multi-BIO large write
240 case, the file inode size must be advanced to reflect the zone write pointer
242 file.
243 A file size may also be reduced to reflect a delayed write error detected on
245 be less than originally indicated by the file inode size. After such I/O
246 error, zonefs always fixes the file inode size to reflect the amount of data
247 persistently stored in the file zone.
250 A zone condition change to read-only is indicated with a change in the file
251 access permissions to render the file read-only. This disables changes to the
252 file attributes and data modification. For offline zones, all permissions
253 (read and write) to the file are disabled.
263 | mount | zone | file file device zone |
287 * With the "errors=remount-ro" mount option, the change of the file access
288 permissions to read-only applies to all files. The file system is remounted
290 * Access permission and file size changes due to the device transitioning zones
294 * File access permission changes to read-only due to the device transitioning
296 the device will not re-enable file write access.
297 * File access permission changes implied by the remount-ro, zone-ro and
299 Unmounting and remounting the file system will restore the previous default
302 actions, that is, file size fixes for zones in a good condition. Zones
304 the zone file access permissions as noted in the table above.
330 file size set to 0. This is necessary as the write pointer of read-only zones
334 The size of the zone file is left unchanged from its last updated value.
343 limit being exceeded if the zone of a file is not already active when a write
347 to be made active using an open zone command when a file is opened for writing
351 to the device on the last close() of a zone file if the zone is not full nor
367 (any file) can be open for writing and written at any time, regardless of the
369 will fail any open() system call requesting to open a sequential zone file for
418 conventional zone file (all conventional zones are aggregated under a single
419 file)::
425 This aggregated conventional zone file can be used as a regular file::
442 For sequential write zone files, the file size changes as data is appended at
443 the end of the file, similarly to any regular file system::
453 The written file can be truncated to the zone size, preventing any further
460 Truncation to 0 size allows freeing the file zone storage space and restart
461 append-writes to the file::
468 of a file as reported by stat() and fstat() indicates the capacity of the file
472 File: /mnt/seq/0
473 Size: 0 Blocks: 524288 IO Block: 4096 regular empty file
481 The number of blocks of the file ("Blocks") in units of 512B blocks gives the
482 maximum file size of 524288 * 512 B = 256 MB, corresponding to the device zone