Macのubuntu 16 on vagrantをupgradeして18にする。
下記askubuntu.comの"Debian way"の通りに修正して、16→18にupgrade出来た。
askubuntu.com
続いてubuntu 18→20へアップグレードする。
結構時間がかかった。1~2時間位。
とりあえず、Macのブラウザからlocal vagrant ubuntu apacheにアクセスできない。
sudo systemctl enable systemd-networkd
を実行するとnetplanの設定ファイルが生成されたっぽい。
これでアクセス出来るようになった気がするが、色々弄ってたので定かではない。
Vagrantfile で vb.gui = true
Vagrantfile で vb.gui = true を有効にしておくとエラーとか出てると気付けるので便利。vagrant upした時にsshで止まってるときとか、rebootした時に起動が終わったかどうか気付ける。
56 config.vm.provider "virtualbox" do |vb| 57 # Display the VirtualBox GUI when booting the machine 58 vb.gui = true 59 60 # Customize the amount of memory on the VM: 61 vb.memory = "1024" 62 end
MySQL関連でエラーが出てるっぽいのでネットワークより先にMySQLを見るが...
masked?初めて見る...。
vagrant@localhost:~$ sudo mysql_secure_installation Securing the MySQL server deployment. Enter password for user root: Error: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) vagrant@localhost:~$ sudo service mysql start Failed to start mysql.service: Unit mysql.service is masked. vagrant@localhost:~$ sudo systemctl status mysql ● mysql.service Loaded: masked (Reason: Unit mysql.service is masked.) Active: inactive (dead)