android gradle build 时出现"Too many open files" 异常

来源:互联网 发布:拜占庭容错共识算法 编辑:程序博客网 时间:2024/05/16 06:58

mac 系统

解决方法一: 增加系统open files 的数量 

ulimit -a 查看open files 

ArjundeMacBook-Pro:~ Arjun$ ulimit -acore file size          (blocks, -c) 0data seg size           (kbytes, -d) unlimitedfile size               (blocks, -f) unlimitedmax locked memory       (kbytes, -l) unlimitedmax memory size         (kbytes, -m) unlimitedopen files                      (-n) 256pipe size            (512 bytes, -p) 1stack size              (kbytes, -s) 8192cpu time               (seconds, -t) unlimitedmax user processes              (-u) 709virtual memory          (kbytes, -v) unlimited

ulimit -n 1024 

ArjundeMacBook-Pro:~ Arjun$ ulimit -n 1024ArjundeMacBook-Pro:~ Arjun$ ulimit -acore file size          (blocks, -c) 0data seg size           (kbytes, -d) unlimitedfile size               (blocks, -f) unlimitedmax locked memory       (kbytes, -l) unlimitedmax memory size         (kbytes, -m) unlimitedopen files                      (-n) 1024pipe size            (512 bytes, -p) 1stack size              (kbytes, -s) 8192cpu time               (seconds, -t) unlimitedmax user processes              (-u) 709virtual memory          (kbytes, -v) unlimited


原创粉丝点击