target filesystem doesn't have /sbin/init

Asked by pete smout

hi,
been running karmic (9.10) since nov 2009 with no problems ran updates today rebooted and now i get: target filesystem doesn't have /sbin/init! and my system does not boot!

please help I am not a complete newbie but have very limited command line experience so please take it easy on me!

currently sending this via livecd as ubuntu 9.10 is my only operating system, and if possible would like to avoid a complete re-installation (and lose all my files!)

Regards

Pete

target filesystem doesn't have /sbin/init

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
pete smout
Solved:
Last query:
Last reply:
Revision history for this message
pete smout (petersmout03) said :
#1

just looked into sbin and there is init if i open the properties by right clicking it says it is a 'shared library (application/x-sharedlib)'. also there is a initctl which properties says is a 'shared library (application/x-sharedlib)'.

so unless it's corrupted then it is there!!

if it is corrupted the how do I go about creating another? can i copy from livecd?

I am now completely stuck, but at least i know i can get at my file if a complete reinstall is needed!!

thanks again

Pete

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#2

I don't have /init/sbin either:

andy@fileserver:/sbin$ ls s*
sfdisk shadowconfig shutdown slattach ss start startpar start-stop-daemon status stop sulogin swapoff swapon switch_root sysctl

at what point do you get the message. Is it before or after grub?

Revision history for this message
pete smout (petersmout03) said :
#3

hi,

just after the grub menu (choice of kernels) it hangs for approx 30sec then gives the message

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#4

http://ubuntuforums.org/showthread.php?t=295508

You need a chroot to install ubuntu-minimal on the system

Revision history for this message
pete smout (petersmout03) said :
#5

hi,

mounted my filesystem to media tried the chroot command as shown in the link provided and i get:

ubuntu@ubuntu:~$ sudo chroot /media/root
chroot: cannot change root directory to /media/root: No such file or directory
ubuntu@ubuntu:~$

from what i can tell /media is where it is mounted, and i have the root password to my ubuntu install, please advise where i am going wrong (never been any good at $paths!)

sorry for my stupidity

Pete

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#6

You need to make the mount point:

sudo mkdir /media/root

You can then mount the partition to it. If you are using the live CD the mount will be the UUID of the partition in /media. You can use that.

Revision history for this message
pete smout (petersmout03) said :
#7

hi,

probably me being stupid again but when i try and mount using the very long uuid string i get this message:

ubuntu@ubuntu:~$ sudo mount 1c167265-2508-4ab1-bf71-91c7a7a9e492 media/root
mount: mount point media/root does not exist
ubuntu@ubuntu:~$ sudo mount 1c167265-2508-4ab1-bf71-91c7a7a9e492 /media/root
mount: special device 1c167265-2508-4ab1-bf71-91c7a7a9e492 does not exist
ubuntu@ubuntu:~$

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#8

ok click places then the partition containing the system

It will open nautilus automatically at /media/1c167265-2508-4ab1-bf71-91c7a7a9e492

You can now open a terminal and run:

sudo chroot /media/1c167265-2508-4ab1-bf71-91c7a7a9e492

Revision history for this message
pete smout (petersmout03) said :
#9

thanks very much all appears good again!!