Debian 9 network conf

Kernels & Hardware, configuring network, installing services

Debian 9 network conf

Postby remus » 2017-12-06 00:28

Hi guys.

I"m trying to learn how to use debian as a kiosk machine OS

Right now I'm stuck on network configuration.

* Environment
Virtualbox VM
8GB Hard drive
512mb ram

Debian Netinst installed
+ openssh
+ base system tools

At first boot I noticed I had no ifconfig, So I installed net-tools
Code: Select all
apt-get install net-tools

ifconfig didn't work for my user, only root...
So I installed sudo
Code: Select all
apt-get install sudo

added my user to sudo group
Code: Select all
sudo adduser username sudo


which revealed that my VM eth0 interface is actually enp0s3 ????
A little google research reveiled that the world has moved on and eth0 is no longer considered useful ????
I'm a little set in my ways so I tried guide here to change it back to eth0
http://www.itzgeek.com/how-tos/linux/debian/change-default-network-name-ens33-to-old-eth0-on-debian-9.html

To regain the ethX back, edit the grub file.
Code: Select all
$ sudo nano /etc/default/grub


Look for “GRUB_CMDLINE_LINUX” and add the following”net.ifnames=0 biosdevname=0“.
From:
Code: Select all
GRUB_CMDLINE_LINUX=""

To:
Code: Select all
GRUB_CMDLINE_LINUX="net.ifnames=0 biosdevname=0"


Generate a new grub file using the “grub-mkconfig” command.
Code: Select all
$ sudo grub-mkconfig -o /boot/grub/grub.cfg


Edited /etc/network/interfaces file to change enp0s3 to eth0 where required
Code: Select all
$ sudo nano /etc/network/interfaces


Using this as a guide to set ip settings
https://linuxconfig.org/how-to-setup-a-static-ip-address-on-debian-linux

And I set a static ip addres which is what I wanted all along

My /etc/network/interfaces now looks like this
Code: Select all
allow-hotplug eth0
iface eth0 inet static
address 10.1.1.213
netmask 255.255.255.0
gateway 10.1.1.1


I restarted my network
Code: Select all
sudo service networking restart


And I have no network now...

I've attached a screenshot of output of following commands
ip a
ifconfig

ping any address on my LAN or internet results in
connect: network is unreachable


suggestions about how to fix this would be very welcome
remus
 
Posts: 65
Joined: 2008-06-03 02:39

Re: Debian 9 network conf

Postby remus » 2017-12-06 00:30

here's the screen shot

https://ibb.co/edyKQG
remus
 
Posts: 65
Joined: 2008-06-03 02:39

Re: Debian 9 network conf

Postby remus » 2017-12-06 03:41

Update.

I've reinstalled Debian 9 to VirtualBox Virual Machine.

This time I made a backup of /etc/network/interfaces file.

I made no change to the system and accepted my network devices is enp0s3

No combination of stock standard static network settings work.

Restoring the orginal /etc/network/interfaces file and rebooting seems to get network up and working again.
Whats interesting is that I'm on a 10.1.1.* network, and I've been assigned an ip of 10.0.2.15

Looking forwards to getting some feedback on this.

Thanks.
remus
 
Posts: 65
Joined: 2008-06-03 02:39

Re: Debian 9 network conf

Postby remus » 2017-12-06 04:08

My bad, I had my VM set to NAT, should of been set to bridged mode.
remus
 
Posts: 65
Joined: 2008-06-03 02:39


Return to System configuration

Who is online

Users browsing this forum: No registered users and 3 guests

fashionable