Prevent mod_jk to shows/append index.cfm?&_modcfmlredirected on page load

 ̄綄美尐妖づ 提交于 2019-12-13 03:23:20

问题


I have set a virtual host configured in apache2 to proxy my cf sites to lucee/tomcat, and using mode_jk for the proxy.

Everything works fine except that on first time opening my website after a server restart the apache or lucee or the mod_jk kinda redirects to index.cfm and appending &_modcfmlredirected to the url.

So when I open url cf.test I get cf.test/index.cfm&_modcfmlredirected

I don't want this to happen, can anyone explain why this is happening AND how to prevent this.

BTW: After 1st hit the webpage loads fine without the above effect.

There is just a single index.cfm page containing Just one line of code which echoes date only.

virtual host config:

<VirtualHost cf.test:80>
    ServerAdmin webmaster@cf.test
    ServerName cf.test
    ServerAlias www.cf.test
    DocumentRoot /var/www/html/cf.test/public_html
    DirectoryIndex index.cfm
    JkMount /*.cfm ajp13_worker

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>

# vim: syntax=apache ts=4 sw=4 sts=4 sr noet

worker-properties:

workers.tomcat_home=/opt/tomcat
workers.java_home=/opt/lucee/jre/bin
worker.list=ajp13_worker
worker.ajp13_worker.port=8009
worker.ajp13_worker.host=localhost
worker.ajp13_worker.type=ajp13
worker.ajp13_worker.lbfactor=1
worker.loadbalancer.type=lb
worker.loadbalancer.balance_workers=ajp13_worker
  • OS: Ubuntu 18.04 - Fresh Install
  • Apache 2.4 - default install
  • PHP 7.3 default install from ondrej ppa
  • mod_jp from default repository install libapache2-mod-jk

回答1:


You can resolve this by updating your 'mod_cfml-valve_v1.1.09.jar' to 'mod_cfml-valve_v1.1.10.jar'.

Your can download the file from from https://github.com/viviotech/mod_cfml/tree/master/java

(Thank you Zac Spitzer)

More Info here: https://github.com/viviotech/mod_cfml/issues/24



来源:https://stackoverflow.com/questions/56575706/prevent-mod-jk-to-shows-append-index-cfm-modcfmlredirected-on-page-load

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!