Articles of curl

无法从给定服务器下载某些文件

我正在开发一个Fedora Core版本6,每当我想从FTP站点下载给定的文件,连接都会被拒绝: $ curl –ftp-pasv "ftp://ftp.ensembl.org/pub/current_mysql/vega_mart_56/CHECKSUMS.gz" curl: (7) couldn't connect to host $ wget "ftp://ftp.ensembl.org/pub/current_mysql/vega_mart_56/CHECKSUMS.gz" –14:25:46– ftp://ftp.ensembl.org/pub/current_mysql/vega_mart_56/CHECKSUMS.gz => `CHECKSUMS.gz' Resolving ftp.ensembl.org… 193.62.203.113 Connecting to ftp.ensembl.org|193.62.203.113|:21… failed: Connection refused. 从HTTP服务器下载是好的。 这是一个防火墙问题? 我怎样才能解决这个问题 ? (系统pipe理员在假期… :-)) 谢谢

如何在ubuntu服务器上安装openssl的cURL?

我在这里遇到了cURL的问题。 我的本地主机已启用opensslcurl,因此我的PHP代码工作正常。 在运行phpinfo()我得到以下 – curl cURL support enabled cURL Information libcurl/7.19.5 OpenSSL/0.9.8g zlib/1.2.3.3 libidn/1.15 但是,在我的其他办公室服务器上,curl没有启用openssl支持。 在运行phpinfo()我得到以下 – curl cURL support enabled cURL Information libcurl/7.20.1 zlib/1.2.3.3 如何获得openssl对curl的支持? 截至目前,办公服务器上都安装了openssl和curl。 我需要立即的帮助。 谢谢。

如何使用FTP仅在Linux机器上启用PHP Curl

我只有访问只有php.ini文件,我想能够添加curl extenssion到我的Linux机器。 我没有进入terminal。 我试着添加: 延长= curl.so 但它不起作用。 是否有可能通过FTP添加curl? 谢谢。

在Ubuntu 11.10上启用CURL

我已经安装了curl: sudo apt-get install curl libcurl3 libcurl3-dev php5-curl 我已经更新了我的php.ini文件,包括(我也试过.so): extension=php_curl.dll 为了testingcurl是否工作,我创build了一个名为testCurl.php的文件,它包含以下内容: <?php echo '<pre>'; var_dump(curl_version()); echo '</pre>'; ?> 当我导航到本地/ testCurl.php我得到一个错误:HTTP错误500 下面是错误日志中的一个片段: PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626+lfs/php_curl.dll' – /usr/lib/php5/20090626+lfs/php_curl.dll: cannot op$ PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php5/20090626+lfs/sqlite.so' – /usr/lib/php5/20090626+lfs/sqlite.so: cannot open sha$ [Sun Dec 25 12:10:17 2011] […]

什么是libcurl.so.3的正确的依赖rpm

所以我有一个失败的依赖项,我无法下载正确的rpm。 错误是libcurl.so.3()(64bit) is needed 。 我有Centos 6,我有正确的转速在这个网站上看。 问题是,这是另一个地方,Linux不能直观,是rpm名称是不同的依赖名称。 所以它可能是一个curl3 rpm或libcurl3 rpm或者我不知道。 任何人都知道这是哪一个?

在Ubuntu Karmic上安装CURL

试图得到这个启动和运行: https://github.com/cloudnull/massupload 我除了CURL安装了一切,当我尝试时,它会失败,如下所示: Reading package lists… Done Building dependency tree Reading state information… Done The following NEW packages will be installed: curl 0 upgraded, 1 newly installed, 0 to remove and 3 not upgraded. Need to get 196kB of archives. After this operation, 311kB of additional disk space will be used. WARNING: The following packages […]

curl,在网站响应内容中匹配一个string

有什么办法,我可以validation页面的内容,如果它们存在吗? 就像我打开google.com,如果其网页内容中有“错误”,那么我可以知道该网页打开不正确。 (我已经知道如何检查页面状态码检查,如200,400,404或500等),我实际上有兴趣获取和比较页面的内容与string,并采取所需的行动,基于该string

testing服务器是否curl和grep。 Grep添加标题?

嗨我想看看我正在运行的服务器是否已经停止(如果有,它会返回一个502错误的网关消息。 所以我试图做到这一点: curl http://MY_URL | grep "502" curl部分返回我所期望的。 但是当我把它变成grep时,grep似乎正在增加一些标题: % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 113 682 113 682 0 0 230k 0 –:–:– –:–:– –:–:– 666k 这些不在curl的输出中。 而在普通文本文件上的grep不会添加它们。 那么为什么他们被添加到curl通过grepcurl?

SSL错误curl / wget未知协议/错误的版本号

我一直在尝试在命令行/ cron作业中使用本地托pipehttpsurl,我得到这些错误。 curl输出类似。 当在其他服务器中使用相同的命令时可以完美地工作。 默认 [root@tejon ~]# wget -O /dev/null https://www.domain.com/cron/notification.php –2013-05-27 10:33:38– https://www.domain.com/cron/notification.php Resolving www.domain.com… 173.45.38.60 Connecting to www.domain.com|173.45.38.60|:443… connected. OpenSSL: error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol Unable to establish SSL connection. 使用TLSv1 [root@tejon ~]# wget –secure-protocol=TLSv1 -O /dev/null https://www.domain.com/cron/notification.php –2013-05-27 10:45:59– https://www.domain.com/cron/notification.php Resolving www.domain.com… 173.45.38.60 Connecting to www.domain.com|173.45.38.60|:443… connected. OpenSSL: error:1408F10B:SSL routines:SSL3_GET_RECORD:wrong version number Unable to […]

是否有可能使用curl来准确地testing一个网站有很多的JavaScript?

我有一个网站,有很多的JavaScript,但简单的HTML。 我想用curl来尝试简单的压力testing。 那可能吗? 如果我只是curl的网站,我得到的HTML。 因此,大量的curl请求并不能告诉我它是如何在一定的stream量上执行的。 (我知道有1000多种复杂的压力testing框架和方法 – 我很高兴能够学习它们,但是现在我需要一些快速和肮脏的东西,因为这个网站在几天之内会有很多stream量。)有没有办法使用CURL来testing一个JavaScript密集的网站?