LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-23-2019, 04:45 AM   #1
jithin10
LQ Newbie
 
Registered: Feb 2016
Posts: 10

Rep: Reputation: Disabled
VSFTPD


Hi All,

Distro: Cenot7
----------------
I've created two users on vsftpd.

User1 > /home/user1
User2 > /home/user2

Then I created a new directory called share on user1 (/home/user1)

And I did #mount --bind /home/user1/share/ /home/user2

So when I login vis FTP as user2, I could see share on user2's home directory. BUT I lost all previous directories kept on user2.

So, I did unmount #umount /home/user2 and I got all directories back.

My question is how would do binf wihout losing exisitng directories?

Any advise?

Thank you
Jn
 
Old 08-23-2019, 05:58 AM   #2
phil.d.g
Senior Member
 
Registered: Oct 2004
Posts: 1,272

Rep: Reputation: 153Reputation: 153
Is there any reason you can't mount to somewhere like /home/user2/share?

If not, then you need to look at union file systems such as OverlayFS, AUFS, etc. I'd suggest against it though.
 
Old 08-23-2019, 07:39 AM   #3
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 22,222

Rep: Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968
Quote:
Originally Posted by jithin10 View Post
Hi All,
Distro: Cenot7
----------------
I've created two users on vsftpd.

User1 > /home/user1
User2 > /home/user2

Then I created a new directory called share on user1 (/home/user1)

And I did #mount --bind /home/user1/share/ /home/user2

So when I login vis FTP as user2, I could see share on user2's home directory. BUT I lost all previous directories kept on user2. So, I did unmount #umount /home/user2 and I got all directories back. My question is how would do binf wihout losing exisitng directories?
Best advice would be to think about what you're doing. You're mounting a directory on top of ANOTHER directory, so whatever is in the mount-point gets ignored, since you're being redirected to /home/user1/share. The files aren't 'lost'...just not visible. Put your mount point elsewhere.

You've been asking about FTP for three years:
https://www.linuxquestions.org/quest...ng-4175574075/
https://www.linuxquestions.org/quest...er-4175573721/
https://www.linuxquestions.org/quest...ng-4175573537/

...and what you're asking about here isn't FTP related at all, but basic Linux administration and mount-points. Have you asked your systems administrator for help?
 
Old 08-29-2019, 08:02 AM   #4
jithin10
LQ Newbie
 
Registered: Feb 2016
Posts: 10

Original Poster
Rep: Reputation: Disabled
Wink

Quote:
Originally Posted by phil.d.g View Post
Is there any reason you can't mount to somewhere like /home/user2/share?

If not, then you need to look at union file systems such as OverlayFS, AUFS, etc. I'd suggest against it though.

Thank you.

But it was due to mount action. Like when we mount the old datas will be hidden. Once we unmount it will be back.
 
Old 08-29-2019, 08:09 AM   #5
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 22,222

Rep: Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968Reputation: 5968
Quote:
Originally Posted by jithin10 View Post
Thank you.
But it was due to mount action. Like when we mount the old datas will be hidden. Once we unmount it will be back.
Right; that's what you were told in post #3.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
vsftpd settingd and VSFTPD DEAD BUT SUBSYS LOCKED pc_copat Linux - Newbie 15 11-05-2009 11:31 PM
VSFTPD:How to have vsftpd ask for anon user to "send email for password"? dmurray8888 Linux - Networking 1 08-31-2008 07:04 PM
vsftpd.conf/chroot/vsftpd.chroot_list issue Jerman Linux - Security 2 06-01-2007 08:24 PM
vsftpd, web uploads, vsftpd virtual users, apache virtual hosts, home directories jerryasher Linux - Software 7 02-18-2007 07:29 AM
VSFTPD Debian VSFTPD "unrecognised variable in config file" DCT Linux - Software 0 05-30-2004 12:59 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:32 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration