• 5 Posts
  • 70 Comments
Joined 4 months ago
cake
Cake day: July 25th, 2024

help-circle





  • I usually use

    dd status=progress conv=sync,noerror bs=64k if=/path/to/source/drive of=/path/to/destination/drive
    

    Take a reading of the drive health first with something like smartctl and if it has a lot of failing attributes, consider lowering the block size to something rather smaller like bs=512.

    Edit: To elaborate, using the sync and noerror arguments will instruct dd to ignore errors and continue in the event of read failures, while allocating zeroes to the remainder of the block space. Which is also why smaller block sizes are better for potentially failing drives. The copy will take longer, but a single error won’t take large swaths of data with it.














  • I do use ClamAV. Most users just run some sort of daily scan, but this is remedial and not preventative.

    In order to truly harness clamav’s potential, you need to configure clamonacc on-access scanning. It passes items off to clamd with lowered privileges and prevents file access through inotify until its realtime scan has cleared.