Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Boot: Not a valid runlevel <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
eusanpe
Tux's lil' helper
Tux's lil' helper


Joined: 06 Sep 2002
Posts: 107

PostPosted: Thu Mar 03, 2011 4:13 am    Post subject: Boot: Not a valid runlevel <SOLVED> Reply with quote

Hello All,

I made a backup of my system yesterday and messed around with installing the newest gnome from the gnome-overlay. Well I didn't like it and
before I found out about demerge, I decided to boot from my sysrescuecd iso on my /boot drive and restore my previous backup. I have done
this numerous times without issues but today I have one.

BTW...I am running with two disks configured as:

/dev/md1 /boot raid1
/dev/md2 swap raid1
/dev/md3 / raid1
/dev/md4 lvm raid0

After I restored it, when I boot up I get the following errors:

boot: not a valid runlevel. I get other errors regarding lvm stating.
mount: special device /dev/vg/usr does not exist
mount: special device /dev/vg/var does not exist

....and so on.

My root disk mounts as read-only and my lvm disks do not mount.

To get things up an running I have to do the following:
mount -o rw,remount /dev/md3
mount /dev/vg/usr /usr
mount /dev/vg/portage /usr/portage
mount /dev/vg/var /var
mount /dev/vg/home /home
/sbin/rc
/etc/init.d/xdm restart

Once I do these manually, I am back up and running. Once I reboot, I have to do this again.
Can anyone offer me any suggestions to fix this issue or anything other info that I can post
to help fix this issue?

Thanks,
Tony

Code:
% cat /etc/mtab
rootfs / rootfs rw 0 0
/dev/root / ext4 rw,noatime,data=writeback,barrier=0,errors=remount-ro,commit=0 0 0
proc /proc proc rw,relatime 0 0
rc-svcdir /libexec/rc/init.d tmpfs rw,nosuid,nodev,noexec,relatime,size=1024k,mode=755 0 0
sysfs /sys sysfs rw,nosuid,nodev,noexec,relatime 0 0
udev /dev tmpfs rw,nosuid,relatime,size=10240k,mode=755 0 0
devpts /dev/pts devpts rw,nosuid,noexec,relatime,gid=5,mode=620 0 0
shm /dev/shm tmpfs rw,nosuid,nodev,noexec,relatime 0 0
/dev/mapper/vg-usr /usr ext4 rw,noatime,data=writeback,barrier=0,errors=remount-ro,commit=0 0 0
/dev/mapper/vg-portage /usr/portage ext4 rw,noatime,data=writeback,barrier=0,errors=remount-ro,commit=0 0 0
/dev/mapper/vg-var /var ext4 rw,noatime,data=writeback,barrier=0,errors=remount-ro,commit=0 0 0
/dev/mapper/vg-opt /opt ext4 rw,noatime,data=writeback,barrier=0,errors=remount-ro,commit=0 0 0
/dev/mapper/vg-home /home ext4 rw,noatime,data=writeback,barrier=0,errors=remount-ro,commit=0 0 0
gvfs-fuse-daemon /home/tony/.gvfs fuse.gvfs-fuse-daemon rw,nosuid,nodev,user=tony 0 0


Code:
% cat /proc/mounts
rootfs / rootfs rw 0 0
/dev/root / ext4 rw,noatime,errors=remount-ro,barrier=0,data=writeback 0 0
proc /proc proc rw,relatime 0 0
rc-svcdir /libexec/rc/init.d tmpfs rw,nosuid,nodev,noexec,relatime,size=1024k,mode=755 0 0
sysfs /sys sysfs rw,nosuid,nodev,noexec,relatime 0 0
udev /dev tmpfs rw,nosuid,relatime,size=10240k,mode=755 0 0
devpts /dev/pts devpts rw,nosuid,noexec,relatime,gid=5,mode=620 0 0
shm /dev/shm tmpfs rw,nosuid,nodev,noexec,relatime 0 0
fusectl /sys/fs/fuse/connections fusectl rw,relatime 0 0
/dev/mapper/vg-usr /usr ext4 rw,noatime,errors=remount-ro,barrier=0,stripe=256,data=writeback 0 0
/dev/mapper/vg-portage /usr/portage ext4 rw,noatime,errors=remount-ro,barrier=0,stripe=256,data=writeback 0 0
/dev/mapper/vg-var /var ext4 rw,noatime,errors=remount-ro,barrier=0,stripe=256,data=writeback 0 0
/dev/mapper/vg-opt /opt ext4 rw,noatime,errors=remount-ro,barrier=0,stripe=256,data=writeback 0 0
/dev/mapper/vg-home /home ext4 rw,noatime,errors=remount-ro,barrier=0,stripe=256,data=writeback 0 0
gvfs-fuse-daemon /home/tony/.gvfs fuse.gvfs-fuse-daemon rw,nosuid,nodev,relatime,user_id=1000,group_id=1000 0 0


Last edited by eusanpe on Thu Mar 03, 2011 9:53 pm; edited 3 times in total
Back to top
View user's profile Send private message
tony-curtis
Tux's lil' helper
Tux's lil' helper


Joined: 20 May 2006
Posts: 111

PostPosted: Thu Mar 03, 2011 5:42 pm    Post subject: Reply with quote

Can you post the /etc/inittab? That might tell us what the runlevel message is about.
Back to top
View user's profile Send private message
eusanpe
Tux's lil' helper
Tux's lil' helper


Joined: 06 Sep 2002
Posts: 107

PostPosted: Thu Mar 03, 2011 9:25 pm    Post subject: Reply with quote

tony-curtis,

Thank you for replying. Here is /etc/inittab.

Code:
% cat /etc/inittab
#
# /etc/inittab:  This file describes how the INIT process should set up
#                the system in a certain run-level.
#
# Author:  Miquel van Smoorenburg, <miquels@cistron.nl>
# Modified by:  Patrick J. Volkerding, <volkerdi@ftp.cdrom.com>
# Modified by:  Daniel Robbins, <drobbins@gentoo.org>
# Modified by:  Martin Schlemmer, <azarah@gentoo.org>
# Modified by:  Mike Frysinger, <vapier@gentoo.org>
# Modified by:  Robin H. Johnson, <robbat2@gentoo.org>
#
# $Header: /var/cvsroot/gentoo-x86/sys-apps/sysvinit/files/inittab-2.86-r12,v 1.3 2009/11/11 21:51:28 vapier Exp $

# Default runlevel.
id:3:initdefault:

# System initialization, mount local filesystems, etc.
si::sysinit:/sbin/rc sysinit

# Further system initialization, brings up the boot runlevel.
rc::bootwait:/sbin/rc boot

l0:0:wait:/sbin/rc shutdown
l0s:0:wait:/sbin/halt -dhp
l1:1:wait:/sbin/rc single
l2:2:wait:/sbin/rc nonetwork
l3:3:wait:/sbin/rc default
l4:4:wait:/sbin/rc default
l5:5:wait:/sbin/rc default
l6:6:wait:/sbin/rc reboot
l6r:6:wait:/sbin/reboot -dk
#z6:6:respawn:/sbin/sulogin

# new-style single-user
su0:S:wait:/sbin/rc single
su1:S:wait:/sbin/sulogin

# TERMINALS
c1:12345:respawn:/sbin/agetty 38400 tty1 linux
c2:2345:respawn:/sbin/agetty 38400 tty2 linux
c3:2345:respawn:/sbin/agetty 38400 tty3 linux
c4:2345:respawn:/sbin/agetty 38400 tty4 linux
c5:2345:respawn:/sbin/agetty 38400 tty5 linux
c6:2345:respawn:/sbin/agetty 38400 tty6 linux

# SERIAL CONSOLES
#s0:12345:respawn:/sbin/agetty 9600 ttyS0 vt100
#s1:12345:respawn:/sbin/agetty 9600 ttyS1 vt100

# What to do at the "Three Finger Salute".
ca:12345:ctrlaltdel:/sbin/shutdown -r now

# Used by /etc/init.d/xdm to control DM startup.
# Read the comments in /etc/init.d/xdm for more
# info. Do NOT remove, as this will start nothing
# extra at boot if /etc/init.d/xdm is not added
# to the "default" runlevel.
x:a:once:/etc/X11/startDM.sh


EDIT...I think I found the issue. For some reason in my '/etc/runlevels' directory, there isn't a 'boot' directory. What the heck
happened. default, shutdown and sysinit directories are there, Well I will create a boot directory and add the necessary
services using rc-update and see what happens.

Tony

EDIT 2...That is what is was. I still can figure out for the life of me what happen to the boot directory in /etc/runlevels. Oh well...
I updated the services that belong to the boot runlevel and everything is working as expected.

Thanks,
Tony
Back to top
View user's profile Send private message
ubq
n00b
n00b


Joined: 11 Sep 2012
Posts: 1

PostPosted: Tue Sep 11, 2012 8:32 pm    Post subject: Reply with quote

This also happened to me, and if anyone is interested in one possible cause, if you backup with rsync and then restore using an exclude pattern, like so:

Code:
rsync -av --delete --exclude="boot/" /backup/ /restore/


,the boot runlevel folder will match promiscuously and fail to restore. With any luck, the expression was not also used during the initial backup and some time can be saved by restoring /etc/runlevels/boot/ from the original backup structure.

This thread was very helpful to me, so I thought I'd add two more cents for the next reader. Thanks all.
Back to top
View user's profile Send private message
Watcom
n00b
n00b


Joined: 12 Apr 2006
Posts: 20

PostPosted: Sun Sep 30, 2012 2:59 pm    Post subject: Reply with quote

Thanks ubq, you hit the nail right in the head. I did not use rsync, but tar. Also used excludes and the same thing happened.
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