免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
1234下一页
最近访问板块 发新帖
查看: 6043 | 回复: 30
打印 上一主题 下一主题

[FTP] [求助]proftpd不能登陆 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2005-10-10 10:21 |只看该作者 |倒序浏览
安装中碰到了一些问题,向大家请教一下。

1.安装proftpd,基本按照《FreeBSD网站平台建设全过程》,但是如果用他的proftpd.conf就会出现以下错误。
#./proftpd -n -d 5 -c /usr/local/proftpd/etc/proftpd.conf
.
.
.
.
ent.com.cn - deleting existing scoreboard '/usr/local/proftpd/var/proftpd/proftpd.scoreboard'
ent.com.cn - Failed binding to 0.0.0.0, port 21: Address already in useent.com.cn - Check the ServerType directive to ensure you are configured correctly.

2.用自己的proftpd.conf,出现了不能登陆的现象:

  1. ServerName                      "Welcome to FTP Server"
  2. ServerType                      standalone
  3. DefaultServer                   on
  4. PidFile                         /usr/local/proftpd/var/proftpd/proftpd.pid
  5. UseReverseDNS                   off
  6. port                            9708
  7. TimeoutIdle                     0
  8. TimeoutLogin                    50
  9. TimeoutNoTransfer               0
  10. Umask                           000
  11. MaxInstances                    300

  12. <Directory />;
  13.   AllowOverwrite                on
  14.   AllowRetrieveRestart          on
  15.   AllowStoreRestart             on
  16. </Directory>;

  17. <Global>;
  18. AllowForeignAddress             on
  19. DefaultTransferMode             binary
  20. DisplayFirstChdir               /usr/local/proftpd/etc/.message
  21. DisplayLogin                    /usr/local/proftpd/etc/welcome
  22. HiddenStor                      off
  23. IdentLookups                    off
  24. MaxLoginAttempts                1
  25. ServerIdent                     on "Welcome To FTP Server...."
  26. RequireValidShell               off
  27. TimesGMT                        off
  28. User                            nobody
  29. Group                           nobody
  30. ServerLog                       /var/log/proftpd.log
  31. file:/usr/local/proftpd/etc/anonymous.allow file:/usr/local/proftpd/etc/anonymous.den
  32. WtmpLog                         off
  33. </Global>;

  34. <Anonymous /data/ftp/>;
  35. User ftp
  36. Group ftpusers
  37. <Limit LOGIN>;
  38. AllowAll
  39. </Limit>;
  40. </Anonymous>;
复制代码


出错情况是:

  1. #/usr/local/etc# ftp localhost 9708
  2. Connected to localhost.
  3. 220 Welcome To FTP Server....
  4. Name (localhost:fly): fly
  5. 421 Service not available, remote server has closed connection.
  6. ftp: Login failed.
  7. ftp: No control connection for command.
  8. ftp>;
复制代码


在问完name后就直接close了。

请大大们指教一下。谢谢!

论坛徽章:
0
2 [报告]
发表于 2005-10-10 10:59 |只看该作者

[求助]proftpd不能登陆

换用你的配置文件之前,停掉proftpd进程了吗

kill掉所有的proftpd进程,然后启动proftpd再试试

论坛徽章:
0
3 [报告]
发表于 2005-10-10 12:26 |只看该作者

[求助]proftpd不能登陆

谢谢版主回复。

换用前停掉进程的,要不然我得不到这2个错误提示的。

论坛徽章:
0
4 [报告]
发表于 2005-10-10 12:55 |只看该作者

[求助]proftpd不能登陆

proftpd都停了的情况下,用netstat -tlunp看看还有没有21端口

论坛徽章:
0
5 [报告]
发表于 2005-10-10 13:05 |只看该作者

[求助]proftpd不能登陆

我的系统是freebsd 4.11 stable

# netstat -tlunp
netstat: option requires an argument -- p
usage: netstat [-AaLnSW] [-f protocol_family | -p protocol]
               [-M core] [-N system]
       netstat -i | -I interface [-abdnt] [-f address_family]
               [-M core] [-N system]
       netstat -w wait [-I interface] [-d] [-M core] [-N system]
       netstat -s [-s] [-z] [-f protocol_family | -p protocol] [-M core]
       netstat -i | -I interface -s [-f protocol_family | -p protocol]
               [-M core] [-N system]
       netstat -m [-M core] [-N system]
       netstat -r [-AanW] [-f address_family] [-M core] [-N system]
       netstat -rs [-s] [-M core] [-N system]
       netstat -g [-W] [-f address_family] [-M core] [-N system]
       netstat -gs [-s] [-f address_family] [-M core] [-N system]

好象没有这个命令。


# netstat -tun | grep :21
这个命令后没有提示。

而且我并没有用到inetd.

论坛徽章:
0
6 [报告]
发表于 2005-10-10 13:09 |只看该作者

[求助]proftpd不能登陆

用你的配置文件
./proftpd -n -d9
启动proftpd,观察用户登录时输出的debug信息

论坛徽章:
0
7 [报告]
发表于 2005-10-10 13:16 |只看该作者

[求助]proftpd不能登陆

还是一样的提示。


  1. # ./proftpd -n -d9
  2. - parsing '/usr/local/proftpd/etc/proftpd.conf' configuration
  3. - FS: using system open()
  4. - FS: using system read()
  5. - dispatching directive 'ServerName' to module mod_core
  6. - dispatching directive 'ServerType' to module mod_core
  7. - dispatching directive 'DefaultServer' to module mod_core
  8. - dispatching directive 'ServerIdent' to module mod_core
  9. - dispatching directive 'Port' to module mod_core
  10. - dispatching directive 'Umask' to module mod_core
  11. - dispatching directive 'MaxLoginAttempts' to module mod_auth
  12. - dispatching directive 'TimeoutLogin' to module mod_auth
  13. - dispatching directive 'TimeoutIdle' to module mod_core
  14. - dispatching directive 'TimeoutNoTransfer' to module mod_xfer
  15. - dispatching directive 'TimeoutStalled' to module mod_xfer
  16. - dispatching directive 'MaxClients' to module mod_auth
  17. - dispatching directive 'MaxClientsPerHost' to module mod_auth
  18. - dispatching directive 'AllowOverwrite' to module mod_xfer
  19. - dispatching directive 'AllowStoreRestart' to module mod_xfer
  20. - dispatching directive 'UseReverseDNS' to module mod_core
  21. - dispatching directive 'RequireValidShell' to module mod_auth
  22. - dispatching directive 'DefaultRoot' to module mod_auth
  23. - dispatching directive 'DefaultRoot' to module mod_auth
  24. - FS: using system read()
  25. - dispatching directive 'MaxInstances' to module mod_core
  26. - dispatching directive 'User' to module mod_core
  27. - dispatching auth request "getpwnam" to module mod_sql
  28. - dispatching auth request "getpwnam" to module mod_auth_file
  29. - dispatching auth request "getpwnam" to module mod_auth_unix
  30. - dispatching directive 'Group' to module mod_core
  31. - dispatching auth request "getgrnam" to module mod_sql
  32. - dispatching auth request "getgrnam" to module mod_auth_file
  33. - dispatching auth request "getgrnam" to module mod_auth_unix
  34. - dispatching directive '<Directory>;' to module mod_core
  35. - <Directory />;: adding section for resolved path '/'
  36. - dispatching directive 'AllowOverwrite' to module mod_xfer
  37. - dispatching directive '</Directory>;' to module mod_core
  38. - dispatching directive '<Anonymous>;' to module mod_core
  39. - dispatching directive 'User' to module mod_core
  40. - dispatching directive 'Group' to module mod_core
  41. - dispatching directive 'UserAlias' to module mod_auth
  42. - dispatching directive 'MaxClients' to module mod_auth
  43. - dispatching directive 'DisplayLogin' to module mod_core
  44. - dispatching directive 'DisplayFirstChdir' to module mod_core
  45. - dispatching directive '</Anonymous>;' to module mod_core
  46. - FS: using system read()
  47. - dispatching directive 'SQLConnectInfo' to module mod_sql
  48. - dispatching directive 'SQLAuthTypes' to module mod_sql
  49. - dispatching directive 'SQLUserInfo' to module mod_sql
  50. - dispatching directive 'SQLGroupInfo' to module mod_sql
  51. - dispatching directive 'SQLAuthenticate' to module mod_sql
  52. - dispatching directive 'SQLHomedirOnDemand' to module mod_sql
  53. - dispatching directive 'QuotaDirectoryTally' to module mod_quotatab
  54. - dispatching directive 'QuotaDisplayUnits' to module mod_quotatab
  55. - dispatching directive 'QuotaEngine' to module mod_quotatab
  56. - dispatching directive 'QuotaLog' to module mod_quotatab
  57. - dispatching directive 'QuotaShowQuotas' to module mod_quotatab
  58. - FS: using system read()
  59. - dispatching directive 'SQLNamedQuery' to module mod_sql
  60. - dispatching directive 'SQLNamedQuery' to module mod_sql
  61. - dispatching directive 'SQLNamedQuery' to module mod_sql
  62. - dispatching directive 'SQLNamedQuery' to module mod_sql
  63. - dispatching directive 'QuotaLimitTable' to module mod_quotatab
  64. - dispatching directive 'QuotaTallyTable' to module mod_quotatab
  65. - FS: using system read()
  66. - FS: using system close()
  67. ent.com.cn -
  68. ent.com.cn - Config for ftpx.3322.org:
  69. ent.com.cn - /ftp/
  70. ent.com.cn -  UserName
  71. ent.com.cn -  GroupName
  72. ent.com.cn -  UserAlias
  73. ent.com.cn -  MaxClients
  74. ent.com.cn -  DisplayLogin
  75. ent.com.cn -  DisplayFirstChdir
  76. ent.com.cn -  Umask
  77. ent.com.cn -  MaxClientsPerHost
  78. ent.com.cn -  AllowOverwrite
  79. ent.com.cn -  AllowStoreRestart
  80. ent.com.cn -  RequireValidShell
  81. ent.com.cn -  SQLConnectInfo
  82. ent.com.cn -  SQLAuthTypes
  83. ent.com.cn -  SQLAuthenticate
  84. ent.com.cn -  SQLHomedirOnDemand
  85. ent.com.cn -  SQLNamedQuery_get-quota-limit
  86. ent.com.cn -  SQLNamedQuery_get-quota-tally
  87. ent.com.cn -  SQLNamedQuery_update-quota-tally
  88. ent.com.cn -  SQLNamedQuery_insert-quota-tally
  89. ent.com.cn - /
  90. ent.com.cn -  AllowOverwrite
  91. ent.com.cn -  Umask
  92. ent.com.cn -  MaxClients
  93. ent.com.cn -  MaxClientsPerHost
  94. ent.com.cn -  AllowStoreRestart
  95. ent.com.cn -  RequireValidShell
  96. ent.com.cn -  SQLConnectInfo
  97. ent.com.cn -  SQLAuthTypes
  98. ent.com.cn -  SQLAuthenticate
  99. ent.com.cn -  SQLHomedirOnDemand
  100. ent.com.cn -  SQLNamedQuery_get-quota-limit
  101. ent.com.cn -  SQLNamedQuery_get-quota-tally
  102. ent.com.cn -  SQLNamedQuery_update-quota-tally
  103. ent.com.cn -  SQLNamedQuery_insert-quota-tally
  104. ent.com.cn - DefaultServer
  105. ent.com.cn - ServerIdent
  106. ent.com.cn - Umask
  107. ent.com.cn - MaxLoginAttempts
  108. ent.com.cn - TimeoutLogin
  109. ent.com.cn - TimeoutIdle
  110. ent.com.cn - TimeoutNoTransfer
  111. ent.com.cn - TimeoutStalled
  112. ent.com.cn - MaxClients
  113. ent.com.cn - MaxClientsPerHost
  114. ent.com.cn - AllowOverwrite
  115. ent.com.cn - AllowStoreRestart
  116. ent.com.cn - RequireValidShell
  117. ent.com.cn - DefaultRoot
  118. ent.com.cn - DefaultRoot
  119. ent.com.cn - UserID
  120. ent.com.cn - UserName
  121. ent.com.cn - GroupID
  122. ent.com.cn - GroupName
  123. ent.com.cn - SQLConnectInfo
  124. ent.com.cn - SQLAuthTypes
  125. ent.com.cn - SQLUserTable
  126. ent.com.cn - SQLUsernameField
  127. ent.com.cn - SQLPasswordField
  128. ent.com.cn - SQLUidField
  129. ent.com.cn - SQLGidField
  130. ent.com.cn - SQLHomedirField
  131. ent.com.cn - SQLShellField
  132. ent.com.cn - SQLGroupTable
  133. ent.com.cn - SQLGroupnameField
  134. ent.com.cn - SQLGroupGIDField
  135. ent.com.cn - SQLGroupMembersField
  136. ent.com.cn - SQLAuthenticate
  137. ent.com.cn - SQLHomedirOnDemand
  138. ent.com.cn - QuotaDirectoryTally
  139. ent.com.cn - QuotaDisplayUnits
  140. ent.com.cn - QuotaEngine
  141. ent.com.cn - QuotaLog
  142. ent.com.cn - QuotaShowQuotas
  143. ent.com.cn - SQLNamedQuery_get-quota-limit
  144. ent.com.cn - SQLNamedQuery_get-quota-tally
  145. ent.com.cn - SQLNamedQuery_update-quota-tally
  146. ent.com.cn - SQLNamedQuery_insert-quota-tally
  147. ent.com.cn - QuotaLimitTable
  148. ent.com.cn - QuotaTallyTable
  149. ent.com.cn - dispatching auth request "getgroups" to module mod_sql
  150. ent.com.cn - dispatching auth request "getgroups" to module mod_auth_file
  151. ent.com.cn - dispatching auth request "getgroups" to module mod_auth_unix
  152. ent.com.cn - SETUP PRIVS at main.c:2733
  153. ent.com.cn - ROOT PRIVS at main.c:1967
  154. ent.com.cn - RELINQUISH PRIVS at main.c:1974
  155. ent.com.cn - ROOT PRIVS at main.c:2322
  156. ent.com.cn - deleting existing scoreboard '/usr/local/proftpd/var/proftpd/proftpd.scoreboard'
  157. ent.com.cn - opening scoreboard '/usr/local/proftpd/var/proftpd/proftpd.scoreboard'
  158. ent.com.cn - RELINQUISH PRIVS at main.c:2348
  159. ent.com.cn - ROOT PRIVS at inet.c:243
  160. ent.com.cn - RELINQUISH PRIVS at inet.c:259
  161. ent.com.cn - ROOT PRIVS at inet.c:322
  162. ent.com.cn - RELINQUISH PRIVS at inet.c:362
  163. ent.com.cn - [color=red]Failed binding to 0.0.0.0, port 21: Address already in use[/color]
  164. ent.com.cn - Check the ServerType directive to ensure you are configured correctly.
复制代码

论坛徽章:
0
8 [报告]
发表于 2005-10-10 13:18 |只看该作者

[求助]proftpd不能登陆

Failed binding to 0.0.0.0, port 21: Address already in use

就是因为这个,我才怀疑是已经有进程占用了21端口,你再仔细查一查吧

论坛徽章:
0
9 [报告]
发表于 2005-10-10 13:37 |只看该作者

[求助]proftpd不能登陆

# netstat -tunl | grep :21
#
好象没有啊

另外请帮忙再看用我自己的conf后,用自己的conf不会出现binding error,但是连接FTP后出现421是怎么回事?谢谢

论坛徽章:
0
10 [报告]
发表于 2005-10-10 14:20 |只看该作者

[求助]proftpd不能登陆

原帖由 "khbd2k4" 发表:
# netstat -tunl | grep :21
#
好象没有啊

另外请帮忙再看用我自己的conf后,用自己的conf不会出现binding error,但是连接FTP后出现421是怎么回事?谢谢


你把 netstat -tunl的结果post上来
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP