Jump to content


Email configuration with Gmail Business

email configuration gmail

7 replies to this topic

#1 wpler

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 26 October 2017 - 02:22 PM

Hello,

I'm sure that i have do all correct, but if i would test on Settings > Email > Accounts > Incoming with the params:

Type: IMAP
Framework: ZendFramework (only this are could choose??)
Host: imap.gmail.com
Port: 993
Username: **
Password: **
Security: SSL

All ports (993 and also 465 for TCP/UDP) are into ufw free. The site using a letsencrypt SSL certificate (don't know its important or not). On the machine works PHP-FPM 7.0.22 with Nginx on Ubuntu 16.04.03 and also Postfix are installed.

The error.logs of the host are empty, also the php-fpm-error.log file.

Also i have see that was many errors on the install (deprecated warnings into the error-logs on the server). For example:
2017/10/26 09:07:48 [error] 13668#13668: *59630 FastCGI sent in stderr: "PHP message: PHP Notice:  Undefined index: timeout_clients in /var/www/help.xxxx.xxx/htdocs/_lib/objects.global.inc.php on line 974
2017/10/26 09:24:08 [error] 2547#2547: *63331 FastCGI sent in stderr: "PHP message: PHP Notice:  Undefined index: poll_frequency_clients in /var/www/help.xxxx.xxx/htdocs/_lib/objects.global.inc.php on line 973
PHP message: PHP Notice:  Undefined index: poll_frequency_tracking in /var/www/help.xxxx.xxx/htdocs/_lib/objects.global.inc.php on line 973
PHP message: PHP Notice:  Undefined index: timeout_clients in /var/www/help.xxxx.xxx/htdocs/_lib/objects.global.inc.php on line 974
PHP message: PHP Notice:  Undefined index: timeout_chats in /var/www/help.xxxx.xxx/htdocs/_lib/objects.global.inc.php on line 974" while reading response header from upstream, client: 83.56.xx.xxx, server: help.xxxx.xxx, request: "POST /server.php?acid=5af90 HTTP/2.0", upstream: "fastcgi://unix:/run/php/php7.0-fpm.sock:", host: "help.xxxx.xxx", referrer: "https://help.xxxx.xxx/mobile/chat.php?acid=bf4b3"

Maybe this (or other deprecated warnings by php 7.0) are the reason?

#2 Patrick Keil

    Administrator

  • Administrators
  • 3303 posts
  • LocationSingen, Germany

Posted 27 October 2017 - 07:26 AM

Hi,

The message from the logs don't seem to be related.

What message do you get when you run the test?

Cheers

#3 wpler

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 27 October 2017 - 09:46 AM

Hi,

a modal says:
Fehler: cannot connect to host; error = Connection timed out (errno = 110 )

On livezilla's Log -> Email:
27.10.17 11:42:31 - Email Error #110: imap.gmail.com IMAP mailbox connection error: cannot connect to host; error = Connection timed out (errno = 110 )

On Livezilla's Log -> Debug:
>";s:4:"args";a:1:{i:0;O:8:"stdClass":6:{s:4:"host";s:14:"imap.gmail.com";s:4:"auth";s:5:"login";s:4:"user";s:17:"support@xxxx.xxx";s:8:"password";s:12:"xxxxxxx";s:4:"port";s:3:"993";s:3:"ssl";s:3:"SSL";}}}i:2;a:6:{s:4:"file";s:58:"/var/www/help.xxxx.xxx/htdocs/_lib/objects.global.inc.php";s:4:"line";i:5943;s:8:"function";s:13:"ReceiveEmails";s:5:"class";s:10:"MailSystem";s:4:"type";s:2:"->";s:4:"args";a:3:{i:0;b:0;i:1;b:0;i:2;b:1;}}i:3;a:6:{s:4:"file";s:66:"/var/www/help.xxxx.xxx/htdocs/_lib/functions.internal.man.inc.php";s:4:"line";i:29;s:8:"function";s:8:"Download";s:5:"class";s:7:"Mailbox";s:4:"type";s:2:"->";s:4:"args";a:3:{i:0;R:40;i:1;b:0;i:2;b:1;}}i:4;a:6:{s:4:"file";s:41:"/var/www/help.xxxx.xxx/htdocs/intern.php";s:4:"line";i:55;s:8:"function";s:15:"TestMailAccount";s:5:"class";s:13:"ServerManager";s:4:"type";s:2:"::";s:4:"args";a:0:{}}i:5;a:4:{s:4:"file";s:41:"/var/www/help.xxxx.xxx/htdocs/server.php";s:4:"line";i:78;s:4:"args";a:1:{i:0;s:41:"/var/www/help.xxxx.xxx/htdocs/intern.php";}s:8:"function";s:7:"require";}}s:19:"Exceptionprevious";N;}


#4 Patrick Keil

    Administrator

  • Administrators
  • 3303 posts
  • LocationSingen, Germany

Posted 27 October 2017 - 10:46 AM

The outgoing socket connection between webserver and mailserver is blocked, either by firewall or by configuration.

Please contact the technical person in charge of the webserver.

#5 wpler

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 27 October 2017 - 01:38 PM

Nope, certainly not! OsTicket use also phpmail's SMTP installed before Livezilla and there are incoming/outgoing works great (but many other things not).

sudo ufw status:
Status: active
To						 Action	  From
--						 ------	  ----
Nginx Full				 ALLOW	   Anywhere
Postfix				    ALLOW	   Anywhere
993/udp				    ALLOW	   Anywhere
993/tcp				    ALLOW	   Anywhere
465/udp				    ALLOW	   Anywhere
465/tcp				    ALLOW	   Anywhere
Nginx Full (v6)		    ALLOW	   Anywhere (v6)
Postfix (v6)			   ALLOW	   Anywhere (v6)
993/udp (v6)			   ALLOW	   Anywhere (v6)
993/tcp (v6)			   ALLOW	   Anywhere (v6)
465/udp (v6)			   ALLOW	   Anywhere (v6)
465/tcp (v6)			   ALLOW	   Anywhere (v6)

I support the server by myself. I am relatively safe that the used STMP-Connect-Class/Structure are not ready with PHP-7.x (like many other things in this software ;)).

Other suggestions?

#6 wpler

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 30 October 2017 - 10:07 AM

Hi,

in fact the ports are closed, althrough i have open it into my firewall. :???:

#7 wpler

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 30 October 2017 - 12:30 PM

For other users: The Problem was not open/closed ports. On my brandnew OVH Server was enabled a "Dual Stack for using IPv4 & IPv6", which are not correctly configured. Therefore all outgoing requests by server tried connect Domains with IPv6 as first (which ends after 3 minutes into connection timeout) and after then IPv4.

This was the problem. Deactivating this Dual Stack and all works fine.

To trying if the ports are open, do into the terminal/console on server:
telnet imap.gmail.com 993

#8 Patrick Keil

    Administrator

  • Administrators
  • 3303 posts
  • LocationSingen, Germany

Posted 02 November 2017 - 09:59 AM

Thanks for the clarification!





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users