Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I am a Linux newbie. Whne linux gets booted, it showing some messages, like Mounting root file system, Welcome to Redhat8.0, Press 'I' to interactive startup INIT: Entering runlevel 5 etc.
whether the above specified messages are in kernel code base or not. If not where it will be ?
Can anyone help me?
These are all part of initscripts and are completely separate from the linux kernel. The linux kernel comes on line relatively quickly and once fully up, the kernel passes control off to a process called init, which then runs the initscripts. The initscripts files are in /etc/rc.d. How familiar are you with the linux file system structure and with shell scripts?
I can view the message when linux boots up in /etc/rc.d folder.
can anyone clarify the below?
In linux we have two things.
1. Kernel image
2. RAM disk image.(has the modules for booting)
a)can anyone explain what are all the things the kernel image, and RAM disk image will have?
b)can i view the modules added up in RAM disk image?
I have seen in kernel upgradation, when we type #make menuconfig, a window will be opened. Some options may selected as[*] and some options selected as [M]. SO all[*] are together as Kernel image and all [M] are together as RAM disk image. am i right?
c)Can i put the two things as a whole kernel image?
Here is one of many articles on initrd (the RAM-disk image). The purpose is to help the process of booting up. Some distros do not use it.
I'm sure it would be technically **possible** to create one file with the kernel and the initrd image, but WHY??????? What swamp are you trying to drain?
The reason for making all stuff into one is,
I was trying to boot a external hard disk with Linux by copying the vmlinuz-version and initrd-version.img file (these were taken from my internal hard disk). I have copied the stage1 and stage2 files and fused the grub into hard disk by using grub command.(ie root and setup)
When i was trying to boot getting error as,
kernel panic: No init found. Try Passing init= option to kernel.
What i thought is the modules are not properly loaded. If keep the both the stuffs, i think i can solve my problem. I have tried by make install_modules command to load the modules into specfied path using export command.
Let's make a couple things clear.
Drivers marked with a star * in make menuconfig will be built into the kernel image;
Drivers marked with an M will be built as modules, that is, separate files, residing in /lib/modules/... and loaded on request by the modprobe command into the running kernel;
The initrd image is somewhat of a crutch, used in situations when some driver is needed very early in the booting process, before /lib/modules is accessible, but the driver is available as a module only. And not included into the kernel image. A typical example of that is the driver for the root filesystem. If you format your / partition, say, as reiserfs, and reiserfs support is modularized in your kernel (not included into the kernel image), then to mount / you need the module, but the module is on the root filesystem, which you don't have access to before it's mounted. To avoid this, you make an initrd, that includes the necessary modules to just get your system up and running. Initrd does not have to include all modules. And the make modules_install commnad has nothing to do with the initrd image.
Now, to your specific question. Could you show the content of your menu.lst and /etc/fstab files? The problem you describe might be caused by an incorrect root= option passed to the kernel.
Last edited by Uncle_Theodore; 02-07-2008 at 08:21 AM.
# grub.conf generated by anaconda
default=0
timeout=10
splashimage=(hd0,0)/boot/grub/splash.xpm.gz
title Red Hat Linux (2.4.18-14)
root (hd0,0)
kernel /boot/vmlinuz-2.4.18-14 ro root=LABEL=/
initrd /boot/initrd-2.4.18-14.img
I haven't copied the menu.lst to my external hard disk. I just fused grub by typing the following commands.
#root (hd1,0)
#setup(hd1)
When reboot my system, i will unplug my internal HDD and type the below,
I am new to linux. Started working in Linux environment.
Can i edit the shell scripts?
Actually, yes. All are plain text files. But you definitely don't want to until you thoroughly know all of the internals of the linux distribution that you are using. From what you are trying to do, it might work out better for you if you just did an install of a linux distribution on your external hard drive. If space is at a premium, there are linux distributions that are quite small. Damnsmalllinux comes to mind at only 50 MB.
Regarding upgrading, I have found that it is the computer hardware and specifically the motherboard that, for the most part, drives that. The older motherboards simply aren't available anymore and the older linux distributions can't install on the newer motherboards since they can't recognize the hardware. Therefore, when an older motherboard gives out, you're pretty much forced to upgrade. I can understand why you want to continue to use an older distribution. You're familiar with its features, like its layout and so forth. You don't want to have to keep reinventing the wheel every year or so by constantly switching distributions. But, there's a way to head that off also which is run the older distribution as a virtual machine under the newer distribution. The software that I have found works best for this is vmware. For example, I still use Mandrake 9.0 and I am getting ready to fold that entire computer into a virtual machine under the new FC8 computer that I just built.
Interesting... RH8 (stated in first post) does not use a menu.lst, it uses grub.conf. Which distro is this? (I think fedora 8 uses menu.lst as a link to grub.conf.)
Anyway, if the listed file is the menu.lst from the external drive, the lines:
Of course, this assumes one primary partition on the external drive and only two drives overall.
It is probably simpler just to boot from the install disk with the external drive plugged in, then select it to install to. When you hit grub installation, make sure you get the right disk.
Thanks Simon.
If i boot the system with external disk plugged in, then i do see the linux boots up from my internal disk. There i edited the grub.conf as below,
When the system starts boot, getting the same error as stated previously.
Currently /dev/hdb1 is mounted as /. Having /boot and /boot/grub folders into it.
/boot is having vmlinuz, inird, system.map files.
/boot/grub is having stage1 and stage2 files only.
Any other files has to be copied?
Currently everything i am doing with VMware.(ie) i have created two virtual machine. In one i have installed the redhat 8.0 and added the another virtual machine. By copying the kernel image files only i was trying to boot the another (ie empty) virtual machine.
When i type make modules_install in kernel upgradation, the modules which i selected during the make menuconfig (ie selected as [M] ) are loaded into the default path (/lib/modules). By using mkinitrd command i can create a initial ramdisk image.
For eg,
mkinitrd (image file name).img kernel-version
The kernel-version what i have specified must be in lib/modules. am i right?
If i removed any of the option already selected, that module will not be loaded?
Can anyone clears my doubt?
By copying the kernel image files only i was trying to boot the another (ie empty) virtual machine.
Oh... you are trying to store VM images on an external drive. Why not just do that?
How you do this depends on the VM software you use.
The instructions I gave you were on the assumption you wanted to boot the external drive as a native linux drive.
At this point you really need to rethink your approach. What are you trying to actually achieve by doing this? It sounds like you are trying something in a way that is far more complicated than it needs to be.
If you still want to stay with the VM approach, make sure you use the language of VMs to describe it.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.