Home
%3CLINGO-SUB%20id%3D%22lingo-sub-839196%22%20slang%3D%22en-US%22%3ELesson%20Learned%20%23108%3A%20How%20the%20data%20is%20purged%20or%20destroyed%20in%20Azure%20Database%20for%20MySQL.%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-839196%22%20slang%3D%22en-US%22%3E%3CP%3EFirst%20of%20all%2C%20in%20both%20platforms%2C%20PaaS%20(Azure%20Database%20MySQL%2C%20Azure%20SQL%20Database%2C%20Azure%20Database%20for%20PostgreSQL%2C%20Azure%20Database%20for%20MariaDB%2C%20etc..)%20and%20IaaS%20(Virtual%20Machine%2C%20for%20example)%2C%20these%20services%20are%20using%20an%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fstorage%2Fcommon%2Fstorage-account-overview%3Ftoc%3D%252fazure%252fstorage%252fblobs%252ftoc.json%23types-of-storage-accounts%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3EAzure%20Storage%20account.%3C%2FA%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EAll%20storage%20accounts%20are%20encrypted%20using%20Storage%20Service%20Encryption%20(SEE)%20for%20data%20at%20rest%2C%20as%20you%20could%20see%20in%20this%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-ie%2Fazure%2Fstorage%2Fcommon%2Fstorage-service-encryption%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3EURL.%3C%2FA%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EAdditional%2C%20you%20could%20use%20Disk%20Encryption%20for%20your%20Virtual%20Machine%20on%20top%20of%20Storage%20Encryption%20as%20we%20have%20explained%20in%20these%20two%20URLs%20and%26nbsp%3BAzure%20SQL%20Database%20and%20Azure%20SQL%20Managed%20Instance%20are%20using%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fsql-database%2Ftransparent-data-encryption-azure-sql%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3ETDE%3C%2FA%3Etoo.%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-ie%2Fazure%2Fstorage%2Fcommon%2Fstorage-service-encryption%23azure-storage-encryption-versus-disk-encryption%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-ie%2Fazure%2Fstorage%2Fcommon%2Fstorage-service-encryption%23azure-storage-encryption-versus-disk-encryption%3C%2FA%3E%26nbsp%3B%3C%2FLI%3E%0A%3CLI%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-ie%2Fazure%2Fstorage%2Fcommon%2Fstorage-security-guide%3Ftoc%3D%252fazure%252fstorage%252fblobs%252ftoc.json%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-ie%2Fazure%2Fstorage%2Fcommon%2Fstorage-security-guide%3Ftoc%3D%252fazure%252fstorage%252fblobs%252ftoc.json%3C%2FA%3E%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWhen%20you%20deleted%20a%20storage%20account%20there%20is%20not%20possible%20to%20restore%2Frecover%20it%20that%20we%20have%20explained%20on%20these%20following%20URLs%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-ie%2Fazure%2Fstorage%2Fcommon%2Fstorage-account-manage%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-ie%2Fazure%2Fstorage%2Fcommon%2Fstorage-account-manage%3C%2FA%3E%3C%2FLI%3E%0A%3CLI%3E%3CA%20href%3D%22https%3A%2F%2Fblogs.msdn.microsoft.com%2Fwalterm%2F2014%2F09%2F04%2Fmicrosoft-azure-data-security-data-cleansing-and-leakage%2F%26nbsp%3B%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fblogs.msdn.microsoft.com%2Fwalterm%2F2014%2F09%2F04%2Fmicrosoft-azure-data-security-data-cleansing-and-leakage%2F%26nbsp%3B%3C%2FA%3E%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EBesides%20that%20the%20storage%20account%20is%20encrypted%2C%20please%2C%20review%20this%20%3CA%20href%3D%22https%3A%2F%2Fdevblogs.microsoft.com%2Fazuregov%2Fdata-security-qa-with-john-molesky-azure-security-engineering%2F%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3EURL%3C%2FA%3E%26nbsp%3Bthat%20contains%20the%20answer%20of%20the%20about%20how%20the%20data%20is%20deleted%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%20style%3D%22padding-left%3A%2030px%3B%22%3E%22To%20understand%20how%20Azure%20handles%20data%20when%20it%20is%20deleted%2C%20let%E2%80%99s%20first%20review%20how%20data%20is%20stored%20within%20Azure.%20For%20durability%20and%20high%20availability%2C%20data%20within%20Azure%20Storage%20accounts%20is%20replicated.%20Locally%20redundant%20storage%20(LRS)%20replicates%20data%20three%20times%20within%20a%20single%20facility%20within%20a%20single%20region%20for%20durability%3B%20geo-redundant%20storage%20(GRS)%20is%20replicated%20an%20additional%20three%20times%20in%20a%20secondary%20region.%20In%20Azure%20Storage%2C%20all%20disk%20writes%20are%20sequential.%20This%20minimizes%20the%20number%20of%20disk%20%E2%80%9Cseeks%2C%E2%80%9D%20but%20requires%20updating%20the%20pointers%20to%20data%20objects%20every%20time%20they%20are%20written.%20A%20side%20effect%20of%20this%20design%20is%20that%20data%20cannot%20be%20deleted%20by%20overwriting%20with%20other%20data.%20The%20original%20data%20will%20remain%20on%20the%20disk%2C%20and%20the%20new%20data%20will%20be%20written%20sequentially.%20When%20a%20customer%20deletes%20a%20storage%20object%20(e.g.%2C%20blob%2C%20file%2C%20queue%2C%20table)%2C%20the%20pointer%20to%20this%20object%20is%20immediately%20deleted%20from%20the%20storage%20index%20used%20to%20locate%20and%20access%20the%20data.%20This%20operation%20is%20replicated%20asynchronously%20for%20GRS.%20With%20the%20storage%20index%20updated%2C%20the%20data%20is%20immediately%20unavailable.%20The%20sectors%20on%20the%20disk%20associated%20with%20the%20deleted%20data%20become%20immediately%20available%20for%20reuse%20and%20are%20overwritten%20when%20the%20associated%20storage%20block%20is%20reused%20for%20storing%20other%20data.%20The%20time%20to%20overwrite%20varies%20depending%20on%20disk%20utilization%20and%20activity%2C%20but%20is%20rarely%20more%20than%20two%20days.%20This%20is%20consistent%20with%20the%20operation%20of%20a%20log-structured%20file%20system.%20Azure%20Storage%20interfaces%20do%20not%20permit%20direct%20disk%20reads%2C%20mitigating%20the%20risk%20of%20another%20customer%20(or%20even%20the%20same%20customer)%20from%20accessing%20the%20deleted%20data%20before%20it%20is%20overwritten.%22%3C%2FP%3E%0A%3CP%20style%3D%22padding-left%3A%2030px%3B%22%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EEnjoy!%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-TEASER%20id%3D%22lingo-teaser-839196%22%20slang%3D%22en-US%22%3E%3CP%3EToday%2C%20I%20had%20a%20very%20cool%20question%20raised%20by%20our%20customer%20about%20how%20they%20could%20be%20sure%20that%20when%20they%20deleted%20the%20database%20or%20the%20server%20the%20data%20is%20not%20recoverable.%20In%20this%20post%2C%20I%20included%20some%20useful%20information%26nbsp%3Bthat%20explains%20the%20prevention%20of%20the%20possibility%20of%20data%20leakage%20or%20exposure%20of%20one%20customer%E2%80%99s%20data%20to%20another%20customer%20upon%20deletion.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-TEASER%3E

First of all, in both platforms, PaaS (Azure Database MySQL, Azure SQL Database, Azure Database for PostgreSQL, Azure Database for MariaDB, etc..) and IaaS (Virtual Machine, for example), these services are using an Azure Storage account.

 

All storage accounts are encrypted using Storage Service Encryption (SEE) for data at rest, as you could see in this URL.

 

Additional, you could use Disk Encryption for your Virtual Machine on top of Storage Encryption as we have explained in these two URLs and Azure SQL Database and Azure SQL Managed Instance are using TDE too. 

 

 

When you deleted a storage account there is not possible to restore/recover it that we have explained on these following URLs:

 

 

Besides that the storage account is encrypted, please, review this URL that contains the answer of the about how the data is deleted:

 

"To understand how Azure handles data when it is deleted, let’s first review how data is stored within Azure. For durability and high availability, data within Azure Storage accounts is replicated. Locally redundant storage (LRS) replicates data three times within a single facility within a single region for durability; geo-redundant storage (GRS) is replicated an additional three times in a secondary region. In Azure Storage, all disk writes are sequential. This minimizes the number of disk “seeks,” but requires updating the pointers to data objects every time they are written. A side effect of this design is that data cannot be deleted by overwriting with other data. The original data will remain on the disk, and the new data will be written sequentially. When a customer deletes a storage object (e.g., blob, file, queue, table), the pointer to this object is immediately deleted from the storage index used to locate and access the data. This operation is replicated asynchronously for GRS. With the storage index updated, the data is immediately unavailable. The sectors on the disk associated with the deleted data become immediately available for reuse and are overwritten when the associated storage block is reused for storing other data. The time to overwrite varies depending on disk utilization and activity, but is rarely more than two days. This is consistent with the operation of a log-structured file system. Azure Storage interfaces do not permit direct disk reads, mitigating the risk of another customer (or even the same customer) from accessing the deleted data before it is overwritten."

 

Enjoy!