{"id":330,"date":"2014-12-09T08:40:39","date_gmt":"2014-12-09T13:40:39","guid":{"rendered":"https:\/\/vhdesigns.com\/?p=330"},"modified":"2014-12-09T08:40:39","modified_gmt":"2014-12-09T13:40:39","slug":"secure-erase-ssd-in-linux","status":"publish","type":"post","link":"https:\/\/vhdesigns.com\/index.php\/2014\/12\/09\/secure-erase-ssd-in-linux\/","title":{"rendered":"Secure Erase SSD in Linux"},"content":{"rendered":"<p>Original Article:\u00a0<a title=\"SSD memory cell clearing\" href=\"https:\/\/wiki.archlinux.org\/index.php\/SSD_memory_cell_clearing\" target=\"_blank\" rel=\"noopener noreferrer\">https:\/\/wiki.archlinux.org\/index.php\/SSD_memory_cell_clearing<\/a><\/p>\n<h2><span id=\"Step_1_-_Make_sure_the_drive_security_is_not_frozen\" class=\"mw-headline\">Step 1 &#8211; Make sure the drive security is not frozen<\/span><\/h2>\n<p>Issue the following command:<\/p>\n<pre># hdparm -I \/dev\/sdX<\/pre>\n<h2><span id=\"Step_2_-_Enable_security_by_setting_a_user_password\" class=\"mw-headline\">Step 2 &#8211; Enable security by setting a user password<\/span><\/h2>\n<div>Note: When the user password is set the drive will be locked after next power cycle denying normal access until unlocked with the correct password.<\/div>\n<p>Any password will do, as this should only be temporary. After the secure erase the password will be set back to NULL. In this example, the password is &#8220;PasSWorD&#8221; as shown:<\/p>\n<pre># hdparm --user-master u --security-set-pass PasSWorD \/dev\/sdX\nsecurity_password=\"PasSWorD\"\n\/dev\/sdX:\nIssuing SECURITY_SET_PASS command, password=\"PasSWorD\", user=user, mode=high\n<\/pre>\n<p>As a sanity check, issue the following command<\/p>\n<pre># hdparm -I \/dev\/sdX\n<\/pre>\n<p>The command output should display &#8220;enabled&#8221;:<\/p>\n<pre>Security: \n        Master password revision code = 65534\n                supported\n                enabled\n        not     locked\n        not     frozen\n        not     expired: security count\n                supported: enhanced erase\n        Security level high\n        2min for SECURITY ERASE UNIT. 2min for ENHANCED SECURITY ERASE UNIT.<\/pre>\n<h2><span id=\"Step_3_-_Issue_the_ATA_Secure_Erase_command\" class=\"mw-headline\">Step 3 &#8211; Issue the ATA Secure Erase command<\/span><\/h2>\n<div><strong>Warning: <\/strong>Triple check that the correct drive designation is used. There is <b>no turning back<\/b> once the command is confirmed. You have been warned.<\/div>\n<pre># hdparm --user-master u --security-erase PasSWorD \/dev\/sdX\n<\/pre>\n<p>Wait until the command completes. This example output shows it took about 40 seconds for an Intel X25-M 80GB SSD.<\/p>\n<pre>security_password=\"PasSWorD\"\n\/dev\/sdX:\nIssuing SECURITY_ERASE command, password=\"PasSWorD\", user=user\n0.000u 0.000s 0:39.71 0.0%      0+0k 0+0io 0pf+0w\n<\/pre>\n<p>The drive is now erased. After a successful erasure the drive security should automatically be set to disabled (thus no longer requiring a password for access). Verify this by running the following command:<\/p>\n<pre># hdparm -I \/dev\/sdX\n<\/pre>\n<p>The command output should display &#8220;not enabled&#8221;:<\/p>\n<pre>Security: \n        Master password revision code = 65534\n                supported\n        not     enabled\n        not     locked\n        not     frozen\n        not     expired: security count\n                supported: enhanced erase\n        2min for SECURITY ERASE UNIT. 2min for ENHANCED SECURITY ERASE UNIT.<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Original Article:\u00a0https:\/\/wiki.archlinux.org\/index.php\/SSD_memory_cell_clearing Step 1 &#8211; Make sure the drive security is not frozen Issue the following command: # hdparm -I \/dev\/sdX Step 2 &#8211; Enable<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[],"class_list":["post-330","post","type-post","status-publish","format-standard","hentry","category-tips"],"_links":{"self":[{"href":"https:\/\/vhdesigns.com\/index.php\/wp-json\/wp\/v2\/posts\/330","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/vhdesigns.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/vhdesigns.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/vhdesigns.com\/index.php\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/vhdesigns.com\/index.php\/wp-json\/wp\/v2\/comments?post=330"}],"version-history":[{"count":0,"href":"https:\/\/vhdesigns.com\/index.php\/wp-json\/wp\/v2\/posts\/330\/revisions"}],"wp:attachment":[{"href":"https:\/\/vhdesigns.com\/index.php\/wp-json\/wp\/v2\/media?parent=330"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/vhdesigns.com\/index.php\/wp-json\/wp\/v2\/categories?post=330"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/vhdesigns.com\/index.php\/wp-json\/wp\/v2\/tags?post=330"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}