4.0.4/4.05 symlink issues

Discussion in 'Install/Configuration' started by kule, Jun 23, 2009.

  1. kule

    kule Member

    I upgraded from 3.x tonight but I'm having issues with a virtual host template that uses symlinks

    The vh_root is like this:

    /home/sites/public_html/site1/public/$VH_ NAME

    public is a symlink to the users site folder, which they have access to:

    I have an access log setup to:

    Now awstats wont work because it tries to follow the ../../ and ends up trying to find the access log at:

    (with [config:vhost:[vh_name]:logging:accesslog] log file is not writable error)

    Instead of following the symlink path back properly to: [EDIT]

    /home/sites/public_html/site1/log/$VH_ NAME/access.log

  2. mistwang

    mistwang LiteSpeed Staff

    Right now, LSWS dereference symbolic early, end up with a result like that.
    We will check and find the best way to accommodate all situations.
  3. kule

    kule Member

    Thanks for the quick reply mistwang - I collapsed in bed as it was about 3am my time when I posted that!

    If you could let me know if this is going to stay like this or change back to how it used to work that'd be great.

    For the moment I've edited the template xml directly now to have the full-path instead for the access/log file locations so at least they will work for the moment.

    The task was made a little harder because the web-inteface expects you to use $VH_ROOT & $VH_NAME for the error and access log properties. Perhaps you could change this to just warn the webuser but allow them to do it anyway?

  4. mistwang

    mistwang LiteSpeed Staff

    I think we will make it match the behavior of that under a command line shell. I think it should match the old behavior.

    For the error and access log properties, we can make the change.
  5. kule

    kule Member

    Thanks mistwang,

    I should have added that I also had the same issue with:

    Security -> Password File Realm Definition -> User DB Location

    Not sure if this would apply too?

  6. mistwang

    mistwang LiteSpeed Staff

    After evaluating the situation, we decide to keep the current behavior, as under some situation, the symbolic link need to be solved early to avoid other troubles.

    And I think there is a easy solution to your problem. If you intended to use a file or directory beyond the $VH_ROOT, then avoid using $VH_ROOT directly in that configuration. For example, if you change log path configuration from



    /home/sites/public_html/site1/public/$VH_ NAME/../../log/$VH_NAME/access.log

    It will do what you want. The same for the User DB location configuration.

Share This Page