Skip to content

Instantly share code, notes, and snippets.

@geopelia
Created August 6, 2013 03:27
Show Gist options
  • Save geopelia/6161768 to your computer and use it in GitHub Desktop.
Save geopelia/6161768 to your computer and use it in GitHub Desktop.
Notas Rehaciendo los usuarios del sistema y configurando canaima con lvm
cat /etc/passwd | cut -f 1 -d : >/tmp/users.list
Then edit /tmp/users.list to only contain the users you want. Then do:
for i in `cat /tmp/users.list`
do
userdel $i
useradd -m -k /etc/skel $i
done
------------------------------------------------------------------------------------------------------
Boot from the CD, install LVM and make all existing volumes active:
apt-get install lvm2
vgchange -a y
lvdisplay
Should display your volumes
apt-get install lvm2
vgchange -a y
mkdir -p /mnt/lvmroot
mount /dev/lvm/root /mnt/lvmroot
mount /dev/sda1 /mnt/lvmroot/boot
mount --bind /dev /mnt/lvmroot/dev
mount -t proc proc /mnt/lvmroot/proc
mount -t sysfs sysfs /mnt/lvmroot/sys
mount -t devpts devpts /mnt/lvmroot/dev/pts
After mounting all needed “partitions” we can chroot into it:
chroot /mnt/lvmroot
We are now in the OS that’s on the hard disk. That’s where we want to add LVM support. The initramfs will be updated automatically.
apt-get install lvm2
http://blog.tersmitten.nl/installing-linux-mint-non-alternate-on-an-lvm-volume.html
http://forums.linuxmint.com/viewtopic.php?f=42&t=108442
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment