настройка proftpd

Г
На сайте с 25.10.2007
Offline
68
2041

Дебиан. Ставил из репы.Модуль для mysql также поставил и включил.

Настраивал частично по этому и этому мануалам. Не конектит.Фаер выключен. Получаю отлуп в виде "соединение закрыто сервером".

#
<IfModule mod_sql.c>

SQLBackend mysql
SQLEngine on
SQLAuthenticate users
SQLAuthTypes Plaintext
SQLConnectInfo
RequireValidShell off
SQLUserInfo users username password uid gid homedir shell
SQLLogFile /var/log/proftpd/sql.log
<Global>
DefaultRoot ~
</Global>
</IfModule>


# Includes DSO modules
Include /etc/proftpd/modules.conf

# Set off to disable IPv6 support which is annoying on IPv4 only boxes.
UseIPv6 off
# If set on you can experience a longer connection delay in many cases.
IdentLookups off

ServerName "Debian"
ServerType standalone
DeferWelcome on

MultilineRFC2228 on
DefaultServer on
ShowSymlinks on

TimeoutNoTransfer 600
TimeoutStalled 600
TimeoutIdle 1200

DisplayLogin welcome.msg
DisplayChdir .message true
ListOptions "-l"

DenyFilter \*.*/
AllowForeignAddress off
DefaultTransferMode binary

# Use this to jail all users in their homes
DefaultRoot ~

# Port 21 is the standard FTP port.
Port 21

PassivePorts 65000 65535

<IfModule mod_dynmasq.c>
# DynMasqRefresh 28800
</IfModule>

MaxInstances 30

# Set the user and group that the server normally runs at.
User ftp
Group ftp


Umask 022 022
# Normally, we want files to be overwriteable.
AllowOverwrite on

# Uncomment this if you are using NIS or LDAP via NSS to retrieve passwords:
# PersistentPasswd off

# This is required to use both PAM-based authentication and local passwords
# AuthOrder mod_auth_pam.c* mod_auth_unix.c

# Be warned: use of this directive impacts CPU average load!
# Uncomment this if you like to see progress and transfer rate with ftpwho
# in downloads. That is not needed for uploads rates.
#
# UseSendFile off

SystemLog /var/log/proftpd/proftpd.log
TransferLog /var/log/proftpd/proftpd-tranfer.log
ExtendedLog /var/log/proftpd/proftpd-extended.log read,write
ExtendedLog /var/log/proftpd/proftpd-auth.log AUTH auth
LogFormat default "%h %l %u %t \"%r\" %s %b"
LogFormat auth "%v [%P] %h %t \"%r\" %s"
LogFormat write "%h %l %u %t \"%r\" %s %b"


<IfModule mod_quotatab.c>
QuotaEngine off
</IfModule>

<IfModule mod_ratio.c>
Ratios off
</IfModule>

<IfModule mod_delay.c>
DelayEngine on
</IfModule>

<IfModule mod_ctrls.c>
ControlsEngine off
ControlsMaxClients 2
ControlsLog /var/log/proftpd/controls.log
ControlsInterval 5
ControlsSocket /var/run/proftpd/proftpd.sock
</IfModule>

<IfModule mod_ctrls_admin.c>
AdminControlsEngine off
</IfModule>

Include /etc/proftpd/sql.conf

Oct 03 10:54:52 proftpd[5404] : ProFTPD 1.3.1 (stable) (built Tue Oct 27 10:09:08 UTC 2009) standalone mode STARTUP
Oct 03 10:54:58 proftpd[5578] ([]): ProFTPD terminating (signal 11)
Oct 03 10:54:58 proftpd[5578] ([]): FTP session closed.

~# telnet localhost 21
Trying 127.0.0.1...
Connected to localhost.localdomain.
Escape character is '^]'.
Connection closed by foreign host.

~# ps aux | grep ftpd
root 3422 0.0 0.2 1716 512 pts/0 S+ 11:07 0:00 grep ftpd
ftp 26192 0.0 0.7 5324 1404 ? Ss 11:02 0:00 proftpd: (accepting connections)
~# netstat -an | grep 21
tcp 0 0 0.0.0.0:21 0.0.0.0:* LISTEN

Не могу понять в чем проблема.

D
На сайте с 11.05.2010
Offline
15
#1

ключ -d включает уровень дебага.

С напильником и бубном (http://kaba.org.ua)
Г
На сайте с 25.10.2007
Offline
68
#2

вот с дебагом 3

Starting ftp server: proftpd - mod_tls/2.1.2: using OpenSSL 0.9.8g 19 Oct 2007
- disabling runtime support for IPv6 connections
- <IfModule>: using 'mod_dynmasq.c' section at line 56
- <IfModule>: using 'mod_quotatab.c' section at line 100
- <IfModule>: skipping 'mod_ratio.c' section at line 104
- <IfModule>: using 'mod_delay.c' section at line 112
- <IfModule>: using 'mod_ctrls.c' section at line 116
- <IfModule>: using 'mod_ctrls_admin.c' section at line 124
- <IfModule>: using 'mod_sql.c' section at line 7

/var/log/proftpd/sql.log пустой

D
На сайте с 11.05.2010
Offline
15
#3

3-ка это мало, врубите 9 или 10-ку, там больше инфы должно быть

Г
На сайте с 25.10.2007
Offline
68
#4

врубил 10 уровень


Starting ftp server: proftpd - mod_tls/2.1.2: using OpenSSL 0.9.8g 19 Oct 2007
- disabling runtime support for IPv6 connections
- DenyFilter: compiling deny regex '\*.*/'
- <IfModule>: using 'mod_dynmasq.c' section at line 56
- retrieved UID 104 for user 'ftp'
- retrieved GID 1002 for group 'ftp'
- <IfModule>: using 'mod_quotatab.c' section at line 100
- <IfModule>: skipping 'mod_ratio.c' section at line 104
- <IfModule>: using 'mod_delay.c' section at line 112
- <IfModule>: using 'mod_ctrls.c' section at line 116
- <IfModule>: using 'mod_ctrls_admin.c' section at line 124
- <IfModule>: using 'mod_sql.c' section at line 7
server -
server - Config for Debian:
server - IdentLookups
server - DeferWelcome
server - DefaultServer
server - ShowSymlinks
server - TimeoutNoTransfer
server - TimeoutStalled
server - TimeoutIdle
server - DisplayLogin
server - DisplayChdir
server - ListOptions
server - DenyFilter
server - AllowForeignAddress
server - DefaultTransferMode
server - DefaultRoot
server - PassivePorts
server - UserID
server - UserName
server - GroupID
server - GroupName
server - Umask
server - DirUmask
server - AllowOverwrite
server - TransferLog
server - ExtendedLog
server - ExtendedLog
server - QuotaEngine
server - DelayEngine
server - SQLBackend
server - SQLEngine
server - SQLAuthenticate
server - SQLAuthTypes
server - SQLConnectInfo
server - RequireValidShell
server - SQLUserTable
server - SQLUsernameField
server - SQLPasswordField
server - SQLUidField
server - SQLGidField
server - SQLHomedirField
server - SQLShellField
server - SQLLogFile
server - DefaultRoot
server - ROOT PRIVS at mod_delay.c:307
server - RELINQUISH PRIVS at mod_delay.c:309
server - ROOT PRIVS at mod_ctrls.c:1618
server - RELINQUISH PRIVS at mod_ctrls.c:1620
server - mod_lang/0.8: binding to text domain 'proftpd' using locale path '/usr/share/locale'
server - retrieved group ID: 65534
server - setting group ID: 65534
server - SETUP PRIVS at main.c:2869
server - ROOT PRIVS at main.c:1946
server - RELINQUISH PRIVS at main.c:1953

лог

Oct 04 15:43:30 server proftpd[26144] server: ROOT PRIVS at main.c:2277
Oct 04 15:43:30 server proftpd[26144] server: opening scoreboard '/var/run/proftpd/proftpd.scoreboard'
Oct 04 15:43:30 server proftpd[26144] server: RELINQUISH PRIVS at main.c:2303
Oct 04 15:43:30 server proftpd[26144] server: ROOT PRIVS at mod_ctrls_admin.c:1092
Oct 04 15:43:30 server proftpd[26144] server: opening scoreboard '/var/run/proftpd/proftpd.scoreboard'
Oct 04 15:43:30 server proftpd[26144] server: RELINQUISH PRIVS at mod_ctrls_admin.c:1094
Oct 04 15:43:30 server proftpd[26144] server: ROOT PRIVS at inet.c:343
Oct 04 15:43:30 server proftpd[26144] server: RELINQUISH PRIVS at inet.c:406
Oct 04 15:43:30 server proftpd[26144] server: ProFTPD 1.3.1 (stable) (built Tue Oct 27 10:09:08 UTC 2009) standalone mode STARTUP
Oct 04 15:43:30 server proftpd[26144] server: ROOT PRIVS at pidfile.c:42
Oct 04 15:43:30 server proftpd[26144] server: RELINQUISH PRIVS at pidfile.c:44
Oct 04 15:43:45 server proftpd[26231] server: RELINQUISH PRIVS at main.c:1074
Oct 04 15:43:45 server proftpd[26231] server: no matching vhost found for 178.63.221.91#21, using DefaultServer 'Debian'
Oct 04 15:43:45 server proftpd[26231] server: notice: unable to resolve 'mm-26-33-120-178.dynamic.pppoe.mgts.by': Resolver Error 0 (no error)
Oct 04 15:43:45 server proftpd[26231] server (ip[ip]): ROOT PRIVS at main.c:919
Oct 04 15:43:45 server proftpd[26231] server (ip[ip]): SETUP PRIVS at main.c:924
Oct 04 15:43:45 server proftpd[26231] server (ip[ip]): FTP session requested from unknown class
Oct 04 15:43:45 server proftpd[26231] server (ip[ip]): performing module session initializations
Oct 04 15:43:45 server proftpd[26231] server (ip[ip]): ROOT PRIVS at mod_sql.c:4229
Oct 04 15:43:45 server proftpd[26231] server (ip[ip]): RELINQUISH PRIVS at mod_sql.c:4231
Oct 04 15:43:45 server proftpd[26231] server (ip[ip]): ProFTPD terminating (signal 11)
Oct 04 15:43:45 server proftpd[26231] server (ip[ip]): FTP session closed.
Oct 04 15:44:00 server proftpd[26144] server: scrubbing scoreboard
Oct 04 15:44:00 server proftpd[26144] server: ROOT PRIVS at scoreboard.c:761
Oct 04 15:44:00 server proftpd[26144] server: RELINQUISH PRIVS at scoreboard.c:763
Oct 04 15:44:00 server proftpd[26144] server: ROOT PRIVS at scoreboard.c:791
Oct 04 15:44:00 server proftpd[26144] server: RELINQUISH PRIVS at scoreboard.c:822

server это внутреннее название сервера

I
На сайте с 05.06.2006
Offline
117
#5

У меня на FreeBSD была похожая ситуация, до тех пор, пока я в /etc/hosts не вписал IP сервера

95.31.24X.XXX jnc-cnc.com
Миграция с ISPManager 4 в VestaCP (https://chast.in/copy-users-from-ispmanager-2-vestacp.html) Хостинг серверов, пользуюсь сам (http://vps-server.ru/rp/pl.php?96)
Г
На сайте с 25.10.2007
Offline
68
#6

в hosts у меня уже давно прописано

ip domain.tld

D
На сайте с 11.05.2010
Offline
15
#7

а к базе он вообще коннектится ? запросы идут ?

AH
На сайте с 06.10.2010
Offline
20
#8

Сталкивался с подобной проблемой. Ставил с диска, lenny update 4. Версия 1.3.1. После гугления снес и поставил с пакетов 1.3.3а - проблема исчезла.

Г
На сайте с 25.10.2007
Offline
68
#9
а к базе он вообще коннектится ? запросы идут ?

Без понятия.:)

Гесер добавил 06.10.2010 в 22:13

Так, я не правильно использовал дебаг:D

Ага, вот:

[quote]/usr/sbin/proftpd -n -d 10

- mod_tls/2.1.2: using OpenSSL 0.9.8g 19 Oct 2007

- disabling runtime support for IPv6 connections

- DenyFilter: compiling deny regex '\*.*/'

- <IfModule>: using 'mod_dynmasq.c' section at line 56

- retrieved UID 104 for user 'xxx'

- retrieved GID 1002 for group 'xxx'

- <IfModule>: using 'mod_quotatab.c' section at line 100

- <IfModule>: skipping 'mod_ratio.c' section at line 104

- <IfModule>: using 'mod_delay.c' section at line 112

- <IfModule>: using 'mod_ctrls.c' section at line 116

- <IfModule>: using 'mod_ctrls_admin.c' section at line 124

- <IfModule>: using 'mod_sql.c' section at line 7

myserver -

myserver - Config for Debian:

myserver - IdentLookups

myserver - DeferWelcome

myserver - DefaultServer

myserver - ShowSymlinks

myserver - TimeoutNoTransfer

myserver - TimeoutStalled

myserver - TimeoutIdle

myserver - DisplayLogin

myserver - DisplayChdir

myserver - ListOptions

myserver - DenyFilter

myserver - AllowForeignAddress

myserver - DefaultTransferMode

myserver - DefaultRoot

myserver - PassivePorts

myserver - UserID

myserver - UserName

myserver - GroupID

myserver - GroupName

myserver - Umask

myserver - DirUmask

myserver - AllowOverwrite

myserver - TransferLog

myserver - ExtendedLog

myserver - ExtendedLog

myserver - QuotaEngine

myserver - DelayEngine

myserver - SQLBackend

myserver - SQLEngine

myserver - SQLAuthenticate

myserver - SQLAuthTypes

myserver - SQLConnectInfo

myserver - RequireValidShell

myserver - SQLUserTable

myserver - SQLUsernameField

myserver - SQLPasswordField

myserver - SQLUidField

myserver - SQLGidField

myserver - SQLHomedirField

myserver - SQLShellField

myserver - SQLLogFile

myserver - DefaultRoot

myserver - ROOT PRIVS at mod_delay.c:307

myserver - RELINQUISH PRIVS at mod_delay.c:309

myserver - ROOT PRIVS at mod_ctrls.c:1618

myserver - RELINQUISH PRIVS at mod_ctrls.c:1620

myserver - mod_lang/0.8: binding to text domain 'proftpd' using lo cale path '/usr/share/locale'

myserver - retrieved group ID: 65534

myserver - setting group ID: 65534

myserver - SETUP PRIVS at main.c:2869

myserver - ROOT PRIVS at main.c:1946

myserver - RELINQUISH PRIVS at main.c:1953

myserver - ROOT PRIVS at main.c:2277

myserver - opening scoreboard '/var/run/proftpd/proftpd.scoreboard '

myserver - RELINQUISH PRIVS at main.c:2303

myserver - ROOT PRIVS at mod_ctrls_admin.c:1092

myserver - opening scoreboard '/var/run/proftpd/proftpd.scoreboard '

myserver - RELINQUISH PRIVS at mod_ctrls_admin.c:1094

myserver - ROOT PRIVS at inet.c:343

myserver - RELINQUISH PRIVS at inet.c:406

myserver - ProFTPD 1.3.1 (stable) (built Tue Oct 27 10:09:08 UTC 2 009) standalone mode STARTUP

myserver - ROOT PRIVS at pidfile.c:42

myserver - RELINQUISH PRIVS at pidfile.c:44

myserver - ROOT PRIVS at main.c:1070

myserver - RELINQUISH PRIVS at main.c:1074

myserver - no matching vhost found for ipserver#21, using Def aultServer 'Debian'

myserver - notice: unable to resolve 'мой домашний ip': Resolver Error 0 (no error)

myserver (ipserver[ipserver]) - ROOT PRIVS at main.c:9 19

myserver (ipserver[ipserver]) - SETUP PRIVS at main.c: 924

myserver (ipserver[ipserver]) - FTP session requested from unknown class

myserver (ipserver[ipserver]) - performing module sess ion initializations

myserver (ipserver[ipserver]) - ROOT PRIVS at mod_sql. c:4229

myserver (ipserver[ipserver]) - RELINQUISH PRIVS at mo d_sql.c:4231

myserver (ipserver[ipserver]) - ProFTPD terminating (s ignal 11)

myserver (ipserver[ipserver]) - FTP session closed.

myserver - scrubbing scoreboard

myserver - ROOT PRIVS at scoreboard.c:761

myserver - RELINQUISH PRIVS at scoreboard.c:763

myserver - ROOT PRIVS at scoreboard.c:791

myserver - RELINQUISH PRIVS at scoreboard.c:822

- scrubbing scoreboard

Тут еще, может быть дело в том, сначала я поставил proftpd из исходников, но не удалил(не догнадался как). Поэтому в системе их два фик знает как они между сабой деруться. т.е. если просто запусть proftpd без пути, то будет Fatal: unknown configuration directive 'bytes_in_avail,' on line 104 of '/usr /local//etc/proftpd.conf' А конфиг proftpd из репы у меня лежит в /etc/proftpd/.

SA
На сайте с 05.08.2010
Offline
2
#10

Напишите в личку, могу помочь разобраться. Все-таки в подобных случаях для понимания причины нужно видеть "пациента" живьем.

Авторизуйтесь или зарегистрируйтесь, чтобы оставить комментарий