LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 05-21-2006, 06:56 AM   #1
Rindert
LQ Newbie
 
Registered: Jun 2005
Location: Roosendaal
Distribution: Kubuntu 6.10, amd64
Posts: 13

Rep: Reputation: 0
Use an other dir for apache files


Hello,

I was wondering if this is possible:
I have a second fat32 partition mounted on '/mnt/data'
On this partion i have a folder '/server/www' and i would like apache to use this folder instead of '/srv/www'.
When i create a symbolic link on /srv/www to '/mnt/data/server/www' i get an "forbidden" error in apache.

I think it has something to do with permissions on the file system.
What i want is be able to read apache the content of '/mnt/data/server/www' and also be albe to write localy to store ht_docs to this location.
I'm also using vsftp and i would like that to use '/mnt/data/server/ftp'. Same way as apache.

Can some one help me with this? or give better sugestions on to to do this?
I'm using Suse 10.1

Thanks

Rindert
 
Old 05-21-2006, 07:13 AM   #2
muha
Member
 
Registered: Nov 2005
Distribution: xubuntu, grml
Posts: 451

Rep: Reputation: 38
This is how it worked for 10.0 with symlinks:
(i guess with 10.1 it hasn't changed but i'm not sure ..)
source
Quote:
We want symlinks so we edit /etc/apache2/default-server.conf so it looks like:
DocumentRoot "/srv/www/htdocs"

#
# Configure the DocumentRoot
#
<Directory "/srv/www/htdocs">
# Possible values for the Options directive are "None", "All",
# or any combination of:
# Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
Options Indexes FollowSymLinks
#
# Note that "MultiViews" must be named *explicitly* --- "Options All"
# doesn't give it to you.
#
# The Options directive is both complicated and important. Please see
# http://httpd.apache.org/docs-2.0/mod/core.html#options
# for more information.
# Options None
# AllowOverride controls what directives may be placed in .htaccess files.
# It can be "All", "None", or any combination of the keywords:
# Options FileInfo AuthConfig Limit
AllowOverride None
# Controls who can get stuff from this server.
Order allow,deny
Allow from all
</Directory>
The other option would be to not use symlinks but just change the document-root to point to that dir on your fat32. And yes, you might be right that it's still a permissions problem but try this first.
Also, please note that using symlinks can cause a security-risk when symlinks point to directories higher up.
 
Old 05-21-2006, 07:42 AM   #3
Rindert
LQ Newbie
 
Registered: Jun 2005
Location: Roosendaal
Distribution: Kubuntu 6.10, amd64
Posts: 13

Original Poster
Rep: Reputation: 0
I first tried to use FollowSymLinks in appache's conf but that didn't work.
Now i've tried just pointing documentroot to my folder on the fat32 disk and that does work.
No complaints about permissions. Thanks.

Now i starting ftp config, hope this works too...
 
Old 05-22-2006, 02:11 AM   #4
muha
Member
 
Registered: Nov 2005
Distribution: xubuntu, grml
Posts: 451

Rep: Reputation: 38
welcome , pointing your apache to the proper directory (like you did now) is better then using symlinks, methinks.

I don't know about vsftp so i'll leave that for somebody else.
Or did you get it working already?
 
Old 05-22-2006, 11:19 AM   #5
Rindert
LQ Newbie
 
Registered: Jun 2005
Location: Roosendaal
Distribution: Kubuntu 6.10, amd64
Posts: 13

Original Poster
Rep: Reputation: 0
I haven't got it working correct.
Bu t i might swicht over to pureftpd since there is a kde progr for config that sever. mische be easier. But now i have compilling errors... :S ( totally different subject)
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
set password for dir in Apache! Shioni Linux - Software 3 05-07-2006 11:36 AM
Q. moving /bin dir files to /dev dir?? Texas_student Linux - Software 2 03-26-2006 11:42 PM
Apache Home Dir Nige General 1 02-24-2004 04:10 PM
apache 2 dir browsing Spaz17 Linux - Software 4 10-22-2003 03:00 PM
apache dir browsing k3v0 Linux - Software 1 08-29-2002 01:29 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 06:06 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration