FileVault encryption never finishes
Each time I restart my Mac, FileVault says that it has 2 hours remaining to encrypt my disk.
But after about a minute, it says that encryption is finished.
But this is not true, because the next time I restart the same thing happens.
Also note that the button to turn off FileVault is disabled. And I am unable to make any Time Machine backups because of this:
Time Machine did not back up because FileVault was encrypting or decrypting a disk. Backups will resume once FileVault finishes.
I looked through the Console logs and found the following error messages that indicate that the encryption process didn't finish, but rather failed.
default 09:24:04.804291-0700 kernel disk2: I/O error.
default 09:24:04.804371-0700 kernel er_fs_root_iterator_error_check:4800: MARKING VOLUME 'Macintosh HD - Data' FAILED DUE TO ERROR 5
default 09:24:04.829375-0700 kernel encrypt_live_fs_data:4868: er: error 5 at fext: 0x2d87651:0x61535000.
default 09:24:08.064893-0700 com.apple.preference.security.remoteservice -[APFSFDEController apfsIsConvertingOrReverting] [743] -- DMAPFSVolumeCryptoMigrationState: 4; dmError: 0
default 09:24:08.065032-0700 com.apple.preference.security.remoteservice -[APFSFDEController _checkFDEEncryptionStatusTimer:] [975] -- looks like encryption/decryption is finished.
I have run First Aid on all of the partitions and it does not detect or correct any errors.
I am not able to restore the OS, since I am unable to complete a Time Machine backup to restore from.
How can I abort the encryption process and return to a state where FileVault is off?
iMac 27″, macOS 10.15