Comments (6)
Hi, @philfry
What I wrote before is from the Wiki's "Encrypting your drive" page, with my modest modification to a non-bootable drive.
I should also mention that your command:
sedutil-cli --initialSetup <yourAdmin1password> /dev/sda
left the LockingRange 0 of your disk disabled.
So don't ask me why you have anything corrupted on this drive because I don't understand at all how you achieved anything by writing data to the drive without executing the command:
sedutil-cli --enableLockingRange 0 <yourAdmin1password> /dev/sda
Also:
I've never used PSID Revert so I don't know why you had data on disk after doing it. Did you get a message after it: "revertTper completed successfully" ?
Here is my humble advice to everyone who is going/starting with sedutil-cli:
Please read the instructions on the Wiki pages first. If something is incomprehensible, or works differently than you thought, check the "Issues" pages to see if someone has already asked about it, and maybe someone else has already answered it.
ATB
from sedutil.
Sorry, I need to correct my previous message.
The command "sedutil-cli --initialSetup ..." left the LockingRange 0 disabled, but also left it set as RW, and that means it was available as for writing, and for reading as well, just the locking by power cycling was disabled. So you could write the data.
initialSetup aalso prepared disk for partition shadowing. I don;t know, if it "stole" some of the disk space for the shadow PBA partition.
I use the disk that it had many data written already, before I have used the sedutil-cli to prepare it to be locked according to the TCG Opal, including the shadow PBA partition, and I don't have any problems with the data corruption.
I think, however, that the better practice is to prepare the TCG Opal shadowing and locking first, and then to install the system and to write the data on it.
Regards
from sedutil.
Hi, @philfry
The performed by you command:
sedutil-cli --initialsetup ${passphrase} /dev/sda
left your disk with MBREnabled = Y (ON) and with MBRDone = Y (ON).
First of all, after performing that command (--initialsetup), you should do also the following commands:
sedutil-cli --enableLockingRange 0 <yourAdmin1password> /dev/sda
sedutil-cli --setLockingRange 0 LK <yourAdmin1password> /dev/sda
sedutil-cli --setMBREnable OFF <yourAdmin1password> /dev/sda
The last one from mentioned above is telling the device that it will not have the shadow MBR partition, since this is not the booting device. You should perform also
sedutil-cli --setLockingRange 0 RW <yourAdmin1password> /dev/sda
if you were going to access the data partition before making power cycle, followed by the linuxpba.
For some reason the linuxpba performed on your booting disk (/dev/nvme0) left your non-booting disk (/dev/sda) with the parameters MBREnabled = Y (ON) and with MBRDone = N (OFF), that means it gave you access to the shadow MBR partition of your data disk, that there is nothing on it (on that partition since you did nod load any PBA image to it), and which partition should not exist on non booting device.
ATB
from sedutil.
Hi @JaBoMa
Many thanks for your help!
I can access my data after issuing sedutil-cli --setMBRDone on ${passphrase} /dev/sda
even though fdisk/parted tell me there's some data corruption regarting the backup gpt:
fdisk -l /dev/sda
# The backup GPT table is corrupt, but the primary appears OK, so that will be used.
# Disk /dev/sda: 931,51 GiB, 1000204886016 bytes, 1953525168 sectors
# Disk model: CT1000MX500SSD1
# Units: sectors of 1 * 512 = 512 bytes
# Sector size (logical/physical): 512 bytes / 512 bytes
# I/O size (minimum/optimal): 512 bytes / 512 bytes
# Disklabel type: gpt
# Disk identifier: 7D59C85D-3056-274A-BB7D-6681918209D3
#
# Device Start End Sectors Size Type
# /dev/sda1 2048 1953523711 1953521664 931,5G Linux filesystem
sgdisk -e /dev/sda
# Caution: invalid backup GPT header, but valid main header; regenerating
# backup header from main header.
# [...]
# Warning! Secondary partition table overlaps the last partition by
# 591 blocks!
# Try reducing the partition table size by 2364 entries.
# Aborting write of new partition table.
To me it looks like some hidden reserved spaces that was taken from the already allocated data partition. Dunno.
I guess it's not enough just issueing the three commands you gave me to fix my issue. Should I start over, like reverting psid, initialize, enableLockingRange 0, setLockingRange LK (what does 'LK' stand for?) and setMBREnable off, or is there an easier way possibly without data loss?
from sedutil.
Hi @JaBoMa
thanks a lot for your explanations and after reading a bit further I think most questions are answered why this happened and what I did wrong.
Kind regards
from sedutil.
fwiw: after issueing the three commands from #420 (comment) and re-writing the partition table the disk was perfectly usable again (even the reserved space came back) and it was unlocked automatically by the pba. Thanks!
from sedutil.
Related Issues (20)
- Samsung 840 EVO SSD locked with m and u password while doing a CMOS reset on Toshiba HOT 1
- is Drive-Trust-Alliance serious about QA ?!?! HOT 11
- TCG Enterprise initialsetup fails
- Solidigm P44 Pro - According to sedutil it has OPAL 2? HOT 8
- Micron 5400 Shows No for Opal compliant HOT 5
- Non-boot drive prompts password on startup and fails. HOT 14
- How to add a package to the PBA? (libusb-1.0-0)
- Drive remains unlocked after reset HOT 2
- Test the PBA results scroll too fast and most exit display to be out of view. HOT 8
- Locked SED drives and linux errors HOT 13
- TCG-Ruby support HOT 2
- The Kernel flag libata.allow_tpm is not set correctly HOT 1
- revertnoerase can't be run due to SP_BUSY HOT 4
- Problem after installing a NVIDIA GPU
- NVME pass through HOT 12
- Query: TCG Pyrite/Opal/Enterprise and IEEE 2883-2022 HOT 1
- Why isn't the main branch being updated anymore?
- Samsung PM981 NVMe: PSID revert does not work HOT 1
- RevertLockingSP on TCG Enterprise doesn't work HOT 2
- version 1.49 unbuildable on linux HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sedutil.