Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Just installed gentoo don't have network (Solved)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
Featherfoot
l33t
l33t


Joined: 28 Dec 2002
Posts: 930
Location: Stuart, Florida

PostPosted: Sun Feb 04, 2018 1:12 am    Post subject: Just installed gentoo don't have network (Solved) Reply with quote

I just finished installing gentoo on my amd_64 system after a major crash. I have run gentoo on this system for several years.

I used the latest stage 3 install and a copy of my .config file from before the crash. I built the system starting with a recent minimal DVD.

It does not boot up with a working eth0. It claims there is no ethernet device. When I do an lspci -v, I it shows that the device is an RTL8169sb and the appropriate driver is r8169. This agrees with the Mint 18.3 linux system I am sending this from.

Since I am not able to mount my home directory either, getting a good copy of a dmesg is a problem. I did manage to get a copy of /var/log/rc.log which follows:
Code:

gentoo}bopper /etc/jc # cat rc.log

rc sysinit logging started at Sat Feb  3 16:55:09 2018


   OpenRC 0.34.11 is starting up Gentoo Linux (x86_64)

 * /proc is already mounted
 * Mounting /run ...
 * /run/openrc: creating directory
 * /run/lock: creating directory
 * /run/lock: correcting owner
 * Caching service dependencies ...
 [ ok ]
 * Remounting devtmpfs on /dev ...
 [ ok ]
 * Mounting /dev/mqueue ...
 [ ok ]
 * Mounting /dev/shm ...
 [ ok ]
 * Creating list of required static device nodes for the current kernel ...
 [ ok ]
 * Mounting security filesystem ...
 [ ok ]
 * Mounting fuse control filesystem ...
 [ ok ]
 * Mounting cgroup filesystem ...
 [ ok ]
 * Starting udev ...
 [ ok ]
 * Generating a rule to create a /dev/root symlink ...
 [ ok ]
 * Populating /dev with existing devices through uevents ...
 [ ok ]

rc sysinit logging stopped at Sat Feb  3 16:55:09 2018


rc boot logging started at Sat Feb  3 16:55:09 2018

 * Loading kernel modules ...
insmod /lib/modules/4.9.76-gentoo-r1/video/nvidia.ko NVreg_DeviceFileMode=432 NVreg_DeviceFileUID=0 NVreg_DeviceFileGID=27 NVreg_ModifyDeviceFiles=1
insmod /lib/modules/4.9.76-gentoo-r1/kernel/sound/pci/hda/snd-hda-intel.ko
insmod /lib/modules/4.9.76-gentoo-r1/kernel/drivers/media/tuners/xc5000.ko
 [ ok ]
 * Setting system clock using the hardware clock [Local Time] ...
 [ ok ]
 * Checking local filesystems  ...
/dev/sda2: clean, 537479/14639104 files, 4546905/58530710 blocks
/dev/sda1: clean, 14/76912 files, 29280/307200 blocks
/dev/sdc3 is in use.
e2fsck: Cannot continue, aborting.


/dev/sdb5 is in use.
e2fsck: Cannot continue, aborting.


/dev/sdb6 is in use.
e2fsck: Cannot continue, aborting.


 * Operational error
 [ !! ]
 * Remounting root filesystem read/write ...
 [ ok ]
 * Remounting filesystems ...
 [ ok ]
 * Updating /etc/mtab ...
 * Creating mtab symbolic link
 [ ok ]
 * Activating swap devices ...
swapon: /dev/sdc7: swapon failed: Device or resource busy
 [ ok ]
 * Mounting local filesystems ...
mount: /mint: /dev/sdb5 already mounted or mount point busy.
mount: /home: /dev/sdc3 already mounted or mount point busy.
mount: /misc: /dev/sdb6 already mounted or mount point busy.
mount: /windows: /dev/sdb2 already mounted or mount point busy.
 * Some local filesystem failed to mount
 [ !! ]
 * The binfmt-misc module needs to be configured in /etc/conf.d/modules or built in.
 * Mounting misc binary format filesystem ...
 [ ok ]
 * Loading custom binary format handlers ...
 [ ok ]
 * Configuring kernel parameters ...
 [ ok ]
 * Creating user login records ...
 [ ok ]
 * Wiping /tmp directory ...
 [ ok ]
 * Setting hostname to bopper  ...
 [ ok ]
 * Setting terminal encoding [UTF-8] ...
 [ ok ]
 * Setting keyboard mode [UTF-8] ...
 [ ok ]
 * Loading key mappings [us] ...
 [ ok ]
 * Bringing up network interface lo ...
 [ ok ]
 * Initializing random number generator ...
 [ ok ]

rc boot logging stopped at Sat Feb  3 21:55:10 2018


rc default logging started at Sat Feb  3 21:55:10 2018

 * Checking your configfile (/etc/syslog-ng/syslog-ng.conf) ...
 [ ok ]
 * Starting syslog-ng ...
 [ ok ]
 * Starting cronie ...
 [ ok ]
 * Starting dbus ...
 [ ok ]
 * Bringing up interface eth0
 *   Caching network module dependencies
need dbus
 *   ERROR: interface eth0 does not exist
 *   Ensure that you have loaded the correct kernel module for your hardware
 * ERROR: net.eth0 failed to start
 * ERROR: cannot start netmount as net.eth0 would not start
 * Starting sshd ...
 [ ok ]
 * Setting up sddm ...
 [ ok ]
 * Starting local ...
 [ ok ]

rc default logging stopped at Sat Feb  3 21:55:11 2018

{gentoo}bopper /etc/jc #

Here is my /etc/init.d/net file:
Code:

{gentoo}bopper /etc/conf.d # cat net
# set the dns_domain_lo variable to the selected domain name
dns_domain_lo="Cox"

config_eth0="dhcp"
#config_eth0=10.0.0.33 netmask 255.255.255.0 brd=10.0.0.255




Here is /etc/conf.d/netmount
Code:

{gentoo}bopper /etc/conf.d # cat netmount
# You will need to set the dependencies in the netmount script to match
# the network configuration tools you are using. This should be done in
# this file by following the examples below, and not by changing the
# service script itself.
#
# Each of these examples is meant to be used separately. So, for
# example, do not set rc_need to something like "net.eth0 dhcpcd".
#
# If you are using newnet and configuring your interfaces with static
# addresses with the network script, you  should use this setting.
#
#rc_need="network"
rc_need="network"
#
# If you are using oldnet, you must list the specific net.* services you
# need.
#
# This example assumes all of your netmounts can be reached on
# eth0.
#
#rc_need="net.eth0"
rc_need="net.eth0"

#
# This example assumes some of your netmounts are on eth1 and some
# are on eth2.
#
#rc_need="net.eth1 net.eth2"
#
# If you are using a dynamic network management tool like
# NetworkManager, dhcpcd in standalone mode, wicd, badvpn-ncd, etc, to
# manage the network interfaces with the routes to your netmounts, you
# should list that tool.
#
#rc_need="NetworkManager"
rc_need="NetworkManager"
#rc_need="dhcpcd"
rc_need="dhcpcd"
#rc_need="wicd"
#
# The default setting is designed to be backward compatible with our
# current setup, but you are highly discouraged from using this. In
# other words, please change it to be more suited to your system.
#
rc_need="net"
#
# Mark certain mount points as critical.
# This contains aspace separated list of mount points which should be
# considered critical. If one of these mount points cannot be mounted,
# netmount will fail.
# By default, this is empty.
#critical_mounts="/home /var"
{gentoo}bopper /etc/conf.d #

This is net-online:
[
Code:

{gentoo}bopper /etc/conf.d # cat net-online
# The interfaces setting controls which interfaces the net-online
# service considers in deciding whether the network is active. The
# default is all interfaces that support ethernet.
#interfaces=""

# This setting controls whether a ping test is included in the test for
# network connectivity after all interfaces are active.
#include_ping_test=no

# This setting is the host to attempt to ping if the above is yes.
# The default is google.com.
#ping_test_host=some.host.name

# The timeout setting controls how long the net-online service waits
# for the network to be configured.
# The default is 120 seconds.
# if this is set to 0, the wait is infinite.
#timeout=120
{gentoo}bopper /etc/conf.d #


Last edited by Featherfoot on Sun Feb 04, 2018 4:54 am; edited 1 time in total
Back to top
View user's profile Send private message
The Doctor
Moderator
Moderator


Joined: 27 Jul 2010
Posts: 2468

PostPosted: Sun Feb 04, 2018 1:29 am    Post subject: Reply with quote

Have you looked at ifconfig? It almost certainly changed names on you.
_________________
First things first, but not necessarily in that order.

Apologies if I take a while to respond. I'm currently working on the dematerialization circuit for my blue box.
Back to top
View user's profile Send private message
Featherfoot
l33t
l33t


Joined: 28 Dec 2002
Posts: 930
Location: Stuart, Florida

PostPosted: Sun Feb 04, 2018 2:17 am    Post subject: Reply with quote

Ifcinfig efh0 shows that eth0 is not defined. Ifconfiv shows that only lo is defined.
Back to top
View user's profile Send private message
The Doctor
Moderator
Moderator


Joined: 27 Jul 2010
Posts: 2468

PostPosted: Sun Feb 04, 2018 2:24 am    Post subject: Reply with quote

ifconfig -a? You want to see all interfaces, including the inactive ones. I expect you will find something absolutely insane.

Or you can touch /etc/udev/rules.d/70-persistent-net.rules, it may get rid of the annoying udev name changes
_________________
First things first, but not necessarily in that order.

Apologies if I take a while to respond. I'm currently working on the dematerialization circuit for my blue box.
Back to top
View user's profile Send private message
Featherfoot
l33t
l33t


Joined: 28 Dec 2002
Posts: 930
Location: Stuart, Florida

PostPosted: Sun Feb 04, 2018 3:07 am    Post subject: Reply with quote

You were right.

Here is the output of ifconfig -a:
Code:

bopper jc # cat ifconfiga.txt
enp4s7: flags=4098<BROADCAST,MULTICAST>  mtu 1500
        ether d8:5d:4c:f2:a8:5e  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1  (Local Loopback)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

bopper jc #


You can probably guess that the file you were discussing; /etc/udev/rules.d/70-persistent-net.rules does not exists.

I just emerge udev again and the file is still not there. How do I get it back?
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 2577
Location: Illinois, USA

PostPosted: Sun Feb 04, 2018 3:13 am    Post subject: Reply with quote

Probably no need to re-emerge. Touch the file or add net.ifnames=0 to your grub boot.
Example from grub-legacy:
Code:

title=Gentoo Longterm (4.9.78-gentoo)
root (hd0,0)
kernel /boot/vmlinuz-4.9.78-gentoo  root=/dev/sda3 vga=0x365 net.ifnames=0
The equivalent in grub2 is an excercise for the student.
Back to top
View user's profile Send private message
Featherfoot
l33t
l33t


Joined: 28 Dec 2002
Posts: 930
Location: Stuart, Florida

PostPosted: Sun Feb 04, 2018 3:33 am    Post subject: Reply with quote

Grub2 is coming from a Mint system. What do I need to do?
Back to top
View user's profile Send private message
The Doctor
Moderator
Moderator


Joined: 27 Jul 2010
Posts: 2468

PostPosted: Sun Feb 04, 2018 4:14 am    Post subject: Reply with quote

Run the command touch /etc/udev/rules.d/70-persistent-net.rules to create the file. No need to try something so messy.
_________________
First things first, but not necessarily in that order.

Apologies if I take a while to respond. I'm currently working on the dematerialization circuit for my blue box.
Back to top
View user's profile Send private message
Featherfoot
l33t
l33t


Joined: 28 Dec 2002
Posts: 930
Location: Stuart, Florida

PostPosted: Sun Feb 04, 2018 4:54 am    Post subject: Reply with quote

I added the net.ifnames=0 statement to the custom command booting up gentoo, did an update-grub and rebooted.It worked!

Thank you for your help. I really appreciate it.
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 2577
Location: Illinois, USA

PostPosted: Sun Feb 04, 2018 3:39 pm    Post subject: Reply with quote

The udev way works IF you use udev. The command line way works always UNTIL the kernel developers decide not to support it anymore.

Best to remember that there are two ways. Actually, the third way is to go with the flow and accept the uneuphonious names and create new net.empanada links and change all the lines in /etc/conf.d/net.
Back to top
View user's profile Send private message
Featherfoot
l33t
l33t


Joined: 28 Dec 2002
Posts: 930
Location: Stuart, Florida

PostPosted: Sun Feb 04, 2018 4:24 pm    Post subject: Reply with quote

It would seem that the developer should follow linux naming conventions, especially if there is some reasoning behind the name. , I suppose he should be allowed some latitude., too.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum