So I have an Apache 2 Ubuntu Server 18.04.3 LTS which has been working fine and now for no reason that I know the SMB share mount has stopped working. My /etc/fstab file is:

//**.*.*.***/********* /media/**** cifs credentials=/home/****/.smbcredentials,uid=www-data,gid=www-data,iocharset=utf8 0 0

And when I try to do ls /media/**** I get ls: cannot access '/media/****': Stale file handle I can't understand why this happened and I can restart the VM and also do umount and mount -a to remount it and then it works for around 10/20 minutes. This wouldn't be a problem if it was just that I couldn't list the files in the mount, but Apache2 can't do that either and therefore it can't find the .htaccess file. Thank you for your help!

  1. Can you read and see the files on the host system?
  2. Is there any unusual file name?
  3. Can you open all these files on the host system?
  4. Can you mount the samba share manually from command line?
  5. Increase the log level in smb.conf and have a look in the smbd.log, nmbd.log
|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.