FTP

FTP 200 Command OK vs 226 Closing Data Connection

Both FTP 200 (Command OK) and 226 (Closing Data Connection) belong to the 2xx Positive Completion category. 200 indicates that the command has been successfully executed. This is a general acknowledgment that the command was understood and carried out. Meanwhile, 226 means that closing data connection. The requested file action was successful and the data connection is being closed.

Mô tả

The command has been successfully executed. This is a general acknowledgment that the command was understood and carried out.

Khi bạn thấy mã này

After issuing any command that completes successfully, such as TYPE, MODE, or NOOP.

Cách khắc phục

No fix needed — the command succeeded. This is the standard positive response for commands that don't return data.

Mô tả

Closing data connection. The requested file action was successful and the data connection is being closed.

Khi bạn thấy mã này

After a file transfer, directory listing, or other data operation completes successfully.

Cách khắc phục

No fix needed — the transfer completed successfully. The data connection is closed and a new one will be opened for the next transfer.

Sự khác biệt chính

1.

FTP 200: The command has been successfully executed. This is a general acknowledgment that the command was understood and carried out.

2.

FTP 226: Closing data connection. The requested file action was successful and the data connection is being closed.

3.

You encounter 200 when after issuing any command that completes successfully, such as TYPE, MODE, or NOOP.

4.

You encounter 226 when after a file transfer, directory listing, or other data operation completes successfully.

Khi nào dùng cái nào

For 200 (Command OK): No fix needed — the command succeeded. This is the standard positive response for commands that don't return data. For 226 (Closing Data Connection): No fix needed — the transfer completed successfully. The data connection is closed and a new one will be opened for the next transfer.

Tìm hiểu thêm