Blast-Radius Aware AI Code Review for Business-Critical Systems
LiveReview LiveReview Explore LiveReview

vfs_readonly - make a Samba share read only for a specified time period

Author

       The original Samba software and related utilities were created by Andrew Tridgell. Samba is now developed
       by the Samba Team as an Open Source project similar to the way the Linux kernel is developed.

Samba 4.22.3-Ubuntu-4.22.3+dfs                     07/21/2025                                    VFS_READONLY(8)

Description

       This VFS module is part of the samba(7) suite.

       The vfs_readonly VFS module marks a share as read only for all clients connecting within the configured
       time period. Clients connecting during this time will be denied write access to all files in the share,
       irrespective of their actual access privileges.

       This module is stackable.

Examples

       Mark all shares read only:

                   [global]vfsobjects=readonly

       Mark the [backup] share as read only during business hours:

                   [backup]path=/readonlyvfsobjects=readonlyreadonly:period=readonly:period="today9:00","today17:00"

Name

       vfs_readonly - make a Samba share read only for a specified time period

Options

       readonly:period = BEGIN, END
           Only mark the share as read only if the client connection was made between the times marked by the
           BEGIN and END date specifiers. The syntax of these date specifiers is the same as that accepted by
           the -d option of GNU date(1).

Synopsis


       vfs objects = readonly

Version

       This man page is part of version 4.22.3-Ubuntu-4.22.3+dfsg-4ubuntu1 of the Samba suite.

See Also