diff --git a/docs/HOME_DIRECTORY.md b/docs/HOME_DIRECTORY.md index c517cf573c..d82aca7065 100644 --- a/docs/HOME_DIRECTORY.md +++ b/docs/HOME_DIRECTORY.md @@ -168,6 +168,10 @@ If the UID assigned to a user does not match the owner of the home directory in the file system, the home directory is automatically and recursively `chown()`ed to the correct UID. -Depending on the `discard` setting of the user record either the backing +Depending on the `luksDiscard` setting of the user record either the backing loopback file is `fallocate()`ed during activation, or the mounted file system is `FITRIM`ed after mounting, to ensure the setting is correctly enforced. + +When deactivating a home directory, the file system or block device is trimmed +or extended as configured in the `luksOfflineDiscard` setting of the user +record. diff --git a/docs/USER_RECORD.md b/docs/USER_RECORD.md index 72acbcc026..6269b1e6ca 100644 --- a/docs/USER_RECORD.md +++ b/docs/USER_RECORD.md @@ -455,6 +455,10 @@ storage. If false and `luks` storage is used turns this behavior off. In addition, depending on this setting an `FITRIM` or `fallocate()` operation is executed to make sure the image matches the selected option. +`luksOfflineDiscard` → A boolean. Similar to `luksDiscard`, it controls whether +to trim/allocate the file system/backing file when deactivating the home +directory. + `luksCipher` → A string, indicating the cipher to use for the LUKS storage mechanism. `luksCipherMode` → A string, selecting the cipher mode to use for the LUKS storage mechanism. @@ -648,11 +652,12 @@ that may be used in this section are identical to the equally named ones in the `mountNoDevices`, `mountNoSuid`, `mountNoExecute`, `cifsDomain`, `cifsUserName`, `cifsService`, `imagePath`, `uid`, `gid`, `memberOf`, `fileSystemType`, `partitionUuid`, `luksUuid`, `fileSystemUuid`, `luksDiscard`, -`luksCipher`, `luksCipherMode`, `luksVolumeKeySize`, `luksPbkdfHashAlgorithm`, -`luksPbkdfType`, `luksPbkdfTimeCostUSec`, `luksPbkdfMemoryCost`, -`luksPbkdfParallelThreads`, `rateLimitIntervalUSec`, `rateLimitBurst`, -`enforcePasswordPolicy`, `autoLogin`, `stopDelayUSec`, `killProcesses`, -`passwordChangeMinUSec`, `passwordChangeMaxUSec`, `passwordChangeWarnUSec`, +`luksOfflineDiscard`, `luksOfflineDiscard`, `luksCipher`, `luksCipherMode`, +`luksVolumeKeySize`, `luksPbkdfHashAlgorithm`, `luksPbkdfType`, +`luksPbkdfTimeCostUSec`, `luksPbkdfMemoryCost`, `luksPbkdfParallelThreads`, +`rateLimitIntervalUSec`, `rateLimitBurst`, `enforcePasswordPolicy`, +`autoLogin`, `stopDelayUSec`, `killProcesses`, `passwordChangeMinUSec`, +`passwordChangeMaxUSec`, `passwordChangeWarnUSec`, `passwordChangeInactiveUSec`, `passwordChangeNow`, `pkcs11TokenUri`. ## Fields in the `binding` section diff --git a/man/homectl.xml b/man/homectl.xml index 6cec7a13c8..632c8b95bb 100644 --- a/man/homectl.xml +++ b/man/homectl.xml @@ -544,6 +544,16 @@ loopback file) the discard logic defaults to on. + + BOOL + + Similar to , controls the trimming of the file + system. However, while controls what happens when the home directory + is active, controls what happens when it becomes inactive, + i.e. whether to trim/allocate the storage when deactivating the home directory. This option defaults + to on, to ensure disk space is minimized while a user is not logged in. + + CIPHER MODE