ISO Storage on ZFS??? Possible?

Jan 23, 2021
51
18
13
Hi all,

I have a new Proxmox installation that I have setup. I have 2x 128GB Supermicro SATA DOM's that I used for the installation.

My plan was to partition them each with a 60GB and 50GB partition. Install Proxmox on two 60GB partitions as a mirror for redundancy. Then with the two 50GB partitions create a stripe for ISO storage.

Proxmox is up and running using the 60GB mirror. Using a mixture of cfisk and zpool on the command line I partitioned and created a new zpool with the two 50GB partitions as a stripe. This is online and showing up in Proxmox.

I then realised that there are limitations to what content can be stored on the various storage types and that storing ISO's on this new pool doesn't appear to be possible.

Is there any way I can make this work? Perhaps using a different method?

Thanks,

FS
 
Register the storage (your zfs pool) and make it an image/iso store. Should work.
 
Thanks.

When you say to register the storage, what exactly do you mean? The storage is showing up in Proxmox under the ZFS section for the node. I created a new directory on it but ISO images wasn't an option.
 
Go to "DataCenter" (Left side) -> choose "Storage" (on the right side).
You there can add storage sources (abstraction layer) and define those as "Disk Image", "Container" or "ISO-Image".
Choose ISO-Image for the ZFS Pool you have created.
 
Sorry. This doesn't seem to be possible for ZFS? Unless I'm missing something. DataCentre -> Storage is where I created the storage. But when you select it as ZFS storage, the option for IOS images is not there.

Looking at the docs I think what I'm trying to do is not possible but I may be wrong.

Screenshot 2021-01-24 at 01.32.38.png

FS
 
Last edited:
Wondering whether to bin the whole idea off. I was just thinking of trying to get the better R/W performance of a stripe for storing the ISO's where redundancy isn't really a big concern.

If I can't do that then I may as well re-install Proxmox and use the full amount of space (or near to) on each SATA DOM in a mirror.

Any further advice would be greatly appreciated as this is pretty much a clean install at the moment with no other configuration so dumping it wouldn't be an issue. I'm holding off on doing any further configuration at the minute.
 
I am having iso-store on my raidz3 - so it should be possible.
Perhaps though I did not look close enough and you need to provide the "directory" option and point the path to your mounted zpool.
Please remember that zfs is a filesystem so you should see it mounted with its pool name (typically).
 
  • Like
Reactions: Kingneutron
Of course. Thank you!

When I created the zpool on the command line I mounted it at /mnt/storage.

I've now created a dataset at storage/iso and then in DataCentre -> Storage added that location as a Directory which can contain ISO’s.

I've uploaded a couple of ISO images to it and it seems to be working.

Thanks again.
 
  • Like
Reactions: Kingneutron
Hi, I have the same problem.

I have created a zfs raidz and it's online and appear to be mounted -->

Code:
root@pm:/RaidZ# zpool status
  pool: RaidZ
 state: ONLINE
config:

        NAME        STATE     READ WRITE CKSUM
        RaidZ       ONLINE       0     0     0
          raidz1-0  ONLINE       0     0     0
            sda2    ONLINE       0     0     0
            sdb2    ONLINE       0     0     0
            sdd2    ONLINE       0     0     0

root@pm:~# zfs list
NAME    USED  AVAIL     REFER  MOUNTPOINT
RaidZ   735K  3.52T      128K  /RaidZ

but as experienced @fsociety3765 I can't set it for ISO upload :/

damn.png

how can I add ISO too ? Thanks.
 
You need to create a dataset on that pool (for example zfs create RaidZ/Iso), then create a Directroy storage at "Datacenter -> Storage -> Add -> Directory" pointing to the mountpoint of that dataset (I think it should be automounted at "/RaidZ/Iso") with content-type set to iso. Then you will have to run pvesm set StorageIdOfYourDirectoryStorage --is_mountpoint yes.
 
Last edited:
You need to create a dataset on that pool (for example zfs create RaidZ/Iso), then create a Directroy storage at "Datacenter -> Storage -> Add -> Directory" pointing to the mountpoint of that dataset (I think it should be automounted at "/RaidZ/Iso") with content-type set to iso. Then you will have to run pvesm set StorageIdOfYourDirectoryStorage --is_mountpoint yes.

Thank you @Dunuin , will experimenting I fall on the way to achieving this :)

But I don't understand very well what does
zfs create RaidZ/ISO

because when I do
Code:
root@pm:~# zfs list
NAME        USED  AVAIL     REFER  MOUNTPOINT
RaidZ       890K  3.52T      139K  /RaidZ
RaidZ/ISO   128K  3.52T      128K  /RaidZ/ISO

/RaidZ & RaidZ/ISO have the same AVAIL size !?

can we create a dataset with lower size than the full size of the ~pool ?
 
Thank you @Dunuin , will experimenting I fall on the way to achieving this :)

But I don't understand very well what does
zfs create RaidZ/ISO

because when I do
Code:
root@pm:~# zfs list
NAME        USED  AVAIL     REFER  MOUNTPOINT
RaidZ       890K  3.52T      139K  /RaidZ
RaidZ/ISO   128K  3.52T      128K  /RaidZ/ISO

/RaidZ & RaidZ/ISO have the same AVAIL size !?

can we create a dataset with lower size than the full size of the ~pool ?
ZFS is thin-provisioned and all datasets and zvols can share the full space.
You could limit the size of a dataset by setting a quota. For example zfs set quota=50G RaidZ/ISO if you want that RaidZ/ISO could only store max 50GB of data.

Also, keep in mind that a ZFS pool should always have 20% of free space. I would highly recommend you also set a pool wide quota of something like 90% so you can't fill up the entire pool by accident. So something like zfs set quota=3.168T RaidZ and then monitor your pool and make sure to delete stuff when it exceeds 2.8TB.
 
Last edited:
  • Like
Reactions: SpongeB0B
Thank @Dunuin

So I recreated this dataset like this
zfs create -o compression=on -o quota=10G -v RaidZ/ISO
it work great !

...and then monitor your pool and make sure to delete stuff when it exceeds 2.8TB.

I'm not there yet... but I gues I can monitor the size used with ZED daemon ?
 
Not sure if zed can also monitor the used space. But I guess that should be possible. But for zed to be able to send emails you would also need to setup postfix first.
I personally use zabbix to monitor my ZFS pools.
 
...Then you will have to run pvesm set StorageIdOfYourDirectoryStorage --is_mountpoint yes.

Code:
root@pm:~# pvesm set ISOonRaidZ --is_mounpoint yes
Unknown option: is_mounpoint
400 unable to parse option
pvesm set <storage> [OPTIONS]
:confused:
 
Can I use default mountpoint for ZFS storage to use as directory ? (it is /RaidZ in example from above)
I do not want to create `zfs create RaidZ/ISO`. I want to create directory storage on /RaidZ.
 
Can I use default mountpoint for ZFS storage to use as directory ? (it is /RaidZ in example from above)
I do not want to create `zfs create RaidZ/ISO`. I want to create directory storage on /RaidZ.
You can do whatever you want, yet you need to live with the consequences.
 
I want to create directory storage on /RaidZ.
I believe from a snapshot/backup point of view, its a better strategy to create separate datasets in zpool for different storage/project strategies. I don't personally use ZFS at all, so someone correct me if I'm mistaken here.
 
  • Like
Reactions: Kingneutron

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!