Having a backup of all data is the ultimate safeguard against loss of said data.
Ransomeware are viruses or trojans that encrypt all data on a system. There is typically a way to get a decryption key through payment of a ransom, typically in the form of bitcoins.
Backup solutions that write to hard drive or file share are also susceptible because the ransomeware will also encrypt the backup data. Backup solutions by isginf
provide protection from this: