Re: Installer: problem installing onto LVM on RAID1

2017-04-09 Thread Lisi Reisz
On Sunday 09 April 2017 18:43:32 Ron Leach wrote:
> While trying to install Debian 7.11

Why are you installing Wheezy?

Lisi



Re: Installer: problem installing onto LVM on RAID1

2017-04-09 Thread Georgi Naplatanov
On 04/09/2017 08:43 PM, Ron Leach wrote:
> List, good evening,
> 
> I am trying to install Debian onto an LVM, and I want the LVM to use a
> pair of disks in a RAID1 configuration.  I'm having difficulty
> instructing the partitioner to do this.
> 
> I have a new, empty, machine with 2 x 3TB disks.  This new machine is
> intended to replace our existing users-files server, which has nearly
> exhausted its current fit of RAID1 on 2 x 2TB disks.  (The server of the
> files uses samba and NFS.)  Some time ago I received advice from the
> raid list that in future I could consider using an LVM so that when an
> existing volume is full it (if it is an LV) can be extended across
> additional disks.  Now that our existing system has reached its capacity
> limit, I'd like to replace it - and also take that advice.
> 
> While trying to install Debian 7.11/amd64 onto the new HW, I reach the
> partitioner and can (first) set up a single md (md0) RAID1 over the 2 x
> 3TB disks.  Next I can set up an LVM physical volume (3TB), and I can
> then set up a 3TB logical volume for '/'.  (I think I'm happy with the
> system, /home, and the general 'users-files' filesystem all sharing the
> one logical volume - similar to how a simple basic Debian install can be
> done on a whole disk.)
> 
> But the installer complains because I don't have any swap - and (in
> addition) I am unsure if I need to do something different for GRUB and
> booting.  I first tried using the 'guided' partitioner (I thought it
> might 'know best' about needing boot and / and so on) but I didn't seem
> to be able to ask it to use RAID *and* LVM.  I could ask it to make a
> RAID1, or an LVM.  May I ask the list a couple of questions?

Hi Ron.

> What partitions - I think I mean logical volumes - might I be best using
> for my installation, keeping in mind that I will need to extend whatever
> logical volume houses the 'users-files'?

Yes, it will be better LVM to be used in your case.
The hierarchy in LVM is:
 - physical volume - this can be a disk, RAID array or partition
 - volume group - this contains one or more physical volumes. In the
future you can add new physical volumes to volume group.
 - logical volume - this contains file system and files and belongs to
particular volume group.

> Is using a whole-disk RAID1 a reasonable choice (the kernel raid wiki
> suggests this will work) or would folks on the list recommend
> configuring multiple mds?

I don't know any downside of using one MD device.

If I was you I would do the following:
 - use GPT partition table for both disks
 - create one partition on each drive for Grub second stage image and
make it big enough. For EFI systems I read that the partition should be
about ~256MB, but if they are bigger that won't hurt, mine are 1GB.
 - create RAID partition on each disk and build one big RAID 1 array (a
MD device)
 - on top of this RAID 1 array create a physical volume
 - create a volume group and add the physical volume to it
 - create logical volumes for the system like you usually do. For
example some people create different file systems for:

/,
/home,
/usr,
/var, etc.

 - create a logical volume for your file server content
 - install the OS.

By the way I have not used LVM on Debian, but I believe that Linux LVM
HOWTO can be your friend.

HTH

Kind regards
Georgi



Re: Installer: problem installing onto LVM on RAID1

2017-04-09 Thread Andy Smith
Hi Ron,

On Sun, Apr 09, 2017 at 06:43:32PM +0100, Ron Leach wrote:
> What partitions - I think I mean logical volumes - might I be best
> using for my installation, keeping in mind that I will need to extend
> whatever logical volume houses the 'users-files'?

I think you are making a conceptual error in using the entirety of
your 3TB volume group as a single logical volume (LV) for the root
filesystem.

One of the points of using LVM is that you can resize things later
when you discover more about where the scarcity lies. By allocating
the whole lot on day one, you are forcing yourself into potentially
having to shrink it again later when you want to change something.

If I were you, I'd create several LVs for important filesystems but
start them off pretty small. When they start to get full you can
grow them online.

These days you can have /boot on LVM (or have /boot as part of / and
have that on LVM) and GRUB has no problem booting from it.
Personally, I am old-fashioned; I like booting and the root
filesystem to be simple, so I put /boot and / on separate MD arrays
outside of LVM.

I then have small LVs for interesting filesystems like /var,
/home, /usr/share and application-specific things that I put under
/srv.

Also you can do swap on an LV but as I never need to resize swap, it
is another thing that I tend to keep outside of LVM for simplicity.

> Is using a whole-disk RAID1 a reasonable choice (the kernel raid wiki
> suggests this will work) or would folks on the list recommend
> configuring multiple mds?

Plenty of people would put everything inside one md RAID-1, it is
just personal preference.

The main thing that I think you are doing wrong is fully-allocating
all your volume group on day one, instead of keeping it unallocated
until it is needed.

Cheers,
Andy

-- 
https://bitfolk.com/ -- No-nonsense VPS hosting



Installer: problem installing onto LVM on RAID1

2017-04-09 Thread Ron Leach

List, good evening,

I am trying to install Debian onto an LVM, and I want the LVM to use a 
pair of disks in a RAID1 configuration.  I'm having difficulty 
instructing the partitioner to do this.


I have a new, empty, machine with 2 x 3TB disks.  This new machine is 
intended to replace our existing users-files server, which has nearly 
exhausted its current fit of RAID1 on 2 x 2TB disks.  (The server of 
the files uses samba and NFS.)  Some time ago I received advice from 
the raid list that in future I could consider using an LVM so that 
when an existing volume is full it (if it is an LV) can be extended 
across additional disks.  Now that our existing system has reached its 
capacity limit, I'd like to replace it - and also take that advice.


While trying to install Debian 7.11/amd64 onto the new HW, I reach the 
partitioner and can (first) set up a single md (md0) RAID1 over the 2 
x 3TB disks.  Next I can set up an LVM physical volume (3TB), and I 
can then set up a 3TB logical volume for '/'.  (I think I'm happy with 
the system, /home, and the general 'users-files' filesystem all 
sharing the one logical volume - similar to how a simple basic Debian 
install can be done on a whole disk.)


But the installer complains because I don't have any swap - and (in 
addition) I am unsure if I need to do something different for GRUB and 
booting.  I first tried using the 'guided' partitioner (I thought it 
might 'know best' about needing boot and / and so on) but I didn't 
seem to be able to ask it to use RAID *and* LVM.  I could ask it to 
make a RAID1, or an LVM.  May I ask the list a couple of questions?


What partitions - I think I mean logical volumes - might I be best 
using for my installation, keeping in mind that I will need to extend 
whatever logical volume houses the 'users-files'?


Is using a whole-disk RAID1 a reasonable choice (the kernel raid wiki 
suggests this will work) or would folks on the list recommend 
configuring multiple mds?


I would be grateful for any guidance,

regards, Ron