# sFTP setup, what's missing?

**URL:** <https://forums.suse.com/t/sftp-setup-whats-missing/23236>\
**Category:** SLES Configure-Administer\
**Created:** [October 25, 2012, 2:35am UTC](https://forums.suse.com/t/sftp-setup-whats-missing/23236 "2012-10-25T02:35:21Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![tonybarcelo](https://avatars.discourse-cdn.com/v4/letter/t/90ced4/32.png) [@tonybarcelo](https://forums.suse.com/u/tonybarcelo)\
**Post date:** [October 25, 2012, 2:35am UTC](https://forums.suse.com/t/sftp-setup-whats-missing/23236/1 "2012-10-25T02:35:21Z")

</div>

I installed a new virtual server, SLES 11.2 64bit to work as a sFTP server for a local community. But I’ve done something wrong and need help.

The server system is installed with LVM on both the OS disk and also a second disk where the /sftp is mounted.

sshd\_config is edited with these lines:

Subsystem sftp internal-sftp

and on the last rows:

Match group sftpgroup  
ForceCommand internal-sftp  
ChrootDirectory /home/%u  
AllowTCPForwarding no  
X11Forwarding no

Reloaded sshd with rcsshd reload.

Then I created a group called “sftpgroup” and a folder structure for the chrooted sftp service.  
mkdir -p /sftp/chroot  
chmod 750 /sftp/chroot  
chown root:sftpgroup /sftp/chroot

Created a user restricted to the group sftpgroup but without shell (/bin/false)

When I try to access the sftpserver with testuser@sftpserver I get:  
“couldn’t read packet: connection reset by peer”  
   
the /var/log/messages on server says:  
“fatal:bad ownership or modes for chroot directory /path”

What is missing/wrong?

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex022/uploads/suse/original/2X/5/5012ba89e3ffb5220dac47d5ea0ba032e2fe1cb6.png) [@system](https://forums.suse.com/u/system)\
**Post date:** [November 1, 2012, 2:30pm UTC](https://forums.suse.com/t/sftp-setup-whats-missing/23236/2 "2012-11-01T14:30:05Z")

</div>

tonybarcelo,

It appears that in the past few days you have not received a response to your  
posting. That concerns us, and has triggered this automated reply.

Has your issue been resolved? If not, you might try one of the following options:

- Visit [http://www.suse.com/support](http://www.suse.com/support) and search the knowledgebase and/or check all  
the other support options available.
- You could also try posting your message again. Make sure it is posted in the  
correct newsgroup. ([http://forums.suse.com](http://forums.suse.com))

Be sure to read the forum FAQ about what to expect in the way of responses:  
[http://forums.suse.com/faq.php](http://forums.suse.com/faq.php)

If this is a reply to a duplicate posting, please ignore and accept our apologies  
and rest assured we will issue a stern reprimand to our posting bot.

Good luck!

Your SUSE Forums Team  
[http://forums.suse.com](http://forums.suse.com)
