Closed hussam-qasem closed 1 year ago
I tried adding NetworkManager-initscripts-updown
to the base box, but that didn't solve the problem (just realized interface name appears empty?):
==> default: Configuring and enabling network interfaces...
The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!
/sbin/ifdown ''
mv -f '/tmp/vagrant-network-entry--1661511789-0' '/etc/sysconfig/network-scripts/ifcfg-'
(test -f /etc/init.d/NetworkManager && /etc/init.d/NetworkManager restart) || ((systemctl | grep NetworkManager.service) && systemctl restart NetworkManager)
/sbin/ifup ''
Stdout from the command:
NetworkManager.service loaded active running Network Manager
Stderr from the command:
Usage: ifdown <device name>
Usage: ifup <device name>
Apologies for the delay...
I believe the issue comes from the fact that OL9 is purely Network Manager based and the /etc/sysconfig/network-scripts
directory is empty...
Worth noticing that there is no interface name in your error messages (e.g. ifcfg-
should be ifcfg-eth1
or something similar).
Another issue might be the NIC Type as the image only contains the virtio drivers -- You could try adding nic_type: "virtio"
to the config.vm.network
stanza.
I'll look a this more in detail shortly.
Thank you @AmedeeBulle. nic_type: "virtio"
did the trick.
Vagrant.configure("2") do |config|
config.vm.box = "oraclelinux/9"
config.vm.box_url = "https://oracle.github.io/vagrant-projects/boxes/oraclelinux/9.json"
config.vm.network "private_network", ip: "192.168.56.4", nic_type: "virtio"
end
Great! thank you for confirming.
Dear Philippe @AmedeeBulle,
I am unable to set a
private_network
/Static IP
with the Oracle Linux 9 boxes:Using the
Vagrantfile
:When running
vagrant up
, I get the error:I am not sure if
NetworkManager-initscripts-updown
needs to be part of the OL9 box. (It's not part of the OL8 box, and OL8 works fine)