Help with access to symlinks

Discussion in 'General' started by handcoded, Aug 12, 2009.

  1. handcoded

    handcoded New Member

    Hi

    I'm running Litespeed Enterprise v4.09 on my WHM + Cpanel server which is a VPS Hybrid with Wiredtree.

    I have an Oscommerce shop at www.brestersbatteries.co.uk/catalog that I have copied to www.soldering-shop.co.uk/catalog

    I've setup a symlink for the images folder to save having to enter products twice and both shops use the same database. Basically www.soldering-shop.co.uk is a satellite shop of the full shop at www.brewstersbatteries.co.uk

    If I switch from litespeed to Apache the images on soldering-shop.co.uk/cataog load just fine but permission is denied when litespeed is running.

    I've checked through my litespeed configuration and follow symlinks is set to yes and checking is set to no. I've also made sure that chroot is set to no.

    I tried adding this to my .htaccess file for soldering-shop.co.uk but this did not seem to do anything. This was recommended by litespeed support.

    Options +FollowSymLinks

    My web host is stumped and to be honest so am I. Whether because I am using suphp or what I have no clue.

    Any help or recommendations would be appreciated.

    Update

    Just tried this which I found in another post on here which said:
    Use "chown -h <user> <path>" to make the symbolic link the same ownership of the link target.

    I tried this by logging into my server via SSH as root and typing this command

    chown -h brewster /home/solder/public_html/catalog/images

    Unfortunately this has not worked either.

    When trying to access an image I receive a 403 error which states that access to this resource on the server is denied. View this error yourself here

    http://www.soldering-shop.co.uk/catalog/images/logo.gif

    I'm off again now to try and find a solution
    Last edited: Aug 12, 2009
  2. handcoded

    handcoded New Member

    Response from Litespeed tech support

    Received this reply from litespeed tech support

    ----------------------

    Hi,

    We may need to duplicate your setup in our lab to find out exactly what
    is the issue.
    The error log does not show the exact reason why. We are out of office
    now for hostingcon.
    There is another solution by adding a custom vhost configuration for
    soldering-shop.co.uk in cPanel/whm

    Alias /catalog/images/ /home/brewster/pubic_html/catalog/images/

    It will skip the symbolic link to access the file directly.

    ----------------------

    Does anyone know exactly how I would set this up ? Does anyone know of a tutorial I could follow should my web host be unable to do this for any reason

    Thanks
  3. handcoded

    handcoded New Member

    web host intervention

    Hi

    My web host (wiredtree) which are excellent by the way tried adding the alias but without success. In order to fix the problem a cron job will be setup which will copy the images across to the other shop at regular intervals.

    Luckily the images folder is not particularly large but it would be great if the litespeed tech support team could try to replicate my setup to find a solution.

    Apache will work but the benefits of litespeed far outway the inconvenience of having to runa cron job.
  4. handcoded

    handcoded New Member

    Solved - sort of

    Hi

    Rsync was setup to copy the images from the primary shop to the satellite shop but for some reason the images still would not show.

    I chown'd and chmodded the contents of the public_html folder but still no joy.
    In desperation I changed the name of the images folder to images 2 and changed the Oscommerce config file and a hard coded link in the shops header and hey presto the images started to appear.

    I asked my web host to change the rsync script so that images would be copied to images2 and not images and though not ideal and maybe not completly upgrade proof it does work.

    There does seem to be some issues with symlinks and litespeed or litespeed not understanding all of Apaches directives. I only hope that when the litespeed tech support team get back to their offices from their hosting conference that they can spend a bit of time trying to re-create my setup to see if this is a genuine bug or just a misconfiguration error.

    I've learnt allot today and am just happy that I can sleep tonight without thinking about this problem.
  5. mistwang

    mistwang LiteSpeed Staff

    Fixed in the latest build of 4.0.10 release package.
  6. ideaoforder

    ideaoforder New Member

    I'm having the same problem

    I'm having this problem too. I have the same setup on a different server using LSWS 4.0.3, and I have no issues (once I turned "restrain" off). But I upgraded a different server to 4.0.12 and I only get 403 errors. How did you get this to work? Or are images just copied into the webroot?

Share This Page