![MySQL 集群无人值守安装](https://linux22.com/image/737467/MySQL%20%E9%9B%86%E7%BE%A4%E6%97%A0%E4%BA%BA%E5%80%BC%E5%AE%88%E5%AE%89%E8%A3%85.png)
我想在无需人工干预的情况下安装 MySQL 集群。我尝试按照官方指南上的步骤操作,但无法正常工作。
我目前所拥有的...
DEBIAN_FRONTEND=noninteractive
sudo apt-get install -y debconf-utils
# set mysql configs
echo "mysql-apt-config mysql-apt-config/select-server select mysql-cluster-7.6" | sudo debconf-set-selections
echo "mysql-apt-config mysql-apt-config/select-tools select Disabled" | sudo debconf-set-selections
echo "mysql-apt-config mysql-apt-config/select-preview select Disabled" | sudo debconf-set-selections
echo "mysql-apt-config mysql-apt-config/select-product select Ok" | sudo debconf-set-selections
echo "mysql-community-server mysql-community-server/root-pass password $SQL_ROOT_PASS" | sudo debconf-set-selections
echo "mysql-community-server mysql-community-server/re-root-pass password $SQL_ROOT_PASS" | sudo debconf-set-selections
# Add apt repository
wget https://dev.mysql.com/get/mysql-apt-config_0.8.13-1_all.deb
sudo dpkg -i mysql-apt-config_0.8.13-1_all.deb
使用debconf-set-selections
我可以正确设置选择。但是,执行时sudo dpkg -i mysql-apt-config_0.8.13-1_all.deb
,我仍然会看到安装屏幕提示我选择软件包。我遗漏了什么吗?