LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 02-22-2012, 12:30 AM   #1
deep27ak
Senior Member
 
Registered: Aug 2011
Location: Bangalore, India
Distribution: RHEL 7.x, SLES 11 SP2/3/4
Posts: 1,195
Blog Entries: 4

Rep: Reputation: 221Reputation: 221Reputation: 221
exec of /sbin/init failed : kernel panic not syncing


Hello All

In one of my server with OEL 5.x(32-bit) I am facing this issue where my OS is not able to boot and consistently throws me this error.

Code:
exec of /sbin/init failed: No such file or directory
kernel panic, Not syncing :Attempting to kill init!
I have checked number of blogs on google in an hope to get answer but unable to resolve this issue.

I booted my OS in rescue mode where it shows the environment variable is set to /mnt/sysimage

Code:
#chroot /mnt/sysimage
cannot execute /bin/sh: no such file or directory
but when I manually checked for these files it seems to be present
Code:
#ls /bin/sh
/bin/sh
#ls /bin/bash
/bin/bash
when I checked the location of init it shows
Code:
#which init
/usr/bin/init
instead of sbin/init

Can anyone please tell me what am I suppose to do at this stage?
I don't want to re-install this machine

Is it possible to change the path of init from /usr/bin/init to /sbin/init
as this file is also present

Code:
#ls /sbin/init
/sbin/init
I tried to add PATH variable in .bash_profile but still not working

Code:
#vi .bash_profile
export PATH=$PATH:$HOME/sbin/init
I think this is not the correct syntax
How can I change the path location of init from /usr/bin/init to /sbin/init?

Last edited by deep27ak; 02-22-2012 at 12:39 AM.
 
Old 02-22-2012, 06:26 AM   #2
sundialsvcs
LQ Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 10,659
Blog Entries: 4

Rep: Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941
Nothing to do with paths and so-forth actually apply here: the kernel has been loaded, it has mounted or tried to mount what it considers to be "the root file system," and, having done that, it cannot find init and therefore it All Falls Down.

Most likely, the boot-time parameter (e.g. in the Grub configuration file) that specifies where the root filesystem is located, is omitted or incorrect.

You have already established that the files are there; therefore, the problem must be that it cannot find them.

Footnote: As you probably know, the part "not syncing" simply means that a filesystem write operation was not underway at the time of failure. Of course.
 
1 members found this post helpful.
Old 02-22-2012, 06:40 AM   #3
deep27ak
Senior Member
 
Registered: Aug 2011
Location: Bangalore, India
Distribution: RHEL 7.x, SLES 11 SP2/3/4
Posts: 1,195

Original Poster
Blog Entries: 4

Rep: Reputation: 221Reputation: 221Reputation: 221
Thanks for the reply

Yes that is true what you said because I successful changed the location of init to /sbin/init and added the path in bash_profile as well but still I got the same error. I searched a lot to get a solution but couldn't get one because the most initial step which I was trying was not working i.e chroot

every time I tried to do chroot I got the same error

Code:
/bin/sh no such file or directory
So how do I fix this any suggestions?(exec of /sbin/init failed: No such file or directory)

Last edited by deep27ak; 02-22-2012 at 06:46 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
exec of init (/sbin/init) failed!!! Permission dened kernel-panic - not syncing! charlztin88 Linux - Newbie 1 03-15-2011 03:17 PM
/sbin/init: Kernel panic - not syncing: Attempted to kill init! jalejo08 Linux - Kernel 7 07-02-2009 01:16 PM
Kernel Panic - exec of init failed - HELP tlombardi Linux - General 1 04-13-2009 11:32 AM
exec of init (/sbin/init) failed!!! kernel panic KiraII Linux - Kernel 1 07-13-2007 09:07 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 08:38 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration