RESOLVED: getcwd cannot access parent directories after file server rebuild
Posted: 2017/09/13 19:40:02
Long story short: our file server died, and we fixed it by taking the drives out of the dead machine and putting them into a good machine, which became our new file server. We had to change the MAC addresses in the network interface files, but after that it seemed to work. The only problem now is that we are getting odd error messages about "getcwd". For instance, when we open a new xterm we get the errors
Also, the same problem appears when we try to run a shell, but only on automounted directories:
As another example, when we run a shell script that connects to another system with ssh, we see "job-working-directory: error retrieving..."
Does anyone have any idea what might have caused this? When I searched for that error message online, all the responses referred to a directory no longer existing, which isn't the case here. If it matters, we're running OpenLDAP for our automap mount points. Thanks in advance for all responses.
Code: Select all
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
chdir: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
Code: Select all
/home/jdoe$ /bin/ls -l
total 120
drwxr-xr-x. 2 jdoe users 4096 Sep 5 10:37 bin
drwxr-xr-x. 2 jdoe users 4096 Sep 13 09:36 etc
drwxr-xr-x. 2 jdoe users 4096 Sep 13 10:18 logs
...
/home/jdoe$ /bin/sh -c "/bin/ls -l"
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
total 120
drwxr-xr-x. 2 jdoe users 4096 Sep 5 10:37 bin
drwxr-xr-x. 2 jdoe users 4096 Sep 13 09:36 etc
drwxr-xr-x. 2 jdoe users 4096 Sep 13 10:18 logs
...
/home/jdoe$ cd /
/$ /bin/ls -l
total 113
dr-xr-xr-x. 2 root root 4096 Aug 25 03:12 bin
dr-xr-xr-x. 5 root root 4096 Sep 13 04:04 boot
drwxr-xr-x. 19 root root 3880 Sep 5 08:53 dev
...
/$ /bin/sh -c "/bin/ls -l"
total 113
dr-xr-xr-x. 2 root root 4096 Aug 25 03:12 bin
dr-xr-xr-x. 5 root root 4096 Sep 13 04:04 boot
drwxr-xr-x. 19 root root 3880 Sep 5 08:53 dev
Does anyone have any idea what might have caused this? When I searched for that error message online, all the responses referred to a directory no longer existing, which isn't the case here. If it matters, we're running OpenLDAP for our automap mount points. Thanks in advance for all responses.