报错信息如下:
[root@server ~]# sudo -i
[root@server ~]# export CV=[CN] DV=N && wget --no-check-certificate https://dl.amh.sh/amh.sh && bash amh.sh nginx-1.20,mysql-5.6,php-7.4
--2024-09-22 18:49:10-- https://dl.amh.sh/amh.sh
Resolving dl.amh.sh (dl.amh.sh)... 120.79.83.73, 2408:4003:1000:9aff:3c8f:27e6:888:b6bb
Connecting to dl.amh.sh (dl.amh.sh)|120.79.83.73|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 12366 (12K) [application/octet-stream]
Saving to: ‘amh.sh.5’
100%[============================================================================================================================================================================================>] 12,366 --.-K/s in 0s
2024-09-22 18:49:10 (271 MB/s) - ‘amh.sh.5’ saved [12366/12366]
AMH-7.1
Powered by amh.sh 2006-2023
https://amh.sh All Rights Reserved
==========================================================================
CentOS7 64Bit
Server ip
2*CPU, 3950MB/RAM, 1023MB/Swap
[Notice] AMH与MySQL初始账号密码:
admin: afca6f3dfdbf
root: afca6f3dfdbf
[Notice] 现在安装AMH-7.1吗?确认安装请输入y回车:y
[Notice] 即将安装AMH ...
已加载插件:fastestmirror
Loading mirror speeds from cached hostfile
One of the configured repositories failed (未知),
and yum doesn't have enough cached data to continue. At this point the only
safe thing yum can do is fail. There are a few ways to work "fix" this:
1. Contact the upstream for the repository and get them to fix the problem.
2. Reconfigure the baseurl/etc. for the repository, to point to a working
upstream. This is most often useful if you are using a newer
distribution release than is supported by the repository (and the
packages for the previous distribution release still work).
3. Run the command with the repository temporarily disabled
yum --disablerepo=<repoid> ...
4. Disable the repository permanently, so yum won't use it by default. Yum
will then just ignore the repository until you permanently enable it
again or use --enablerepo for temporary usage:
yum-config-manager --disable <repoid>
or
subscription-manager repos --disable=<repoid>
5. Configure the failing repository to be skipped, if it is unavailable.
Note that yum will try to contact the repo. when it runs most commands,
so will have to try and fail each time (and thus. yum will be be much
slower). If it is a very temporary problem though, this is often a nice
compromise:
yum-config-manager --save --setopt=<repoid>.skip_if_unavailable=true
Cannot find a valid baseurl for repo: base/7/x86_64
Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=7&arch=x86_64&repo=os&i... error was
14: curl#6 - "Could not resolve host: mirrorlist.centos.org; 未知的错误"
已加载插件:fastestmirror
Loading mirror speeds from cached hostfile
One of the configured repositories failed (未知),
and yum doesn't have enough cached data to continue. At this point the only
safe thing yum can do is fail. There are a few ways to work "fix" this:
1. Contact the upstream for the repository and get them to fix the problem.
2. Reconfigure the baseurl/etc. for the repository, to point to a working
upstream. This is most often useful if you are using a newer
distribution release than is supported by the repository (and the
packages for the previous distribution release still work).
3. Run the command with the repository temporarily disabled
yum --disablerepo=<repoid> ...
4. Disable the repository permanently, so yum won't use it by default. Yum
will then just ignore the repository until you permanently enable it
again or use --enablerepo for temporary usage:
yum-config-manager --disable <repoid>
or
subscription-manager repos --disable=<repoid>
5. Configure the failing repository to be skipped, if it is unavailable.
Note that yum will try to contact the repo. when it runs most commands,
so will have to try and fail each time (and thus. yum will be be much
slower). If it is a very temporary problem though, this is often a nice
compromise:
yum-config-manager --save --setopt=<repoid>.skip_if_unavailable=true
Cannot find a valid baseurl for repo: base/7/x86_64
Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=7&arch=x86_64&repo=os&i... error was
14: curl#6 - "Could not resolve host: mirrorlist.centos.org; 未知的错误"
systemctl: /usr/bin/systemctl /usr/share/man/man1/systemctl.1.gz
chronyc: /usr/bin/chronyc /usr/share/man/man1/chronyc.1.gz
506 Cannot talk to daemon
Start time: 2024年 09月 22日 星期日 18:49:13 CST
groupadd:“www”组已存在
useradd:用户“www”已存在
--2024-09-22 18:49:13-- https://dl.amh.sh/file/AMH/7.1/amh-conf-7.1.tar.gz
正在解析主机 dl.amh.sh (dl.amh.sh)... 120.79.83.73, 2408:4003:1000:9aff:3c8f:27e6:888:b6bb
正在连接 dl.amh.sh (dl.amh.sh)|120.79.83.73|:443... 已连接。
已发出 HTTP 请求,正在等待回应... 200 OK
长度:5112 (5.0K) [application/octet-stream]
正在保存至: “amh-conf-7.1.tar.gz”
0K .... 100% 1.19G=0s
2024-09-22 18:49:13 (1.19 GB/s) - 已保存 “amh-conf-7.1.tar.gz” [5112/5112])
amh-conf-7.1/
amh-conf-7.1/conf/
amh-conf-7.1/conf/amh-base
amh-conf-7.1/conf/amh.c
amh.sh:行182: gcc: 未找到命令
chmod: 无法访问"/bin/amh": 没有那个文件或目录
amh.sh:行199: amh: 未找到命令
amh.sh:行200: amh: 未找到命令
amh.sh:行201: amh: 未找到命令
amh.sh:行202: amh: 未找到命令
amh.sh:行203: amh: 未找到命令
[Error] libiconv-1.14 download failed.
[Error] mysql-5.6 download failed.
[Error] nginx-1.20 download failed.
[Error] php-7.4 download failed.
[Error] amh-7.1 download failed.
抱歉。安装 AMH 失败了,
centos7官方已经停止维护,
一定要用centos7,可以试换阿里云的源,或其它还在线的系统软件源。
新安装amh建议是用新版本的系统。