stop when > 90% files allowed

This commit is contained in:
edoapra 2023-07-19 09:42:28 -07:00
parent 6ad6458e7e
commit 9eba058b4f
No known key found for this signature in database
GPG key ID: 48E12DA1EDE9E1B0

View file

@ -32,8 +32,8 @@ cat > mpipr-too-many.patch <<EOF
+#ifdef DEBUGSHM
+ if(nfiles % 1000 == 0) fprintf(stderr," %d: no. open files = %ld maxfiles = %ld\n", g_state.rank, nfiles, maxfiles);
+#endif
+ long mylimit = (maxfiles/100)*60;
+ if(nfiles > (maxfiles/100)*60) {
+ long mylimit = (maxfiles/100)*90;
+ if(nfiles > (maxfiles/100)*90) {
+ printf(" %d: running out of files; files = %ld maxfiles = %ld\n", g_state.rank, nfiles, maxfiles);
+#if PAUSE_ON_ERROR
+ fprintf(stderr,"%d(%d): too many open files\n",