Estou recebendo um erro ao tentar executar o servidor em um aplicativo Laravel, usei o kit inicial com React como o tutorial nos documentos
> dev
> vite
VITE v5.4.10 ready in 1082 ms
➜ Local: http://localhost:5173/
➜ Network: use --host to expose
➜ press h + enter to show help
LARAVEL v10.48.22 plugin v1.0.5
➜ APP_URL: http://localhost
node:internal/fs/watchers:247
const error = new UVException({
^
Error: ENOSPC: System limit for number of file watchers reached, watch '/home/note/Área de trabalho/2024/Projects/kanban/laravel-kanban-v1/vendor/league/commonmark/src/Extension/ConfigurableExtensionInterface.php'
at FSWatcher.<computed> (node:internal/fs/watchers:247:19)
at Object.watch (node:fs:2490:36)
at createFsWatchInstance (file:///home/note/%C3%81rea%20de%20trabalho/2024/Projects/kanban/laravel-kanban-v1/node_modules/vite/dist/node/chunks/dep-BWSbWtLw.js:42779:17)
at setFsWatchListener (file:///home/note/%C3%81rea%20de%20trabalho/2024/Projects/kanban/laravel-kanban-v1/node_modules/vite/dist/node/chunks/dep-BWSbWtLw.js:42826:15)
at NodeFsHandler._watchWithNodeFs (file:///home/note/%C3%81rea%20de%20trabalho/2024/Projects/kanban/laravel-kanban-v1/node_modules/vite/dist/node/chunks/dep-BWSbWtLw.js:42981:14)
at NodeFsHandler._handleFile (file:///home/note/%C3%81rea%20de%20trabalho/2024/Projects/kanban/laravel-kanban-v1/node_modules/vite/dist/node/chunks/dep-BWSbWtLw.js:43045:23)
at NodeFsHandler._addToNodeFs (file:///home/note/%C3%81rea%20de%20trabalho/2024/Projects/kanban/laravel-kanban-v1/node_modules/vite/dist/node/chunks/dep-BWSbWtLw.js:43287:21)
Emitted 'error' event on FSWatcher instance at:
at FSWatcher._handleError (file:///home/note/%C3%81rea%20de%20trabalho/2024/Projects/kanban/laravel-kanban-v1/node_modules/vite/dist/node/chunks/dep-BWSbWtLw.js:44480:10)
at NodeFsHandler._addToNodeFs (file:///home/note/%C3%81rea%20de%20trabalho/2024/Projects/kanban/laravel-kanban-v1/node_modules/vite/dist/node/chunks/dep-BWSbWtLw.js:43295:18) {
errno: -28,
syscall: 'watch',
code: 'ENOSPC',
path: '/home/note/Área de trabalho/2024/Projects/kanban/laravel-kanban-v1/vendor/league/commonmark/src/Extension/ConfigurableExtensionInterface.php',
filename: '/home/note/Área de trabalho/2024/Projects/kanban/laravel-kanban-v1/vendor/league/commonmark/src/Extension/ConfigurableExtensionInterface.php'
}
Node.js v20.18.0
Estou usando o Ubuntu 23.04
laravel 10
Reinstalei o pacote mas continuo recebendo o mesmo erro, apaguei o node_modules mas também não funcionou
O erro
ENOSPC: System limit for number of file watchers reached
ocorre quando o sistema atinge o limite máximo de arquivos que podem ser assistidos pelo sistema. Essa é uma limitação de nível de sistema, não um problema do Laravel ou do Node.js.Verifique seu limite atual de monitoramento do inotify e aumente o limite:
Isso aumentará o limite de monitoramento de arquivos para 524288, o que deve ser suficiente para a maioria dos ambientes de desenvolvimento.
Se você quiser tornar essa alteração permanente (sobreviver a reinicializações), você pode criar um novo arquivo de configuração:
Depois de aplicar essas alterações, tente executar seu servidor de desenvolvimento novamente.