April 21, 20188 yr Description: AFP shares fail to mount under OS X. How to reproduce: Create a user share and make available under AFP. Attempt to connect to the share via AFP. Expected results: Share is successfully mount. Actual results: Share fails to mount. Finder shows "Connection Failed". Error logs from UnRAID cnid_dbd. Other information: I did some investigation and it looks like the cause is that cnid_dbd is failing with No such device (ENODEV) errors: Apr 21 19:13:29 UnRAID cnid_metad[19156]: Multiple attempts to start CNID db daemon for "/mnt/user/testafp" failed, wiping the slate clean... Apr 21 19:13:29 UnRAID cnid_dbd[19156]: error opening DB environment after recovery: No such device Apr 21 19:13:29 UnRAID cnid_dbd[19156]: Failed to open CNID database for volume "testafp" Apr 21 19:13:29 UnRAID cnid_dbd[19156]: Recreated CNID BerkeleyDB databases of volume "testafp" Apr 21 19:13:29 UnRAID cnid_dbd[19156]: error opening DB environment after recovery: No such device Apr 21 19:13:29 UnRAID cnid_dbd[19156]: open_db() failed: No such device Apr 21 19:13:29 UnRAID cnid_dbd[19156]: reinit_db() failed: No such device Apr 21 19:13:29 UnRAID afpd[19134]: read: Connection reset by peer Apr 21 19:13:30 UnRAID cnid_dbd[19158]: error opening DB environment after recovery: No such device Apr 21 19:13:30 UnRAID cnid_dbd[19158]: Failed to open CNID database for volume "testafp" Apr 21 19:13:30 UnRAID cnid_dbd[19158]: Recreated CNID BerkeleyDB databases of volume "testafp" Apr 21 19:13:31 UnRAID cnid_dbd[19158]: error opening DB environment after recovery: No such device Apr 21 19:13:31 UnRAID cnid_dbd[19158]: open_db() failed: No such device Apr 21 19:13:31 UnRAID cnid_dbd[19158]: reinit_db() failed: No such device Apr 21 19:13:31 UnRAID afpd[19134]: read: Connection reset by peer Apr 21 19:13:32 UnRAID afpd[19134]: read: Connection reset by peer Apr 21 19:13:33 UnRAID afpd[19134]: read: Connection reset by peer Apr 21 19:13:34 UnRAID afpd[19134]: read: Connection reset by peer Apr 21 19:13:35 UnRAID afpd[19134]: read: Connection reset by peer Apr 21 19:13:36 UnRAID afpd[19134]: read: Connection reset by peer Apr 21 19:13:36 UnRAID afpd[19134]: transmit: Request to dbd daemon (volume testafp) timed out. Apr 21 19:13:36 UnRAID afpd[19134]: afp_openvol(/mnt/user/testafp): Fatal error: Unable to get stamp value from CNID backend Apr 21 19:13:37 UnRAID afpd[19134]: dsi_stream_read: len:0, unexpected EOF Further investigation into the /mnt/user/testafp/.AppleDB/db_errlog suggests that mmap appears to be returning that error: root@UnRAID:/mnt/user/testafp/.AppleDB# tail db_errlog mmap: No such device mmap: No such device mmap: No such device Finding last valid log LSN: file: 1 offset 28 mmap: No such device mmap: No such device mmap: No such device Finding last valid log LSN: file: 1 offset 28 mmap: No such device mmap: No such device The man page for mmap claims that a return code of ENODEV means that the underlying filesystem does not support memory mapping. /mnt/user appears to be mounted on the fuse.shfs filesystem which I do not have the source code to verify whether it supports mapping files into memory. tl;dr I believe shfs does not support memory mapping causing cnid_dbd to fail which causes AFP to unable to mount the share. Attached is the diagnostics file. unraid-diagnostics-20180421-1921.zip
Archived
This topic is now archived and is closed to further replies.