简体   繁体   中英

Pecl install sqlsrv returns No releases available for package

While installing sqlsrv module for PHP7 i'm getting following error -

No releases available for package "pecl.php.net/sqlsrv

Command used

sudo pecl install sqlsrv 

Any idea how to resolve this issue?

Same problem here... Solved installing modules as root this way (Ubuntu 16.04):

    wget http://pecl.php.net/get/sqlsrv-4.3.0.tgz
    pear install sqlsrv-4.3.0.tgz

    wget http://pecl.php.net/get/pdo_sqlsrv-4.3.0.tgz
    pear install pdo_sqlsrv-4.3.0.tgz

You can check latests available versions here: http://pecl.php.net/package-search.php?pkg_name=sqlsrv&bool=AND&submit=Search

And check if php modules are enabled after installation:

    php -m | grep sqlsrv   

对于公司代理用户,您可能只需要告诉 pear 使用您的代理。

pear config-set http_proxy http://proxy.example.com:8080

Try to install a certain version that you know exists:

$ pecl install sqlsrv-4.3.0

Also try to clear the cache:

$ pear clear-cache

Sometimes pecl.php.net is not available or down. In this case pecl install may show "no releases available".

Just for information.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM