Problem with Logging Plugin

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Problem with Logging Plugin

byrnejb
The problem I am experiencing is that whenever I enable the squirrel_logger
Logging plugin then the SM web app blanks the web page and becomes
non-responsive when a user opens a new or logs out of an existing SM session.

Setup.

CentOS-6.5 x86_64
Server version: Apache/2.2.15 (Unix) Server built:   Jul 23 2014 14:17:29

. . .
  ServerName webmail.hamilton.harte-lyne.ca
  DocumentRoot  /usr/share/squirrelmail
  ErrorLog      /var/log/httpd/webmail_ssl_error.log
  LogLevel      warn
  TransferLog   /var/log/httpd/webmail_ssl_access.log

  Alias         /webmail        /usr/share/squirrelmail

  <Directory /usr/share/squirrelmail>
    Order allow,deny
    allow from all
    Options +Indexes
  </Directory>

#   SSL Engine Switch:
#   Enable/Disable SSL for this virtual host.
SSLEngine on
. . .


SquirrelMail configtest

This script will try to check some aspects of your SquirrelMail configuration
and point you to errors whereever it can find them. You need to go run conf.pl
in the config/ directory first before you run this script.

SquirrelMail version: 1.4.22-4.el6
Config file version: 1.4.0
Config file last modified: 08 September 2014 17:09:38
Checking PHP configuration...
    PHP version 5.3.3 OK.
    Running as N/A(N/A) / N/A(N/A)
    display_errors:
    error_reporting: 22527
    variables_order OK: GPCS.
    PHP extensions OK. Dynamic loading is disabled.

    ERROR: You have configured PHP not to allow short tags
(short_open_tag=off). This shouldn't be a problem with SquirrelMail or any
plugin coded coded according to the SquirrelMail Coding Guidelines, but if
you experience problems with PHP code being displayed in some of the pages
and changing setting to "on" solves the problem, please file a bug report
against the failing plugin. The correct contact information is most likely
to be found in the plugin documentation.
Checking paths...
    Data dir OK.
    Attachment dir OK.
    Plugins OK.
    Themes OK.
    Default language OK.
    Base URL detected as: https://webmail.harte-lyne.ca/src (location base
autodetected)
Checking outgoing mail service....
    SMTP server OK (220 inet08.hamilton.harte-lyne.ca ESMTP Postfix)
Checking IMAP service....
    IMAP server ready (* OK [CAPABILITY IMAP4 IMAP4rev1 LITERAL+ ID AUTH=LOGIN
AUTH=PLAIN SASL-IR COMPRESS=DEFLATE] inet07.hamilton.harte-lyne.ca Cyrus
IMAP v2.3.16-Fedora-RPM-2.3.16-6.el6_2.5 server ready)
    Capabilities: * CAPABILITY IMAP4 IMAP4rev1 LITERAL+ ID AUTH=LOGIN
AUTH=PLAIN SASL-IR COMPRESS=DEFLATE ACL RIGHTS=kxte QUOTA
MAILBOX-REFERRALS NAMESPACE UIDPLUS NO_ATOMIC_RENAME UNSELECT CHILDREN
MULTIAPPEND BINARY SORT SORT=MODSEQ THREAD=ORDEREDSUBJECT
THREAD=REFERENCES ANNOTATEMORE CATENATE CONDSTORE SCAN IDLE LISTEXT
LIST-SUBSCRIBED X-NETSCAPE URLAUTH
Checking internationalization (i18n) settings...
     gettext - Gettext functions are available. On some systems you must have
appropriate system locales compiled.
     mbstring - Mbstring functions are available.
     recode - Recode functions are unavailable.
     iconv - Iconv functions are available.
     timezone - Webmail users can change their time zone settings.
Checking database functions...
    not using database functionality.

Congratulations, your SquirrelMail setup looks fine to me!

SquirrelMail Configuration : Read: config.php (1.4.0)
---------------------------------------------------------
Plugins
  Installed Plugins
    1. delete_move_next
    2. squirrelspell
    3. newmail
    4. compatibility
    5. sent_subfolders
    6. calendar_file_backend
    7. message_details
    8. calendar
    9. administrator
    10. translate
    11. filters
    12. vlogin
    13. abook_import_export
    14. abook_take
    15. listcommands
    16. info
    17. smime
    18. attachment_tnef
    19. autocomplete
    20. move_all_messages
    21. view_as_html

  Available Plugins:
    22. bug_report
    23. captcha
    24. compose_extras
    25. fortune
    26. gpg
    27. lockout
    28. mail_fetch
    29. quicksave
    30. spamcop
    31. squirrel_logger
    32. test

-rw-r--r--. 1 root    root      22814 Dec  4  2006
plugins/abook_import_export-1.0-1.4.4.tar.gz
-rw-r--r--. 1 root    root      15362 Dec 15  2009
plugins/attachment_tnef-0.7-1.4.0.hll.tar.gz
-rw-r--r--. 1 root    root       4237 Jul  8  2009
plugins/autocomplete.2.0-1.0.0.tar.gz
-rw-r--r--. 1 root    root    2061228 Jul  8  2011
plugins/captcha-1.2.3-1.2.9.tar.gz
-rw-r--r--. 1 root    root      41497 Dec  6  2009
plugins/compatibility-2.0.16-1.0.tar.gz
-rw-r--r--. 1 root    root      24851 Nov 20  2011
plugins/compose_extras-0.9-1.4.0.tar.gz
-rw-r--r--. 1 root    root     553777 Jun 20  2013 plugins/gpg-2.1.1.1.tar.gz
-rw-r--r--. 1 byrnejb byrnejb  553777 Jan  8  2014 plugins/gpg-2.1.1.r.tar.gz
-rw-r--r--. 1 root    root     553758 Jun 17  2013 plugins/gpg-2.1.1.tar.gz
-rw-r--r--. 1 root    root      23567 Nov  4  2009
plugins/lockout-1.6-1.4.1.tar.gz
-rw-r--r--. 1 root    root      24561 Nov  4  2010
plugins/lockout-1.7-1.4.1.tar.gz
-rw-r--r--. 1 root    root      13271 Mar  4  2011
plugins/move_all_messages-1.0-1.4.0.tar.gz
-rw-r--r--. 1 root    root      35269 Feb  2  2010
plugins/quicksave-2.4.5-1.2.9.tar.gz
-rw-r--r--. 1 root    root     299580 Jun 20  2006
plugins/shared_calendars-2.0.1-1.4.0.tar.gz
-rw-r--r--. 1 root    root     368749 Jan  1  2012 plugins/smime-1.0-1.1.1.tar.gz
-rw-r--r--. 1 root    root      31220 Jul  6  2011
plugins/squirrel_logger-2.3.1-1.2.7.tar.gz
-rw-r--r--. 1 root    root       4715 Jul  8  2009
plugins/view_as_html-3.8.tar.gz


--
***          E-Mail is NOT a SECURE channel          ***
James B. Byrne                mailto:[hidden email]
Harte & Lyne Limited          http://www.harte-lyne.ca
9 Brockley Drive              vox: +1 905 561 1241
Hamilton, Ontario             fax: +1 905 561 0757
Canada  L8E 3C3


------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce.
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
-----
squirrelmail-users mailing list
Posting guidelines: http://squirrelmail.org/postingguidelines
List address: [hidden email]
List archives: http://news.gmane.org/gmane.mail.squirrelmail.user
List info (subscribe/unsubscribe/change options): https://lists.sourceforge.net/lists/listinfo/squirrelmail-users
Reply | Threaded
Open this post in threaded view
|

Re: Problem with Logging Plugin

Paul Lesniewski
On 9/8/14, James B. Byrne <[hidden email]> wrote:
> The problem I am experiencing is that whenever I enable the squirrel_logger
> Logging plugin then the SM web app blanks the web page and becomes
> non-responsive when a user opens a new or logs out of an existing SM
> session.

This is a FAQ in the list archives.  See:
http://www.squirrelmail.org/docs/admin/admin-11.html#ss11.1

--
Paul Lesniewski
SquirrelMail Team
Please support Open Source Software by donating to SquirrelMail!
http://squirrelmail.org/donate_paul_lesniewski.php

------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce.
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
-----
squirrelmail-users mailing list
Posting guidelines: http://squirrelmail.org/postingguidelines
List address: [hidden email]
List archives: http://news.gmane.org/gmane.mail.squirrelmail.user
List info (subscribe/unsubscribe/change options): https://lists.sourceforge.net/lists/listinfo/squirrelmail-users
Reply | Threaded
Open this post in threaded view
|

Re: Problem with Logging Plugin

byrnejb

On Tue, September 9, 2014 03:08, Paul Lesniewski wrote:
> On 9/8/14, James B. Byrne <[hidden email]> wrote:
>> The problem I am experiencing is that whenever I enable the squirrel_logger
>> Logging plugin then the SM web app blanks the web page and becomes
>> non-responsive when a user opens a new or logs out of an existing SM
>> session.
>
> This is a FAQ in the list archives.  See:
> http://www.squirrelmail.org/docs/admin/admin-11.html#ss11.1

Adding the error reporting flags to /etc/php.ini produces the following error
in  /var/log/httpd/webmail_ssl_error.log:

[Tue Sep 09 09:53:34 2014] [error] [client 216.185.71.76] PHP Deprecated:
Function eregi() is deprecated in
/usr/share/squirrelmail/plugins/abook_take/setup.php on line 50, referer:
https://webmail.harte-lyne.ca/webmail/src/right_main.php?PG_SHOWALL=0&sort=0&startMessage=1&mailbox=INBOX

Running the configtest script results in this error as well:


PHP Warning:  date(): It is not safe to rely on the system's timezone
settings. You are *required* to use the date.timezone setting or the
date_default_timezone_set() function. In case you used any of those methods
and you are still getting this warning, you most likely misspelled the
timezone identifier. We selected 'America/New_York' for 'EDT/-4.0/DST' instead
in /usr/share/squirrelmail/src/configtest.php on line 80


However, if the logging plugin is enabled and I try and login then the page
goes blank and nothing whatsoever is logged in any file that I can detect.


Other than listing the logging plugin as well the debugging plugin yields the
following output whether the logging plugin is enabled or not:

Notice: A session had already been started - ignoring session_start() in
/usr/share/squirrelmail/functions/global.php on line 473


Stack Trace:

session_start()
/usr/share/squirrelmail/functions/global.php
line 473

    sqsession_start()
    /usr/share/squirrelmail/functions/global.php
    line 453

        sqsession_is_active()
        /usr/share/squirrelmail/functions/global.php
        line 291

            sqsession_register("https://webmail.harte-lyne.ca", "sq_base_url")
            /usr/share/squirrelmail/functions/strings.php
            line 414

                get_location()
                /usr/share/squirrelmail/src/redirect.php
                line 38



My browser information:
  Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Firefox/24.0

My web server information:
  PHP Version 5.3.3
  PHP Extensions (List)
    * 0 = Core
    * 1 = date
    * 2 = ereg
    * 3 = libxml
    * 4 = openssl
    * 5 = pcre
    * 6 = zlib
    * 7 = bz2
    * 8 = calendar
    * 9 = ctype
    * 10 = hash
    * 11 = filter
    * 12 = ftp
    * 13 = gettext
    * 14 = gmp
    * 15 = session
    * 16 = iconv
    * 17 = Reflection
    * 18 = standard
    * 19 = shmop
    * 20 = SPL
    * 21 = SimpleXML
    * 22 = sockets
    * 23 = exif
    * 24 = tokenizer
    * 25 = xml
    * 26 = apache2handler
    * 27 = curl
    * 28 = fileinfo
    * 29 = json
    * 30 = mbstring
    * 31 = Phar
    * 32 = zip

SquirrelMail-specific information:
  Version:  1.4.22-4.el6
  Plugins (List)
    * 0 = delete_move_next
    * 1 = squirrelspell
    * 2 = newmail
    * 3 = compatibility
    * 4 = sent_subfolders
    * 5 = calendar_file_backend
    * 6 = message_details
    * 7 = calendar
    * 8 = administrator
    * 9 = translate
    * 10 = filters
    * 11 = vlogin
    * 12 = abook_import_export
    * 13 = abook_take
    * 14 = listcommands
    * 15 = info
    * 16 = smime
    * 17 = attachment_tnef
    * 18 = autocomplete
    * 19 = move_all_messages
    * 20 = view_as_html
    * 21 = debugger

My IMAP server information:
  Server type:  cyrus
  Server info:   [HIDDEN]  Capabilities:  Fatal error: tls_start_servertls()
failed


--
***          E-Mail is NOT a SECURE channel          ***
James B. Byrne                mailto:[hidden email]
Harte & Lyne Limited          http://www.harte-lyne.ca
9 Brockley Drive              vox: +1 905 561 1241
Hamilton, Ontario             fax: +1 905 561 0757
Canada  L8E 3C3


------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce.
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
-----
squirrelmail-users mailing list
Posting guidelines: http://squirrelmail.org/postingguidelines
List address: [hidden email]
List archives: http://news.gmane.org/gmane.mail.squirrelmail.user
List info (subscribe/unsubscribe/change options): https://lists.sourceforge.net/lists/listinfo/squirrelmail-users
Reply | Threaded
Open this post in threaded view
|

Re: Problem with Logging Plugin

Paul Lesniewski
On 9/9/14, James B. Byrne <[hidden email]> wrote:

>
> On Tue, September 9, 2014 03:08, Paul Lesniewski wrote:
>> On 9/8/14, James B. Byrne <[hidden email]> wrote:
>>> The problem I am experiencing is that whenever I enable the
>>> squirrel_logger
>>> Logging plugin then the SM web app blanks the web page and becomes
>>> non-responsive when a user opens a new or logs out of an existing SM
>>> session.
>>
>> This is a FAQ in the list archives.  See:
>> http://www.squirrelmail.org/docs/admin/admin-11.html#ss11.1
>
> Adding the error reporting flags to /etc/php.ini produces the following
> error
> in  /var/log/httpd/webmail_ssl_error.log:
>
> [Tue Sep 09 09:53:34 2014] [error] [client 216.185.71.76] PHP Deprecated:
> Function eregi() is deprecated in
> /usr/share/squirrelmail/plugins/abook_take/setup.php on line 50, referer:
> https://webmail.harte-lyne.ca/webmail/src/right_main.php?PG_SHOWALL=0&sort=0&startMessage=1&mailbox=INBOX

Please take note of the warning text for this plugin:
http://squirrelmail.org/plugin_view.php?id=31

> PHP Warning:  date(): It is not safe to rely on the system's timezone
> settings. You are *required* to use the date.timezone setting or the
> date_default_timezone_set() function. In case you used any of those methods
> and you are still getting this warning, you most likely misspelled the
> timezone identifier. We selected 'America/New_York' for 'EDT/-4.0/DST'
> instead
> in /usr/share/squirrelmail/src/configtest.php on line 80

This is self-explanatory; otherwise Google is your friend.

> However, if the logging plugin is enabled and I try and login then the page
> goes blank and nothing whatsoever is logged in any file that I can detect.

Things don't go blank without an error somewhere.  Increase your
logging verbosity?  Go back to default configuration file for the
plugin?  Keep digging.

Cheers,
--
Paul Lesniewski
SquirrelMail Team
Please support Open Source Software by donating to SquirrelMail!
http://squirrelmail.org/donate_paul_lesniewski.php

------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce.
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
-----
squirrelmail-users mailing list
Posting guidelines: http://squirrelmail.org/postingguidelines
List address: [hidden email]
List archives: http://news.gmane.org/gmane.mail.squirrelmail.user
List info (subscribe/unsubscribe/change options): https://lists.sourceforge.net/lists/listinfo/squirrelmail-users
Reply | Threaded
Open this post in threaded view
|

Re: Problem with Logging Plugin

byrnejb

On Tue, September 9, 2014 13:22, Paul Lesniewski wrote:
>
> Things don't go blank without an error somewhere.  Increase your
> logging verbosity?  Go back to default configuration file for the
> plugin?  Keep digging.
>

The problem was, as you suggested, with the config.php file.  The statement
$sl_dateformat = 'M j H:i:s'; had a trailing ":" after the terminal ";"
character. Everything seems to work now.

I have downloaded the add_address replacement for the abook_take plugin and
will get around to testing that once the fail2ban configuration is working.

I have also added the default timezone to /etc/php.ini.

Thank you,

--
***          E-Mail is NOT a SECURE channel          ***
James B. Byrne                mailto:[hidden email]
Harte & Lyne Limited          http://www.harte-lyne.ca
9 Brockley Drive              vox: +1 905 561 1241
Hamilton, Ontario             fax: +1 905 561 0757
Canada  L8E 3C3


------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce.
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
-----
squirrelmail-users mailing list
Posting guidelines: http://squirrelmail.org/postingguidelines
List address: [hidden email]
List archives: http://news.gmane.org/gmane.mail.squirrelmail.user
List info (subscribe/unsubscribe/change options): https://lists.sourceforge.net/lists/listinfo/squirrelmail-users
Reply | Threaded
Open this post in threaded view
|

Re: Problem with Logging Plugin

André Z. D. A.
In reply to this post by byrnejb
Couldn't an easy command like "php -l config.php" be added to the configtest? I have just tested it for a trailing colon like it happened and it will complain. Should someone add a bug or request or patch for this?

Further, it will complain about many other simple mistakes we could probably miss when quickly skimming the config.php file. And James did, from the beginning, what I would do: "Does configtest complains? No? So the problem is not on configuration". Which is not what we've found.

Regards,

Andre'

------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
-----
squirrelmail-users mailing list
Posting guidelines: http://squirrelmail.org/postingguidelines
List address: [hidden email]
List archives: http://news.gmane.org/gmane.mail.squirrelmail.user
List info (subscribe/unsubscribe/change options): https://lists.sourceforge.net/lists/listinfo/squirrelmail-users