2,284   Apache Ubuntu WordPress

apache启用headers and expires

ubuntu部署好wordpress后,发现插件wp_super_cache里面有几个警告,请启用mod_expires和mod_headers.

可以按照以下命令,

ubuntu@ip-172-31-6-145:/var/www/html/luckybird/wp-content$ sudo a2enmod headers

Enabling module headers.

To activate the new configuration, you need to run:

service apache2 restart

ubuntu@ip-172-31-6-145:/var/www/html/luckybird/wp-content$ sudo a2enmod expires

Enabling module expires.

To activate the new configuration, you need to run:

service apache2 restart

ubuntu@ip-172-31-6-145:/var/www/html/luckybird/wp-content$ sudo service apache2 restart

* Restarting web server apache2                                                                                                      [ OK ]

ubuntu@ip-172-31-6-145:/var/www/html/luckybird/wp-content$

 

 




Leave a Reply

Your email address will not be published. Required fields are marked *