Stumbled across this error as I try to run NPM on my docker container.
FATAL EISDIR: illegal operation on a directory, read 19:05:13
at Object.readSync (node:fs:723:3)
at tryReadSync (node:fs:433:20)
at Object.readFileSync (node:fs:479:19)
at loadEnv (node_modules/#nuxt/config/dist/config.js:1152:78)
at Object.loadNuxtConfig (node_modules/#nuxt/config/dist/config.js:1070:15)
at loadNuxtConfig (node_modules/#nuxt/cli/dist/cli-index.js:338:32)
at NuxtCommand.getNuxtConfig (node_modules/#nuxt/cli/dist/cli-index.js:463:26)
at Object.run (node_modules/#nuxt/cli/dist/cli-start.js:115:30)
at NuxtCommand.run (node_modules/#nuxt/cli/dist/cli-index.js:413:22)
So in my case npm install worked just fine....when you try to run
the app with npm run start your greeted with the above error.
What it was not:
File permission issue - was running command as root
.npmrc in the same directory or user directory issue
Solution
Add all your python virtual environment folders to .dockerignore in my case i wasn't even copying the virtual environment folder to my docker container. Its existence is what caused the issue.
Example
.dockerignore
/api/.env
Its weird and I don't know why this is happening...but i spent days trying to figure out why my build worked on deployment but wouldn't work locally - python virtual environments are ignored during deployment so they were never there during cloud build thats why it worked.
Here is more resource regarding the issue however these did not work for me:
https://github.com/yarnpkg/yarn/issues/4336
NPM stuck giving the same error EISDIR: Illegal operation on a directory, read at error (native)
When I try to run my gitlab-ci.yml, I got this error ?
Has anyone have any idea?
Thank you
The Error: mkdir command fails.
mkdir is a Linux/iOS command that creates a new directory.
When it throws the error:
Permission denied
it tells that the user running that command (the user executing the script or running the process) has no rights to create a directory in
/Users/nawinpoolsawad/builds/pxKER6-V/0/bitnance-exchange/exchange-ios.tmp
To fix the issue, change permission of the directory /Users/nawinpoolsawad/builds/pxKER6-V/0/bitnance-exchange/ and its parents or execute that application/script with another user (eg root).
I am trying to automate the execution of Robot Framework using Jenkins.
But when I run Jenkins I am receiving the error "Permission denied". You can see bellow the error's print screen.
Despite several attenpts Im not able to identify where this restriction is.
I have already include the Jenkins user as SUDO user, but the error is still there.
I also applied o CHMOD 777 /home/eduardo/.local/bin/robot but did not solve.
Can someone please tell me how I can identify where this restriction (Permission denied) is.
Thank in advance.
I suddenly got this error at my app which ran without problems for more than two years:
Rails Error: Unable to access log file. Please ensure that .../production.log exists...
WARN -- : Errno::EACCES: Permission denied # rb_sysopen .../log/newrelic_agent.log
The result of this error is that my mongoDB is killed. After I restarted the app everything works again until scheduled tasks are called which lead to that behaviour.
The error message says that i have to chmod to 0664, but this is still the case. For the deployment I use capistrano.
Any ideas?
Make log directory writable for other users:
chmod -R 777 specify_app_path_here/log
Now I know the reason for that strange behaviour: Hard Disk Failure !!!
Even both Disks were dead at the same time (RAID1) :(
I am using React Native as a Pod in my iOS project.
When I try to load a view that I created with React Native I get the Error screen referring me to the Terminal window where npm is running.
In the Terminal the error I am seeing is:
Error: Cannot find entry file in any of the roots:
I tried a few things, moving the file to a different location, but no luck.
I did run "npm start" and I am looking for the file in "http://localhost:8081/".
The current location of the file is in the same location as where I ran "npm start" from.
I am completely stuck here.
Did I configure something wrong. How can I troubleshoot from here?
Check for the node server running in one of the bash terminal, this was probably kicked by previous ReactNative XCode project you launched earlier. Stop that process and run XCode project again, this should fix the problem.
Sorry for answering my own question (a bit lame), but I hope it helps somebody else.
Apperantly we need run the npm command by giving an alternative path.
npm run start -- --root <directory_with_your_react_component_js_sources>
On http://facebook.github.io/react-native/docs/embedded-app.html#content is a guide on how to integrate React Native in an existing app.
That happens when React wants to use a port that is already being used by other application. Since React listens to port 8081, you can get the process running at that port typing the following in Shell:
lsof -n -i4TCP:8081
You'll get an answer like this:
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
node 28571 username 32u IPv6 0x742e2ab233abdb9f 0t0 TCP *:sunproxyadmin (LISTEN)
Just killed that by typing in shell
kill -9 <PID>. Use the same PID that has been provided in the last answer.
Then run npm start.
There's this issue:
https://github.com/facebook/react-native/issues/541
Which seems the same thing. The user there seemed to indicate that they had run the project from that directory before, which leads me to wonder if this is due to a hanging or left-over packager from a previous run? Try closing the terminal window and re-running the Xcode project.
In general this sounds like an issue with the packager not generating the files as expected. Are there any other messages in the terminal window?
I wanted to update this after getting a bit frustrated my setup still wasn't working after killing all node processes and running the command above.
There seems to be a ReactNative open issue at present: https://github.com/facebook/react-native/issues/14246
The solution for this is to kill the externally launched package manager and just run "npm start" in the project folder.
Check if you have index.ios or index in your AppDelegate.m:
jsCodeLocation = [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:#"index.ios" fallbackResource:nil];
I had index and I was previously using index.ios and index.android so that's why it was failing.
In my experience, it is because of Watchman and Jest.
The solution I've found is
add
name = name.replace('/', '\\');
to 'node_modules\jest-haste-map\build\crawlers\watchman.js'
You can check further info here
Watchman not working with React Native