dongyang1518 2019-04-27 08:02
浏览 330

Synology NAS php缺少扩展名

I'm using a Synology DS213 with DSM 6.2.2-24922. It appears to have a php engine even before I install any php packages on it. Unfortunately it won't let me connect to any database at it appears none of those extensions have beens allowed.

It appears my current php.ini file is located at /etc/php/php.ini and I could find the following extensions:

extension = bcmath.so
extension = bz2.so
extension = curl.so
extension = iconv.so
extension = ldap.so
extension = mcrypt.so
extension = openssl.so
extension = pdo_sqlite.so
extension = posix.so
extension = phar.so
extension = shmop.so
extension = sockets.so
extension = sqlite3.so
extension = zip.so
extension = syno_compiler.so

As you can see, pdo_mysql and mysqli are not supported. I tried adding them in, but that would give me the error that the file was missing.

I then tried working with the package manager and installed Web Station with PHP 5.6 and 7.2. This appears to have had no effect, as my default php was not changed whatsoever.

I verified this the following way:

root@DiskStation:/etc/php# php --ini
Configuration File (php.ini) Path: /etc/php
Loaded Configuration File:         /etc/php/php.ini
Scan for additional .ini files in: (none)
Additional .ini files parsed:      (none)

As you can see, it's still calling the default php.ini instead of the new ones I got from my packages.

All I want to do is very simple. I'm running a PHP script which is calling an api. It parses the response and writes it to the MariaDB 10 also located on the Synology NAS. Calling the api already works, but actually getting a connection to the database is proving to be rather difficult.

  • 写回答

0条回答 默认 最新

    报告相同问题?

    悬赏问题

    • ¥15 素材场景中光线烘焙后灯光失效
    • ¥15 请教一下各位,为什么我这个没有实现模拟点击
    • ¥15 执行 virtuoso 命令后,界面没有,cadence 启动不起来
    • ¥50 comfyui下连接animatediff节点生成视频质量非常差的原因
    • ¥20 有关区间dp的问题求解
    • ¥15 多电路系统共用电源的串扰问题
    • ¥15 slam rangenet++配置
    • ¥15 有没有研究水声通信方面的帮我改俩matlab代码
    • ¥15 ubuntu子系统密码忘记
    • ¥15 保护模式-系统加载-段寄存器