# (SOLVED) ERROR: interface eth0 failed to start

## altoids762

I recently installed Gentoo on my laptop, and googled this error after not being able to connect to the internet.

The fix was to run this command;

```
 touch /etc/udev/rules.d/80-net-name-slot.rules 
```

However it returns with this error;

```
 touch: cannot touch '/etc/udev/rules.d/80-net-name-slot.rules' : Read-only file system 
```

I'm a little stuck here.Last edited by altoids762 on Tue Jul 27, 2021 8:26 pm; edited 1 time in total

----------

## mike155

I really doubt that the touch-command will fix the network problem.

Something else is wrong.

The "Read-only file system" message might point to the real problem. During the first boot phase, the root filesystem is mounted in read-only mode. After the first boot phase, the root filesystem gets remounted in read-write mode.

The "Read-only file system" error message probably means that the remount to read-write mode didn't work. You should fix this problem - and if you fix this problem, the connection problem to the internet will probably also be solved.

Check for any error messages on the screen or in the output of "dmesg". You may also want to double-check your /etc/fstab.

----------

## altoids762

 *mike155 wrote:*   

> I really doubt that the touch-command will fix the network problem.
> 
> Something else is wrong.
> 
> The "Read-only file system" message might point to the real problem. During the first boot phase, the root filesystem is mounted in read-only mode. After the first boot phase, the root filesystem gets remounted in read-write mode.
> ...

 

My /etc/fstab looks like this:

```

/dev/sda1          /boot     ext2     noato,noatime 0 2

/dev/sda2          none      swap   sw                   0 0

/dev/sda3          /            ext     noauto,ro         0 0

```

My startup errors read as such:

```

*/etc is not writable, unable to create /etc/mtab

*failed to create needed directory /var/lib/misc

*ERROR: bootmisc failed to start

*ERROR interface eth0 does not exist

*ERROR cannot start netmount as net.eth0 would not start

```

And the only error I can read in my dmesg is;

```
 9.569752] udevd[1232]: Unknown key identifier 'zoom' 
```

Thanks for any help

----------

## jburns

In /etc/fstab fix the entry 

```
/dev/sda3          /            ext     noauto,ro         0 0
```

 ext is missing a number.

----------

## altoids762

 *jburns wrote:*   

> In /etc/fstab fix the entry 
> 
> ```
> /dev/sda3          /            ext     noauto,ro         0 0
> ```
> ...

 

It says I can't write to it.

----------

## freke

You might need to chroot into your system to fix your / -entry in fstab.

It shouldn't be neither noauto nor ro.

----------

## altoids762

 *freke wrote:*   

> You might need to chroot into your system to fix your / -entry in fstab.
> 
> It shouldn't be neither noauto nor ro.

 

How do I chroot back into my system?

----------

## pietinger

 *altoids762 wrote:*   

> How do I chroot back into my system?

 

The same way you did when starting your installation. From the AMD64 handbook:

```
- boot with amd64-minimal CD

# clear

# /etc/init.d/dhcpcd start

# mount /dev/sdXY /mnt/gentoo

# cd /mnt/gentoo

# mount -t proc /proc /mnt/gentoo/proc

# mount --rbind /sys /mnt/gentoo/sys

# mount --rbind /dev /mnt/gentoo/dev

# chroot /mnt/gentoo /bin/bash

# . /etc/profile

( # mount /dev/sdXZ /boot ) ( if you need also your boot-partition) 
```

----------

## altoids762

 *pietinger wrote:*   

>  *altoids762 wrote:*   How do I chroot back into my system? 
> 
> The same way you did when starting your installation. From the AMD64 handbook:
> 
> ```
> ...

 

Running 

```
/etc/init.d/dhcpcd start
```

 yields;

```
 * Starting DHCP Client DDaemon . . . 

* start-stop-daemon: /sbin/dhcpcd is already running

* Failed to start DHCP Client Daemon

* ERROR: dhcpcd failed to start 
```

----------

## pietinger

 *altoids762 wrote:*   

> 
> 
> ```
> * start-stop-daemon: /sbin/dhcpcd is already running
> ```
> ...

 

If it is already running you dont need to start it. If you only doing this chroot to edit your /etc/fstab you even dont need to be online.

----------

## Jaglover

 *altoids762 wrote:*   

>  *freke wrote:*   You might need to chroot into your system to fix your / -entry in fstab.
> 
> It shouldn't be neither noauto nor ro. 
> 
> How do I chroot back into my system?

 

It pays to address the problem instead of consequences. The problem is read-only root filesystem, the solution is remounting in rw mode.

```
mount -o remount,rw /
```

----------

## freke

 *Jaglover wrote:*   

>  *altoids762 wrote:*    *freke wrote:*   You might need to chroot into your system to fix your / -entry in fstab.
> 
> It shouldn't be neither noauto nor ro. 
> 
> How do I chroot back into my system? 
> ...

 

Wasn't even aware you could do that - but just testing on a live / - remounted fine with both ro and rw, so much easier  :Very Happy: 

----------

## altoids762

 *freke wrote:*   

>  *Jaglover wrote:*    *altoids762 wrote:*    *freke wrote:*   You might need to chroot into your system to fix your / -entry in fstab.
> 
> It shouldn't be neither noauto nor ro. 
> 
> How do I chroot back into my system? 
> ...

 

I was able to run the remount command and make it a writable filesystem, I fixed my fstab to look like:

```
/dev/sda1          /boot     ext2     noato,noatime 0 2

/dev/sda2          none      swap    sw                  0 0

/dev/sda3          /           ext2      /                     0 0
```

However after reboots it returns to a read only filesystem.

----------

## freke

What does dmesg | grep sda show?

What does mount show?

Also you should fix the entry for /dev/sda1 - it should probably be noauto and not noato.

EDIT:

Also the / after ext2 in

```
/dev/sda3          /           ext2      /                     0 0
```

doesn't belong there AFAIK - could try with a defaults or noatime instead...Last edited by freke on Tue Jul 27, 2021 7:55 pm; edited 1 time in total

----------

## Hu

Is your root filesystem really ext2?  That would be quite unusual on a modern system.

----------

## altoids762

 *freke wrote:*   

> What does dmesg | grep sda show?
> 
> What does mount show?
> 
> Also you should fix the entry for /dev/sda1 - it should probably be noauto and not noato.
> ...

 

dmesg | grep sda yeilds;

```

[     6.053589] sd 0:0:0:0 [sda] 25006980 512-byte logical blocks: (128 GB/119 GiB)

[     6.053714] sd 0:0:0:0 [sda] Write Protect is off

[     6.053720] sd 0:0:0:0 [sda] Mode Sense: 00 3a 00

[     6.053756] sd 0:0:0:0 [sda] Write cahce: enabled, read cache: enable. doesn't support DPO or FUA

[     6.098989]   sda: sda1 sda2 sda3

[     6.098989] sd 0:0:0:0: [sda] Attached SCSI disk

[     6.506099] EXT4-fs (sda3): mounted filesystem with ordered data mode. Opts: (null)

[     9.461680] EXT4-fs (sda3): Unrecognized mount option "/" or missing value

[     9.608744] Adding 419400k swap on /dev/sda2. Priority:-2 extents:1 across:4194300k SSFS

```

After attempting to run mount -o remount,rw / again, it yeilds;

```

mount: /: mount point not mounted or bad option.

```

And I can't edit my fstab now that I can't run that mount command again.

----------

## freke

Edited my previous post - I wrote the 2nd /, but meant the / after the ext2 (filesystem column)

Your entry should be something like

```
/dev/sda3               /                       ext2    noatime                                                 0 0
```

(if you're really using ext2 as Hu is asking) or

```
/dev/sda3               /                       ext2    defaults                                                 0 0
```

Last edited by freke on Tue Jul 27, 2021 8:04 pm; edited 2 times in total

----------

## freke

 *altoids762 wrote:*   

>  *freke wrote:*   What does dmesg | grep sda show?
> 
> What does mount show?
> 
> Also you should fix the entry for /dev/sda1 - it should probably be noauto and not noato.
> ...

 

Can you do

```
mount -o remount,rw /dev/sda3 /
```

?

----------

## altoids762

 *Hu wrote:*   

> Is your root filesystem really ext2?  That would be quite unusual on a modern system.

 

I'm not sure, I'm running a ThinkPad x201.

----------

## freke

 *altoids762 wrote:*   

>  *Hu wrote:*   Is your root filesystem really ext2?  That would be quite unusual on a modern system. 
> 
> I'm not sure, I'm running a ThinkPad x201.

 

You created the root-filesystem on /dev/sda3 earlier during install - with a mkfs.ext2/3/4 command I would imagine?

----------

## altoids762

 *freke wrote:*   

>  *altoids762 wrote:*    *freke wrote:*   What does dmesg | grep sda show?
> 
> What does mount show?
> 
> Also you should fix the entry for /dev/sda1 - it should probably be noauto and not noato.
> ...

 

That worked. Thank you!

However, I still get the net.eth0 error on startup, and i still cant ping.

----------

## freke

 *altoids762 wrote:*   

>  *freke wrote:*    *altoids762 wrote:*    *freke wrote:*   What does dmesg | grep sda show?
> 
> What does mount show?
> 
> Also you should fix the entry for /dev/sda1 - it should probably be noauto and not noato.
> ...

 

Good - now at least boot/startup is maybe working?

output of ifconfig -a?

How have you configured your network?

EDIT:

might need to

```
touch /etc/udev/rules.d/80-net-name-slot.rules
```

again - if you haven't done this on a rw-filesystem - to get the old (ethX) naming-scheme.

----------

## altoids762

 *freke wrote:*   

>  *altoids762 wrote:*    *freke wrote:*    *altoids762 wrote:*    *freke wrote:*   What does dmesg | grep sda show?
> 
> What does mount show?
> 
> Also you should fix the entry for /dev/sda1 - it should probably be noauto and not noato.
> ...

 

Running 

```
touch /etc/udev/rules.d/80-net-name-slot.rules
```

 fixed it, after a reboot my ethernet was working perfectly.

Thanks a million.

----------

## freke

Glad it worked out  :Smile: 

----------

