Solved Cannot use nullfs


I am trying to add nullfs(5) to fstab in order to mount a zfs dataset insite a jail but I get the following error message:
mount_nullfs -o rw /iocage/jails/dbb40c5a-cdd8-11e5-99af-f04da20055fe/root/usr/local/www/production/httpdocs /iocage/jails/ff9c18b2-e4a1-11e5-b3ca-f04da20055fe/root/home/mydomain/production
mount_nullfs: /iocage/jails/ff9c18b2-e4a1-11e5-b3ca-f04da20055fe/root/home/mydomain/production: File name too long
Looking on google its a bug that exist since FreeBSD 5 that has never been fixed.
My question is: Has anyone managed to get a workaround this problem or sugest another way to mount the files system?

The aim is to mount my www directory to my ftp jail

Thank you
Shuffle it around a bit:
mkdir /httpdocs /mydomain
mount -t nullfs /iocage/jails/dbb40c5a-cdd8-11e5-99af-f04da20055fe/root /httpdocs
mount -t nullfs /iocage/jails/ff9c18b2-e4a1-11e5-b3ca-f04da20055fe/root /mydomain
mount -t nullfs /httpdocs/root/usr/local/www/production/httpdocs /mydomain/home/mydomain/production
Hi tobik
I tried the sugestion but for some reason it cannot see the last /httpdocs directory when running
mount -t nullfs /httpdocs/root/usr/local/www/production/httpdocs
mount -t nullfs /httpdocs/root/usr/local/www/production/httpdocs /mydomain/home/mydomain/production
Hmm, it's a copy and paste error on my part. /httpdocs/root/usr/local/www/production/httpdocs is wrong in my post above. Should be just /httpdocs/usr/local/www/production/httpdocs.
sysutils/iocage proposes a workaround with what they call the hack88 property. You should give it a try and see if it solves your problem. Once you activate this property the mount point of the jail is much shorter. On my system, it looks like this :
% sudo iocage get mountpoint social