1

Topic: iredmail work slow

Required information ====
- iRedMail version (check /etc/iredmail-release): 0.9.5-1
- Linux/BSD distribution name and version: Ubuntu 12.04
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): LDAP
- Web server (Apache or Nginx):Apache
- Manage mail accounts with iRedAdmin-Pro? YES
- Related log if you're reporting an issue

Users complain that email (roundcube1.2.1) work slow.
Any suggestions how to resolve the problem ?

Thanks

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: iredmail work slow

You must ask yourself this question first: Why is it slow?

*) Is Roundcube fast in local network?
*) Slow bandwidth on client-side? Slow server performance? Server is too busy to handle requests?

3

Re: iredmail work slow

ZhangHuangbin wrote:

You must ask yourself this question first: Why is it slow?

*) Is Roundcube fast in local network?
*) Slow bandwidth on client-side? Slow server performance? Server is too busy to handle requests?



1) Yes. Roudcube is slow in local network.Slow load mesages.
2)Bandwidth is ok.

I use iRdedmail more than 5 years. It hass been problems with mySQL but I can not understand now.

Any suggestions ?

4

Re: iredmail work slow

platpirs wrote:

1) Yes. Roudcube is slow in local network.Slow load mesages.

Is it fast with IMAP client like Thunderbird, Outlook?

5

Re: iredmail work slow

ZhangHuangbin wrote:
platpirs wrote:

1) Yes. Roudcube is slow in local network.Slow load mesages.

Is it fast with IMAP client like Thunderbird, Outlook?

95% user use Roundcube.
No. It is slow with  Thunderbird, Outlook also.

Which MySQL table data which could affect it ?

6

Re: iredmail work slow

*) Please show us your server hardware. CPU, Memory, Hard disk, network bandwidth.
*) How many mail users do you host on this server?
*) How many concurrent IMAP clients do you serve when it's slow?

7

Re: iredmail work slow

ZhangHuangbin wrote:

*) Please show us your server hardware. CPU, Memory, Hard disk, network bandwidth.
*) How many mail users do you host on this server?
*) How many concurrent IMAP clients do you serve when it's slow?


1)How many mail users do you host on this server?
1-1(165)

2)How many concurrent IMAP clients do you serve when it's slow? 
2-2How can I see that ? Where ?


3)Please show us your server hardware. CPU, Memory, Hard disk, network bandwidth
3-3) network bandwidth - 84,85Mbps download/92.27Mbps upload.
3-4)Hard disk - 680GB/223 GB used
3-5)Stored emails     364782 Emails. 223.94 GB.
3-6)Memory - 7,4GB, swap 5 GB
3-7)CPU - 2 procesors, intel i7

I think the problem is not server hardware.
I see myPHPadmin. Roundcubemail.  Table session.
I see 106,339 rows. It is normal ?

8

Re: iredmail work slow

I check e-mail server resources(RAM.) All day RAM usege was 99%.  at 19:00 pm  still usage was 99%
watch -n 5 free -m comand show

             total       used       free     shared    buffers     cached
Mem:          7544       7496         47          0          0       6476
-/+ buffers/cache:       1019       6524
Swap:         5128        298       4829

I think problem is swap.
Any suggestions?




platpirs wrote:
ZhangHuangbin wrote:

*) Please show us your server hardware. CPU, Memory, Hard disk, network bandwidth.
*) How many mail users do you host on this server?
*) How many concurrent IMAP clients do you serve when it's slow?


1)How many mail users do you host on this server?
1-1(165)

2)How many concurrent IMAP clients do you serve when it's slow? 
2-2How can I see that ? Where ?


3)Please show us your server hardware. CPU, Memory, Hard disk, network bandwidth
3-3) network bandwidth - 84,85Mbps download/92.27Mbps upload.
3-4)Hard disk - 680GB/223 GB used
3-5)Stored emails     364782 Emails. 223.94 GB.
3-6)Memory - 7,4GB, swap 5 GB
3-7)CPU - 2 procesors, intel i7

I think the problem is not server hardware.
I see myPHPadmin. Roundcubemail.  Table session.
I see 106,339 rows. It is normal ?

9

Re: iredmail work slow

with 163 mail users, so many swap usage doesn't make sense to me.

*) Please run 'top' command, which programs use most memory?
*) Do you run many Amavisd child processes to handle emails?

10

Re: iredmail work slow

1) top command show
4516 dovenull  20   0 19848 2932 2232 S    0  0.0   0:00.04 imap-login
4517 vmail     20   0 22820 2412 1692 S    0  0.0   0:00.04 imap
    1 root      20   0 24160 1432  960 S    0  0.0   0:00.18 init
    2 root      20   0     0    0    0 S    0  0.0   0:00.00 kthreadd/102
    3 root      20   0     0    0    0 S    0  0.0   0:00.00 khelper/102
   92 root      20   0 17188  232  228 S    0  0.0   0:00.00 upstart-udev-br
  151 root      20   0 21528  692  688 S    0  0.0   0:00.00 udevd
  248 root      20   0 49992 2028 1908 S    0  0.0   0:00.16 sshd
  255 messageb  20   0 23776  220  216 S    0  0.0   0:00.00 dbus-daemon
  283 root      20   0 21524  252  248 S    0  0.0   0:00.00 udevd
  284 root      20   0 21524  252  248 S    0  0.0   0:00.00 udevd
  330 root      20   0 15144  152  148 S    0  0.0   0:00.00 upstart-socket-
  375 root      20   0 14924  800  796 S    0  0.0   0:00.00 xinetd
  393 root      20   0 17392 1216 1076 S    0  0.0   0:47.12 dovecot
  404 root      20   0 19068  856  760 S    0  0.0   0:00.31 cron
  418 vmail     20   0 18152 1016 1012 S    0  0.0   0:00.00 lmtp
  419 vmail     20   0 18152 1016 1012 S    0  0.0   0:00.00 lmtp
  420 vmail     20   0 18152 1016 1012 S    0  0.0   0:00.00 lmtp
  421 vmail     20   0 18152 1016 1012 S    0  0.0   0:00.00 lmtp
  422 vmail     20   0 18152 1016 1012 S    0  0.0   0:00.00 lmtp
  423 dovecot   20   0  8908  972  840 S    0  0.0   0:13.27 anvil
  424 root      20   0  9032 1044  872 S    0  0.0   0:15.24 log
  430 root      20   0 24448 2808 1052 S    0  0.0   0:48.67 config
  439 mysql     20   0 1339m 122m 4368 S    0  1.6   2:37.81 mysqld
  461 syslog    20   0 12708  760  648 S    0  0.0   0:03.24 syslogd
  499 bind      20   0  239m 3148 1556 S    0  0.0   0:00.03 named
  623 amavis    20   0  212m  36m 2872 S    0  0.5   0:03.00 amavisd (master
  654 openldap  20   0  541m 7256 4132 S    0  0.1   2:15.03 slapd
1120 clamav    20   0 1201m 379m 1900 S    0  5.0   3:09.47 clamd
1204 www-data  20   0  369m  36m  20m S    0  0.5   0:03.04 apache2
1232 clamav    20   0 52336 1992 1468 S    0  0.0   2:43.79 freshclam
1302 www-data  20   0  367m  35m  21m S    0  0.5   0:03.41 apache2
1311 www-data  20   0  364m  34m  21m S    0  0.5   0:04.04 apache2
1333 iredapd   20   0  186m 7872 2704 S    0  0.1   0:06.81 python
1343 opendkim  20   0 96488  464  300 S    0  0.0   0:00.00 opendkim
1345 opendkim  20   0  696m 7528 2276 S    0  0.1   0:43.57 opendkim
1448 root      20   0 25064 1492 1364 S    0  0.0   0:06.55 master
1457 postfix   20   0 27360 1776 1448 S    0  0.0   0:02.10 qmgr
1468 cluebrin  20   0 77220 6824 2264 S    0  0.1   0:04.22 cbpolicyd
1496 root      20   0 78700  404  400 S    0  0.0   0:00.00 saslauthd
1498 root      20   0 78700   32   28 S    0  0.0   0:00.00 saslauthd
1552 root      20   0  354m 6984 4300 S    0  0.1   0:07.03 apache2
1565 iredadmi  20   0  663m  38m 4168 S    0  0.5   0:58.12 apache2
1586 root      20   0  639m 5116 2208 S    0  0.1   1:43.71 fail2ban-server
1588 root      20   0 22484 1284 1016 S    0  0.0   0:25.63 gam_server
1720 postfix   20   0 27128 1660 1348 S    0  0.0   0:00.00 anvil
1839 postfix   20   0 38536 2908 2388 S    0  0.0   0:01.21 tlsmgr
2644 dovenull  20   0 19832 2924 2228 S    0  0.0   0:00.00 imap-login
2647 vmail     20   0 22908 2456 1680 S    0  0.0   0:00.00 imap
3218 amavis    20   0  293m  69m 4476 S    0  0.9   0:00.74 amavisd (ch3-av
3595 dovecot   20   0 78752 3784 2516 S    0  0.0   0:16.69 auth
3618 dovenull  20   0 19848 2920 2220 S    0  0.0   0:00.00 imap-login
3619 vmail     20   0 22688 2100 1660 S    0  0.0   0:00.00 imap
3749 www-data  20   0  366m  31m  16m S    0  0.4   0:01.05 apache2
4024 www-data  20   0  360m  19m  10m S    0  0.3   0:00.13 apache2

more use is for clamd 5%

2)Do you run many Amavisd child processes to handle emails?
I think not.



ZhangHuangbin wrote:

with 163 mail users, so many swap usage doesn't make sense to me.

*) Please run 'top' command, which programs use most memory?
*) Do you run many Amavisd child processes to handle emails?

11

Re: iredmail work slow

Cannot figure it out with pastes logs/output so far. Have to log to server for further debug.
Did you try to tune Apache for better performance?

12

Re: iredmail work slow

ZhangHuangbin wrote:

Cannot figure it out with pastes logs/output so far. Have to log to server for further debug.
Did you try to tune Apache for better performance?

No.
Is there any manual  to tune Apache for better performance ?

13

Re: iredmail work slow

platpirs wrote:

Is there any manual  to tune Apache for better performance ?

A quick Google search will give you quick answers. smile

14

Re: iredmail work slow

HI
I still have problems with swap.
Swap use 95% of memory. 
After system rebot some time is ok. sistem use 50% memori. Swap use 5% or lessts.
But after some time 2 day, 1 day random swap use 95% memory.
Maybe any suggestions?



ZhangHuangbin wrote:
platpirs wrote:

Is there any manual  to tune Apache for better performance ?

A quick Google search will give you quick answers. smile

15

Re: iredmail work slow

Please try to figure out why your system requires so much swap first. We cannot login to your server for troubleshooting, so you're on your own.