[mythtv-users] Re: /video XFS need new HD
lunchtimelarry at gmail.com
Wed Sep 28 00:32:12 UTC 2005
Let's reinforce what was said previously in this thread:
If you don't have lvm and want to convert to one the easies way is to
add the new drive as first phisical volume of lvm, create a single
logical volume on top of that, format it using xfs and then copy files
over from the old partition/disk. When everything is on the new drive
- add the old drive/partition as next phisical volume and then extend
the logical one to span across both drives.
This is exactly how I did mine. My mythtv was initally set up using 150GB
xfs partition /dev/hda4 mounted as /video. Purchased 300GB drive to expand
the storage. Linux Volume Manager (LVM) will hook these 2 together as one.
Here are the steps I went thru, more or less.
1. Ran fdisk to create an LVM partition on the new 300GB drive
2. Created physical volume: pvcreate /dev/hdc1
3. Created volume group: vgcreate vg
4. Created logical volume: lvcreate /vg/video
5. Created xfs file system /dev/vg/video (mkfs.xfs /dev/vg/video)
6. Mounted /dev/vg/video as /video2 via /etc/fstab (also, ad-hoc by mount -t
xfs /dev/vg/video /video2)
Copied all video files from /video to /video2 and pointed mythtv to /video2.
Now, /video is unused and /video2 is the mythtv video storage location. The
next steps reformat the original storage and add it to the volume group:
1. Using fdisk, deleted /dev/hda4 partition
2. Using fdisk, created /dev/hda4 as LVM
3. Created physical volume: pvcreate /dev/hda4
4. Extended volume group: vgextend vg /dev/hda4
5. Ran vgdisplay to see amount of free space that needs to be extended
(18214 in my case)
6. unmount the volume group: umount /dev/vg/video
7. extend: lvextend -l +18214 /dev/vg/video
8. mount /dev/vg/video
9. grow the xfs file system: xfs_grow /dev/vg/video
10. Remove /video from /etc/fstab
Now, df -k shows the new space:
[root at mythtv ~]# df -k
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/hda2 10080520 2938120 6630332 31% /
/dev/hda1 101086 16752 79115 18% /boot
none 257908 0 257908 0% /dev/shm
/dev/mapper/vg-video 442105856 113816336 328289520 26% /video2
The knoppmyth wiki cited in this thread is pretty helpful, altho it deviates
a bit since it is talking ext3, not xfs. I had to adapt.
On 8/8/05, jacko <emailgeek at gmail.com> wrote:
> On 8/8/05, jacko <emailgeek at gmail.com> wrote:
> > On 8/7/05, jacko <emailgeek at gmail.com> wrote:
> > > I have come to a point where I am running out of space on my /dev/hda
> > > due to the amount of video I have recorded (only 80 gigs). I would
> > > like to add a new 160g HD to my system but lack the know how to add a
> > > disk to an XFS partition in FC2. I found a good tutorial for FC3 off
> > > of Jarod's site. Should this be the same FC2? If so, can someone
> > > explain what VolGroup00 is when using vgextend?
> > >
> > > http://svn.wilsonet.com/projects/mythtvology/ticket/87
> > >
> > > Thanks in advance...
> > >
> > My partition setup is as follows just as Jarod suggested:
> > Partition Mount Point Size Format
> > /dev/hda1 /boot 50-100MB ext3
> > /dev/hda2 swap 512MB swap
> > /dev/hda3 / 8-12GB ext3
> > /dev/hda5 /video Everything else xfs
> > So would add a volume group for hda5 and then extend it? Sorry,
> > totally confused after reading last link and where it talks about
> > using ext3.
> tried to do a 'vgcreate mythvideo /dev/hda5' and I get the following
> No physical volume label read from /dev/hda5
> /dev/hda5 not identified as an existing physical volume
> Unable to add physical volume '/dev/hda5' to volume group 'mythvideo'.
> mythtv-users mailing list
> mythtv-users at mythtv.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the mythtv-users