On Sunday 29 August 2010 03:24:42 Nikos Chantziaras wrote: > On 08/28/2010 10:42 PM, Dale wrote: > > Alex Schuster wrote: > >> Dale writes: > >>> It would be nice if something like *fdisk could edit the labels tho. > >>> It would be so much easier. I didn't see anything in the man pages > >>> tho. > >> > >> I'd like this, too. cfdisk displays them, but is not abel to edit. > >> > >>> I looked into LVM a good while ago. It's just to much for me to keep > >>> up with since I just have a desktop system here. It has its good > >>> points but just way overkill for what I have here. > >> > >> It's not that complicated. In a nutshell: > >> > >> Choose the partitions you want to use for LVM, and prepare them to be > >> physical volumes: > >> pvcreate /dev/sda[678] > >> > >> Create a volume group out of these partitions: > >> vgcreate myvg /dev/sda[678] > >> > >> Create logical volumes in this volume group: > >> lvcreate -L 5G -n lvm1 myvg > >> lvcreate -L 2G -n lvm2 myvg > >> > >> Use these logical volumes just as disk partitions: > >> > >> mke2fs -j -L fs_on_lvm /dev/myvg/lvm1 > >> mount /dev/myg/lvm1 /mnt/fs_on_lvm > >> > >> The file system is too small? Just extend its size by 1G, without > >> unmouning: > >> > >> lvresize -L +1G /dev/myvg/lvm1 > >> > >> The volume groups is getting full, no space to add LVMs? Add other > >> partitions. If you like, even from a 2nd drive: > >> > >> pvcreate /dev/sdb5 > >> vgextend myvg /dev/sdb5 > >> > >> So, it's of course more complicated than just firing up cfdisk, create > >> partitions and file systems on them, but you have much more flexibility. > >> Once you have LVM, you do not have to care what the actual device > >> names of > >> your drives are. If sda becomes sdb and vice versa, no problem, and > >> nothing to worry about. LVM does not use the device name, it scans each > >> partition and uses the LVM UUIDs on them to identify what is what. > >> > >> Wonko > > > > Since I finally got this thing settled with partition sizes, that's > > pretty complicated. I have root, /boot, /home, portage and a data > > partition for misc. junk. I doubt it will change any in the near future. > > > > I did read up on it one time a while back. It's neat when you have to > > add drives and resize things but still a bit much for a little desktop. > > I'd stay away from LVM. I started using it on a Debian Lenny machine > and performance went down the drain. For example, deleting a 3GB file > was almost instant and now it takes like 15 seconds. It's almost as if > with LVM, deleting a file means writing 0 all over the 3GB first :-/
That sounds like a different issue. I haven't noticed any major performance issues myself. But to test quickly: LVM: # ~/speedtest $ time dd if=/dev/zero of=3gigfile bs=1024 count=3000000 3000000+0 records in 3000000+0 records out 3072000000 bytes (3.1 GB) copied, 33.3029 s, 92.2 MB/s real 0m33.305s user 0m0.440s sys 0m16.370s # ~/speedtest $ time rm 3gigfile real 0m3.827s user 0m0.000s sys 0m1.131s # hdparm -Tt /dev/sda /dev/sda: Timing cached reads: 4758 MB in 2.00 seconds = 2379.87 MB/sec Timing buffered disk reads: 274 MB in 3.02 seconds = 90.84 MB/sec ************** Non-LVM: # /data/speedtest $ time dd if=/dev/zero of=3gigfile bs=1024 count=3000000 3000000+0 records in 3000000+0 records out 3072000000 bytes (3.1 GB) copied, 38.2821 s, 80.2 MB/s real 0m38.284s user 0m0.397s sys 0m9.490s # /data/speedtest $ time rm 3gigfile real 0m0.721s user 0m0.000s sys 0m0.720s # hdparm -Tt /dev/sdb /dev/sdb: Timing cached reads: 3396 MB in 2.00 seconds = 1698.30 MB/sec Timing buffered disk reads: 252 MB in 3.00 seconds = 83.94 MB/sec Both filesystems are ext3 Based on this, it takes about 3 seconds more. That is something I can easily live with. But instantaneous to 15 seconds, I think there might be some other factors there? -- Joost