mount.ceph fails with ERANGE if name= option is longer than 37 characters
Aaron reported on the cephfs mailing list that some mount attempts were failing with ERANGE. For example:
# mount.ceph :/ /mnt/cephfs -o name=user-20c5338c-34db-11ea-b27a-de7033e90,secret=AQC6dhpeyczkDxAAhRcr7oERUY4BcD2NCUkuNg==
Trimming the name down to 37 characters allows it to work. The problem is the SECRET_OPTIONS_LEN constant is too small for long usernames.
#4 Updated by Jeff Layton 6 months ago
It turns out that name= options can pretty much be arbitrarily long, so I reworked the code to remove the need for an artificial limit there. It should do the right thing for any name= option. Note that the mount() syscall has a 1 page limit for options so if you try to give it too long a name it's going to fail anyway.