High CPU for command /authentic-theme/index.cgi

SYSTEM INFORMATION
OS type and version CentOS 7.9
Webmin version 2.013
Authentic Theme version 20.13
RAM 32GB
Swap 16GB
CPU Intel Xeon Silver 4210 CPU @ 2.20GHz, 8 cores
VM VMwaare
NIC type E1000

Recently, we notice that when switching between virtual servers or renaming domains within Virtualmin, there is high CPU usage during these actions. When we switch Webmin to use the Framed Theme, it seems fine.

We did a strace of the process for /authentic-theme/index.cgi and notice that there’s a lot of lstat read readlink calls to all the nginx configuration files under /etc/nginx/conf.d and trying to prepare for letsencrypt. Is this normal?

lstat("/etc/nginx/globals/staticfiles.conf", {st_mode=S_IFREG|0644, st_size=3256, ...}) = 0
readlink("/etc", 0x7ffea60046b0, 4095)  = -1 EINVAL (Invalid argument)
readlink("/etc/nginx", 0x7ffea60046b0, 4095) = -1 EINVAL (Invalid argument)
readlink("/etc/nginx/globals", 0x7ffea60046b0, 4095) = -1 EINVAL (Invalid argument)
readlink("/etc/nginx/globals/staticfiles.conf", 0x7ffea60046b0, 4095) = -1 EINVAL (Invalid argument)
open("/etc/nginx/globals/staticfiles.conf", O_RDONLY) = 6
ioctl(6, TCGETS, 0x7ffea6005240)        = -1 ENOTTY (Inappropriate ioctl for device)
lseek(6, 0, SEEK_CUR)                   = 0
fstat(6, {st_mode=S_IFREG|0644, st_size=3256, ...}) = 0
fcntl(6, F_SETFD, FD_CLOEXEC)           = 0
read(6, "    # prepare for letsencrypt \n "..., 8192) = 3256
read(6, "", 8192)                       = 0
close(6)                                = 0
lstat("/etc/nginx/conf.d/mydomain.com/php-wpsc.conf", {st_mode=S_IFREG|0644, st_size=4371, ...}) = 0
brk(NULL)                               = 0x228d8000
brk(0x228f9000)                         = 0x228f9000
readlink("/etc", 0x7ffea60046b0, 4095)  = -1 EINVAL (Invalid argument)
readlink("/etc/nginx", 0x7ffea60046b0, 4095) = -1 EINVAL (Invalid argument)
readlink("/etc/nginx/conf.d", 0x7ffea60046b0, 4095) = -1 EINVAL (Invalid argument)
readlink("/etc/nginx/conf.d/mydomain.com", 0x7ffea60046b0, 4095) = -1 EINVAL (Invalid argument)
readlink("/etc/nginx/conf.d/mydomain.com/php-wpsc.conf", 0x7ffea60046b0, 4095) = -1 EINVAL (Invalid argument)
open("/etc/nginx/conf.d/mydomain.com/php-wpsc.conf", O_RDONLY) = 6
ioctl(6, TCGETS, 0x7ffea6005240)        = -1 ENOTTY (Inappropriate ioctl for device)
lseek(6, 0, SEEK_CUR)                   = 0
fstat(6, {st_mode=S_IFREG|0644, st_size=4371, ...}) = 0
fcntl(6, F_SETFD, FD_CLOEXEC)           = 0
read(6, "\n    location ~ [^/]\\.php(/|$) {"..., 8192) = 4371
read(6, "", 8192)                       = 0
close(6)

We also notice some of these calls below trying to open somes file but it’s not there.

open("/etc/webmin/virtual-server/module.info.override", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/etc/webmin/miniserv.conf", {st_mode=S_IFREG|0600, st_size=46087, ...}) = 0
stat("/usr/libexec/webmin//prefs.info", 0x20b5138) = -1 ENOENT (No such file or directory)
stat("/etc/webmin/miniserv.conf", {st_mode=S_IFREG|0600, st_size=46087, ...}) = 0
lstat("/usr/libexec/webmin/virtual-server", {st_mode=S_IFDIR|0755, st_size=20480, ...}) = 0
open("/etc/webmin/virtual-server/module.info.override", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/etc/webmin/miniserv.conf", {st_mode=S_IFREG|0600, st_size=46087, ...}) = 0
stat("/usr/libexec/webmin//prefs.info", 0x20b5138) = -1 ENOENT (No such file or directory)
stat("/etc/webmin/miniserv.conf", {st_mode=S_IFREG|0600, st_size=46087, ...}) = 0
stat("/usr/libexec/webmin//prefs.info", 0x20b5138) = -1 ENOENT (No such file or directory)
stat("/etc/webmin/miniserv.conf", {st_mode=S_IFREG|0600, st_size=46087, ...}) = 0
stat("/usr/libexec/webmin//prefs.info", 0x20b5138) = -1 ENOENT (No such file or directory)
lstat("/usr/libexec/webmin/virtual-server", {st_mode=S_IFDIR|0755, st_size=20480, ...}) = 0
open("/etc/webmin/virtual-server/module.info.override", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/etc/webmin/miniserv.conf", {st_mode=S_IFREG|0600, st_size=46087, ...}) = 0
stat("/usr/libexec/webmin//prefs.info", 0x20b5138) = -1 ENOENT (No such file or directory)
stat("/etc/webmin/miniserv.conf", {st_mode=S_IFREG|0600, st_size=46087, ...}) = 0
lstat("/usr/libexec/webmin/virtual-server", {st_mode=S_IFDIR|0755, st_size=20480, ...}) = 0
open("/etc/webmin/virtual-server/module.info.override", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/etc/webmin/miniserv.conf", {st_mode=S_IFREG|0600, st_size=46087, ...}) = 0
stat("/usr/libexec/webmin//prefs.info", 0x20b5138) = -1 ENOENT (No such file or directory)
stat("/etc/webmin/miniserv.conf", {st_mode=S_IFREG|0600, st_size=46087, ...}) = 0
stat("/usr/libexec/webmin//prefs.info", 0x20b5138) = -1 ENOENT (No such file or directory)
stat("/etc/webmin/miniserv.conf", {st_mode=S_IFREG|0600, st_size=46087, ...}) = 0
stat("/usr/libexec/webmin//prefs.info", 0x20b5138) = -1 ENOENT (No such file or directory)
lstat("/usr/libexec/webmin/virtual-server", {st_mode=S_IFDIR|0755, st_size=20480, ...}) = 0

I’ve tried re-installing the authentic theme but still happens. The above calls still happens when we use framed theme. But the CPU doesn’t spike up. Only happens with authentic theme. Is this expected?

Hardware? VM? Either way, system specs might be nice to know.

Yes it is a VM. I have updated my original post with more details on the specs.

Intresting 4210 CPU :thinking:

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