You are not logged in.
I don't want to reinstall and I believe I messed up my HOOKS
The entire steps I did were
sgdisk -Z /dev/sda
sgdisk -a 2048 -o /dev/sda
gdisk /dev/sda
n
<enter>
+512M
EF00
c
boot
n
1
<enter>
<enter>
<enter>
c
2
root
w
mkfs.vfat -F32 /dev/sda1
cryptsetup --cipher aes-xts-plain64 --key-size 512 --hash sha512 --iter-time 5000 --use-random --verify-passphrase luksFormat /dev/sda2
cryptsetup luksOpen --allow-discards /dev/sda2 lvm
pvcreate /dev/mapper/lvm
vgcreate vg /dev/mapper/lvm
lvcreate -L 16G -n swap
lvcreate -L 10G -n root
lvcreate -L 50G -n home
lvcreate -L 20G -n usr
lvcreate -L 20G -n opt
lvcreate -L 20G -n var
lvcreate -L 20G -n tmp
mkfs.ext4 -L root /dev/mapper/vg-root
mkfs.ext4 -L home /dev/mapper/vg-home
mkfs.ext4 -L usr /dev/mapper/vg-usr
mkfs.ext4 -L opt /dev/mapper/vg-opt
mkfs.ext4 -L var /dev/mapper/vg-var
mkfs.ext4 -L tmp /dev/mapper/vg-tmp
mkswap -L swap /dev/mapper/vg-swap
swapon -d /dev/mapper/vg-swap
mount /dev/mapper/vg-root /mnt
mkdir -p /mnt/boot/efi
mount /dev/sda1 /mnt/boot/efi
mkdir /mnt/home
mkdir /mnt/usr
mkdir /mnt/opt
mkdir /mnt/var
mkdir /mnt/tmp
mount /dev/mapper/vg-home /mnt/home
mount /dev/mapper/vg-usr /mnt/usr
mount /dev/mapper/vg-opt /mnt/opt
mount /dev/mapper/vg-var /mnt/var
mount /dev/mapper/vg-tmp /mnt/tmp
pacstrap -i /mnt base base-devel bash-completion vim
genfstab -U -p /mnt >> /mnt/etc/fstab
nano /mnt/etc/fstab
ON THE usr Partition, set passno to 0
ON THE swap partition, change default to default,discard
arch-chroot /mnt
nano /etc/mkinitcpio.conf
add modules vfat ext4 dm_mod dm_crypt aes_x86_64 crc32c-intel
hook string = base udev block autodetect modconf encrypt lvm2 resume filesystems keyboard usr fsk shutdown
nano /etc/lvm/lvm.conf
issue_discards 1
use_lvmetad 0
pacman -S grub efibootmgr
nano /etc/default/grub
ADD ON 2nd line GRUB_ENABLE_CRYPTODISK=y
MAKE GRUB_CMDLINE_LINUX="cryptdevice=/dev/sda1:lvm:allow-discards resume=/dev/mapper/vg-swap"
grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=grub --recheck
mkinitcpio -p linux
quit
reboot
And then I'm getting the error in the picture after I input my passkey.
When I input my passkey I choose arch and then I need to input my passkey again and then it can not find root device.
So I want to change some of my hooks around and see if that helps.
http://i.imgur.com/X3Uauzp.jpg is the error message I receive.
EDIT I wrote my cryptdevice wrong in mkinitcpio.conf, so it might not be the hooks string. Still how do I fix this?
Last edited by CjStaal (2015-06-06 19:42:38)
Offline
Load the Arch live ISO, mount your partitions, use `arch-chroot`, edit /etc/mkinitcpio, run `mknitcpio -p linux` and profit!
Also, use code tags when posting terminal output.
Jin, Jîyan, Azadî
Offline
Load the Arch live ISO, mount your partitions, use `arch-chroot`, edit /etc/mkinitcpio, run `mknitcpio -p linux` and profit!
Also, use code tags when posting terminal output.
I reinstalled, I used
base udev autodetect block modconf encrypt lvm2 resume filesystems keyboard usr fsk shutdown
and GRUB_CMDLINE_LINUX="cryptdevice=/dev/sda2:lvm:allow-discards resume=/dev/mapper/vg-swap"
and now I'm getting "Enter passphrase for HD0,gpt2
error: no such cryptodisk found
Ugh... This is such a headache. But it will be worth it.
EDIT: It was wrong password. Now I"m getting
error: no such device: <UUID>
Loading Linux core repo kernel...
error: no such partition
loading initial ramdisk ...
alloc magis is broken at 0xb66218c0: b673f3c0
Aborted. Press any key to exit.EDIT 2: When remounting, do I need to mkdir all of them again first?
EDIT 3: Since I'm using LVM, I changed use_lvmetad to 1.
Now when I'm trying to install grub I get
FIle descriptor 4 (/dev/sda1) leaked on vgs....
warning failed to connect etc
x2
install finished ...."/dev/sda1 is NOT an LVM. It is my boot partition [using GPT]
Is this fine?
EDIT: So I redid the HOOKS and the GRUB_LINUX_CMDLINE and still receiving that erro message of no such device.
EDIT: SOLVED! I FORGOT TO grub-mkconfig -o /boot/grub/grub.cfg WHEN I WAS DONE MAKING THE CHANGES!
Last edited by CjStaal (2015-06-06 19:42:25)
Offline