LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 05-06-2008, 07:40 PM   #1
sean_zhang
LQ Newbie
 
Registered: Aug 2007
Posts: 26

Rep: Reputation: 15
How to share folders on different drives via FTP


Service: vsftpd
OS: RHEL

I want to share multiple folders on different drives/partitions via FTP. But I don't want to copy all of these files to /var/ftp/pub/.
Is there a kind of "link" that could do this job?

3Q!
 
Old 05-06-2008, 10:07 PM   #2
eggixyz
Member
 
Registered: Apr 2008
Posts: 310

Rep: Reputation: 30
Hey There,

You could set up account based login access. Or are you stuck with only being able to offer anonymous?

Thanks,

Mike
 
Old 05-06-2008, 11:58 PM   #3
eliufoo
Member
 
Registered: Oct 2007
Posts: 71

Rep: Reputation: 15
Give the folder appropriate privilege access to the ftp users, then create a symbolic link (ln -s) between the partitioned folders and user folder (/home/ or /var/ftp/pub).

Elly
 
Old 05-07-2008, 12:18 AM   #4
sean_zhang
LQ Newbie
 
Registered: Aug 2007
Posts: 26

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by eliufoo View Post
Give the folder appropriate privilege access to the ftp users, then create a symbolic link (ln -s) between the partitioned folders and user folder (/home/ or /var/ftp/pub).

Elly
I have a folder /data/share on /dev/sdb1.
I changed its context:
chcon --reference=/var/ftp/pub /data/share
And created a soft link to /data/share in /var/ftp/pub/.

But I cannot open the folder pub/share/ from the client.
 
Old 05-07-2008, 12:24 AM   #5
sean_zhang
LQ Newbie
 
Registered: Aug 2007
Posts: 26

Original Poster
Rep: Reputation: 15
lftp localhost:/pub> ls
share/
lftp localhost:/pub> cd share
cd: Access failed: 550 Failed to change directory. (/pub/share)
 
Old 05-07-2008, 02:13 AM   #6
eggixyz
Member
 
Registered: Apr 2008
Posts: 310

Rep: Reputation: 30
Hey There,

For vsftpd, I believe the users are chrooted by default. Is this just anonymous, or individual logins?

For a quick test, change the perms on /data/share to 777 and you'll know if it's a permissions issue or a "jail" ftp issue.

Thanks,

Mike
 
Old 05-07-2008, 03:46 AM   #7
sean_zhang
LQ Newbie
 
Registered: Aug 2007
Posts: 26

Original Poster
Rep: Reputation: 15
# anonymous login
lftp server
# /var/ftp/pub
> cd share
Access filaed:550 error failed to change directory

# local user login
lftp sean@server
# /home/sean/
> ls
>
# I canno see anything in this folder.

vsftpd.conf

Quote:
anonymous_enable=YES
local_enable=YES
write_enable=YES
local_umask=022
anon_upload_enable=YES
anon_mkdir_write_enable=NO
anon_other_write_enable=NO
anon_world_readable_only=NO

dirmessage_enable=YES
xferlog_enable=YES
connect_from_port_20=YES
xferlog_std_format=YES
ftpd_banner=Welcome to blah FTP service.
listen=YES
pam_service_name=vsftpd
userlist_enable=YES
tcp_wrappers=YES
 
  


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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Still CANNOT Share Folders StefanP Linux - Newbie 10 04-30-2007 06:38 PM
Cannot Share Folders StefanP Linux - Newbie 3 04-28-2007 01:29 PM
Share folders hylke Linux - Newbie 8 10-22-2004 01:32 PM
Share Windows Folders Foggy Linux - Newbie 21 12-09-2003 06:57 PM
how to share win2k folders/drives to RedHat 8? kublador Linux - Networking 3 03-24-2003 08:02 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 01:05 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