Some google key words: Moved Permanently Apache mod_dir mod_index mod_proxy mod_rewrite directory slash / problemProblem:
http://www.foo.de/modeling --> error but http://www.foo.de/modeling/ is o.k. - Why and how to solve... GET /modeling HTTP/1.1 --> HTTP/1.1 301 Moved Permanently but GET /modeling/ HTTP/1.1 --> HTTP/1.1 200 OK -----------------------------------------------------------------zsmac3:~/Desktop/ijb20 andreas$ telnet zsweb 8013 Trying 193.174.61.130... Connected to zsweb.inet.dkfz-heidelberg.de. Escape character is '^]'. GET /modeling HTTP/1.1 Host: zsweb HTTP/1.1 301 Moved Permanently Date: Tue, 09 Mar 2004 11:25:46 GMT Server: Apache/1.3.24 (Unix) PHP/4.2.0 mod_ssl/2.8.8 OpenSSL/0.9.6c Location: http://www.dkfz-heidelberg.de:8013/modeling/ Transfer-Encoding: chunked Content-Type: text/html; charset=iso-8859-1 149 ################################################################# GET /modeling/ HTTP/1.1 --> HTTP/1.1 200 OK -----------------------------------------------------------------301 Moved Permanently Moved Permanently
The document has moved here.
Apache/1.3.24 Server at www.dkfz-heidelberg.de Port 8013 0 Connection closed by foreign host.zsmac3:~/Desktop/ijb20 andreas$ telnet zsweb 8013 Trying 193.174.61.130... Connected to zsweb.inet.dkfz-heidelberg.de. Escape character is '^]'. GET /modeling/ HTTP/1.1 Host: zsweb HTTP/1.1 200 OK Date: Tue, 09 Mar 2004 12:19:12 GMT Server: Apache/1.3.24 (Unix) PHP/4.2.0 mod_ssl/2.8.8 OpenSSL/0.9.6c X-Powered-By: PHP/4.2.0 Set-Cookie: PHPSESSID=c5a74965c29313870ee3c2790ae26e4b; path=/ Expires: Thu, 19 Nov 1981 08:52:00 GMT Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0 Pragma: no-cache Transfer-Encoding: chunked Content-Type: text/html ################################################################## Solution: check the httpd.conf of your Apache and set UseCanonicalName Off UseCanonicalName directive Syntax: UseCanonicalName on|off|dns Default: UseCanonicalName on Context: server config, virtual host, directory Override: Options Compatibility: UseCanonicalName is only available in Apache 1.3 and later In many situations Apache has to construct a self-referential URL. That is, a URL which refers back to the same server. With UseCanonicalName on (and in all versions prior to 1.3) Apache will use the ServerName and Port directives to construct the canonical name for the server. This name is used in all self-referential URLs, and for the values of SERVER_NAME and SERVER_PORT in CGIs. For example, if ServerName is set to www.example.com and Port is set to 9090, then the canonical name of the server is www.example.com:9090. In the event that Port has its default value of 80, the :80 is omitted from the canonical name. With UseCanonicalName off Apache will form self-referential URLs using the hostname and port supplied by the client if any are supplied (otherwise it will use the canonical name, as defined above). These values are the same that are used to implement name based virtual hosts, and are available with the same clients. The CGI variables SERVER_NAME and SERVER_PORT will be constructed from the client supplied values as well. An example where this may be useful is on an intranet server where you have users connecting to the machine using short names such as www. You'll notice that if the users type a shortname, and a URL which is a directory, such as http://www/splat, without the trailing slash then Apache will redirect them to http://www.domain.com/splat/. If you have authentication enabled, this will cause the user to have to authenticate twice (once for www and once again for www.domain.com -- see the FAQ on this subject for more information). But if UseCanonicalName is set off, then Apache will redirect to http://www/splat/. There is a third option, UseCanonicalName DNS, which is intended for use with mass IP-based virtual hosting to support ancient clients that do not provide a Host: header. With this option Apache does a reverse DNS lookup on the server IP address that the client connected to in order to work out self-referential URLs. Warning: if CGIs make assumptions about the values of SERVER_NAME they may be broken by this option. The client is essentially free to give whatever value they want as a hostname. But if the CGI is only using SERVER_NAME to construct self-referential URLs then it should be just fine. See also: ServerName, Port ################################################################################################### now zsmac3:~/Desktop/ijb20 andreas$ telnet zsweb 8013 Trying 193.174.61.130... Connected to zsweb.inet.dkfz-heidelberg.de. Escape character is '^]'. GET /modeling HTTP/1.1 Host: zsweb HTTP/1.1 301 Moved Permanently Date: Tue, 09 Mar 2004 12:18:11 GMT Server: Apache/1.3.24 (Unix) PHP/4.2.0 mod_ssl/2.8.8 OpenSSL/0.9.6c Location: http://zsweb:8013/modeling/ Transfer-Encoding: chunked Content-Type: text/html; charset=iso-8859-1127 --------------------------------------------------------------------------------------- other It means your httpd.conf is misconfigured. Usually this error happens when you've defined the Subversion virtual "location" to exist within two different scopes at the same time. For example, if you've exported a repository as301 Moved Permanently Moved Permanently
The document has moved here.
Apache/1.3.24 Server at zsweb Port 8013, but you've also set your DocumentRoot to be /www, then you're in trouble. When the request comes in for /www/foo/bar, apache doesn't know whether to find a real file named /foo/bar within your DocumentRoot, or whether to ask mod_dav_svn to fetch a file /bar from the /www/foo repository. Usually the former case wins, and hence the "Moved Permanently" error. The solution is to make sure your repository does not overlap or live within any areas already exported as normal web shares.