LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   FTP Permissions With Proftpd (https://www.linuxquestions.org/questions/linux-newbie-8/ftp-permissions-with-proftpd-194229/)

Seventh 06-16-2004 12:14 PM

FTP Permissions / Home Directory errors
 
Quick question,

I have a website in:

/home/httpd/vhosts/whatever.com/httpdocs

(bad spot, works, not the issue)

I made a directory under it called /members/membername.

If I hit www.mysite.com/members/membername, I get the default index file, and that is happy.

However when I FTP to my site, and login as the user, I get "Service not available, remote server has closed connection".

The user is the owner of members/membername, and I chmodded it to 777 just to see if that'd help, but no dice.

Is there another permission I need to set on this so that he can FTP into his home directory?

btw: I set his home dir to /home/httpd/vhosts/whatever.com/httpdocs/members/membername.

Thanks!

bruno buys 06-16-2004 01:42 PM

What ftp server are you running? My last install of pure-ftp grabbed users from the system users. I guess you have to add them on the system.

Seventh 06-16-2004 06:32 PM

Proftpd on RH9.

They're added in /etc/passwd, did an adduser, etc.

Donboy 06-17-2004 12:00 AM

Try here, specifically section 2...

http://www.castaglia.org/proftpd/doc...-HOWTO-NAT.txt

Seventh 06-17-2004 08:41 AM

Quote:

Originally posted by Donboy
Try here, specifically section 2...

http://www.castaglia.org/proftpd/doc...-HOWTO-NAT.txt

Hmm, wrong link?

The server runs and connects fine, it's an account/permissions issue, not a NAT issue. :)

Donboy 06-17-2004 11:23 AM

Man, I have no idea. If it's not NAT, then maybe something to do with your config file. Post it here and maybe an answer will surface.

Seventh 06-17-2004 11:46 AM

Here's my proftpd.conf, the include file that it references is blank.

Code:

-sh-2.05b$ cat /etc/proftpd.conf
#
# To have more informations about Proftpd configuration
# look at : http://www.proftpd.org/
#

# This is a basic ProFTPD configuration file (rename it to
# 'proftpd.conf' for actual use.  It establishes a single server
# and a single anonymous login.  It assumes that you have a user/group
# "nobody" and "ftp" for normal operation and anon.

ServerName                      "ProFTPD"
ServerType      inetd
ServerType      inetd
DefaultServer                  on
<Global>
DefaultRoot    ~
AllowOverwrite          on
</Global>
DefaultTransferMode    binary
UseFtpUsers                    on

# Port 21 is the standard FTP port.
Port                            21
# Umask 022 is a good standard umask to prevent new dirs and files
# from being group and world writable.
Umask                          022

# To prevent DoS attacks, set the maximum number of child processes
# to 30.  If you need to allow more than 30 concurrent connections
# at once, simply increase this value.  Note that this ONLY works
# in standalone mode, in inetd mode you should use an inetd server
# that allows you to limit maximum number of processes per service
# (such as xinetd)
MaxInstances                    30

#Following part of this config file were generate by PSA automatically
#Any changes in this part will be overwritten by next manipulation
#with Anonymous FTP feature in PSA control panel.

#Include directive should point to place where FTP Virtual Hosts configuratio
#preserved

ScoreboardFile /var/run/proftpd/scoreboard

# Primary log file mest be outside of system logrotate province

TransferLog /usr/local/psa/var/log/xferlog

#Change default group for new files and directories in vhosts dir to psacln

<Directory /home/httpd/vhosts>
        GroupOwner      psacln
</Directory>

Include /etc/proftpd.include
-sh-2.05b$

Again anything in /home/whoever works fine, but if I move it to /home/httpd/vhosts/whatever.com/httpdocs/members/membername, it won't let people login.

The reason for the long folder is so that people can upload things (pics, etc) and link to them, and /httpdocs is the only folder that apache can see.

Thanks again. :)

Donboy 06-17-2004 12:04 PM

Hmmm.. well, here's mine. This works fine for me. Maybe there's something here you can use.

Code:

ServerName                        "FTP Server"
ServerType                        standalone
DefaultServer                        on
RequireValidShell                off
TimeoutStalled                        300
TimeoutNoTransfer                1000
TimeoutIdle                        1000
UseReverseDNS                        off
AllowRetrieveRestart                on
AllowForeignAddress                on
ServerIdent                        Off
DefaultRoot ~
ListOptions -a
DisplayConnect /etc/proftpd/prelogin.msg
Port                                21
Umask                                022
MaxClients                        50
MaxInstances                        15
MaxClientsPerHost                3
MaxHostsPerUser                        3
User                                nobody
Group                                nobody

<Directory />
        HideUser root
        AllowOverwrite        on
        HideNoAccess On
        <Limit ALL>
                AllowAll
        </Limit>
        <Limit SITE_CHMOD>
                AllowAll
        </Limit>
</Directory>


Seventh 06-18-2004 09:54 AM

Are your home directories /home/username, or are they somewhere else?

Donboy 06-18-2004 10:06 AM

Yeah, each one is /home/username, and I have a bunch.

Seventh 06-19-2004 01:38 PM

I'm trying to bury them underneath a single /home/username, like /home/username/stuff/morestuff/thefolderinquestion.

Not sure if that matters, really. :\

Donboy 06-19-2004 02:25 PM

I think all you need is to have each user's home directory specified in /etc/passwd and have all the levels chmod 755 all the way to their home directory... so you'll want to have /home /home/username /home/username/stuff (etc, all the way down to their actual home dir) all of them chmod 755.


All times are GMT -5. The time now is 04:48 PM.