[pve-devel] run_command and shellquote

Dietmar Maurer dietmar at proxmox.com
Mon Nov 3 06:00:59 CET 2014


> but due to run_command applies shellquote which will apply quotes to the
> param refreservation=4g because of '=' to the command the command ends up
> like this:
> /usr/bin/ssh -o 'BatchMode=yes'
> -i /etc/pve/priv/zfs/192.168.3.145_id_rsa root at 192.168.3.145 zfs set
> 'refreservation=4g' tank/vm-100-disk-1
> 
> which causes it to fail.
> 
> Any way to prevent shellquote to apply qoutes to refreservation=4g ?

Why does shell quoting make the command fail? I thought shell quoting should not have any effect on
how the command receives parameters?




More information about the pve-devel mailing list