/[sysadmin-cookbook]/recepies/ganeti/migrate-lxc/3-ganeti-root-lvm.sh
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Contents of /recepies/ganeti/migrate-lxc/3-ganeti-root-lvm.sh

Parent Directory Parent Directory | Revision Log Revision Log


Revision 316 - (show annotations)
Thu Apr 24 07:26:24 2014 UTC (10 years, 1 month ago) by dpavlin
File MIME type: application/x-sh
File size: 452 byte(s)
split master and storage node, support machines with dash in name

1 #!/bin/sh -x
2
3 . ./0-host.sh
4 . ./0-ganeti.sh
5
6 ssh_storage lvcreate --size `cat $host/size` --name $host ffzgvg
7 ssh_storage lvextend --size 4G /dev/mapper/ffzgvg-$hostlv
8
9 ssh_storage parted -s /dev/mapper/ffzgvg-$hostlv 'mklabel msdos mkpart primary 0% 100% set 1 boot on'
10
11 ssh_storage mkfs.ext4 -L root /dev/mapper/ffzgvg-${hostlv}p1
12
13 ssh_storage mkdir /tmp/$host
14 ssh_storage mount /dev/mapper/ffzgvg-${hostlv}p1 /tmp/$host
15 ssh_storage df -h /tmp/$host

Properties

Name Value
svn:executable *

  ViewVC Help
Powered by ViewVC 1.1.26