Usermin crash at first connection after reboot

SYSTEM INFORMATION
**OS type and version: Debian 10 and almalinux 8.4 REQUIRED
**Webmin version:1.981 REQUIRED
**Virtualmin version:6.17 REQUIRED
**Related products version: RECOMMENDED

hello,
i have same problem on different server (2 debian 10 and 1 almalinux 8.4).

problem is when i try to open : https://server:20000 usermin crash
if i login in ssh and execute
systemctl restart usermin
after works fine.
but at next reboot (kernel update or similar) i have same issue

for now i create a rule in
System and Server Status
so usermin is auto restart if down

but i can’t find why happens…
can you help me to find this strange behaviour?

thank you

If I were a betting man, I would bet you’re running out of memory.

ok, i think same.
but how i check that?

these 3 servers are only mail server (so nothing big website mysql or similar, but spamassasins)

on first server i think same because i have only 4gb ram (debian 10)
but second have 16gb ram (debian 10) and have only 8 domain with only mail…

i search in many logs but i can’t find nothing to usermin out of memory…

thank you

Oh, it is probably not memory, then. Even 4GB should be enough, unless you’re doing something very large on the system.

Look in the /var/usermin/miniserv.error log when it stops for clues about why.

here is a piece of log

[01/Nov/2021:15:48:37 +0100] Using SHA512 module Crypt::SHA
readline() on closed filehandle $ADDRESS at /usr/libexec/usermin/mailbox/mailbox-lib.pl line 166.
readline() on closed filehandle $ADDRESS at /usr/libexec/usermin/mailbox/mailbox-lib.pl line 166.
Use of uninitialized value $mailbox::in{"jump"} in pattern match (m//) at /usr/libexec/usermin/mailbox/index.cgi line 77.
Use of uninitialized value $mailbox::in{"start"} in int at /usr/libexec/usermin/mailbox/index.cgi line 85.
Use of uninitialized value $mailbox::in{"start"} in int at /usr/libexec/usermin/mailbox/index.cgi line 85.
Use of uninitialized value in numeric ge (>=) at /usr/libexec/usermin/mailbox/index.cgi line 86, <IMAP16357781201> line 43.
Use of uninitialized value in addition (+) at /usr/libexec/usermin/mailbox/index.cgi line 385, <IMAP16357781201> line 343.
Use of uninitialized value in addition (+) at /usr/libexec/usermin/mailbox/index.cgi line 388, <IMAP16357781201> line 343.
Use of uninitialized value in subtraction (-) at /usr/libexec/usermin/mailbox/index.cgi line 390, <IMAP16357781201> line 343.
Use of uninitialized value in subtraction (-) at /usr/libexec/usermin/mailbox/index.cgi line 391, <IMAP16357781201> line 343.
Use of uninitialized value $mailbox::in{"start"} in int at /usr/libexec/usermin/mailbox/index.cgi line 106, <IMAP16357781201> line 343.
Use of uninitialized value in addition (+) at /usr/libexec/usermin/mailbox/index.cgi line 107, <IMAP16357781201> line 343.
readline() on closed filehandle $ADDRESS at /usr/libexec/usermin/mailbox/mailbox-lib.pl line 166.
readline() on closed filehandle $ADDRESS at /usr/libexec/usermin/mailbox/mailbox-lib.pl line 166.
Use of uninitialized value in pattern match (m//) at /usr/libexec/usermin/mailbox/mailbox-lib.pl line 1444, <IMAP16357781221> line 74.
readline() on closed filehandle $ADDRESS at ./mailbox-lib.pl line 166.
Use of uninitialized value $mailbox::in{"sub"} in split at /usr/libexec/usermin/mailbox/view_mail.cgi line 25, <IMAP16357781241> line 67.
Use of uninitialized value in pattern match (m//) at ./mailbox-lib.pl line 1444, <IMAP16357781241> line 67.
print() on unopened filehandle DEBUG at ./mailbox-lib.pl line 1611, <IMAP16357781241> line 67.
Use of uninitialized value in pattern match (m//) at ./mailbox-lib.pl line 76.
Use of uninitialized value $mailbox::in{"body"} in numeric eq (==) at /usr/libexec/usermin/mailbox/view_mail.cgi line 122.
Use of uninitialized value $mailbox::in{"body"} in numeric eq (==) at /usr/libexec/usermin/mailbox/view_mail.cgi line 123.
Use of uninitialized value $htmlbody in string eq at /usr/libexec/usermin/mailbox/view_mail.cgi line 127.
Use of uninitialized value in concatenation (.) or string at /usr/libexec/usermin/mailbox/view_mail.cgi line 185.
Use of uninitialized value in concatenation (.) or string at /usr/libexec/usermin/mailbox/view_mail.cgi line 185.
Use of uninitialized value in concatenation (.) or string at /usr/libexec/usermin/mailbox/view_mail.cgi line 187.
Use of uninitialized value in concatenation (.) or string at /usr/libexec/usermin/mailbox/view_mail.cgi line 187.
[01/Nov/2021:17:36:35 +0100] Restarting
[01/Nov/2021:17:36:35 +0100] miniserv.pl started
[01/Nov/2021:17:36:35 +0100] Using MD5 module Digest::MD5
[01/Nov/2021:17:36:35 +0100] Using SHA512 module Crypt::SHA
[01/Nov/2021:17:39:49 +0100] Restarting
[01/Nov/2021:17:39:50 +0100] miniserv.pl started
[01/Nov/2021:17:39:50 +0100] Using MD5 module Digest::MD5
[01/Nov/2021:17:39:50 +0100] Using SHA512 module Crypt::SHA
[01/Nov/2021:17:44:42 +0100] miniserv.pl started
[01/Nov/2021:17:44:42 +0100] Using MD5 module Digest::MD5
[01/Nov/2021:17:44:42 +0100] Using SHA512 module Crypt::SHA
[01/Nov/2021:17:44:42 +0100] Reloading configuration
readline() on closed filehandle $ADDRESS at /usr/libexec/usermin/mailbox/mailbox-lib.pl line 166.
readline() on closed filehandle $ADDRESS at /usr/libexec/usermin/mailbox/mailbox-lib.pl line 166.

today usermin crash at 17:15 about…

thank you

OK, I don’t see any problems there that would explain the service exiting. So, I’m back to thinking it’s memory.

Check the kernel log for out-of-memory killer messages.

i reproduce now on debian 10 (16gb ram).

to search out-of-memory killer messages is correct this command?
cat /var/log/messages | grep kill
because is empty, so return no line…

and last line of log /var/usermin/miniserv.error is
…
[29/Oct/2021:17:30:04 +0200] PAM authentication enabled

and this is result of
systemctl status usermin.service
â—Ź usermin.service - LSB: web-based account administration interface for Unix systems
Loaded: loaded (/etc/init.d/usermin; generated)
Active: active (exited) since Fri 2021-10-29 17:30:04 CEST; 3 days ago
Docs: man:systemd-sysv-generator(8)

seems exited… strange…

ps. sorry ram is
free -m
total used free shared buff/cache available
Mem: 16042 1870 13479 185 692 13674
Swap: 4095 438 3657

The OOM killer will “exit” the process. It has not choice in the matter. Status will show exited no mater how it got there.

ok , but for me the strange thing is that once restarted the service works without problems …

so I am tempted to add in crontab
@reboot sleep 90 ; systemctl restart usermin

to check if problem persist…

Just to make sure you’re worrying about the right things: Usermin (and Webmin) do not crash. If they’ve exited, they were made to exit by something else. This is often the OOM killer, but could be other things, I don’t know.

2 Likes

ok thank you for reply.

just one question.
where i search to find some log or something to understand issue?

/var/log/messages
/var/usermin/miniserv.error

somewhere else?
thank you

you should have a go at /var everything there… possibly you will discover other issues related towards the os you are using. have a fun.

ok, thank you for reply.

i search in usermin folder
and found this

Use of uninitialized value in concatenation (.) or string at /usr/share/usermin/mailbox/view_mail.cgi line 187.

can this crash usermin ?

thank you

No. That’s just a Perl strictures warning. Irrelevant. And, again, Usermin does not crash. If it is exiting, something is making it exit.

yes , sorry usermin exit (not crash) …

for now i’m testing this solution,
i add in crontab
@reboot sleep 300 ; systemctl restart usermin >/dev/null 2>&1

try to reboot and check in next days if happens again…
for now i reboot and login correct in usermin.

thank you

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.