When adding sieve to a valid hestia error 500 web mail

Hi everyone, I used this theme to add sieve, but got error 500 when logging into the webmail Roundcube. Rolled back system login to web mail returned. Perhaps someone came across this, I want to add sieve to the installed system and before I did it without difficulties, why now I don’t understand so much. Tell me who knows where to look to fix it, I reviewed all the logs but never saw why the error, the domain is available, the logs of the panel, mail, nginx without errors, in the/var/log/roundcube itself is also empty).
I even used ‘v-update-sys-hestia-git hestiacp main install’ and updated to version 10 alpha, but error 500 remained)

	Service		Description	Uptime	CPU	Memory

 cron	
job scheduler	16 minutes	0	0 MB

 dovecot	
imap/pop3 server	16 minutes	0	17 MB

 exim4	
mail server	16 minutes	0	16 MB

 fail2ban	
brute-force protection	18 minutes	0	311 MB

 iptables	
firewall	0 minutes	0	0 MB

 mariadb	
database server	16 minutes	0	709 MB

 nginx	
web server	10 minutes	0	24 MB

 php8.3-fpm	
php interpreter	18 minutes	0.1	38 MB

 spamd	
email spam filter	18 minutes	0	1101 MB

 ssh	
ssh server	16 minutes	0	3 MB

Hi,

The install_sieve.sh script should work. To find the cause of the 500 error, we need the log. A 500 error must leave an entry in the logs.

Now I’ll run the sieve script again, but I searched the logs when webmail returned error 500, which log to watch?

If you are using Nginx only /var/log/nginx/error.log and /var/log/nginx/domains/webmail.YourDomain.error.log

2025/12/05 02:56:36 [error] 6122#6122: *1 FastCGI sent in stderr: "PHP message: PHP Warning:  Undefined array key "log_dir" in /var/lib/roundcube/program/lib/Roundcube/rcube_config.php on line 233; PHP message: PHP Warning:  Undefined array key "log_dir" in /var/lib/roundcube/program/lib/Roundcube/rcube_config.php on line 233; PHP message: PHP Warning:  Undefined array key "temp_dir" in /var/lib/roundcube/program/lib/Roundcube/rcube_config.php on line 233; PHP message: PHP Warning:  Undefined array key "temp_dir" in /var/lib/roundcube/program/lib/Roundcube/rcube_config.php on line 233; PHP message: PHP Warning:  Undefined array key "drafts_mbox" in /var/lib/roundcube/program/lib/Roundcube/rcube_config.php on line 243; PHP message: PHP Warning:  Undefined array key "junk_mbox" in /var/lib/roundcube/program/lib/Roundcube/rcube_config.php on line 243; PHP message: PHP Warning:  Undefined array key "sent_mbox" in /var/lib/roundcube/program/lib/Roundcube/rcube_config.php on line 243; PHP message: PHP Warning:  Undefined array key "trash_mbox" in /var/lib/roundcube/program/lib/Roundcube/rcube_config.php on line 243; PHP message: PHP Warning:  Undefined array key "log_driver" in /var/lib/roundcube/program/lib/Roundcube/rcube_config.php on line 247; PHP message: PHP Warning:  file_put_contents(/var/lib/errors.log): Failed to open stream: Permission denied in /var/lib/roundcube/program/lib/Roundcube/rcube.php on line 1381; PHP message: PHP Warning:  Configuration error. Unsupported database driver:  in /var/lib/roundcube/program/lib/Roundcube/rcube.php on line 1504" while reading response header from upstream, client: 104.28.198.242, server: webmail.angellive.ru, request: "GET / HTTP/2.0", upstream: "fastcgi://unix:/run/php/www.sock:", host: "webmail.domen.com"

Show the output of these commands:

dpkg -l | grep roundcune
ls -la /etc/roundcube/
ls -la /var/lib/roundcube/
cat -n /etc/roundcube/config.inc.php | grep -Ev '[0-9]{1,}\s*\/\/' | sed 's/roundcube:.*@/roundcube:removed@/'
dpkg -l | grep roundcune
root@hestia:~# ls -la /etc/roundcube/
total 84
drwxr-x--x   3 root www-data  4096 Dec  5 02:55 .
drwxr-xr-x 105 root root      4096 Dec  5 02:31 ..
-rwxr-x--x   1 root www-data  3734 Dec  5 02:55 config.inc.php
-rwxr-x--x   1 root www-data 65150 Dec  5 02:31 defaults.inc.php
-rwxr-x--x   1 root www-data  2760 Dec  5 02:31 mimetypes.php
drwxr-x--x   6 root www-data  4096 Dec  5 02:55 plugins
root@hestia:~# ls -la /var/lib/roundcube/
total 412
drwxr-xr-x 11 hestiamail www-data   4096 Dec  5 02:41 .
drwxr-xr-x 45 root       root       4096 Dec  5 02:41 ..
drwxr-xr-x  2 hestiamail www-data   4096 Dec  5 02:41 bin
-rw-r--r--  1 hestiamail www-data 217388 Dec  5 02:41 CHANGELOG.md
-rw-r--r--  1 hestiamail www-data    994 Dec  5 02:41 composer.json
-rw-r--r--  1 hestiamail www-data   1086 Dec  5 02:41 composer.json-dist
-rw-r--r--  1 hestiamail www-data  56803 Dec  5 02:41 composer.lock
lrwxrwxrwx  1 hestiamail www-data     15 Dec  5 02:41 config -> /etc/roundcube/
-rw-r--r--  1 hestiamail www-data   2553 Dec  5 02:41 .htaccess
-rw-r--r--  1 hestiamail www-data  11209 Dec  5 02:41 index.php
-rw-r--r--  1 hestiamail www-data  12714 Dec  5 02:41 INSTALL
-rw-r--r--  1 hestiamail www-data  35147 Dec  5 02:41 LICENSE
drwxr-xr-x  2 hestiamail www-data   4096 Dec  5 02:41 logs
drwxr-xr-x 37 hestiamail www-data   4096 Dec  5 02:41 plugins
drwxr-xr-x  8 hestiamail www-data   4096 Dec  5 02:41 program
drwxr-xr-x  3 hestiamail www-data   4096 Dec  5 02:41 public_html
-rw-r--r--  1 hestiamail www-data   3853 Dec  5 02:41 README.md
-rw-r--r--  1 hestiamail www-data     26 Dec  5 02:41 robots.txt
-rw-r--r--  1 hestiamail www-data   1049 Dec  5 02:41 SECURITY.md
drwxr-xr-x  3 hestiamail www-data   4096 Dec  5 02:41 skins
drwxr-xr-x  7 hestiamail www-data   4096 Dec  5 02:41 SQL
drwxr-xr-x  2 hestiamail www-data   4096 Dec  5 02:41 temp
-rw-r--r--  1 hestiamail www-data   4657 Dec  5 02:41 UPGRADING
drwxr-xr-x 14 hestiamail www-data   4096 Dec  5 02:41 vendor
root@hestia:~# cat -n /etc/roundcube/config.inc.php | grep -Ev '\/\/' | sed 's/roundcube:.*@/roundcube:removed@/'
     1  <?php
     2  /* Local configuration for Roundcube Webmail */
     3
     6
     8  $config["smtp_log"] = false;
     9
    11  $config["imap_debug"] = true;
    12
    14  $config["smtp_debug"] = true;
    15
    32  $config["imap_host"] = "localhost:143";
    33
    45  $config["imap_conn_options"] = [
    46          "ssl" => [
    47                  "verify_peer" => false,
    48                  "verify_peer_name" => false,
    49                  "verify_depth" => 3,
    50                  "cafile" => "/etc/ssl/certs/ca-certificates.crt",
    51          ],
    52  ];
    53
    66  $config["smtp_conn_options"] = [
    67          "ssl" => [
    68                  "verify_peer" => false,
    69                  "verify_peer_name" => false,
    70                  "verify_depth" => 3,
    71                  "cafile" => "/etc/ssl/certs/ca-certificates.crt",
    72          ],
    73  ];
    74
    77  $config["support_url"] = "";
    78
    82  $config["log_dir"] = "/var/log/roundcube/";
    83
    88  $config["des_key"] = "NbyMUo5ndlwuOWrcEL9XUNdl";
    89
    92  $config["max_recipients"] = 100;
    93
    95  $config["plugins"] = ["password", "newmail_notifier", "zipdownload", "archive", "managesieve"];
    96
    97  $config["default_user"] = "%u";
    98
    99  $config["default_pass"] = "%p";
   100
   101  $config["smtp_host"] = "localhost:587";
   102
 104  $config["log_session"] = true;

chown -R hestiamail:www-data /etc/roundcube/
chown -R hestiamail:www-data /var/log/roundcube/

And try again.

2 Likes

Yes, thank you very much!
It turns out that when using the sieve installation script, directory rights fly off.

2 Likes