Problem adding an extra local storage in VE 5.2

lucentsound

New Member
Sep 20, 2018
6
0
1
59

Hi All,
i’m a newbie about Proxmox and i ask you for an help about the starting configuration.

I installed VE 5.2 on one HDD of a Server so SDA is the drive where Proxmox installation is running.

Then i add a second HDD locally on the same Server for storage purposes, SDB, and followed these commands i found on a blog:

fdisk –l (to see the name of new drive)

cfdisk /dev/sdb

and create new, primary, partition.

Then

pvcreate /dev/sdb1

Created a volume group for example "Data-Storage"

vgcreate Data-Storage /dev/sdb1


Then Added the storage in ProxMox webinterface



- clicked on tab Storage.

- clicked Add – LVM Group

- typed an ID Name Data-Storage

- Base Storage: Existing Volume Groups

- Volume Group: Data-Storage



- Enabled: Checked

Now the problem is that under menu : pve – Data Storage (pve) – Content i can’t upload any image cause the button is gray.

I added some screenshoot.

I know the question is stupid but please help me to under stand the mistake.

Thanks to all in advance.
 

Attachments

  • Fdisk.jpg
    Fdisk.jpg
    226.9 KB · Views: 5
  • Fdisk2.jpg
    Fdisk2.jpg
    225.4 KB · Views: 4
  • Data-storage.jpg
    Data-storage.jpg
    74.2 KB · Views: 6
  • Data-storage 2.jpg
    Data-storage 2.jpg
    115.6 KB · Views: 6
Are you trying to upload ISO images? LVM is a block level storage. I dont believe you can store any ISO or LXC templates on block storage. You should mount the drive in a directory and add it to Pmx as Local storage instead of LVM. You can still have LVM on the actual drive, just need to mount it.
 
Yes Ahmed, i would like to use this second disk to upload ISO and also to contain virtual machine. Can you indicate me the steps i should make to reconfigure the disk? Thank you
 
The process is very simple. You do not need to reconfigure the drive itself.

This needs to be done from Command line:
1. Create an empty directory with any name. For example,
# mkdir /mnt/lvmdata

2. Run the command lvdisplay to get the exact name of the LVM you created. It should be in the following format:
/dev/volume_group_name/logical_volume_name

3. Add the following line into /etc/fstab so the node mounts the directory automatically after a reboot. I am assuming you used ext4 as to create filesystem.
/dev/mapper/logival_volume_name /mnt/lvmdata ext4 defaults 0 0

This needs to be done from GUI:
4. Goto Datacenter > Storage > Add > Directory

5. In the directory box type in: /mnt/lvmdata and click Add

Now you can select any Content type.
 
Hi, thank you very much for your precious support.
As you suggested me i investigated first the LVM i created and there is something i don't understand.
If i run the command pvscan i get:

root@pve:/# pvscan
PV /dev/sdb1 VG Data-Storage lvm2 [278.87 GiB / 278.87 GiB free]
PV /dev/sda3 VG pve lvm2 [135.87 GiB / 16.00 GiB free]
Total: 2 [414.74 GiB] / in use: 2 [414.74 GiB] / in no VG: 0 [0 ]
root@pve:/#

So it seams to me i created a volume group named "Data-Storage" on a physical volume /dev/sdb1 of 278.87 GiB free ( the new disk i added is a 300 Gib)

But if i run the command lvdisplay i get:

root@pve:/# lvdisplay
--- Logical volume ---
LV Path /dev/pve/swap
LV Name swap
VG Name pve
LV UUID PUaRIy-oSc5-iKZl-VprO-RM8r-eQWp-yRnFbu
LV Write Access read/write
LV Creation host, time proxmox, 2018-09-18 18:52:46 +0200
LV Status available
# open 2
LV Size 8.00 GiB
Current LE 2048
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 253:0

--- Logical volume ---
LV Path /dev/pve/root
LV Name root
VG Name pve
LV UUID AuW3xq-7Ori-aWIo-3BES-DO3d-igtW-C9MzmA
LV Write Access read/write
LV Creation host, time proxmox, 2018-09-18 18:52:46 +0200
LV Status available
# open 1
LV Size 33.75 GiB
Current LE 8640
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 253:1

--- Logical volume ---
LV Name data
VG Name pve
LV UUID dofs9N-QP3C-RmoJ-zQzI-FtEs-jYzv-q7T1hd
LV Write Access read/write
LV Creation host, time proxmox, 2018-09-18 18:52:47 +0200
LV Pool metadata data_tmeta
LV Pool data data_tdata
LV Status available
# open 0
LV Size 76.12 GiB
Allocated pool data 0.00%
Allocated metadata 0.04%
Current LE 19487
Segments 1
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 253:4

So, it seams i can't see the 278.87 GiB free that hoped to create. Where am i wrong?
 

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!