Hi Lars -
Thank you for your replies. While it helped, in setting a selection a moving on to completion - it did not solve the issues, especially in installing MySQL 8.
I am running it on Vagrant 2.1 (latest) setup on Oracle VirtualBox 5.2 (latest), on Ubuntu server 18.04.
...
Issues I face are:
- Still installs MySQL 5.7; apt-cache shows set to 5.7.
- I get a 'break' in screen when the selection is run by running deb file.
Thank you again for your help.
...
Details: Script and Output as follows.
...
SCRIPT:
sudo apt-get update && apt-get upgrade -y;
sudo apt-get install -y debconf-utils zsh htop libaio1;
wget --user-agent="Mozilla" -O mysql-apt-config_0.8.10-1_all.deb
https://dev.mysql.com/get/mysql-apt-config_0.8.10-1_all.deb;
export DEBIAN_FRONTEND="noninteractive";
echo mysql-apt-config mysql-apt-config/select-server select mysql-8.0 | sudo debconf-set-selections;
sudo dpkg -i mysql-apt-config_0.8.10-1_all.deb;
-- Tried swapping above two lines and also get break in screen when deb file runs as shown below.
sudo apt-get update && apt-get upgrade -y;
ufw enable; ufw allow 22; ufw allow 3306;
sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password password mysql';
sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password_again password mysql';
sudo apt-get install -y mysql-server;
...
OUTPUT (taken out initial name of server in beginning of line):
Selecting previously unselected package mysql-apt-config.
(Reading database ... 60994 files and directories currently installed.)
Preparing to unpack mysql-apt-config_0.8.10-1_all.deb ...
Unpacking mysql-apt-config (0.8.10-1) ...
Setting up mysql-apt-config (0.8.10-1) ...
-- Get a break in screen and output shifts to top of screen, freezing lower half of terminal.
Package configuration┌─────────────────────┤ Configuring mysql-apt-config ├──────────────────────┐│ MySQL APT Repo features MySQL Server along with a variety of MySQL││ components. You may select the appropriate product to choose the version ││ that you wish to receive.││││ Once you are satisfied with the configuration then select last option││ 'Ok' to save the configuration, then run 'apt-get update' to load││ package list. Advanced users can always change the configurations later, ││ depending on their own needs.││││ Which MySQL product do you wish to configure?││││MySQL Server & Cluster (Currently selected: mysql-8.0)││MySQL Tools & Connectors (Currently selected: Enabled)││MySQL Preview Packages (Currently selected: Disabled)││Ok││││││<Ok>│││└───────────────────────────────────────────────────────────────────────────┘
Failed to open terminal.debconf: whiptail output the above errors, giving up!
dpkg: error processing package mysql-apt-config (--install):
installed mysql-apt-config package post-installation script subprocess returned error exit status 255
Errors were encountered while processing:sh-common.
mysql-apt-configck .../zsh-common_5.4.2-3ubuntu3_all.deb ...
Hit:1
http://security.ubuntu.com/ubuntu bionic-security InRelease
Hit:2
http://archive.ubuntu.com/ubuntu bionic InRelease
Hit:3
http://archive.ubuntu.com/ubuntu bionic-updates InRelease
Hit:4
http://archive.ubuntu.com/ubuntu bionic-backports InRelease
Reading package lists... (1.5.66) ...
Reading package lists...libc-bin (2.27-3ubuntu1) ...
Building dependency tree....3.110-5) ...
Reading state information...
Calculating upgrade...
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up mysql-apt-config (0.8.10-1) ...
Warning: apt-key should not be used in scripts (called from postinst maintainerscript of the package mysql-apt-config)
OK
W
:
APT had planned for dpkg to do more than it reported back (0 vs 4).
Affected packages: mysql-apt-config:amd64
Reading package lists...
-- Continues on to install MySQL 5.7.22
...
apt-cache policy mysql-server shows:
mysql-server:
Installed: 5.7.22-0ubuntu18.04.1
Candidate: 5.7.22-0ubuntu18.04.1
Version table:
*** 5.7.22-0ubuntu18.04.1 500
500
http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 Packages
500
http://security.ubuntu.com/ubuntu bionic-security/main amd64 Packages
100 /var/lib/dpkg/status
5.7.21-1ubuntu1 500
500
http://archive.ubuntu.com/ubuntu bionic/main amd64 Packages