简体   繁体   English

安装Libsodium(Amazon EC2)时发生库故障

[英]Library failure when installing Libsodium (Amazon EC2)

I can't figure out how to get Libsodium up and running on my EC2 instance. 我不知道如何在我的EC2实例上启动和运行Libsodium。

When attempting to check if the installation was successful with: 尝试使用以下方法检查安装是否成功:

php7 --info | grep sodium

I get the following warning: 我收到以下警告:

PHP Warning:  PHP Startup: Invalid library (maybe not a PHP library) 'sodium.so' in Unknown on line 0

Here's what I've tried so far: 到目前为止,这是我尝试过的方法:

  • Installing Libsodium using pecl7 install libsodium. 使用pecl7安装Libsodium安装libsodium。
  • Installing Libsodium using the latest tar.gz 使用最新的tar.gz安装Libsodium
  • Reinstalled PHP7 entirely (with apache 2.4) 完全重新安装了PHP7(使用Apache 2.4)

This particular warning keeps popping up and my sodium functions are still unavailable. 此特殊警告不断弹出,并且我的钠功能仍然不可用。

Does anyone have any experience with installing Libsodium on PHP 7(+) on Amazon EC2 instances or do I have to wait for 7.2 to be stable and available? 是否有人在Amazon EC2实例上的PHP 7(+)上安装Libsodium有任何经验,还是我必须等待7.2稳定并可用?

Edit: 编辑:

For anyone reading this after this question has been answered: This was a bug in the package manager ( https://github.com/jedisct1/libsodium-php/issues/156 ) the matter has been resolved, reinstalling with pecl7 install libsodium fixed the issues. 对于在回答此问题后阅读此书的任何人:这是程序包管理器( https://github.com/jedisct1/libsodium-php/issues/156 )中的错误,此问题已解决,请使用pecl7重新安装libsodium已修复问题。

Same on alpine and PHP 7.1... I am installing it via PECL. 在Alpine和PHP 7.1上也是如此...我正在通过PECL安装它。

There is a bug report about it: https://github.com/jedisct1/libsodium-php/issues/156 有关于它的错误报告: https : //github.com/jedisct1/libsodium-php/issues/156

You can overcome this issue by forcing to use 2.0.8 until the issue gets fixed: pecl install -f libsodium-2.0.8 您可以通过强制使用2.0.8直到问题得到解决来解决此问题: pecl install -f libsodium-2.0.8

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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