trying to add to this file fastcgi.conf

May 1, 2015 1.2k views
Apache Linux Commands Ubuntu

I am trying to follow this tutorial https://www.digitalocean.com/community/tutorials/how-to-configure-nginx-as-a-web-server-and-reverse-proxy-for-apache-on-one-ubuntu-14-04-droplet

I have checked apache version sudo apache2 -v
Server version: Apache/2.4.10 (Ubuntu)

it then says to edit this file sudo nano /etc/apache2/mods-enabled/fastcgi.conf

and Add the following lines to the bottom of the <IfModule mod_fastcgi.c> . . . </IfModule> block for Apache 2.4:

AddType application/x-httpd-fastphp5 .php
Action application/x-httpd-fastphp5 /php5-fcgi
Alias /php5-fcgi /usr/lib/cgi-bin/php5-fcgi
FastCgiExternalServer /usr/lib/cgi-bin/php5-fcgi -socket /var/run/php5-fpm.sock -pass-header Authorization
<Directory /usr/lib/cgi-bin>
Require all granted
</Directory>

which I have like the following

<IfModule mod_fastcgi.c>
AddHandler fastcgi-script .fcgi
#FastCgiWrapper /usr/lib/apache2/suexec
FastCgiIpcDir /var/lib/apache2/fastcgi
AddType application/x-httpd-fastphp5 .php
Action application/x-httpd-fastphp5 /php5-fcgi
Alias /php5-fcgi /usr/lib/cgi-bin/php5-fcgi
FastCgiExternalServer /usr/lib/cgi-bin/php5-fcgi -socket /var/run/php5-fpm.sock -pass-header Authorization
<Directory /usr/lib/cgi-bin>
Require all granted
</Directory>
</IfModule>

and this is the error I get
AH00526: Syntax error on line 6 of /etc/apache2/mods-enabled/fastcgi.conf:
Invalid command 'Action', perhaps misspelled or defined by a module not included in the server configuration
Action '-t' failed.

Be the first one to answer this question.