LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 04-19-2011, 01:37 PM   #1
persson121
LQ Newbie
 
Registered: Apr 2011
Posts: 11

Rep: Reputation: 0
Kernel Panic - Not syncing: No init found. Try passing init= option to kernel.


Hello. Im am building a Linux distro. It will be very tiny and fast.

I only have a minimal linuxkernel (bzImage) who is 1,2 mb big. And then I have Busybox who is 174,6 kb big.

The commands in busybox is: cd, ls, mkdir, rmdir, wget, httpd, clear, rm, poweroff, halt, reboot, fdisk, mount, umount, free, and cp.


When I compiled the kernel i use initramfs/initrd function and point it to a folder where initrd/initramfs source is.

The kernel works OK with others initramfs/initrd files. But not with my own.

Quote:
Waring: unable to open initial console.
Freeing unused kernel memory: 412k freed
Failed to execute /init
Kernel Panic - Not syncing: No init found. Try passing init= option to kernel.

Here is how the end of the kernelcomplie look like.
Quote:
BUILD arch/x86/boot/bzImage
Root device is (8, 1)
Setup is 13132 bytes (padded to 13312 bytes).
System is 1232 kB
CRC 8ed74771
Kernel: arch/x86/boot/bzImage is ready (#4)
root@desktop-GA-7VAXFS:/home/desktop/Hämtningar/linux-2.6.38.3#
Here is my init file who is the initrd/initramfs source.

Quote:
#!/bin/busybox sh
mkdir -p /dev /proc /sys
mount -t devtmpfs devfs /dev
mkdir -p /dev/pts
mount -t devpts ptsfs /dev/pts
mount -t proc procfs /proc
mount -t sysfs sysfs /sys
exec /bin/busybox sh
/folder/to/initramfs/bin/busybox
The initramfs folder contains "bin" (folder) and "init" a file. No more.

What is the problem? I know the problem, but not to solve it. The problem is that the kernel cannot find/read init file. I have search, but no answers fitt this question.

Last edited by persson121; 04-19-2011 at 01:41 PM.
 
Old 04-19-2011, 02:08 PM   #2
lisle2011
Member
 
Registered: Mar 2011
Location: Surrey B.C. Canada (Metro Vancouver)
Distribution: Slackware 2.6.33.4-smp
Posts: 183
Blog Entries: 1

Rep: Reputation: 25
Kernel panic

you wrote "others init files work but not mine" please clarify
1. Others systems work with their init file
2. Others init files work with your system

Thanks
 
Old 04-20-2011, 05:07 AM   #3
persson121
LQ Newbie
 
Registered: Apr 2011
Posts: 11

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by lisle2011 View Post
you wrote "others init files work but not mine" please clarify
1. Others systems work with their init file
2. Others init files work with your system

Thanks
If I use MY kernel and TinyCore linux INIT FILE = works!
If I use MY kernel and the kernelfuntion initrd/initramfs and MY own init file = NOT working!
 
Old 04-20-2011, 03:57 PM   #4
persson121
LQ Newbie
 
Registered: Apr 2011
Posts: 11

Original Poster
Rep: Reputation: 0
Anyone who know why init file do not read?
 
Old 04-23-2011, 04:49 AM   #5
persson121
LQ Newbie
 
Registered: Apr 2011
Posts: 11

Original Poster
Rep: Reputation: 0
Btw, I have syslinux as a bootloader.
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Diskless: Kernel panic-not syncing: No init found. Try passing init= option to kernel Pier Gentoo 6 10-10-2011 06:17 AM
Kernel panic-not syncing:No init found. Try passing init=option to kernel cucolin@ Ubuntu 5 12-26-2008 06:44 AM
Kernel panic - not syncing: No init found. Try passing init= option to kernel. john_schimandle Linux - Newbie 4 10-09-2008 02:40 AM
Kernel panic - not syncing: No init found. Try passing init= option to kernel ranjithmrk Linux - Newbie 4 08-22-2008 02:33 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 12:32 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