当前位置: 首页 > news >正文

configured user limit (128) on the number of inotify instances has been reached

问题:netcore 站点无法启动

ERROR System.IO.IOException: The configured user limit (128) on the number of inotify instances has been reached, or the per-process limit on the number of open file descriptors has been reached. 
 System.IO.IOException: The configured user limit (128) on the number of inotify instances has been reached, or the per-process limit on the number of open file descriptors has been reached.
   at System.IO.FileSystemWatcher.StartRaisingEvents()
   at Microsoft.Extensions.FileProviders.Physical.PhysicalFilesWatcher.TryEnableFileSystemWatcher()
   at Microsoft.Extensions.FileProviders.Physical.PhysicalFilesWatcher.CreateFileChangeToken(String filter)
   at Microsoft.Extensions.Primitives.ChangeToken.ChangeTokenRegistration`1..ctor(Func`1 changeTokenProducer, Action`1 changeTokenConsumer, TState state)
   at Microsoft.Extensions.Primitives.ChangeToken.OnChange(Func`1 changeTokenProducer, Action changeTokenConsumer)
   at Microsoft.Extensions.Configuration.FileConfigurationProvider..ctor(FileConfigurationSource source)
   at Microsoft.Extensions.Configuration.Json.JsonConfigurationSource.Build(IConfigurationBuilder builder)
   at Microsoft.Extensions.Configuration.ConfigurationBuilder.Build()

解决办法:

cat /proc/sys/fs/inotify/max_user_instances
ulimit -n
sudo find /proc/*/fd -lname 'anon_inode:inotify' 2>/dev/null | wc -l
cat /proc/sys/fs/file-nr
sudo sysctl fs.inotify.max_user_instances=512
nano /etc/sysctl.d/99-inotify.conf
=========================================
fs.inotify.max_user_instances = 512
=========================================
sudo sysctl -p /etc/sysctl.d/99-inotify.conf

 

相关文章:

  • 常考计算机操作系统面试习题(三上)
  • 项目代码的构建
  • 【QA】单件模式在Qt中有哪些应用?
  • isaacgymEnvs 的yaml文件dt设置
  • 【AI学习笔记】Coze平台实现将Excel文档批量导入数据库全过程
  • 多源数据融合处理方法综述
  • 机器学习——KNN超参数
  • 第十五章:模板参数推导_《C++ Templates》notes
  • L2-【英音】地道语音语调--连读
  • 一条sql语句在mysql中的执行流程(Mysql基础架构)
  • 【Unity3D】摄像机适配场景以及Canvas适配
  • 使用LangChain开发智能问答系统
  • c#难点整理
  • 【模板】计算几何入门
  • Vue 表单输入绑定,双向绑定
  • 基于 intellij-platform-plugin-template 开发IDEA插件注意事项
  • form 表单内容序列化成一个字符串
  • 大模型架构记录2 【综述-相关代码】
  • 数据服务赋能数据治理:从“One Service”到QuickAPI的演进
  • redis操作
  • 网站建设的安全措施/软文广告发稿
  • 天津做网站找哪家好/淘宝运营培训班去哪里学
  • 做国内电影网站赚钱不/高权重外链
  • 河北省最新任免/高级seo招聘
  • 网站制作技巧/临沂seo整站优化厂家
  • 长沙网站制作作/百度学术查重