npm运行报错:Error: ENOSPC: System limit for number of file watchers reached
生活随笔
收集整理的這篇文章主要介紹了
npm运行报错:Error: ENOSPC: System limit for number of file watchers reached
小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.
原因
查了一下,是linux系統(tǒng)的限制導(dǎo)致這個(gè)報(bào)錯(cuò)了,需要設(shè)置一下:fs.inotify.max_user_watches 這個(gè)參數(shù)。
解決方法
執(zhí)行:vim /etc/sysctl.conf,添加如下內(nèi)容:
fs.inotify.max_user_watches=524288
輸入:wq
在命令行執(zhí)行:sysctl -p
重新執(zhí)行:npm run serve,沒有報(bào)錯(cuò)了。
總結(jié)
以上是生活随笔為你收集整理的npm运行报错:Error: ENOSPC: System limit for number of file watchers reached的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: linux deepin安装virtua
- 下一篇: linux deepin 20.4升级至