You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

DirectAdmin CustomBuild无法下载PHP文件问题求助

问题:DirectAdmin CustomBuild构建PHP时遭遇404错误,无法获取PHP源码包

错误详情

curl: (22) The requested URL returned error: 404 Not Found Download of https://files.directadmin.com/services/custombuild/php-8.1.16.tar.gz failed, re-downloading the file... Download of https://files.directadmin.com/services/custombuild/php-8.1.16.tar.gz failed 4 times, exiting...

多次执行构建操作均失败,检查发现DirectAdmin CustomBuild的官方目录中不存在任何PHP版本文件。

解决方法

1. 更新CustomBuild工具

旧版本CustomBuild可能仍在使用过时的源码路径,先执行更新:

cd /usr/local/directadmin/custombuild
./build update

更新完成后重新尝试构建PHP:

./build php n

2. 手动下载PHP源码包到本地

若官方源确实缺失对应文件,可手动下载源码包到CustomBuild的下载目录:

  • 创建下载目录(如不存在):
mkdir -p /usr/local/directadmin/custombuild/downloads
  • 从PHP官方渠道下载指定版本源码包(以php-8.1.16为例):
wget https://www.php.net/distributions/php-8.1.16.tar.gz -P /usr/local/directadmin/custombuild/downloads/
  • 执行构建命令:
./build php n

3. 检查CustomBuild配置文件

查看options.conf确认PHP相关配置是否正常:

cat /usr/local/directadmin/custombuild/options.conf

若发现错误的源地址,修改后保存,再重新执行更新与构建操作。

4. 联系DirectAdmin官方支持

若上述方法均无效,可能是官方源临时故障或该PHP版本已被移除,建议提交工单联系DirectAdmin官方,确认版本支持情况或获取替代下载方案。

内容的提问来源于stack exchange,提问作者Mehran

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.25 13:17:15