View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0006591 | unreal | ircd | public | 2025-11-07 20:19 | 2026-01-19 10:33 |
| Reporter | geekshell | Assigned To | syzop | ||
| Priority | normal | Severity | minor | Reproducibility | always |
| Status | resolved | Resolution | fixed | ||
| Platform | Linux | OS | Debian | OS Version | 10 |
| Product Version | 6.2.1 | ||||
| Fixed in Version | 6.2.2 | ||||
| Summary | 0006591: OOM kill because of low memory during installation | ||||
| Description | Upgrade fails at this stage: CC src/libpcre2_8_la-pcre2_match.lo gcc: internal compiler error: Killed (program cc1) Please submit a full bug report, with preprocessed source if appropriate. See <file:///usr/share/doc/gcc-6/README.Bugs> for instructions. Makefile:2721: recipe for target 'src/libpcre2_8_la-pcre2_match.lo' failed make[1]: *** [src/libpcre2_8_la-pcre2_match.lo] Error 1 make[1]: Leaving directory '/home/test/unrealircd-6/extras/pcre2-10.45' Makefile:1581: recipe for target 'all' failed make: *** [all] Error 2 dmesg tells me it's because of low memory: and I have this error in dmesg: Out of memory in UB 1905: OOM killed process 32385 (cc1) score 0 vm:173224kB, rss:128360kB, swap:0kB | ||||
| Steps To Reproduce | Run ./Config or ./unrealircd upgrade on low memory machine. | ||||
| Additional Information | Temporary solution is to use less aggressive C optimization : CFLAGS="-O1" ./Config This flag didn't work for me with ./unrealircd upgrade. This is without the flag (default): Install prefix ..................... : /home/test/unrealircd-6.2.0.2/extras/pcre2 C preprocessor ..................... : C compiler ......................... : gcc Linker ............................. : /usr/bin/ld -m elf_x86_64 C preprocessor flags ............... : C compiler flags ................... : -pthread -O2 -fvisibility=hidden Linker flags ....................... : -Wl,-rpath,/home/test/test/lib Extra libraries .................... : Build 8-bit pcre2 library .......... : yes Build 16-bit pcre2 library ......... : no Build 32-bit pcre2 library ......... : no Include debugging code ............. : no Enable JIT compiling support ....... : yes Use SELinux allocator in JIT ....... : no Enable Unicode support ............. : yes Newline char/sequence .............. : lf \R matches only ANYCRLF ............ : no \C is disabled ..................... : no EBCDIC coding ...................... : no EBCDIC code for NL ................. : n/a Rebuild char tables ................ : no Internal link size ................. : 2 Maximum variable lookbehind ........ : 255 Nested parentheses limit ........... : 250 Heap limit ......................... : 20000000 kibibytes Match limit ........................ : 10000000 Match depth limit .................. : MATCH_LIMIT Build shared libs .................. : yes Build static libs .................. : yes Use JIT in pcre2grep ............... : yes Enable callouts in pcre2grep ....... : yes Enable fork in pcre2grep callouts .. : yes Initial buffer size for pcre2grep .. : 20480 Maximum buffer size for pcre2grep .. : 1048576 Link pcre2grep with libz ........... : no Link pcre2grep with libbz2 ......... : no Link pcre2test with libedit ........ : no Link pcre2test with libreadline .... : no Valgrind support ................... : no Code coverage ...................... : no Fuzzer support ..................... : no Differential fuzzer support ........ : no Use %zu and %td .................... : auto This is with the flag: pcre2-10.45 configuration summary: Install prefix ..................... : /home/test/unrealircd-6.2.0.2/extras/pcre2 C preprocessor ..................... : C compiler ......................... : gcc Linker ............................. : /usr/bin/ld -m elf_x86_64 C preprocessor flags ............... : C compiler flags ................... : -pthread -O1 -fno-strict-aliasing -fno-common -funsigned-char -Wall -Wextra -Waggregate-return -Wformat-nonliteral -Wduplicated-cond -Wparentheses -Wno-pointer-sign -Wno-format-zero-length -Wno-unused -Wno-unused-parameter -Wno-unused-but-set-parameter -Wno-char-subscripts -Wno-sign-compare -Wno-empty-body -Wno-pragmas -fvisibility=hidden Linker flags ....................... : -Wl,-rpath,/home/test/test/lib Extra libraries .................... : Build 8-bit pcre2 library .......... : yes Build 16-bit pcre2 library ......... : no Build 32-bit pcre2 library ......... : no Include debugging code ............. : no Enable JIT compiling support ....... : yes Use SELinux allocator in JIT ....... : no Enable Unicode support ............. : yes Newline char/sequence .............. : lf \R matches only ANYCRLF ............ : no \C is disabled ..................... : no EBCDIC coding ...................... : no EBCDIC code for NL ................. : n/a Rebuild char tables ................ : no Internal link size ................. : 2 Maximum variable lookbehind ........ : 255 Nested parentheses limit ........... : 250 Heap limit ......................... : 20000000 kibibytes Match limit ........................ : 10000000 Match depth limit .................. : MATCH_LIMIT Build shared libs .................. : yes Build static libs .................. : yes Use JIT in pcre2grep ............... : yes Enable callouts in pcre2grep ....... : yes Enable fork in pcre2grep callouts .. : yes Initial buffer size for pcre2grep .. : 20480 Maximum buffer size for pcre2grep .. : 1048576 Link pcre2grep with libz ........... : no Link pcre2grep with libbz2 ......... : no Link pcre2test with libedit ........ : no Link pcre2test with libreadline .... : no Valgrind support ................... : no Code coverage ...................... : no Fuzzer support ..................... : no Differential fuzzer support ........ : no Use %zu and %td .................... : auto | ||||
| 3rd party modules | |||||
|
|
When we were compiling PCRE2, it was indeed ignoring the CFLAGS. This was fixed the same day as this bug report in https://github.com/unrealircd/unrealircd/commit/4e0eaecb335867b9691a93621f726dac381bf79e So the CFLAGS passing should work fine now with 6.2.2 release (which came quite a bit later) and thus also with ./unrealircd upgrade. If your system is resource constraint, you may also want to consider installing all the library dependencies as packages, so UnrealIRCd does not compile the shipped libs. Saves time, and in your case a potential OOM during compiling of said libs. The "Prerequisites" in https://www.unrealircd.org/docs/Installing_from_source should tell you all of them. If system lib exists and meets dependencies then that is used instead of shipped-with-unrealircd-libs. Only libargon2 is still compiled because self-compiled is usually 2x/3x faster which is an important performance improvement, but even that one can be ignored if you pass --with-system-argon2 to configure args (last step in ./Config). And, of course, in the end, there is only so much we can do. Your CFLAGS should help. The fix should help. And the above prerequisites suggestion should help. But in the end a certain amount of memory is needed to compile UnrealIRCd. We can't fix that :) Hope this |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2025-11-07 20:19 | geekshell | New Issue | |
| 2026-01-19 10:32 | syzop | Assigned To | => syzop |
| 2026-01-19 10:32 | syzop | Status | new => closed |
| 2026-01-19 10:32 | syzop | Resolution | open => fixed |
| 2026-01-19 10:32 | syzop | Fixed in Version | => 6.2.2 |
| 2026-01-19 10:32 | syzop | Note Added: 0023591 | |
| 2026-01-19 10:32 | syzop | Status | closed => resolved |
| 2026-01-19 10:33 | syzop | Note Edited: 0023591 |