Well technically that is possible in any OS. You can mount the drive elsewhere or to a live cd, change root password. That is the recommended way to recover from lost root password (assuming FS is not encrypted - which was the case you were talking about)
Let us assume one can’t easily modify the filesystem or special boot options are not available
Let us assume one can’t easily modify the filesystem or special boot options are not available