[xwiki-users] My xwiki login page always redirects to localhost
Hi, all, I got a problem with our xwiki site setup, I have apache webserver and tomcat behind with xwiki 3.5 deployed, when I do login, logout or clicking buttons on the server machine browser with http://localhost:8082/xwiki/bin/login/XWiki/XWikiLogin, I can login, everything works fine, but if I use external public internet to access our xwiki site like: http://mydomain.com/xwiki/bin/login/XWiki/XWikiLogin, I got the login page shown up, but if I login, it redirects me to localhost/xwiki/bin/view/Main/WebHome, which points to my localhost, not my server mydomain.com machine, then from the browser address bar, if I change the localhost url to this url: http://mydomain.com/xwiki/bin/view/Main/WebHome, I can see the page correctly. Hers is my httpd.conf file setup: ProxyPass /xwiki http://localhost:8082/xwiki ProxyPassReverse /xwiki http://localhost:8082/xwiki Any clue what is going on? Thanks Dave
By the way, if I logout, it will also direct to localhost. The whole problem happened after I set up rights for unregistered users to prevent them from viewing pages, regardless of the pages or space rights and from editing pages regarding of the page or space rights, which are check boxes in Wiki administration, Rights page (in XWikiPreference). Thanks Dave On Sun, May 6, 2012 at 1:13 PM, Geo Du <[email protected]> wrote:
Hi, all,
I got a problem with our xwiki site setup, I have apache webserver and tomcat behind with xwiki 3.5 deployed, when I do login, logout or clicking buttons on the server machine browser with http://localhost:8082/xwiki/bin/login/XWiki/XWikiLogin, I can login, everything works fine, but if I use external public internet to access our xwiki site like: http://mydomain.com/xwiki/bin/login/XWiki/XWikiLogin, I got the login page shown up, but if I login, it redirects me to localhost/xwiki/bin/view/Main/WebHome, which points to my localhost, not my server mydomain.com machine, then from the browser address bar, if I change the localhost url to this url: http://mydomain.com/xwiki/bin/view/Main/WebHome, I can see the page correctly.
Hers is my httpd.conf file setup:
ProxyPass /xwiki http://localhost:8082/xwiki ProxyPassReverse /xwiki http://localhost:8082/xwiki
Any clue what is going on?
Thanks Dave
On 05/06/2012 01:13 PM, Geo Du wrote:
Hi, all,
I got a problem with our xwiki site setup, I have apache webserver and tomcat behind with xwiki 3.5 deployed, when I do login, logout or clicking buttons on the server machine browser with http://localhost:8082/xwiki/bin/login/XWiki/XWikiLogin, I can login, everything works fine, but if I use external public internet to access our xwiki site like: http://mydomain.com/xwiki/bin/login/XWiki/XWikiLogin, I got the login page shown up, but if I login, it redirects me to localhost/xwiki/bin/view/Main/WebHome, which points to my localhost, not my server mydomain.com machine, then from the browser address bar, if I change the localhost url to this url: http://mydomain.com/xwiki/bin/view/Main/WebHome, I can see the page correctly.
Hers is my httpd.conf file setup:
ProxyPass /xwiki http://localhost:8082/xwiki ProxyPassReverse /xwiki http://localhost:8082/xwiki
Any clue what is going on?
You should use the ajp protocol instead of http to connect to the Tomcat server. The configuration is almost the same, except that instead of http:// links, you use the ajp:// prefix. -- Sergiu Dumitriu http://purl.org/net/sergiu/
Hi, Sergiu, Thanks for your help, I tried the ajp approach, but it did not work, this is my tomcat server.xml setup: <Connector port="8009" protocol="AJP/1.3" redirectPort="9443" /> This is my httpd.conf file setup: #Listen 1979 NameVirtualHost *:80 <VirtualHost *:80> ServerName localhost ErrorLog logs/error.log CustomLog logs/ajp.log combined <Proxy *> AddDefaultCharset Off Order deny,allow Allow from all </Proxy> ProxyPass /xwiki ajp://localhost:8009/xwiki ProxyPassReverse /xwiki ajp://localhost:8009/xwiki </VirtualHost> This setup gave me error saying I am redirecting to itself in firefox, I am not sure it said that, I google around, some people used similar setup. Any idea? Thanks Dave On Sun, May 6, 2012 at 8:42 PM, Sergiu Dumitriu <[email protected]> wrote:
On 05/06/2012 01:13 PM, Geo Du wrote:
Hi, all,
I got a problem with our xwiki site setup, I have apache webserver and tomcat behind with xwiki 3.5 deployed, when I do login, logout or clicking buttons on the server machine browser with http://localhost:8082/xwiki/**bin/login/XWiki/XWikiLogin<http://localhost:8082/xwiki/bin/login/XWiki/XWikiLogin>, I can login, everything works fine, but if I use external public internet to access our xwiki site like: http://mydomain.com/xwiki/bin/**login/XWiki/XWikiLogin<http://mydomain.com/xwiki/bin/login/XWiki/XWikiLogin>, I got the login page shown up, but if I login, it redirects me to localhost/xwiki/bin/view/Main/**WebHome, which points to my localhost, not my server mydomain.com machine, then from the browser address bar, if I change the localhost url to this url: http://mydomain.com/xwiki/bin/**view/Main/WebHome<http://mydomain.com/xwiki/bin/view/Main/WebHome>, I can see the page correctly.
Hers is my httpd.conf file setup:
ProxyPass /xwiki http://localhost:8082/xwiki ProxyPassReverse /xwiki http://localhost:8082/xwiki
Any clue what is going on?
You should use the ajp protocol instead of http to connect to the Tomcat server. The configuration is almost the same, except that instead of http://links, you use the ajp:// prefix.
-- Sergiu Dumitriu http://purl.org/net/sergiu/ ______________________________**_________________ users mailing list [email protected] http://lists.xwiki.org/**mailman/listinfo/users<http://lists.xwiki.org/mailman/listinfo/users>
I changed the localhost here: ServerName localhost to mydomain name, but still the same error: *The page isn't redirecting properly*. *Firefox has detected that the server is redirecting the request for this address in a way that will never complete. Thanks Dave * On Mon, May 7, 2012 at 12:04 AM, Geo Du <[email protected]> wrote:
Hi, Sergiu,
Thanks for your help, I tried the ajp approach, but it did not work, this is my tomcat server.xml setup:
<Connector port="8009" protocol="AJP/1.3" redirectPort="9443" />
This is my httpd.conf file setup:
#Listen 1979 NameVirtualHost *:80 <VirtualHost *:80> ServerName localhost ErrorLog logs/error.log CustomLog logs/ajp.log combined
<Proxy *> AddDefaultCharset Off Order deny,allow Allow from all </Proxy>
ProxyPass /xwiki ajp://localhost:8009/xwiki ProxyPassReverse /xwiki ajp://localhost:8009/xwiki
</VirtualHost>
This setup gave me error saying I am redirecting to itself in firefox, I am not sure it said that, I google around, some people used similar setup.
Any idea?
Thanks Dave
On Sun, May 6, 2012 at 8:42 PM, Sergiu Dumitriu <[email protected]> wrote:
On 05/06/2012 01:13 PM, Geo Du wrote:
Hi, all,
I got a problem with our xwiki site setup, I have apache webserver and tomcat behind with xwiki 3.5 deployed, when I do login, logout or clicking buttons on the server machine browser with http://localhost:8082/xwiki/**bin/login/XWiki/XWikiLogin<http://localhost:8082/xwiki/bin/login/XWiki/XWikiLogin>, I can login, everything works fine, but if I use external public internet to access our xwiki site like: http://mydomain.com/xwiki/bin/**login/XWiki/XWikiLogin<http://mydomain.com/xwiki/bin/login/XWiki/XWikiLogin>, I got the login page shown up, but if I login, it redirects me to localhost/xwiki/bin/view/Main/**WebHome, which points to my localhost, not my server mydomain.com machine, then from the browser address bar, if I change the localhost url to this url: http://mydomain.com/xwiki/bin/**view/Main/WebHome<http://mydomain.com/xwiki/bin/view/Main/WebHome>, I can see the page correctly.
Hers is my httpd.conf file setup:
ProxyPass /xwiki http://localhost:8082/xwiki ProxyPassReverse /xwiki http://localhost:8082/xwiki
Any clue what is going on?
You should use the ajp protocol instead of http to connect to the Tomcat server. The configuration is almost the same, except that instead of http://links, you use the ajp:// prefix.
-- Sergiu Dumitriu http://purl.org/net/sergiu/ ______________________________**_________________ users mailing list [email protected] http://lists.xwiki.org/**mailman/listinfo/users<http://lists.xwiki.org/mailman/listinfo/users>
participants (2)
-
Geo Du -
Sergiu Dumitriu