FTP ダウンロードに Curb (ruby curl bindings) を使用すると問題が発生します。
拡張パッシブ モードが失敗した場合、縁石はシンプル パッシブ モードにフォールバックしないようです。ログからの抜粋は次のとおりです。
< 250 Directory changed to /outgoing/productcatalog/35591
> EPSV
* Connect data stream passively
< 229 Entering Passive Mode (|||40938|)
* Trying 216.34.207.42... * Connecting to 216.34.207.42 (216.34.207.42) port 40938
* Connection failed
* Expire cleared
* Closing connection #0
次に、スローで Curl::Err::ConnectionFailedError: サーバーに接続できませんでした
ただし、コマンド ラインで curl を使用すると、
< 250 Directory changed to /outgoing/productcatalog/35591
> EPSV
* Connect data stream passively
< 229 Entering Passive Mode (|||43267|)
* Trying 216.34.207.42... Connection refused
* couldn't connect to host
* got positive EPSV response, but can't connect. Disabling EPSV
> PASV
< 227 Entering Passive Mode (216,34,207,42,169,4)
* Trying 216.34.207.42... connected
解決策は epsv を完全に無効にすることですが、Curb では不可能なようです。そのようなオプションはありません。この状況で何ができるでしょうか?