HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   Installation/Configuration (http://www.howtoforge.com/forums/forumdisplay.php?f=27)
-   -   add new subdomain with redirect type L fails when redirect path is /home/ (http://www.howtoforge.com/forums/showthread.php?t=47117)

finn 8th July 2010 01:00

add new subdomain with redirect type L fails when redirect path is /home/
 
Hi there.

Run into a problem I have replicated on two separate installs.

I add a new subdomain for a website, and set

Code:

host: home

domain: domain.com

Redirect Type: L

Redirect path: /home/

Active: checked

Browsing to the subdomain then gives me a 403

Code:

Forbidden

You don't have permission to access / on this server.

Additionally, a 403 Forbidden error was encountered while trying to use an ErrorDocument to handle the request.

I try the exact same settings with other names of subdomain and folders which work just fine.

Is this picking up on the 'home' keyword as it is potentially a system path? Am I missing something obvious?

till 8th July 2010 11:40

Quote:

Is this picking up on the 'home' keyword as it is potentially a system path?
Yes.

What you can try is to use either "home/" without a / at the beginning or the full path like /var/www/clients/client5/web3/web/home/

finn 8th July 2010 14:24

Hi Till.

Thanks for your quick reply.

I had already tried that, and it throws an error:
ERROR

Invalid redirect path. Valid redirects are for example: /test/ or http://www.domain.tld/test/
Adding the full URL for the "Redirect Path" does seem to work, but then the L flag seems not to be respected, and the browser is forwarded to the http://www.domain.tld/home/ rather than staying on http://home.domain.tld/

This also seems to happen for any subdomain named with a root system folder name (etc, var, home). Further, creating a folder in the root with the name 'subdomain' triggers the same behaviour for any subdomains called 'subdomain'. This could cause issues, if many clients had a subdomain 'mail' and one day we created a root folder called 'mail' - it could get very messy.

Is this a bug? Should I report it on the bugtracker?

Many thanks.

Finn.

till 8th July 2010 14:44

Quote:

Is this a bug? Should I report it on the bugtracker?
Thats the normal behaviour of the apache webserver. Its not relkated to ispconfig, ispconfig is just a frontend which makes it easier to edit apache files.

till 8th July 2010 14:47

Just as a note, if you want to have a subdomain that has its own directory, you normally create a website in ispconfig for this subdomain and not a redirect.

Polk 22nd August 2010 09:23

Quote:

Originally Posted by till (Post 233076)
Just as a note, if you want to have a subdomain that has its own directory, you normally create a website in ispconfig for this subdomain and not a redirect.

When I add a subdomain, what does ispconfig3 do? where does it create? I dont see where to upload files. DNS records are set.

till 22nd August 2010 10:38

A subdomain is a vhost alias, it does not has a separate directory.

As I mentioned above, if you want to have a separate directory, create a new website.

Polk 22nd August 2010 10:42

aaaaaaah. I see. I didn't get it even after reading a few times.

thank you very much for your patience and details.


All times are GMT +2. The time now is 16:03.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.