Skip to content
This repository has been archived by the owner on Nov 9, 2020. It is now read-only.

Volume creation: Cannot specify Datastore name when using xfs #2084

Open
Foxi352 opened this issue May 17, 2018 · 1 comment
Open

Volume creation: Cannot specify Datastore name when using xfs #2084

Foxi352 opened this issue May 17, 2018 · 1 comment
Labels

Comments

@Foxi352
Copy link

Foxi352 commented May 17, 2018

Environment:
ESXi: 6.5U2
Docker: 18.03.1-ce
Host OS: Photon OS 2.0

Specifying the target datastore by using the @ in the volume name does not work when using the xfs fstype.

Example using ext4:

root@srvdocker-admin [ ~ ]# docker volume create --driver=vsphere --name=toto@DAS-VMFS -o size=1gb  -o diskformat=thin
toto@DAS-VMFS

Everything is fine. But when using the xfs type:

root@srvdocker-admin [ ~ ]# docker volume create --driver=vsphere --name=toto@DAS-VMFS -o size=1gb  -o diskformat=thin -o fstype=xfs
Error response from daemon: create toto@DAS-VMFS: VolumeDriver.Create: Failed to create filesystem on /dev/disk/by-path/pci-0000:03:00.0-scsi-0:0:1:0: exit status 1. Output = Illegal value toto@DAS-VMFS for -L option
Usage: mkfs.xfs
/* blocksize */		[-b log=n|size=num]
/* metadata */		[-m crc=0|1,finobt=0|1,uuid=xxx]
/* data subvol */	[-d agcount=n,agsize=n,file,name=xxx,size=num,
			    (sunit=value,swidth=value|su=num,sw=num|noalign),
			    sectlog=n|sectsize=num
/* force overwrite */	[-f]
/* inode size */	[-i log=n|perblock=n|size=num,maxpct=n,attr=0|1|2,
			    projid32bit=0|1,sparse=0|1]
/* no discard */	[-K]
/* log subvol */	[-l agnum=n,internal,size=num,logdev=xxx,version=n
			    sunit=value|su=num,sectlog=n|sectsize=num,
			    lazy-count=0|1]
/* label */		[-L label (maximum 12 characters)]
/* naming */		[-n log=n|size=num,version=2|ci,ftype=0|1]
/* no-op info only */	[-N]
/* prototype file */	[-p fname]
/* quiet */		[-q]
/* realtime subvol */	[-r extsize=num,size=num,rtdev=xxx]
/* sectorsize */	[-s log=n|size=num]
/* version */		[-V]
			devicename
<devicename> is required unless -d name=xxx is given.
<num> is xxx (bytes), xxxs (sectors), xxxb (fs blocks), xxxk (xxx KiB),
      xxxm (xxx MiB), xxxg (xxx GiB), xxxt (xxx TiB) or xxxp (xxx PiB).
<value> is xxx (512 byte blocks).
@Foxi352
Copy link
Author

Foxi352 commented May 28, 2018

I am 99% sure the problem is the following xfs limitation (see above): [-L label (maximum 12 characters)]
So i propose to remove the @xxxxx part and truncate to the first 12 characters of the given name for the -L option.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

4 participants