sh: 0: getcwd() failed: No such file or directory on cited drive

CrazyKitty Rotoshi picture CrazyKitty Rotoshi · Oct 6, 2012 · Viewed 188.5k times · Source

I am trying to compile ARM code in Ubuntu 12.

Everything is working fine when I put the code in the local directory.

But when I put the code in cited mount directory error shows up:

making testXmlFiles
sh: 0: getcwd() failed: No such file or directory
ARM Compiling xxxxx.c
sh: 0: getcwd() failed: No such file or directory

Here is my setting in fstab

//10.0.0.1/data /mnt/data   cifs    auto,noserverino,credentials=/root/.smbcredentials,file_mode=0777,dir_mode=0777,uid=user,gid=users,noperm 0 0

What is going on here? What could cause this error?

Answer

Hooman picture Hooman · Feb 6, 2014

This error is usually caused by running a command from a directory that no longer exist.

Try changing your directory and re-run the command.