LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 06-13-2008, 12:48 AM   #31
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,276

Rep: Reputation: 686Reputation: 686Reputation: 686Reputation: 686Reputation: 686Reputation: 686

As a side note, if you want to get really technical, you don't even need to rebuild the modules as far as I know, since you're only changing one option which doesn't affect any modules (as far as I know --but I could be wrong). You could probably get away with a simple
Code:
# cp /usr/src/linux-2.6.24.5 /usr/src/linux-2.6.24.5-custom
# cd /usr/src/linux-2.6.24.5-custom
# make menuconfig
Change the relevant options in menuconfig
Code:
# make bzImage
# cp arch/i386/boot/bzImage /boot/vmlinuz-2.6.24.5-custom
# cp System.map /boot/System.map-2.6.24.5-custom
# cp .config /boot/config-2.6.24.5-custom
# ln -sf /boot/System.map-2.6.24.5-custom /boot/System.map
# vi /etc/lilo.conf
etc. etc.

However, if you want to be sure, you should just build the whole thing, as explained previously.
Quote:
Originally Posted by shadowsnipes
You only need to patch your sources if using a vanilla kernel, and you only need to clean them if you already mucked around with them.
Very true -- I guess I just like working from a vanilla setup to avoid conflicts when `make`ing something that has residual files lying around from the original `make`. However, that shouldn't be a problem here, so you likely can skip the `make mrproper` step and the patching step. As a side note, my original patching lines were stupid anyway -- it can be accomplished better with `zcat linux-2.6.24.5.dnotify.diff.gz | patch -p0`. Simpler and using less space. The linux-2.6.24.5.dnotify.diff.gz file is also already present in /usr/src/linux-2.6.24.5, so it would already be present in /usr/src/linux-2.6.24.5-custom. That section would be better represented by the following, assuming you still want to start from scratch (which most likely is not necessary in this instance, as shadowsnipes pointed out):
Code:
# cp -a /usr/src/linux-2.6.24.5 /usr/src/linux-2.6.24.5-custom
# cd /usr/src/linux-2.6.24.5-custom
# make mrproper
# cp /boot/config-generic-smp-2.6.24.5-smp ./.config
# zcat linux-2.6.24.5.dnotify.diff.gz | patch -p0
# make menuconfig
 
Old 06-13-2008, 04:38 AM   #32
Daedra
Senior Member
 
Registered: Dec 2005
Location: Springfield, MO
Distribution: Slackware64-14.1
Posts: 1,223

Rep: Reputation: 177Reputation: 177
I'm confused, I thought that 4gb of memory was not possible with a 32bit operating system, only with a 64bit OS?
 
Old 06-13-2008, 05:56 AM   #33
storkus
Member
 
Registered: Jun 2008
Posts: 310

Rep: Reputation: 45
Go 64 bit

I just skimmed this while looking for something else and thought I should
mention it in case no one else did: have you considered going 64 bit?
While Slackware itself doesn't yet, its clones do: I'm using SlamD64 (.com)
very happily; it's also the only one that has 32 bit compatibility
libraries. In your particular case, going 64 bit means you'll have direct
(without PAE aka paging) access to all the memory in your system no matter
how big you get it (at least for the next dozen years or so, LOL!). Other
than the occasional non-FOSS package that's 32 bit only like Flash or
most games, the transition has been very smooth for me and my system runs
noticeably faster, particularly in the I/O department. YMMV, of course.

Mike
 
Old 06-13-2008, 04:14 PM   #34
glore2002
Member
 
Registered: Mar 2007
Location: Buenos Aires, Argentina.
Distribution: Debian Lenny AMD64
Posts: 506

Original Poster
Rep: Reputation: 32
This is not a piece of cake!

Hello back!

Well, I was going to re-build my kernel following reikyv steps. Then, when I've got home, I entered the forum and saw Shadowsnipes reply. Then, I stopped. Now, I am getting a bit confused and I am not sure what to do. For instance, I don't know if I have to rebuild my kernel or if it is preferable to download a new kernel and update the one I have installed.

That's why I will really appreciate if someone could write all the needed steps in order (as Reikyv did) to rebuild my Kernel enabling 64Gb support without losing what I have installed and being able to boot my O.S.

Your replies and suggestions are very important to me and I really appreciate that because you are the ones that know a lot about Slackware but if I can see all the instructions together, it would be much clarifying to me. Maybe you can modify and or optimize Reikyv set of instructions.

At the same time and following your advices, I am starting to read Slackware Linux Essentials, Slackware Linux Basics and also The article from http://slackwiki.org/Kerne26Compilation. They are great sources of information tools.

But, and I don't want to bother with this, a refined list of needed steps will be very useful not just for me (it course it will) but for many other Slackware users who are starting to understand how Slacware and Linux work.

Sorry for such a long Thread. It wasn't what I meant when starting it. Believe me. I thought it was easier but now I wont stop until I reach my goal :-)

Thank you friends!

Glore2002.-

Last edited by glore2002; 06-13-2008 at 04:16 PM.
 
Old 06-13-2008, 04:39 PM   #35
shadowsnipes
Senior Member
 
Registered: Sep 2005
Distribution: Slackware
Posts: 1,441

Rep: Reputation: 70
As I said previously T3sliders directions (1st set) are mostly fine. Basically I am just recopying most of that.

As root
Code:
cp -a /usr/src/linux-2.6.24.5 /usr/src/linux-2.6.24.5-custom
cd /usr/src/linux-2.6.24.5-custom
cp /boot/config-generic-smp-2.6.24.5-smp ./.config
make menuconfig
"General Setup" -> "Local version - append to kernel release"
Enter -custom

"Processor Type and Features" -> "High Memory Support" and select 64GB.

Exit and Save
Code:
make
make modules_install
cp arch/i386/boot/bzImage /boot/vmlinuz-2.6.24.5-custom
cp System.map /boot/System.map-2.6.24.5-custom
cp .config /boot/config-2.6.24.5-custom
Quote:
Originally Posted by T3slider
Now edit your lilo.conf file (you can use pico or nano or another editor if you don't like vi) and add the following stanza (to get it to boot by default, make sure it is the first stanza of its kind. You could also use the "default=" option if you don't want to add it to the beginning of the kernel stanzas but still want it to be the default):

Code:
image = /boot/vmlinuz-2.6.24.5-custom
  initrd = /boot/initrd.gz
  root = /dev/sda1
  label = Custom
  read-only  # Partitions should be mounted read-only for checking
Make sure you change /dev/sda1 to point to the root partition of your hard drive (check the existing stanzas to see what that is). Now you must create an initrd (initial ramdisk), since the generic kernel requires it. You should read the /boot/README.initrd file to see what command you should use. I personally just type `mkinitrd -c -k 2.6.24.5-smp -m reiserfs` since I use reiserfs, but a GREAT script that usually outputs the correct mkinitrd command is located here. Run the appropriate mkinitrd command and it will generate a /boot/initrd.gz file (and a /boot/initrd-tree directory).

Code:
/sbin/lilo -v
If LILO gives you any ERRORS (not warnings) don't reboot until they are resolved. If you have to temporarily comment out the new stuff. Alternatively you could create a backup of lilo.conf before you edit it.

After everything is all good you can optionally
Code:
cd /usr/src/linux-2.6.24.5-custom
make clean
 
Old 06-13-2008, 04:43 PM   #36
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,276

Rep: Reputation: 686Reputation: 686Reputation: 686Reputation: 686Reputation: 686Reputation: 686
The thing is, it IS pretty easy and I think my reply is fairly detailed. If you omit a few steps, as shadowsnipes explained, it will also work. We really can't spell it out any clearer. Following my steps makes it impossible to destroy your current kernel and modules, so you have nothing to lose. If you follow my steps but omit a few steps, as explained by shadowsnipes, you still have nothing to lose since your original kernel sources and modules will still be intact. If you follow my second, shorter set of instructions without building the modules, you still have nothing to lose -- though I can't 100% guarantee that it'll work.

Just try it out. If it doesn't work, reboot back into your old kernel and try again.
 
Old 06-13-2008, 04:58 PM   #37
shadowsnipes
Senior Member
 
Registered: Sep 2005
Distribution: Slackware
Posts: 1,441

Rep: Reputation: 70
Just be sure to tell us what you actually did especially if you run into problems.
 
Old 06-13-2008, 05:45 PM   #38
onebuck
Moderator
 
Registered: Jan 2005
Location: Midwest USA, Central Illinois
Distribution: SlackwareŽ
Posts: 11,320
Blog Entries: 3

Rep: Reputation: 1466Reputation: 1466Reputation: 1466Reputation: 1466Reputation: 1466Reputation: 1466Reputation: 1466Reputation: 1466Reputation: 1466Reputation: 1466
Hi,

I would like to add 'Linux Kernel in a Nutshell' as a must read.

This link and others are available from 'Slackware-Links'. More than just SlackwareŽ links!
 
Old 06-13-2008, 09:33 PM   #39
glore2002
Member
 
Registered: Mar 2007
Location: Buenos Aires, Argentina.
Distribution: Debian Lenny AMD64
Posts: 506

Original Poster
Rep: Reputation: 32
Quote:
Originally Posted by shadowsnipes View Post
Just be sure to tell us what you actually did especially if you run into problems.
Hello! Thanks for all the help and especially for the steps you've added.

Well, I followed these steps one by one. The mkinitrd I've got after using the script you told me and the one I used was:

mkinitrd -c -k 2.6.24.5-smp -f ext3 -r /dev/sda3 -m mbcache:jbd:ext3 -o /boot/initrd.gz (by the way, should it be -smp or -custom?)

When rebooting, I chose option Custom at the Slackware menu. The system started to boot and then it stopped showing the following messages:
----------------------------------------------------------------
No kernel modules found for linux 2.6.24.5-custom
mount: mounting /dev/sda3 on /mnt failed: No such device
ERROR: No sbin/init found on rootdev (or not mounted). Trouble ahead.
You can try to fix it. Type 'exit' when things are done
/bin/sh: can't access tty; job control turned off.

---------------------------------------------------------------

Here it is part of my lilo.conf just to verify that I've added things correctly:

---------------------------------------------
# Windows bootable partition config begins
other = /dev/sda1
label = Windows
table = /dev/sda
# Windows bootable partition config ends

# Custom bootable partition config begins
image = /boot/vmlinuz-2.6.24.5-custom
initrd = /boot/initrd.gz
root = /dev/sda3
label = Custom
read-only # Partitions should be mounted read-only for checking
# Custom bootable partition config ends


# Linux bootable partition config begins
image = /boot/vmlinuz
root = /dev/sda3
label = Linux
read-only
# Linux bootable partition config ends
----------------------------------------------

Please, let me know if you need any other kind of information to guide me.

Thanks my friends!
 
Old 06-13-2008, 09:59 PM   #40
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,276

Rep: Reputation: 686Reputation: 686Reputation: 686Reputation: 686Reputation: 686Reputation: 686
Quote:
Originally Posted by glore2002
mkinitrd -c -k 2.6.24.5-smp -f ext3 -r /dev/sda3 -m mbcache:jbd:ext3 -o /boot/initrd.gz (by the way, should it be -smp or -custom?)
It should be -custom if you set the LOCALVERSION variable to custom. To check the EXACT entry, you should check the name of the newly created directory in /lib/modules. It should be /lib/modules/2.6.24.5-custom. That command is trying to figure out the correct mkinitrd command for the current running kernel. I think you can specify which kernel to test to give you the correct command, but since the kernels are almost identical you could probably get away with the following mkinitrd command:
Code:
mkinitrd -c -k 2.6.24.5-custom -f ext3 -r /dev/sda3 -m mbcache:jbd:ext3 -o /boot/initrd.gz
It is possible that you also have to specify the dash (-) to get /lib/modules/2.6.24.5-custom, so it might be /lib/modules/2.6.24.5custom (I'm not sure). If that is the case, then you should use the following line:
Code:
mkinitrd -c -k 2.6.24.5custom -f ext3 -r /dev/sda3 -m mbcache:jbd:ext3 -o /boot/initrd.gz
I should also note that you should copy /etc/rc.d/rc.modules-2.6.24.5-smp to /etc/rc.d/rc.modules-2.6.24.5-custom (or omit the dash if it is incorrect).

Looking through the default Slackware configuration, it does indeed look like the dash (-) is needed in LOCALVERSION to get the ideal syntax. You may be able to omit it as described above though. If not, you could recompile with the LOCALVERSION set to "-custom".

Last edited by T3slider; 06-13-2008 at 10:01 PM.
 
Old 06-13-2008, 10:30 PM   #41
shadowsnipes
Senior Member
 
Registered: Sep 2005
Distribution: Slackware
Posts: 1,441

Rep: Reputation: 70
In my directions I had said to use -custom, so the '-' would be included. So, T3slider's first mkinitrd command should work.

I know I had mentioned creating/editing /etc/rc.d/rc.modules-2.6.24.5-custom earlier, but I forgot to mention it in my last set of directions. Thanks for mentioning this T3slider.
 
Old 06-14-2008, 06:39 AM   #42
glore2002
Member
 
Registered: Mar 2007
Location: Buenos Aires, Argentina.
Distribution: Debian Lenny AMD64
Posts: 506

Original Poster
Rep: Reputation: 32
Quote:
Originally Posted by T3slider View Post
It should be -custom if you set the LOCALVERSION variable to custom. To check the EXACT entry, you should check the name of the newly created directory in /lib/modules. It should be /lib/modules/2.6.24.5-custom. That command is trying to figure out the correct mkinitrd command for the current running kernel. I think you can specify which kernel to test to give you the correct command, but since the kernels are almost identical you could probably get away with the following mkinitrd command:
Code:
mkinitrd -c -k 2.6.24.5-custom -f ext3 -r /dev/sda3 -m mbcache:jbd:ext3 -o /boot/initrd.gz
It is possible that you also have to specify the dash (-) to get /lib/modules/2.6.24.5-custom, so it might be /lib/modules/2.6.24.5custom (I'm not sure). If that is the case, then you should use the following line:
Code:
mkinitrd -c -k 2.6.24.5custom -f ext3 -r /dev/sda3 -m mbcache:jbd:ext3 -o /boot/initrd.gz
I should also note that you should copy /etc/rc.d/rc.modules-2.6.24.5-smp to /etc/rc.d/rc.modules-2.6.24.5-custom (or omit the dash if it is incorrect).

Looking through the default Slackware configuration, it does indeed look like the dash (-) is needed in LOCALVERSION to get the ideal syntax. You may be able to omit it as described above though. If not, you could recompile with the LOCALVERSION set to "-custom".
Here I am again! By checking into my /lib/modules directory, I see that the name is 2.6.24.5-custom (with the dash). So, based on shadowsnipes set of instructions What should I change and where? (could you please quote that for me?)

I've just tried with (dash included):

mkinitrd -c -k 2.6.24.5-custom -f ext3 -r /dev/sda3 -m mbcache:jbd:ext3 -o /boot/initrd.gz

and then copying:

cp /etc/rc.d/rc.modules-2.6.24.5-smp /etc/rc.d/rc.modules-2.6.24.5-custom

without recompiling. Just wrote the two set of instructions above and restart the computer. The same error messages appear when rebooting.

So, I am sure I am doing something wrong.

Thank you!
 
Old 06-14-2008, 08:07 AM   #43
reikyv
Member
 
Registered: Oct 2007
Location: Malaysia
Distribution: Slackware
Posts: 80

Rep: Reputation: 15
Hi Glore2002,

Actually it is really not that difficult to re-compile your kernel. At least I've tried many times these two days, from the slackware kernel to those vanilla kernel (just pay attention to those instruction you received here, and Alien's wiki page, the steps are actually not much different... and also read those documentations come with your slackware distribution, I am pretty shame that this is my first time that I really study all those documentations, lol).

And I just re-built my laptop to have fully encrypted file system now (although it takes me more than 12 hours to dump my harddisk with /dev/random file ;-p)

Anyway it is awesome now. I pretty enjoying breaking thing. Good luck.
 
Old 06-14-2008, 09:45 AM   #44
shadowsnipes
Senior Member
 
Registered: Sep 2005
Distribution: Slackware
Posts: 1,441

Rep: Reputation: 70
Quote:
Originally Posted by glore2002 View Post
I've just tried with (dash included):

Code:
mkinitrd -c -k 2.6.24.5-custom -f ext3 -r /dev/sda3 -m mbcache:jbd:ext3 -o /boot/initrd.gz
and then copying:

Code:
cp /etc/rc.d/rc.modules-2.6.24.5-smp /etc/rc.d/rc.modules-2.6.24.5-custom
without recompiling. Just wrote the two set of instructions above and restart the computer. The same error messages appear when rebooting.

So, I am sure I am doing something wrong.

Thank you!
As far as I can tell it should be working. Perhaps try running lilo again. This shouldn't matter since your initrd.gz is still in the same location.

Also, make sure rc.modules-2.6.24.5-custom is executable.
Code:
chmod +x /etc/rc.d/rc.modules-2.6.24.5-custom
This shouldn't make a difference as far as getting your root partition to mount, however.

Based on your errors, it is as if either the initrd is not working or you need more/different modules in it.

You are using ext3 for your root file system, right? If not, that is your problem.

Also, verify that
Code:
/lib/modules/2.6.24.5-custom/kernel/fs/ext3/ext3.ko
exists.

Other than that I don't know, as of right now, what needs to be done. Based upon the commands you have run it should be working (assuming your root fs is ext3).
 
Old 06-14-2008, 02:34 PM   #45
glore2002
Member
 
Registered: Mar 2007
Location: Buenos Aires, Argentina.
Distribution: Debian Lenny AMD64
Posts: 506

Original Poster
Rep: Reputation: 32
Almost, almost. We are almost getting it!

Well, after checking what Shadowsnipes suggested, I reboot and the same ERROR message appeared. Then (as he also said), I re-run lilo and restart. This was a big change. The booting process didn't show up the message. I was expecting X to start (with a smile on my face)...But it stopped don't letting me press any key. So, I've restarted the computer and change /etc/inittab to boot into command prompt (3) instead of directly into X (4). Then I restarted.

When the system booted up and at the command prompt $ I typed startx and the following error message showed up (I will write down the most important lines):

-------------------------------------------------------------
:
:
Using config file: "/var/log/Xorg.0.log"
Using config file: "/etc/X11/xorg.conf"
Module "ramdac" already built in

FATAL: Module nvidia not found
Nvidia(0): Failed to load Nvidia kernel module!
Nvidia(0) ***Aborting***

Scree(s) found but none have a usable configuration

FATAL server error: no screens found
giving up

:
:
-------------------------------------------------------------

I think we are almost there friends! Just one more help, pleeeeaaaasssseeee

Thanks!!!

Last edited by glore2002; 06-14-2008 at 02:35 PM.
 
  


Reply

Tags
can, data, get, help, how, installing, ubuntu


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
AS 2.1 Not showing full ram rashid68 Linux - Server 4 07-13-2007 03:24 PM
RAM becomes full izvrashenj Debian 5 07-20-2006 11:57 AM
Top not reporting full ram satinet Linux - Hardware 5 02-05-2006 03:28 PM
Slackware Linux RAM/Memory Issues Darvocet Slackware 6 05-25-2005 03:16 PM
RAM seems very full? ginda Linux - Newbie 12 03-07-2005 10:17 PM


All times are GMT -5. The time now is 08:49 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration