Rewrites not working on Openlitespeed Install

#1
Hello,

I have an openlitespeed install setup for development, but the company is using a paid version in production. Everything is working but the rewrites. The server has only openlitespeed, MariaDB, HHVM and PHP 7.2 for wp cli. No Apache is installed. It's running WordPress. The errors I am getting are attached in error.log. The actual httaccess file is attached also.

Example of some of the errors are below:
Code:
2019-05-02 15:44:33.249533 [INFO] Invalid rewrite directive: <files .htaccess>
2019-05-02 15:44:33.249536 [INFO] Rewrite directive: <IfModule mod_litespeed.c> bypassed.
2019-05-02 15:44:33.249539 [INFO] Invalid rewrite directive: Order allow,deny
2019-05-02 15:44:33.249541 [INFO] Invalid rewrite directive: Deny from all
2019-05-02 15:44:33.249544 [INFO] Rewrite directive: </IfModule> bypassed.
2019-05-02 15:44:33.249546 [INFO] Invalid rewrite directive: </files>
2019-05-02 15:44:33.249549 [INFO] Invalid rewrite directive: <files readme.html>
2019-05-02 15:44:33.249552 [INFO] Rewrite directive: <IfModule mod_litespeed.c> bypassed.
2019-05-02 15:44:33.249554 [INFO] Invalid rewrite directive: Order allow,deny
2019-05-02 15:44:33.249557 [INFO] Invalid rewrite directive: Deny from all
2019-05-02 15:44:33.249560 [INFO] Rewrite directive: </IfModule> bypassed.
2019-05-02 15:44:33.249562 [INFO] Invalid rewrite directive: </files>
2019-05-02 15:44:33.249565 [INFO] Invalid rewrite directive: <files readme.txt>
2019-05-02 15:44:33.249568 [INFO] Rewrite directive: <IfModule mod_litespeed.c> bypassed.
2019-05-02 15:44:33.249570 [INFO] Invalid rewrite directive: Order allow,deny
2019-05-02 15:44:33.249573 [INFO] Invalid rewrite directive: Deny from all
2019-05-02 15:44:33.249576 [INFO] Rewrite directive: </IfModule> bypassed.
2019-05-02 15:44:33.249578 [INFO] Invalid rewrite directive: </files>
2019-05-02 15:44:33.249581 [INFO] Invalid rewrite directive: <files wp-config.php>
2019-05-02 15:44:33.249584 [INFO] Rewrite directive: <IfModule mod_litespeed.c> bypassed.
2019-05-02 15:44:33.249586 [INFO] Invalid rewrite directive: Order allow,deny
2019-05-02 15:44:33.249589 [INFO] Invalid rewrite directive: Deny from all
2019-05-02 15:44:33.249592 [INFO] Rewrite directive: </IfModule> bypassed.2019-05-02 15:44:33.249594 [INFO] Invalid rewrite directive: </files>
2019-05-02 15:44:33.249597 [INFO] Invalid rewrite directive: <Files  ~ "\.log$">
2019-05-02 15:44:33.249600 [INFO] Rewrite directive: <IfModule mod_litespeed.c> bypassed.
2019-05-02 15:44:33.249602 [INFO] Invalid rewrite directive: Order allow,deny
2019-05-02 15:44:33.249605 [INFO] Invalid rewrite directive: Deny from all
2019-05-02 15:44:33.249608 [INFO] Rewrite directive: </IfModule> bypassed.
2019-05-02 15:44:33.249610 [INFO] Invalid rewrite directive: </Files>
2019-05-02 15:44:33.249613 [INFO] Rewrite directive: <IfModule mod_rewrite.c> bypassed.
2019-05-02 15:44:33.249635 [INFO] Rewrite directive: </IfModule> bypassed.
2019-05-02 15:44:33.249638 [INFO] Rewrite directive: <IfModule mod_rewrite.c> bypassed.
2019-05-02 15:44:33.249642 [INFO] RewriteBase [/] parsed, set to HttpContext 0x1500a80.
2019-05-02 15:44:33.249652 [INFO] Rewrite directive: </IfModule> bypassed.
2019-05-02 15:44:33.249655 [INFO] Invalid rewrite directive: Options -Indexes
2019-05-02 15:44:33.249658 [INFO] Rewrite directive: <IfModule LiteSpeed> bypassed.
2019-05-02 15:44:33.249661 [INFO] Invalid rewrite directive: php_value auto_prepend_file '/sites/hightide/public_html/wordfence-waf.php'
2019-05-02 15:44:33.249664 [INFO] Rewrite directive: </IfModule> bypassed.
2019-05-02 15:44:33.249667 [INFO] Rewrite directive: <IfModule lsapi_module> bypassed.
2019-05-02 15:44:33.249670 [INFO] Invalid rewrite directive: php_value auto_prepend_file '/sites/hightide/public_html/wordfence-waf.php'
2019-05-02 15:44:33.249672 [INFO] Rewrite directive: </IfModule> bypassed.
2019-05-02 15:44:33.249675 [INFO] Invalid rewrite directive: <Files ".user.ini">
2019-05-02 15:44:33.249677 [INFO] Rewrite directive: <IfModule mod_authz_core.c> bypassed.
2019-05-02 15:44:33.249683 [INFO] Invalid rewrite directive: Require all denied
2019-05-02 15:44:33.249686 [INFO] Rewrite directive: </IfModule> bypassed.
2019-05-02 15:44:33.249688 [INFO] Rewrite directive: <IfModule !mod_authz_core.c> bypassed.
2019-05-02 15:44:33.249691 [INFO] Invalid rewrite directive: Order deny,allow
2019-05-02 15:44:33.249693 [INFO] Invalid rewrite directive: Deny from all
2019-05-02 15:44:33.249696 [INFO] Rewrite directive: </IfModule> bypassed.
2019-05-02 15:44:33.249699 [INFO] Invalid rewrite directive: </Files>
2019-05-02 15:44:33.249702 [INFO] RewriteFile [/sites/hightide/public_html/.htaccess] parsed, return 0.
2019-05-02 15:44:33.249737 [INFO] [PlainConf] [virtualHostTemplate:] start parsing file /usr/local/lsws/conf/templates/ccl.conf
2019-05-02 15:44:33.255687 [INFO] [PlainConf] [virtualHostTemplate:] RCS checkin config file /usr/local/lsws/conf/templates/ccl.conf0 OK.
2019-05-02 15:44:33.255765 [INFO] [PlainConf] [context:/] rewrite [] add rules [rewritefile .htaccess]
2019-05-02 15:44:33.255801 [INFO] [PlainConf] [virtualHostTemplate:] start parsing file /usr/local/lsws/conf/templates/rails.conf
2019-05-02 15:44:33.261541 [INFO] [PlainConf] [virtualHostTemplate:] RCS checkin config file /usr/local/lsws/conf/templates/rails.conf0 OK.
2019-05-02 15:44:33.261604 [INFO] [PlainConf] [context:/] rewrite [] add rules [rewritefile .htaccess]
2019-05-02 15:44:33.261632 [NOTICE] [ZConfManager] No VHosts added, do not send!
Any help I could get would be greatly appreciated as I am lost here.

Thank you!
 

Attachments

Last edited by a moderator:

Pong

Administrator
Staff member
#2
On openlitespeed, only rewrite rules work in .htaccess. all the rest configurations including "redirect" "header" etc won't work. that's why the error log saying "invalid rewrite directive".

maybe you can consider LiteSpeed Enterprise free version for your dev environment.
 
Top