Koozali.org formerly Contribs.org

symbolic links in e-smith tree

John Cherry

symbolic links in e-smith tree
« on: August 17, 2001, 08:28:27 AM »

I'm using the e-smith web server to allow intranet acess to a number of MP3 files. This works, but, of course, I have more files than will fit on the drive I installed e-smith on.

So I created a symbolic link to another larger drive (/home/e-smith/files/ibays/mp3/html is a link to /mnt/disk2/home/httpd/html/mp3) and made sure the ownership and permissions of the target directory matched the parent tree, but e-smith tells me that I don't have permission to access /mp3

Nothing I've tried by way of permissions allows me to access the mp3 ibay when html is a link. I've tried making the symlink in a subdirectory of html but that didn't help, either.

Perhaps I should be running some kind of script to set the permissions, or perhaps it's apache denying me permission. I don't know.

Does anyone have advice?

Les Mikesell

Re: symbolic links in e-smith tree
« Reply #1 on: August 17, 2001, 09:57:52 PM »
Apache needs an 'Options' directive in the httpd.conf file to specifically allow access to symlinks.  On e-smith this is controlled by the templates in /etc/e-smith/templates/httpd/httpd.conf/ and you are supposed to override it by building a parallel tree under templates-custom that include any lines you want to modify or add.   It looks like changing line 105 in 90e-smithAccess40ibays from:
$result .= "   Options Indexes \n";
$result .= "   Options Indexes FollowSymLinks\n";
should do it.


Re: symbolic links in e-smith tree
« Reply #2 on: August 28, 2001, 02:44:51 PM »
John, G'day mate!

I had the same kind of thing and I think I can see the problem you're having.

You're symbolic link needs to be whatever the ibay directory name is AND THEN the directory called "files" inside it, which is the actual directory that shows up in Network Neigbourhood on your client, though this is not obvious.

eg: /home/e-smith/files/ibays/"name of your ibay"/files needs to be the link pointing to the directory where your content is.

Now, you could also make the link inside that files dir instead if you preferred I suppose, I haven't tried that. In my case, I just created the fresh ibay, deleted the "files" dir in it and replaced it with a link as above. Works perfectly.

Check what I mean with

ls -l /home/e-smith/files/ibays/"name of your ibay"

See? Check the permissions there too.

Hope this helps.