Skip to content

Instantly share code, notes, and snippets.

@Bouhnosaure
Last active November 6, 2015 12:53
Show Gist options
  • Save Bouhnosaure/01ebe7e1466c4c2ff670 to your computer and use it in GitHub Desktop.
Save Bouhnosaure/01ebe7e1466c4c2ff670 to your computer and use it in GitHub Desktop.
For each new VM
create virtual mac and add it to physical properties in network-device
under E100
then add this lines to /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
source /etc/network/interfaces.d/*
# The loopback network interface
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet static
address #ip du FO#
netmask 255.255.255.255
broadcast #ip du FO#
post-up route add #ip passerelle#.254 dev eth0
post-up route add default gw #ip passerelle#.254
pre-down route del #ip passerelle#.254 dev eth0
pre-down route del default gw #ip passerelle#.254
dns-nameservers 213.186.33.99 8.8.8.8
dns-search ovh.net
and if the dns cant resolve add to /etc/resolv.conf
nameserver 8.8.8.8
nameserver 8.8.4.4
and
service networking restart
ping google.com
(add also openssh server if not include by default)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment