pct man page incorrect?

ml1941

Member
May 12, 2017
14
0
21
44
I am running proxmox-ve: 4.4-87 and need to create containers from the CLI.

when I do "man pct" the format of the rootfs command is:

-rootfs [volume=]<volume> [,acl=<1|0>] [,quota=<1|0>] [,ro=<1|0>] [,shared=<1|0>] [,size=<DiskSize>]​

However, when I ran a pct create with the following rootfs option:

-rootfs volume=local-lvm,size=40​

I get the following:

unable to parse volume ID 'local-lvm'​

If I change that to the following, then everything works:

-rootfs volume=local-lvm:40​

What is the difference between the two formats and does the man page need to be updated?

Also found some other confusing issues with the man page... whose attention should I bring those to?
 
that is a long standing source of confusion. the "size" property is read-only and informative (i.e., it tells you how big the disk is). the syntax "storageid:sizeingb" is a special short cut syntax which triggers an allocate action automatically, and replaces the sizeingb with the resulting volume id. this is handy when creating/restoring a guest or adding a new mount point/disk to it, because you only need one command/API call instead of two. unfortunately, it does not really fit into the way we generate our documentation (at the moment), so it is rather under-documented..
 
Thank you Fabian. Would be great to improve the docs as I spent too long trying to get it to work before trying the other shortcut syntax that I found on the web.

The two other more minor issues I found with the pct create man page were:
  • it is not clear that you can specify "dhcp" in the -net[n] ip=<ipaddr> parameter
  • I initially thought -ssh-public-keys took the key itself as a parameter (properly quoted, of course) but it takes a file instead. So, a description like "File containing ssh keys to set up for the root user" would be better.
 
Thank you Fabian. Would be great to improve the docs as I spent too long trying to get it to work before trying the other shortcut syntax that I found on the web.

I just sent a patch adding a note to the long documentation.

The two other more minor issues I found with the pct create man page were:
  • it is not clear that you can specify "dhcp" in the -net[n] ip=<ipaddr> parameter

also sent patches for this

  • I initially thought -ssh-public-keys took the key itself as a parameter (properly quoted, of course) but it takes a file instead. So, a description like "File containing ssh keys to set up for the root user" would be better.

that was actually already fixed, but got broken and nobody noticed ;) sent a patch unbreaking it as well.

thanks for taking the time to give this feedback - developers tend to get a bit "documentation blind"..
 

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!