On Tue, Oct 28, 2008 at 07:23:37AM -0400, Nicholas wrote:
> $ telnet 192.168.4.10 21 (nas)
> ...
> 230 User logged in, proceed.
> HELP
> 211 System not supported features
> USER  PASS  QUIT  PORT  NLST  LIST  TYPE  MODE  RETR  STOR
> DELE  CWD  CDUP  PWD  XPWD  MKD  XMKD  RMD  XRMD  NOOP
> SYST  ABOR  RNFR  RNTO  PASV  REST  APPE  STAT  HELP  SIZE
> SITE  FEAT  OPTS
>
> LIST
> 425 Can't open data connection.
> CWD /tmp
> 550 Requested action not taken.
> MKD foo
> 550 Requested action not taken.
> cwd PUBLIC
> 250 Requested file action okay, completed.
> MKD foo
> 257 "/PUBLIC/foo" created.
> ...
>
> И далее переименование работает.
> Вопрос как переместить файл или директорию в другую директорию.
> Эксперементы с RNFR/RNTO непомогли:
>
> cwd PUBLIC
> 250 Requested file action okay, completed.
> MKD 1
> 257 "/PUBLIC/1" created.
> MKD 2
> 257 "/PUBLIC/2" created.
> cwd 1
> 250 Requested file action okay, completed.
> MKD 3
> 257 "/PUBLIC/1/3" created.
> RNFR 3
> 350 Requested file action pending further information.
> RNTO /PUBLIC/2
> 250 Requested file action okay, completed.
>
> в этом случае директория /PUBLIC/1/3 переименовыывется в /PUBLIC/1/2, а  
> не перемещается в /PUBLIC/2/
> То же самое происходит, если RNTO ../2

Что и требовалось доказать: нерабочий/криво настронный ftp-сервер.
Выбрось каку. Ниже пример с vsftpd:

>>>>> xterm 1 <<<<<
% telnet 192.168.0.1 21
Trying 192.168.0.1...
Connected to 192.168.0.1.
Escape character is '^]'.
220 (vsFTPd 2.0.6)
user stas
331 Please specify the password.
pass ************
230 Login successful.
cwd /tmp
250 Directory successfully changed.
mkd foo
257 "/tmp/foo" created
mkd bar
257 "/tmp/bar" created
mkd foo/1
257 "/tmp/foo/1" created
mkd foo/2
257 "/tmp/foo/2" created
mkd foo/3
257 "/tmp/foo/3" created
rnfr foo
350 Ready for RNTO.
rnto bar/foo
250 Rename successful.
cwd bar/foo
250 Directory successfully changed.
pasv
227 Entering Passive Mode (192,168,0,1,137,120)
>>>>> xterm 2 <<<<<
% telnet 192.168.0.1 `calc 137*256+120`
Trying 192.168.0.1...
Connected to 192.168.0.1.
Escape character is '^]'.
>>>>> xterm 1 <<<<<
list
150 Here comes the directory listing.
>>>>> xterm 2 <<<<<
drwx------    2 1000     1000           40 Oct 28 17:58 1
drwx------    2 1000     1000           40 Oct 28 17:59 2
drwx------    2 1000     1000           40 Oct 28 17:59 3
Connection closed by foreign host.
>>>>> xterm 1 <<<<<
226 Directory send OK.
quit
221 Goodbye.
Connection closed by foreign host.
>>>>> the end <<<<<

-- 
Stanislav


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Ответить