Author Topic: sogod consumes all the RAM available  (Read 4833 times)

mindesbunister

  • Zen Apprentice
  • *
  • Posts: 33
  • Karma: +0/-0
    • View Profile
sogod consumes all the RAM available
« on: September 15, 2014, 10:15:09 pm »
Hi,

for some reason the sogod is consuming all the RAM available. Reminds me on exchange. Any idea how to change this?

Running Zentyal 3.5 .

Attached you will find a screenshot of HTOP.

edit= needless to say, that this is causing the whole server to get stuck, as all the SWAP is getting consumed to.

As soon as this process stops, RAM is getting empty again and the system works perfect
 

Thanks in advance for help.
« Last Edit: September 15, 2014, 10:25:52 pm by mindesbunister »

figarocorso

  • Zentyal Staff
  • Zen Apprentice
  • *****
  • Posts: 43
  • Karma: +4/-0
    • View Profile
    • Personal Site
Re: sogod consumes all the RAM available
« Reply #1 on: September 16, 2014, 03:41:27 pm »
I've seen this sort of issues, but they were mostly solved by a "sudo service sogo restart".

Does the server becomes unusable after trying to login with a user at SOGo webmail? Or it just copes the 100% of your resources when you just start it?
You can see (and share) more information at: /var/log/sogo/sogo.log

Regards,
Miguel (Miky) Julián Ramos - Developer
Zentyal - Active Exchange
www.zentyal.com

mindesbunister

  • Zen Apprentice
  • *
  • Posts: 33
  • Karma: +0/-0
    • View Profile
Re: sogod consumes all the RAM available
« Reply #2 on: September 17, 2014, 09:23:13 pm »
what i found is this

2014-09-17 21:06:42.482 sogod[8774] -[WEClientCapabilities initWithRequest:]: Unknown WebClient: user-agent='Android/4.2.2-EAS-1.3'
Sep 17 21:06:44 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:06:45 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:06:47 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:06:48 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:06:49 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:06:51 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:06:52 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:06:54 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:06:55 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:06:56 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:06:58 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:06:59 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:01 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:02 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:04 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:05 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:06 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:08 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:09 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:17 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:18 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:20 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:21 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:23 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:24 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:26 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:27 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:29 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:30 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:31 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:33 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:35 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:36 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:38 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:40 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:41 sogod [7847]: [WARN] <0x0x7ffd90ffb7b8[WOWatchDogChild]> pid 8774 has been hanging in the same request for 1 minutes
Sep 17 21:07:42 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!
Sep 17 21:07:44 sogod [7847]: [ERROR] <0x0x7ffd910fa688[WOWatchDog]> No child available to handle incoming request!

edit: i have found https://wiki.zentyal.org/wiki/ActiveSync . I am using sogo-activesync . Should i try the other one? Is this anyway somehow related? Just because the Android thing in the log file

« Last Edit: September 17, 2014, 09:25:50 pm by mindesbunister »

papajulio

  • Zentyal Staff
  • Zen Monk
  • *****
  • Posts: 64
  • Karma: +6/-0
    • View Profile
Re: sogod consumes all the RAM available
« Reply #3 on: September 18, 2014, 09:22:16 am »
Apparently it's a problem with a misconfiguration of SOGO,

https://lists.inverse.ca/sogo/arc/users/2013-11/msg00096.html

WOWorkersCount by default apparently it's 1, increase it to 10 and check again.

https://github.com/inverse-inc/sogo/blob/master/SoObjects/SOGo/SOGoDefaults.plist

Cheers!!
--
Julio José García Martín - QA Engineer

mindesbunister

  • Zen Apprentice
  • *
  • Posts: 33
  • Karma: +0/-0
    • View Profile
Re: sogod consumes all the RAM available
« Reply #4 on: September 18, 2014, 08:45:34 pm »
alright. I did change it from 1 to 10 in /usr/lib/GNUstep/Frameworks/SOGo.framework/Versions/2/Resources/SOGoDefaults.plist

rebooted, but nothing changed.

It still tells me in the logs, that there is No child available to handle incoming request!

edit= it seems nothing has changed after editing the file. The workercount seems to be still 1 ?! see attached screenshot. Have i modified the wrong file?



Any other ideas?
« Last Edit: September 19, 2014, 09:56:24 am by mindesbunister »

mindesbunister

  • Zen Apprentice
  • *
  • Posts: 33
  • Karma: +0/-0
    • View Profile
Re: sogod consumes all the RAM available
« Reply #5 on: September 19, 2014, 12:51:59 pm »
ok seems to be fixed. I did change the wrong file. It wants to be changed in /etc/default/sogo

my reference was http://www.sogo.nu/files/docs/SOGo%20Installation%20Guide.pdf page 14

have changed it to 10. So far so good


Hmm After reboot it went back to 1. Can someone tell what i have to do to keep this at 10 ?
« Last Edit: September 19, 2014, 01:00:07 pm by mindesbunister »

figarocorso

  • Zentyal Staff
  • Zen Apprentice
  • *****
  • Posts: 43
  • Karma: +4/-0
    • View Profile
    • Personal Site
Re: sogod consumes all the RAM available
« Reply #6 on: September 19, 2014, 01:50:53 pm »
Hi,

There is a header in /etc/default/sogo that says that "this file is managed by Zentyal" (or similar). This means that file is generated by a Zentyal template/stub.

If you want to change that file (good work finding it out, I was going to point you there) you should follow this documentation: https://wiki.zentyal.org/wiki/En/3.5/Development_and_advanced_configuration

(Quick sum up: copy the stub to custom stubs folder, modify it, enjoy ;-) )

Cheers,
Miguel (Miky) Julián Ramos - Developer
Zentyal - Active Exchange
www.zentyal.com

mindesbunister

  • Zen Apprentice
  • *
  • Posts: 33
  • Karma: +0/-0
    • View Profile
Re: sogod consumes all the RAM available
« Reply #7 on: September 20, 2014, 11:35:10 am »
hmm ok. Thanks a lot for that.

I have copied the sogo.conf.mas and the sogo.mas into /etc/zentyal/stubs/openchange  (after creating the subfolders stubs and openchange). Then i changed the value in the sogo.mas for the prefork to 10. It now looks the following

<%args>
    $prefork => 10
</%args>
<%init>
</%init>
# Generated by Zentyal

# The amount of processes that should be spawned
PREFORK=<% $prefork %>

# The name of the account under which SOGo will be running (Default: sogo)
USER=sogo


But i think i have done something wrong, as it is getting ignored. The /etc/default/sogo still displays the Prefork=1 .

Any ideas on what i have done wrong?

jbahillo

  • Zentyal Staff
  • Zen Hero
  • *****
  • Posts: 1444
  • Karma: +77/-2
    • View Profile
Re: sogod consumes all the RAM available
« Reply #8 on: September 20, 2014, 07:28:26 pm »
Hello:

Instead of changing the default value of the variable,  directly hardcode where it is used, so:
<%args>
    $prefork => 10
</%args>
<%init>
</%init>
# Generated by Zentyal

# The amount of processes that should be spawned
PREFORK=10
# The name of the account under which SOGo will be running (Default: sogo)
USER=sogo

mindesbunister

  • Zen Apprentice
  • *
  • Posts: 33
  • Karma: +0/-0
    • View Profile
Re: sogod consumes all the RAM available
« Reply #9 on: September 22, 2014, 01:02:15 pm »
perfect. Ok, now it is using the defined value.

Never the less, it is still showing the same behaviour . I have tried 1,4 and 10. It is still using all the RAM and SWAP available.

edit= even with 5, 8 and 20 it does not change anything

I can not realy see any changes in the behaviour by changing this value. Is there anything else i can go for?

System is unusable like this.

Any help is greatly appreciated.

kind regards,
« Last Edit: September 22, 2014, 02:43:01 pm by mindesbunister »

figarocorso

  • Zentyal Staff
  • Zen Apprentice
  • *****
  • Posts: 43
  • Karma: +4/-0
    • View Profile
    • Personal Site
Re: sogod consumes all the RAM available
« Reply #10 on: September 24, 2014, 11:40:18 am »
At the "oneworker" screenshot, the process didn't seem to  be wasting all the server memory, so let me ask a few questions here:
* Is the sogo process stable just after a "sudo service sogo restart"?
* Does the "memory consuming problem" appear when you enter into some user account through the web UI?

If both answers are "yes", it is probably a problem of the given user account, just try to create a new one, and see what happens there.

Thank you for your information.
Miguel (Miky) Julián Ramos - Developer
Zentyal - Active Exchange
www.zentyal.com

mindesbunister

  • Zen Apprentice
  • *
  • Posts: 33
  • Karma: +0/-0
    • View Profile
Re: sogod consumes all the RAM available
« Reply #11 on: September 24, 2014, 11:46:09 am »
Thanks for your answer.

Indeed, the answer is yes. Just as soon as someone is trying to access via webmail, phone or outlook, it "explodes". I have tried with 3 different accounts with the same result.

I will create a new domain account, try it again and report back.

thanks

figarocorso

  • Zentyal Staff
  • Zen Apprentice
  • *****
  • Posts: 43
  • Karma: +4/-0
    • View Profile
    • Personal Site
Re: sogod consumes all the RAM available
« Reply #12 on: September 24, 2014, 11:56:45 am »
BTW, sorry for not asking this before, it would be nice if you could also attach here the versions of the Zentyal packages:
dpkg -l *zentyal*

Thank you in advance.
Miguel (Miky) Julián Ramos - Developer
Zentyal - Active Exchange
www.zentyal.com

mindesbunister

  • Zen Apprentice
  • *
  • Posts: 33
  • Karma: +0/-0
    • View Profile
Re: sogod consumes all the RAM available
« Reply #13 on: September 24, 2014, 12:05:47 pm »
No prob. Here they are


figarocorso

  • Zentyal Staff
  • Zen Apprentice
  • *****
  • Posts: 43
  • Karma: +4/-0
    • View Profile
    • Personal Site
Re: sogod consumes all the RAM available
« Reply #14 on: September 24, 2014, 01:29:15 pm »
It seem someone just came from a holiday break ¬¬  ;D

Now we know we are in a 3.5, also versions about *sogo* and *openchange* packages would be good to research. You can just provide them when testing the new user behaviour.
Miguel (Miky) Julián Ramos - Developer
Zentyal - Active Exchange
www.zentyal.com