suggest me how to use two disk drives...

timucin

New Member
Feb 20, 2011
12
0
1
Istanbul/Turkey
My test server now runs temporarly on production untill I setup my real server and replace that test machine.

My server is an intel barebones 1u rack server hardware with 6GB RAM and xeon 3040 CPU. I have two sata 320GB hard disks in that server and no other space to install additional disk but 320GB space is more than enough for me.

Currently, my virtual machines consumes total of only 100GB. Now, what is the proper way to use those two disks with proxmox.
I was thinking about setting up software raid mirroring, I know software raid1 is not fast but it's fast enough for my applications. When I read on the forums about software raid is not supported, I've decided to ask here about the proper way.

That server was working happly with vmware-server 2.0 with only 2GB RAM so after I add 4GB more it should be good on proxmox.

When I setup proxmox from the bare metal iso cd, it partitions the first hard disk and setups everything there. Now I have second disk (sdb) with no partitions. Now What should I do? What is the correct way of using it?
 
I've formatted the second hard disk as lvm volume and mounted by adding a fstab entry.
here is my new etc/fstab file:
server0:~# cat /etc/fstab
# <file system> <mount point> <type> <options> <dump> <pass>
/dev/pve/root / ext3 errors=remount-ro 0 1
/dev/pve/data /var/lib/vz ext3 defaults 0 1
/dev/vg-disk1/lv-disk1 /mnt/disk1 ext3 defaults 0 1
UUID=290c6dc9-d38e-40a2-a5de-7c7bd0474668 /boot ext3 defaults 0 1
/dev/pve/swap none swap sw 0 0
proc /proc proc defaults 0 0

Now I can access the disk from /mnt/disk1

Now what should I do? if I add it as storage from the proxmox web interface, I think I can put some of the virtual machine disks there.


I'm planning to use 3 or 4 VM in this machine, so if I put 2 vm on first disk and 2 to the second will it be good?
 
You DON'T have to do this, is what you read in the wiki I pointed you to or just missed it? :)
Re-read carefully the wiki url I indicated, and if you have specific problems or steps that you can't understand, feel free to ask, I will be happy to help if I can. Just repeating here what is wrote there is useless.
Once you have added the lvm additional storage as described in the wiki, when you create a new virtual machine just drop down the combo box "Disk Storage" and select the new storage (instead of "local"), so a Logical Volume will be created to contain your new VM (instead of a file in the local storage). Install the VM as usual, shut it down and edit the config file to specify "cache=none" to speed up I/O even further (search the forum).
Start putting 2 machine in one storage and 2 in the new one. In any case you can always backup from one storage, destroy, and restore in a different one, or directly use dd and some advanced skill :)
For using LVM storage a certain knowledge of LVM2 basic operation and theory is recommended, google around and read the wiki/forum.
 
I read the wiki.
When I try to make it like described in wiki, I can use the disk for KVM images but I'd like to be able to see the actual files on the filesystem, that's why I've mounted the second disk.
I think, this way, I can not use snapshot backup feature but that's ok for me now. backup with suspend works for me so no problem.
And the virtual machines do not under heavy load so I have no performance issues right now.

The reason why I did like this is I do not know much about LVM storage and I do not want to go with LVM storage way until I'm more confident with my LVM knowledge. I've googled around and read lots of documents about LVM but still I do not wanted to dive into unknown territories.
 
Sorry, but seemed you accepted my suggestion and was asking further details.
You have mixed things a bit.
If you don't want to use LVM, don't format the second HD as lvm. Partition and format as regular GNU/Linux file system ext3, mount in a dir through fstab (like you have done) and through web interface add storage as "add directory".
You could also use LVM tools and add as additional storage to the "local" volume group, obtaining a sort of "extension" of your normal storage, but you should learn lvm and you could not control in what physical HD your vm will be saved (AFAIK).
 
no, the volume is a lvm volume addes to fstab and added to proxmox storage as directory.

here is my fstab:
-------------------
server0:~# cat /etc/fstab
# <file system> <mount point> <type> <options> <dump> <pass>
/dev/pve/root / ext3 errors=remount-ro 0 1
/dev/pve/data /var/lib/vz ext3 defaults 0 1
/dev/vg-disk1/lv-disk1 /mnt/disk1 ext3 defaults 0 1
UUID=290c6dc9-d38e-40a2-a5de-7c7bd0474668 /boot ext3 defaults 0 1
/dev/pve/swap none swap sw 0 0
proc /proc proc defaults 0 0
------------


and this is the output of lvdisplay:
-------------
server0:~# lvdisplay
--- Logical volume ---
LV Name /dev/vg-disk1/lv-disk1
VG Name vg-disk1
LV UUID LK0raT-QLt8-nUQk-OIeq-bO07-TEe3-xeBIFd
LV Write Access read/write
LV Status available
# open 1
LV Size 294.08 GB
Current LE 75285
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 254:3

--- Logical volume ---
LV Name /dev/pve/swap
VG Name pve
LV UUID cpJMLj-uo7R-FmBc-2S9K-329p-4E1S-63zHLZ
LV Write Access read/write
LV Status available
# open 1
LV Size 6.00 GB
Current LE 1536
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 254:0

--- Logical volume ---
LV Name /dev/pve/root
VG Name pve
LV UUID AZrFbe-ZnJG-3wce-cf9D-3JKc-S7Bz-5U0BkW
LV Write Access read/write
LV Status available
# open 1
LV Size 30.00 GB
Current LE 7680
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 254:1

--- Logical volume ---
LV Name /dev/pve/data
VG Name pve
LV UUID mHnUct-jqGT-f8cb-dF5j-bhHJ-xP17-Pu8eIa
LV Write Access read/write
LV Status available
# open 1
LV Size 257.59 GB
Current LE 65944
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 254:2
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!