Reverse Proxy & Log Format
- Written by alamise
- font size decrease font size increase font size
- Print Email
Tip when you install ispconfig 3 behind a reverse proxy like nginx.
In /etc/apache2/sites-available/ispconfig.conf changes '%h' to '%{X-Real-IP}i' to get this:
Code:
LogFormat "%v %{X-Real-IP}i %l %u %t \"%r\" %>s %B \"%{Referer}i\" \"%{User-Agent}i\"" combined_ispconfig
In order to apache logs for awstats works properly.
I've also defined in my /etc/nginx/nginx.conf config file:
Code:
proxy_set_header X-Real-IP $remote_addr;
A better solution will be appreciated
( ! ) Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/vhosts/shan.info/httpdocs/templates/gk_publisher/html/com_k2/templates/default/item.php on line 169 | ||||
---|---|---|---|---|
Call Stack | ||||
# | Time | Memory | Function | Location |
1 | 0.0019 | 412552 | {main}( ) | .../index.php:0 |
2 | 0.0836 | 4262520 | Joomla\CMS\Application\SiteApplication->execute( ) | .../index.php:49 |
3 | 0.0836 | 4262520 | Joomla\CMS\Application\SiteApplication->doExecute( ) | .../CMSApplication.php:196 |
4 | 0.3043 | 11372352 | Joomla\CMS\Application\SiteApplication->dispatch( ) | .../SiteApplication.php:233 |
5 | 0.3051 | 11394064 | Joomla\CMS\Component\ComponentHelper::renderComponent( ) | .../SiteApplication.php:194 |
6 | 0.3061 | 11449392 | Joomla\CMS\Component\ComponentHelper::executeComponent( ) | .../ComponentHelper.php:377 |
7 | 0.3065 | 11476792 | require_once( '/var/www/vhosts/shan.info/httpdocs/components/com_k2/k2.php' ) | .../ComponentHelper.php:402 |
8 | 0.3181 | 11876424 | K2ControllerItem->execute( ) | .../k2.php:64 |
9 | 0.3182 | 11876424 | K2ControllerItem->display( ) | .../BaseController.php:710 |
10 | 0.3275 | 12527128 | K2ControllerItem->display( ) | .../item.php:78 |
11 | 0.3275 | 12527128 | K2ControllerItem->display( ) | .../controller.php:19 |
12 | 0.3315 | 12898168 | Joomla\CMS\Cache\Controller\ViewController->get( ) | .../BaseController.php:663 |
13 | 0.3355 | 12918536 | K2ViewItem->display( ) | .../ViewController.php:102 |
14 | 0.4688 | 15972208 | K2ViewItem->display( ) | .../view.html.php:742 |
15 | 0.4688 | 15972208 | K2ViewItem->loadTemplate( ) | .../HtmlView.php:230 |
16 | 0.4728 | 16145144 | include( '/var/www/vhosts/shan.info/httpdocs/templates/gk_publisher/html/com_k2/templates/default/item.php' ) | .../HtmlView.php:701 |
( ! ) Notice: Only variables should be assigned by reference in /var/www/vhosts/shan.info/httpdocs/templates/gk_publisher/html/com_k2/templates/default/item.php on line 478 | ||||
---|---|---|---|---|
Call Stack | ||||
# | Time | Memory | Function | Location |
1 | 0.0019 | 412552 | {main}( ) | .../index.php:0 |
2 | 0.0836 | 4262520 | Joomla\CMS\Application\SiteApplication->execute( ) | .../index.php:49 |
3 | 0.0836 | 4262520 | Joomla\CMS\Application\SiteApplication->doExecute( ) | .../CMSApplication.php:196 |
4 | 0.3043 | 11372352 | Joomla\CMS\Application\SiteApplication->dispatch( ) | .../SiteApplication.php:233 |
5 | 0.3051 | 11394064 | Joomla\CMS\Component\ComponentHelper::renderComponent( ) | .../SiteApplication.php:194 |
6 | 0.3061 | 11449392 | Joomla\CMS\Component\ComponentHelper::executeComponent( ) | .../ComponentHelper.php:377 |
7 | 0.3065 | 11476792 | require_once( '/var/www/vhosts/shan.info/httpdocs/components/com_k2/k2.php' ) | .../ComponentHelper.php:402 |
8 | 0.3181 | 11876424 | K2ControllerItem->execute( ) | .../k2.php:64 |
9 | 0.3182 | 11876424 | K2ControllerItem->display( ) | .../BaseController.php:710 |
10 | 0.3275 | 12527128 | K2ControllerItem->display( ) | .../item.php:78 |
11 | 0.3275 | 12527128 | K2ControllerItem->display( ) | .../controller.php:19 |
12 | 0.3315 | 12898168 | Joomla\CMS\Cache\Controller\ViewController->get( ) | .../BaseController.php:663 |
13 | 0.3355 | 12918536 | K2ViewItem->display( ) | .../ViewController.php:102 |
14 | 0.4688 | 15972208 | K2ViewItem->display( ) | .../view.html.php:742 |
15 | 0.4688 | 15972208 | K2ViewItem->loadTemplate( ) | .../HtmlView.php:230 |
16 | 0.4728 | 16145144 | include( '/var/www/vhosts/shan.info/httpdocs/templates/gk_publisher/html/com_k2/templates/default/item.php' ) | .../HtmlView.php:701 |