HDDの中身を完全に書き換えるのと、処理に大変時間が掛かります。普通の方は真似しないのが無難と思います。また、セキュリティパスワードを取り扱うのでこれをセットした状態で忘れるとどうしようもなくなります。
まず、現在の状況を確認します。
sudo hdparm -I /dev/sdd
「sdd」のところは環境に合わせて変えます。
/dev/sdd:
ATA device, with non-removable media
Model Number: WDC WD2003FYYS-01T8B0
Serial Number: WD-WMAUR0125992
Firmware Revision: 01.00D02
Transport: Serial, SATA 1.0a, SATA II Extensions, SATA Rev 2.5, SATA Rev 2.6
Standards:
Supported: 8 7 6 5
Likely used: 8
Configuration:
Logical max current
cylinders 16383 16383
heads 16 16
sectors/track 63 63
--
CHS current addressable sectors: 16514064
LBA user addressable sectors: 268435455
LBA48 user addressable sectors: 3907029168
Logical/Physical Sector size: 512 bytes
device size with M = 1024*1024: 1907729 MBytes
device size with M = 1000*1000: 2000398 MBytes (2000 GB)
cache/buffer size = unknown
Nominal Media Rotation Rate: 7200
Capabilities:
LBA, IORDY(can be disabled)
Queue depth: 32
Standby timer values: spec'd by Standard, with device specific minimum
R/W multiple sector transfer: Max = 16 Current = 0
Advanced power management level: 128
Recommended acoustic management value: 128, current value: 254
DMA: mdma0 mdma1 mdma2 udma0 udma1 udma2 udma3 udma4 udma5 *udma6
Cycle time: min=120ns recommended=120ns
PIO: pio0 pio1 pio2 pio3 pio4
Cycle time: no flow control=120ns IORDY flow control=120ns
Commands/features:
Enabled Supported:
* SMART feature set
Security Mode feature set
* Power Management feature set
* Write cache
* Look-ahead
* Host Protected Area feature set
* WRITE_BUFFER command
* READ_BUFFER command
* NOP cmd
* DOWNLOAD_MICROCODE
* Advanced Power Management feature set
Power-Up In Standby feature set
* SET_FEATURES required to spinup after power up
SET_MAX security extension
Automatic Acoustic Management feature set
* 48-bit Address feature set
* Device Configuration Overlay feature set
* Mandatory FLUSH_CACHE
* FLUSH_CACHE_EXT
* SMART error logging
* SMART self-test
* General Purpose Logging feature set
* WRITE_{DMA|MULTIPLE}_FUA_EXT
* 64-bit World wide name
* IDLE_IMMEDIATE with UNLOAD
* WRITE_UNCORRECTABLE_EXT command
* {READ,WRITE}_DMA_EXT_GPL commands
* Segmented DOWNLOAD_MICROCODE
* Gen1 signaling speed (1.5Gb/s)
* Gen2 signaling speed (3.0Gb/s)
* Native Command Queueing (NCQ)
* Phy event counters
* Idle-Unload when NCQ is active
* NCQ priority information
DMA Setup Auto-Activate optimization
Software settings preservation
* SMART Command Transport (SCT) feature set
* SCT Read/Write Long (AC1), obsolete
* SCT Write Same (AC2)
* SCT Error Recovery Control (AC3)
* SCT Features Control (AC4)
* SCT Data Tables (AC5)
unknown 206[12] (vendor specific)
unknown 206[13] (vendor specific)
Security:
Master password revision code = 65534
supported
not enabled
not locked
not frozen
not expired: security count
supported: enhanced erase
316min for SECURITY ERASE UNIT. 316min for ENHANCED SECURITY ERASE UNIT.
Logical Unit WWN Device Identifier: 50014ee057365f80
NAA : 5
IEEE OUI : 0014ee
Unique ID : 057365f80
Checksum: correct
こんな感じに表示されます。難しいことは置いておいて「Security: 」でセキュリティパスワードが設定されているかわかります。設定されていてパスワードがわからなければ、ここで終了!解除する方法は????
sudo hdparm --user-master u --security-set-pass password1 /dev/sddまず、パスワードを設定します。ここでは「password1」これはすぐ終わります。
準備は整いました。いよいよ物理フォーマットしちゃいます。
sudo hdparm --user-master u --security-erase "password1" /dev/sdd
「”」でパスワードを括ることを忘れないようにします。この処理はHDDによりますが、1昼夜を目安に十分時間が使えるときにします。SSDだともっと早いと思いますが。。。。試してないので???
さて、最後に
物理フォーマットって何のためにするの?
通常は、工場で行われていて、今はユーザーが行う機会はほぼありません。
何らかの原因で、致命的な物理フォーマット情報の破壊がされた場合は有効な手段となりますし、中身が完全に書き換えられますので、ほぼ完全なデータ消去を行えるくらいでしょう。(なんか全面書き換えを行っても磁気的履歴をたどってデータを再現するなんて技術の噂もありますが、国防・金融データならいざ知らず個人データには完全な消去でしょう)
ここに書いたのはLinuxでの方法ですが、Windowsでは専用のToolがあるようです。「hdd low level format tool」で検索すると見つかります。


コメントを残す