2

We have an SFTP server (CentOS) set up to give our clients larger files. We set each user up with the following commands:

useradd -g sftpgroup -d /data1 -s /sbin/nologin user1
passwd user1
mkdir /sftp/user1/
mkdir /sftp/user1/data
chown user1:sftpgroup /sftp/user1/data/

and the same thing for user2.

This allows our clients to use WinScp to log into the sftp - automatically landing in their own data directory. Each client's data directory resides on the server in /sftp/user#/data

We have two current issues.

  1. our sda has become full, and
  2. we have several very large files that we need to share with at least 6 clients.

We have mounted a new sdb and configured it with /data/sftpdata

Questions:

  1. how do I put a shared directory in /data/sftpdata/shareddocs and make it available to the clients winscp login? Possibly with something like a shortcut in each data directory?

  2. If I create a new user with

    useradd -g sftpgroup -d /data1 -s /sbin/nologin user3
    passwd user3
    mkdir /data/sftpdata/user3/
    mkdir /data/sftpdata/user3/data
    chown user1:sftpgroup /data/sftpdata/user3/data/
    

    would that work to create a new user, but use the new drive? Or is there something else embedded in CentOS that needs to be set?

  • Apologize for my wording - what I was looking at was to add user3 etc using the new drive - code line corrected - Thanks – Dennis Newman Jul 27 at 15:44
0

Answered the second part of my question myself.

Wound up adding all of sdb to /dev/vg_server/vm_root which allowed me to post the data for my other users.

But this is still a space wasting answer.

I am still hoping to find instruction on allowing several jailed users to see a directory of "shared" information.

Every time I think I have it set up (as root) when I test as the user, the shortcut tells me they don't have the rights.

Any guidance on where to read up on an answer would be appreciated.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.