CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviMail (Moderator: Piotr Szotkowski) »
  • Mail cron exhausting php memory
Pages: [1]

Author Topic: Mail cron exhausting php memory  (Read 1085 times)

pswartz

  • I post occasionally
  • **
  • Posts: 41
  • Karma: 0
  • CiviCRM version: 4.4.6
  • CMS version: Drupal 7.x
  • MySQL version: 5.1.46
  • PHP version: 5.3.3
Mail cron exhausting php memory
January 27, 2012, 06:21:32 am
Hello All,
Our latest mailing is causing this error in our apache logs:

[Fri Jan 27 07:33:54 2012] [error] [client 127.0.0.2] PHP Fatal error:  Allowed memory size of 134217728 bytes exhausted (tried to allocate 7228335 bytes) in /srv/www/htdocs/sites/all/modules/civicrm/packages/Mail/mime.php on line 1030
[Fri Jan 27 07:43:09 2012] [error] [client 127.0.0.2] PHP Fatal error:  Allowed memory size of 134217728 bytes exhausted (tried to allocate 7228335 bytes) in /srv/www/htdocs/sites/all/modules/civicrm/packages/Mail/mime.php on line 1030
[Fri Jan 27 07:44:44 2012] [error] [client 127.0.0.2] PHP Fatal error:  Allowed memory size of 205520896 bytes exhausted (tried to allocate 7228335 bytes) in /srv/www/htdocs/sites/all/modules/civicrm/packages/Mail/mime.php on line 1030
[Fri Jan 27 07:46:15 2012] [error] [client 127.0.0.2] PHP Fatal error:  Allowed memory size of 268435456 bytes exhausted (tried to allocate 7228335 bytes) in /srv/www/htdocs/sites/all/modules/civicrm/packages/Mail/mime.php on line 1030

Our php.ini started out with the standard 128M of memory, I then increased to 196M, then again to 256M and each time the memory was exhausted.

Upon searching through the forums, I saw a couple of other hits, but no real answer --
http://forum.civicrm.org/index.php/topic,22211.msg93360.html#msg93360
http://forum.civicrm.org/index.php/topic,22359.msg93714.html

I did confirm that PHP was getting all 256M of memory through - phpinfo();

We are using:
CiviCRM version:4.0.8
CMS version:Drupal 7.10
MySQL version:5.1.46
PHP version:5.3.3

Any help would be appreciated!

Patrick

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: Mail cron exhausting php memory
January 27, 2012, 07:43:38 am
Hi,

Are you using the cli version or the wget version?

you should use the cli (where you can put much more memory and leave the cgi/mod to a 'saner' 128)

http://book.civicrm.org/user/basic-setup/email-system-configuration

X+
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

pswartz

  • I post occasionally
  • **
  • Posts: 41
  • Karma: 0
  • CiviCRM version: 4.4.6
  • CMS version: Drupal 7.x
  • MySQL version: 5.1.46
  • PHP version: 5.3.3
Re: Mail cron exhausting php memory
January 27, 2012, 04:44:32 pm
Thanks for the idea, as I was indeed using the wget version.
However, that leads to a different issue -- due mostly to my lack of understanding or inability to read/comprehend...
But, trying to get cli cron job to work I get this email response --

PHP Warning:  session_start(): open(/var/lib/php5/sess_g25if60dm7ml296tq7hn9rlg18cavbhe, O_RDWR) failed: Permission denied (13) in /srv/www/htdocs/sites/all/modules/civicrm/bin/cli.php on line 86

I have tried every username combination that I can think of and none of them make the script happy...

Is the "USER=" the webuser that runs apache/drupal/civicrm?
Is there supposed to be a space between the "-s" "-u" and "-p" .. like "-u myusername -p mypasswd -s default" or no space like "-umyusername -pmypasswd -sdefault"? 
And is that username the drupal/civi user that has rights?

Between reading the book link and the cli.php code I wasn't able to determine the right method... as neither seemed to work.

Thank you for your patience and support!

Patrick


Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviMail (Moderator: Piotr Szotkowski) »
  • Mail cron exhausting php memory

This forum was archived on 2017-11-26.