How to cryptsetup newly installed Ubuntu Server 18.10
I was wondering how to encrypt my harddrive on a newly installed Ubuntu Server 18.10. I tried this on Arch, which seemed to work fine, because I've done it during the installation fase. But with Ubuntu I have to setup cryptsetup, after booting the newly installed system.
I followed the follwing instructions https://www.cyberciti.biz/hardware/howto-linux-hard-disk-encryption-with-luks-cryptsetup-command/
But everytime I try to configure cryptsetup I get the following error:
$ sudo cryptsetup -y -v luksFormat /dev/sda3
WARNING: Device /dev/sda3 already contains a 'LVM2_member' superblock signature.
WARNING!
========
This will overwrite data on /dev/sda3 irrevocably.
Are you sure? (Type uppercase yes): YES
Enter passphrase for /dev/sda3:
Verify passphrase:
Device /dev/sda3 is in use. Can not proceed with format operation.
Command failed with code -1 (wrong or missing parameters).
$_
My setup:
Device Start End Sectors Size Type
/dev/sda1 2048 4095 2048 1M BIOS boot
/dev/sda2 4096 2101247 2097152 1G Linux filesystem
/dev/sda3 2101248 209713151 207611904 99G Linux filesystem
Any help is appreciated. I doubt the issue is my LVM setup, but who knows. I cannot find a website or blog with instructions, which explains this error. They all seem to work fine by just entering the cryptsetup command on the partition or harddisk.
One more question, wondering if it is possible (and advised) to run cryptsetup on the whole harddisk instead just the partition.
server encryption 18.10 cryptsetup
add a comment |
I was wondering how to encrypt my harddrive on a newly installed Ubuntu Server 18.10. I tried this on Arch, which seemed to work fine, because I've done it during the installation fase. But with Ubuntu I have to setup cryptsetup, after booting the newly installed system.
I followed the follwing instructions https://www.cyberciti.biz/hardware/howto-linux-hard-disk-encryption-with-luks-cryptsetup-command/
But everytime I try to configure cryptsetup I get the following error:
$ sudo cryptsetup -y -v luksFormat /dev/sda3
WARNING: Device /dev/sda3 already contains a 'LVM2_member' superblock signature.
WARNING!
========
This will overwrite data on /dev/sda3 irrevocably.
Are you sure? (Type uppercase yes): YES
Enter passphrase for /dev/sda3:
Verify passphrase:
Device /dev/sda3 is in use. Can not proceed with format operation.
Command failed with code -1 (wrong or missing parameters).
$_
My setup:
Device Start End Sectors Size Type
/dev/sda1 2048 4095 2048 1M BIOS boot
/dev/sda2 4096 2101247 2097152 1G Linux filesystem
/dev/sda3 2101248 209713151 207611904 99G Linux filesystem
Any help is appreciated. I doubt the issue is my LVM setup, but who knows. I cannot find a website or blog with instructions, which explains this error. They all seem to work fine by just entering the cryptsetup command on the partition or harddisk.
One more question, wondering if it is possible (and advised) to run cryptsetup on the whole harddisk instead just the partition.
server encryption 18.10 cryptsetup
add a comment |
I was wondering how to encrypt my harddrive on a newly installed Ubuntu Server 18.10. I tried this on Arch, which seemed to work fine, because I've done it during the installation fase. But with Ubuntu I have to setup cryptsetup, after booting the newly installed system.
I followed the follwing instructions https://www.cyberciti.biz/hardware/howto-linux-hard-disk-encryption-with-luks-cryptsetup-command/
But everytime I try to configure cryptsetup I get the following error:
$ sudo cryptsetup -y -v luksFormat /dev/sda3
WARNING: Device /dev/sda3 already contains a 'LVM2_member' superblock signature.
WARNING!
========
This will overwrite data on /dev/sda3 irrevocably.
Are you sure? (Type uppercase yes): YES
Enter passphrase for /dev/sda3:
Verify passphrase:
Device /dev/sda3 is in use. Can not proceed with format operation.
Command failed with code -1 (wrong or missing parameters).
$_
My setup:
Device Start End Sectors Size Type
/dev/sda1 2048 4095 2048 1M BIOS boot
/dev/sda2 4096 2101247 2097152 1G Linux filesystem
/dev/sda3 2101248 209713151 207611904 99G Linux filesystem
Any help is appreciated. I doubt the issue is my LVM setup, but who knows. I cannot find a website or blog with instructions, which explains this error. They all seem to work fine by just entering the cryptsetup command on the partition or harddisk.
One more question, wondering if it is possible (and advised) to run cryptsetup on the whole harddisk instead just the partition.
server encryption 18.10 cryptsetup
I was wondering how to encrypt my harddrive on a newly installed Ubuntu Server 18.10. I tried this on Arch, which seemed to work fine, because I've done it during the installation fase. But with Ubuntu I have to setup cryptsetup, after booting the newly installed system.
I followed the follwing instructions https://www.cyberciti.biz/hardware/howto-linux-hard-disk-encryption-with-luks-cryptsetup-command/
But everytime I try to configure cryptsetup I get the following error:
$ sudo cryptsetup -y -v luksFormat /dev/sda3
WARNING: Device /dev/sda3 already contains a 'LVM2_member' superblock signature.
WARNING!
========
This will overwrite data on /dev/sda3 irrevocably.
Are you sure? (Type uppercase yes): YES
Enter passphrase for /dev/sda3:
Verify passphrase:
Device /dev/sda3 is in use. Can not proceed with format operation.
Command failed with code -1 (wrong or missing parameters).
$_
My setup:
Device Start End Sectors Size Type
/dev/sda1 2048 4095 2048 1M BIOS boot
/dev/sda2 4096 2101247 2097152 1G Linux filesystem
/dev/sda3 2101248 209713151 207611904 99G Linux filesystem
Any help is appreciated. I doubt the issue is my LVM setup, but who knows. I cannot find a website or blog with instructions, which explains this error. They all seem to work fine by just entering the cryptsetup command on the partition or harddisk.
One more question, wondering if it is possible (and advised) to run cryptsetup on the whole harddisk instead just the partition.
server encryption 18.10 cryptsetup
server encryption 18.10 cryptsetup
asked Feb 1 at 9:23
Erik van de VenErik van de Ven
1105
1105
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
Of course, you can't do it on the running system.
You need to configure your LUKS container (with cryptsetup) from the LiveCD/USB and then proceed to the installation by feeding those containers to the installer.
May be, it is better that you use a LVM install from the installer. It will automatically use LUKS/cryptsetup.
Thanks, I will try it using a live cd. In earlier versions I could choose for encrypted LVM volume, but 18.10 only shows a "Use An Entire Disk And Set Up LVM" option. So guess I actually have to use a live cd to prepare the partitions with LUKS. Thanks for the advice
– Erik van de Ven
Feb 1 at 11:15
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1114670%2fhow-to-cryptsetup-newly-installed-ubuntu-server-18-10%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
Of course, you can't do it on the running system.
You need to configure your LUKS container (with cryptsetup) from the LiveCD/USB and then proceed to the installation by feeding those containers to the installer.
May be, it is better that you use a LVM install from the installer. It will automatically use LUKS/cryptsetup.
Thanks, I will try it using a live cd. In earlier versions I could choose for encrypted LVM volume, but 18.10 only shows a "Use An Entire Disk And Set Up LVM" option. So guess I actually have to use a live cd to prepare the partitions with LUKS. Thanks for the advice
– Erik van de Ven
Feb 1 at 11:15
add a comment |
Of course, you can't do it on the running system.
You need to configure your LUKS container (with cryptsetup) from the LiveCD/USB and then proceed to the installation by feeding those containers to the installer.
May be, it is better that you use a LVM install from the installer. It will automatically use LUKS/cryptsetup.
Thanks, I will try it using a live cd. In earlier versions I could choose for encrypted LVM volume, but 18.10 only shows a "Use An Entire Disk And Set Up LVM" option. So guess I actually have to use a live cd to prepare the partitions with LUKS. Thanks for the advice
– Erik van de Ven
Feb 1 at 11:15
add a comment |
Of course, you can't do it on the running system.
You need to configure your LUKS container (with cryptsetup) from the LiveCD/USB and then proceed to the installation by feeding those containers to the installer.
May be, it is better that you use a LVM install from the installer. It will automatically use LUKS/cryptsetup.
Of course, you can't do it on the running system.
You need to configure your LUKS container (with cryptsetup) from the LiveCD/USB and then proceed to the installation by feeding those containers to the installer.
May be, it is better that you use a LVM install from the installer. It will automatically use LUKS/cryptsetup.
answered Feb 1 at 9:36
solsTiCesolsTiCe
6,05932049
6,05932049
Thanks, I will try it using a live cd. In earlier versions I could choose for encrypted LVM volume, but 18.10 only shows a "Use An Entire Disk And Set Up LVM" option. So guess I actually have to use a live cd to prepare the partitions with LUKS. Thanks for the advice
– Erik van de Ven
Feb 1 at 11:15
add a comment |
Thanks, I will try it using a live cd. In earlier versions I could choose for encrypted LVM volume, but 18.10 only shows a "Use An Entire Disk And Set Up LVM" option. So guess I actually have to use a live cd to prepare the partitions with LUKS. Thanks for the advice
– Erik van de Ven
Feb 1 at 11:15
Thanks, I will try it using a live cd. In earlier versions I could choose for encrypted LVM volume, but 18.10 only shows a "Use An Entire Disk And Set Up LVM" option. So guess I actually have to use a live cd to prepare the partitions with LUKS. Thanks for the advice
– Erik van de Ven
Feb 1 at 11:15
Thanks, I will try it using a live cd. In earlier versions I could choose for encrypted LVM volume, but 18.10 only shows a "Use An Entire Disk And Set Up LVM" option. So guess I actually have to use a live cd to prepare the partitions with LUKS. Thanks for the advice
– Erik van de Ven
Feb 1 at 11:15
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1114670%2fhow-to-cryptsetup-newly-installed-ubuntu-server-18-10%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown