rhansen / unlock-cryptroot Goto Github PK
View Code? Open in Web Editor NEWScript to unlock an Ubuntu or Debian encrypted root filesystem via ssh
License: BSD 2-Clause "Simplified" License
Script to unlock an Ubuntu or Debian encrypted root filesystem via ssh
License: BSD 2-Clause "Simplified" License
Rather than re-run cryptsetup and then kill askpass, feed the password to askpass via /lib/cryptsetup/passfifo
.
Hey @rhansen,
Great script, I used it fine on 15.10. After dist-upgrade to 16.04, after I run the script it works (mounting the drive) but then tries again and again to mount it, and can't, because it already exists. Not sure what I have to change. If I log in with -l and do it manually, it works and the system boots.
checking if /scripts/local-top/cryptroot is running...
getting /sbin/cryptsetup command-line arguments...
command: /sbin/cryptsetup -T 1 --allow-discards open --type luks /dev/mapper/4TBDataMirror-sda1 lvroot_crypt --key-file=-
Enter passphrase:
passphrase accepted; killing passphrase prompt...
checking for /lib/cryptsetup/[a]skpass...
killing PID 344...
checking for [a]sk-for-password...
getting /sbin/cryptsetup command-line arguments...
command: /sbin/cryptsetup -T 1 --allow-discards open --type luks /dev/mapper/4TBDataMirror-sda1 lvroot_crypt --key-file=-
trying previously entered passphrase...
Device lvroot_crypt already exists.
ERROR: '/sbin/cryptsetup -T 1 --allow-discards open --type luks /dev/mapper/4TBDataMirror-sda1 lvroot_crypt --key-file=-' failed
Enter passphrase:
Cheers,
Noah
Since the latest commit, I get:
line 151: syntax error near unexpected token `;;'
and
line 151: ` case $2 in remove) fatal "'cryptsetup remove' is running";; esac'
Thanks for still working on the script btw, I appreciate it ๐
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.