Steps to fix where proxy service not starting: Difference between revisions

(Created page with "===<h1>Steps to fix where proxy service not starting</h1>=== <hr> <br> <h2>Problem:</h2> Proxy service not starting and getting ''NullPointerException''[zimbra@ZIMBRA ~]$ <...")
 
No edit summary
Line 5: Line 5:
<h2>Problem:</h2>
<h2>Problem:</h2>


Proxy service not starting and getting ''NullPointerException''[zimbra@ZIMBRA ~]$
Proxy service not starting and getting ''NullPointerException'' with "zmproxyconfgen -v"
 
<pre>
<pre>
[zimbra@ZIMBRA ~]$
zmproxyctl restart
zmproxyctl restart
/opt/zimbra/conf/nginx.conf is missing.
/opt/zimbra/conf/nginx.conf is missing.
Starting nginx...failed. /opt/zimbra/conf/nginx.conf is missing. with "zmproxyconfgen -v"
Starting nginx...failed. /opt/zimbra/conf/nginx.conf is missing.  
</pre>
</pre>


Line 18: Line 20:
Stopping proxy...proxy is not running.
Stopping proxy...proxy is not running.
Starting proxy...nginx: [emerg] invalid port in "192.168.0.120:0" of the "listen" directive in /opt/zimbra/conf/nginx/includes/nginx.conf.mail.imap:7
Starting proxy...nginx: [emerg] invalid port in "192.168.0.120:0" of the "listen" directive in /opt/zimbra/conf/nginx/includes/nginx.conf.mail.imap:7
</pre>
</pre>  
 
'''OR'''


<pre>
<pre>
Line 51: Line 55:
Proxy and memcached services install but not configured.   
Proxy and memcached services install but not configured.   


1). Check IMAP port settings in global and server level configuration.   
'''1).''' Check IMAP port settings in global and server level configuration.   


  $ zmprov -l gacf zimbraImapBindPort zimbraImapProxyBindPort   
  $ zmprov -l gacf zimbraImapBindPort zimbraImapProxyBindPort   
Line 57: Line 61:




2). Configure correct ports on server and global config level if default ports previously changed.  .   
'''2).''' Configure correct ports on server and global config level if default ports previously changed.  .   


  zmprov -l mcf zimbraImapBindPort 7143 zimbraImapProxyBindPort 143  
  zmprov -l mcf zimbraImapBindPort 7143 zimbraImapProxyBindPort 143  
Line 71: Line 75:




Heera Singh Koranga


"Heera Singh" <hsingh@zimbra.com>
 
 
Submitted by:  Heera Singh Koranga

Revision as of 08:25, 21 August 2017

Steps to fix where proxy service not starting



Problem:

Proxy service not starting and getting NullPointerException with "zmproxyconfgen -v"

[zimbra@ZIMBRA ~]$ 
zmproxyctl restart
/opt/zimbra/conf/nginx.conf is missing.
Starting nginx...failed. /opt/zimbra/conf/nginx.conf is missing. 

OR

[zimbra@ZIMBRA ~]$ zmproxyctl restart
Stopping proxy...proxy is not running.
Starting proxy...nginx: [emerg] invalid port in "192.168.0.120:0" of the "listen" directive in /opt/zimbra/conf/nginx/includes/nginx.conf.mail.imap:7

OR

[zimbra@ZIMBRA ~]$ /opt/zimbra/libexec/zmproxyconfgen -v
[] DEBUG: GET_CONN - millis=[2], usage=[GET_GLOBALCONFIG], conn=[1], connPool=[ZimbraReplica(770947228)]
[] DEBUG: GET_ENTRY - millis=[22], usage=[GET_GLOBALCONFIG], conn=[1], dn=[cn=config,cn=zimbra]
[] DEBUG: REL_CONN - conn=[1]
[] DEBUG: Working Directory: /opt/zimbra
[] DEBUG: Template Directory: /opt/zimbra/conf/nginx/templates
[] DEBUG: Config Includes Directory: /opt/zimbra/conf/nginx/includes
[] DEBUG: Config File Prefix: nginx.conf
[] DEBUG: Template File Prefix: nginx.conf
[] DEBUG: Building Default Variable Map
[] DEBUG: Loading Attrs in Domain Level
[] DEBUG: GET_CONN - millis=[0], usage=[SEARCH], conn=[1], connPool=[ZimbraReplica(770947228)]
[] DEBUG: SEARCH - millis=[6], resp=[0 (success)], usage=[SEARCH], conn=[1], controls=[Simple Paged Results Control], base=[], filter=[(objectClass=zimbraDomain)]
[] DEBUG: REL_CONN - conn=[1]
[] DEBUG: Updating Default Variable Map
[] DEBUG: GET_CONN - millis=[0], usage=[GET_SERVER], conn=[1], connPool=[ZimbraReplica(770947228)]
[] DEBUG: GET_ENTRY - millis=[1], usage=[GET_SERVER], conn=[1], dn=[cn=SERVER.EXAMPLE.COM,cn=servers,cn=zimbra]
[] DEBUG: REL_CONN - conn=[1]
Exception in thread "main" java.lang.NullPointerException
at com.zimbra.cs.util.ProxyConfVar.isValidUpstream(ProxyConfGen.java:308)
at com.zimbra.cs.util.WebEwsSSLUpstreamServersVar.update(ProxyConfGen.java:989)
at com.zimbra.cs.util.ProxyConfGen.updateDefaultVars(ProxyConfGen.java:2471)
at com.zimbra.cs.util.ProxyConfGen.createConf(ProxyConfGen.java:2630)
at com.zimbra.cs.util.ProxyConfGen.main(ProxyConfGen.java:2827)

Solution:

Proxy and memcached services install but not configured.

1). Check IMAP port settings in global and server level configuration.

$ zmprov -l gacf zimbraImapBindPort zimbraImapProxyBindPort   
$ zmprov -l gs `zmhostname` zimbraImapBindPort zimbraImapProxyBindPort    


2). Configure correct ports on server and global config level if default ports previously changed. .

zmprov -l mcf zimbraImapBindPort 7143 zimbraImapProxyBindPort 143 
zmprov -l ms `zmhostname` zimbraImapBindPort 7143 zimbraImapProxyBindPort 143    
/opt/zimbra/libexec/zmproxyconfig -m -w -e -x redirect -H `zmhostname`  
zmprov mcf zimbraPublicServiceHostname MAIL.EXAMPLE.COM                          #Enter FQDN here. 
zmprov mcf zimbraPublicServiceProtocol https
zmprov mcf zimbraPublicServicePort 443   
zmprov ms `zmhostname` zimbraMailReferMode reverse-proxied  
zmcontrol restart  
zmcontrol status



Submitted by: Heera Singh Koranga

Jump to: navigation, search