1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice
  2. Dear Pleskians, please read this carefully! New attachments and other rules Thank you!
    Dismiss Notice

Symlinks resulting in 403 Error

Discussion in 'Plesk for Linux - 8.x and Older' started by qxxx, Dec 7, 2005.

  1. qxxx

    qxxx Guest

    0
     
    Hello!

    i would like to acces files from subdomains also on the main domain,
    example:

    http://download.example.com/file.zip
    want to acces from here:
    http://www.example.com/download/file.zip

    i created a symlink like that:
    ln -s /home/httpd/vhosts/example.com/subdomains/download/httpdocs download
    (in folder: /home/httpd/vhosts/example.com/httpdocs)

    the symlink is created.
    now if i acces a file like that:
    http://www.example.com/download/file.zip
    apache shows: a 403 error (forbidden)
    The Apache Logs showing "Symlinks are not allowed here"

    i chmoded all 777, chown wwwrun.www, restarted the apache,
    what can i do more?

    Thanks in Advance, Q
     
  2. jlschwab

    jlschwab Guest

    0
     
    You need to edit plesk's virtual host overrides file in that domain's /conf/ directory, the file is called: vhost.conf.

    In this file you need to put:

    Code:
    <Directory <full/path/to/the/domains/httpdocs>
        Options FollowSymLinks
    </Directory>
    
    Then you need to restart the apache server:

    (If its a redhat box): # service httpd restart

    This should solve the problem, as the default plesk apache installation does not tend to allow you to follow symlinks automatically.

    I just recently had todo this my self actually.

    Hope this helps!

    If you need further assistance, feel free to contact me on here, or direclty, thanks.
     
  3. qxxx

    qxxx Guest

    0
     
    sorry, doesnt work, still 403.
    i have everywhere a vhost.conf file:

    in domain.com\subdomains\blabla\conf
    and
    domain.com\conf

    all something like this inside:
    PHP:
    <Directory "/home/httpd/vhosts/domain.com">
    Options -Indexes +FollowSymLinks +Includes
    DirectoryIndex index
    .php
    php_admin_value open_basedir 
    /home/httpd/vhosts/domain.com/httpdocs/
    php_admin_flag safe_mode Off
    php_admin_value memory_limit 60M
    </Directory>
    :(
     
  4. ylon

    ylon Basic Pleskian

    23
    23%
    Joined:
    Apr 28, 2007
    Messages:
    39
    Likes Received:
    0
    He's apparently right, I don't see this working either... time to keep digging for an answer.
     
  5. ylon

    ylon Basic Pleskian

    23
    23%
    Joined:
    Apr 28, 2007
    Messages:
    39
    Likes Received:
    0
    Sorry, spoke too soon, didn't check my permissions of the symlink. After chown'ing them it is working dandily. Thanks!
     
  6. poke

    poke Guest

    0
     
    :) Those darn perms...
     
Loading...