LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices



Reply
 
Search this Thread
Old 10-24-2005, 01:19 PM   #1
haertig
Senior Member
 
Registered: Nov 2004
Distribution: Debian, Ubuntu, LinuxMint, Slackware, SysrescueCD
Posts: 2,032

Rep: Reputation: 309Reputation: 309Reputation: 309Reputation: 309
Howto? upgrade kernel on initial boot into Sarge


I am attempting to install Sarge 3.1r0a on my system, but it is apparently failing to detect/configure/whatever my onboard ethernet (nForce3 250Gb chipset).

I'm thinking this may be because the 2.6.8 kernel that comes with Sarge does not support this. Being a Linux newbie, I am GUESSING that if I could somehow upgrade the kernel to a newer version I might be OK. Knoppix with the 2.6.11 kernel works with this ethernet.

So, is there some way to install a newer kernel on first boot into this new system? The basic install off the netinst CD has completed and I'm stuck at the next step where you boot into the new system and then start configuring apt. This fails because the network isn't working and it can't connect to the repositories I'm trying to configure.

Without networking working, I can't use apt to download anything yet. This box can dual-boot into Windows and I'm thinking I might be able to download some installable kernel from there, save it to a FAT32 partition I have, then boot back into Debian, mount that FAT32, and somehow install this newer kernel before moving on to the apt configure step where networking is required.

Is this a workable idea, or am I way off the deep end? If it's workable, can anybody tell me how to actually accomplish this? At this stage of the game my Debian install is in it's very infancy, so I assume I don't have many tools to work with. And being a newbie, I can't say I know how to use all the tools I may have yet. Any pointers would be appreciated.

Thanks!

Related post:

http://www.linuxquestions.org/questi...hreadid=376178
 
Old 10-24-2005, 02:08 PM   #2
samael26
Member
 
Registered: Oct 2004
Location: France, Provence
Distribution: Debian
Posts: 848

Rep: Reputation: 30
Hi,

I would say to try to d/load a newer netinstall CD if yours
is a bit outdated. It does make a difference, I had the same
problem with a Broadcom card not detected until a newly-built
cd did the job. Since you're on dual-boot, visit debian.org, they
have weekly builds, or perhaps you could try testing, though the
kernel is the same.
I doubt you could try to do what you suggested about the FAT32
partition, but I have never tried that, to be honest.

cheers
 
Old 10-24-2005, 10:45 PM   #3
haertig
Senior Member
 
Registered: Nov 2004
Distribution: Debian, Ubuntu, LinuxMint, Slackware, SysrescueCD
Posts: 2,032

Original Poster
Rep: Reputation: 309Reputation: 309Reputation: 309Reputation: 309
To followup on my own post ... I was able to upgrade the kernel as I originally thought I could. Unfortunately that did not fix my ethernet problem, but I managed to fix that problem a different way. See http://www.linuxquestions.org/questi...hreadid=376178 for the ethernet solution.

Here's how I upgraded the kernel, in case anyone is interested in the procedure.

First, I have to obtain the kernel image. I used a different computer at work that was running Debian Sarge. I pointed apt to the unstable branch and downloaded the 2.6.12 kernel found there. There were three files, one "kernel-image..." and two "linux-image..." files.

As root on the work computer, I created the directory /root/debs and put those three downloaded files there. Then from the /root directory I ran: dpkg-scanpackages debs /dev/null | gzip > debs/Packages.gz Now I had four files in /root/debs and I copied those to my USB flashdrive for transport to my home computer.

At home, I dual-booted the half-complete Debian computer into Windows and copied the flashdrive files to a fat32 partition. Then I dual-booted back into the half-completed debian install, created /mnt/fat32, and ran "mount -t vfat /dev/hda1 /mnt/fat32" (my fat32 partition is the first partition on hda). Next I created /root/debs and copied the four files from /mnt/fat32 partition there.

Next, I edited /etc/apt/sources.list, commented out everything that was in there, then added the line "deb file:/root debs/". Next I ran "apt-get update". Followed with "apt-get install kernel-image-2.6-686". This ran without hitch and even updated Grub's config. I then restored /etc/apt/sources.list back to the way it originally was.

Rebooted, and I was up and running 2.6.12 !

(Next I will download the 2.6.12 kernel source so I can compile things correctly when I get to that.)
 
Old 11-10-2005, 07:05 PM   #4
bhomass
Member
 
Registered: Nov 2005
Posts: 69

Rep: Reputation: 15
I am interested in following your procedure to upgrade to 2.6.12, and I do currently have Debian Sarge.

excuse a newby question, but what do you mean by "pointed apt to the unstable branch"?

I went to http://packages.debian.org/unstable/base/ but and found only one linux-image file linux-image-2.6.12-1-686 (2.6.12-10). I don't see a total of 3 files as you described.

could you please give me a bit more detail on the down load by apt.

Thanks
 
Old 11-10-2005, 08:33 PM   #5
haertig
Senior Member
 
Registered: Nov 2004
Distribution: Debian, Ubuntu, LinuxMint, Slackware, SysrescueCD
Posts: 2,032

Original Poster
Rep: Reputation: 309Reputation: 309Reputation: 309Reputation: 309
Quote:
excuse a newby question, but what do you mean by "pointed apt to the unstable branch"?
There is a file on your system:/etc/apt/sources.list It's a plain text file.

Mine normally contains the following (yours will probably be slightly different):
Code:
deb http://mirrors.kernel.org/debian/ stable main
deb-src http://mirrors.kernel.org/debian/ stable main
deb http://ftp.debian.org/debian/ stable main
deb-src http://ftp.debian.org/debian/ stable main
deb http://ftp.us.debian.org/debian/ stable main
deb-src http://ftp.us.debian.org/debian/ stable main
deb http://security.debian.org/ stable/updates main
Everywhere you see the word "stable" you replace that with "unstable" (not needed on the "security.debian.org" line however). Note: Your sources.list file may have "sarge" instead of "stable". At the moment, they mean the same thing (this will change in the future when "etch" becomes the "stable" release).

After you've edited the sources.list file, you need to run the command "apt-get update" to put your changes in place.

After you're done with your download (detailed below), reverse the sources.list editing procedure and put things back the way the were, then run "apt-get update" again.
Quote:
I went to http://packages.debian.org/unstable/base/ but and found only one linux-image file linux-image-2.6.12-1-686 (2.6.12-10). I don't see a total of 3 files as you described.
I believe that's only a placedholder (called a "transistion package"). When you select it for download you'll actualy get three files. At least that's the way I think I remember it going. I seem to remember that the file I asked to download was kernel-image... and what I got was that one kernel-image... file and two linux-image... files. I did not do this download from the command line via "apt-get". I did it from within "synaptic", which is a graphical frontend for apt. You will find synaptic under Applications->SystemTools->SynapticPackageManager When I was about to download, I clicked the box labeled "download files only, do not install" or something like that. I'm sure there is a command line switch for apt-get to do this, but I don't know it off the top of my head.

After you've got your system booted up with the new kernel you'll want to go download the kernel source (for future compiles and such). Point apt to unstable as described above, then use synaptic to download and install linux-headers-2.6.12-1, linux-headers-2.6.12-1-686, and linux-source-2.6.12 These should end up in your /usr/src directory after the download and install. As root, cd to /usr/src and run "tar -jxvf *.bz2" If you have more than one .bz2 file there you'll want to give the specific filename rather than my wildcard *.bz2 After running the tar command run "ln -s linux-2.6.12 linux" (while still in /usr/src). Grab the newer version of "gcc" from unstable while you're in synaptic too. Sarge comes default with gcc-3.3 but this new kernel you've installed was compiled with version 4 of gcc and you don't want to be mixing kernels and compilers from what I've read. After installing gcc-4.0 go to /usr/bin and run "ls -l *gcc*" and make sure "gcc" is a symbolic link pointing to "gcc-4.0" and "gccbug" is pointing to "gccbug-4.0" If not, use "rm gcc gccbug" and then "ln -s gcc gcc-4.0" and "ln -s gccbug gccbug-4.0" to fix things.
 
Old 11-10-2005, 09:32 PM   #6
bhomass
Member
 
Registered: Nov 2005
Posts: 69

Rep: Reputation: 15
Thanks. I tried snaptic, from which I realized how picking one file automatically picked the two other dependency files. so indeed, there are 3 overall. since I could not figure out how to download without install using snaptic, I took down the 3 file namess and downloaded directly.

but something goes wrong when I create Packages.gz

debian:~# dpkg-scanpackages debs /dev/null | gzip > debs/Packages.gz
** Packages in archive but missing from override file: **
kernel-image-2.6-686 linux-image-2.6-686 linux-image-2.6.14-1-686

Wrote 3 entries to output Packages file.


The Packages.gz is very small and gzip -l shows no content. can you tell what went wrong?

Notice I downloaded 2.6.14 intentionally.
 
Old 11-10-2005, 11:44 PM   #7
haertig
Senior Member
 
Registered: Nov 2004
Distribution: Debian, Ubuntu, LinuxMint, Slackware, SysrescueCD
Posts: 2,032

Original Poster
Rep: Reputation: 309Reputation: 309Reputation: 309Reputation: 309
Quote:
debian:~# dpkg-scanpackages debs /dev/null | gzip > debs/Packages.gz
** Packages in archive but missing from override file: **
kernel-image-2.6-686 linux-image-2.6-686 linux-image-2.6.14-1-686
I think the above is normal. I just reran that command on my system and got the same message. The resulting Packages.gz file is pretty small. Mine's only 721 bytes.

Below is my terminal session:
Code:
familyroom:~# id
uid=0(root) gid=0(root) groups=0(root)
familyroom:~# pwd
/root
familyroom:~# mkdir deb
familyroom:~# cp /home/david/tmp/* deb/.
familyroom:~# ls deb
kernel-image-2.6-686_1%3a2.6.12-10_i386.deb
linux-image-2.6-686_2.6.12-10_i386.deb
linux-image-2.6.12-1-686_2.6.12-10_i386.deb
familyroom:~# dpkg-scanpackages deb /dev/null | gzip > deb/Packages.gz
 ** Packages in archive but missing from override file: **
  kernel-image-2.6-686 linux-image-2.6-686 linux-image-2.6.12-1-686

 Wrote 3 entries to output Packages file.
familyroom:~# ls -l deb/*
-rw-r--r--  1 root root      721 Nov 11 02:38 deb/Packages.gz
-rwx------  1 root root     8732 Nov 11 02:38 deb/kernel-image-2.6-686_1%3a2.6.12-10_i386.deb
-rwx------  1 root root     8752 Nov 11 02:38 deb/linux-image-2.6-686_2.6.12-10_i386.deb
-rwx------  1 root root 16685742 Nov 11 02:38 deb/linux-image-2.6.12-1-686_2.6.12-10_i386.deb
familyroom:~# cd deb
familyroom:~/deb# gunzip Packages.gz
familyroom:~/deb# ls -l
total 16380
-rw-r--r--  1 root root     1968 Nov 11 02:38 Packages
-rwx------  1 root root     8732 Nov 11 02:38 kernel-image-2.6-686_1%3a2.6.12-10_i386.deb
-rwx------  1 root root     8752 Nov 11 02:38 linux-image-2.6-686_2.6.12-10_i386.deb
-rwx------  1 root root 16685742 Nov 11 02:38 linux-image-2.6.12-1-686_2.6.12-10_i386.deb
familyroom:~/deb# cat Packages
Package: kernel-image-2.6-686
Source: linux-2.6 (2.6.12-10)
Version: 1:2.6.12-10
Priority: extra
Section: base
Maintainer: Debian Kernel Team <debian-kernel@lists.debian.org>
Depends: linux-image-2.6-686
Architecture: i386
Filename: deb/kernel-image-2.6-686_1%3a2.6.12-10_i386.deb
Size: 8732
Installed-Size: 36
MD5sum: a861f3e0d028b11187ce7b208c145c31
Description: Linux kernel 2.6 image on PPro/Celeron/PII/PIII/P4 machines - transition package
 This package is for transition only.

Package: linux-image-2.6-686
Source: linux-2.6
Version: 2.6.12-10
Priority: optional
Section: base
Maintainer: Debian Kernel Team <debian-kernel@lists.debian.org>
Depends: linux-image-2.6.12-1-686
Architecture: i386
Filename: deb/linux-image-2.6-686_2.6.12-10_i386.deb
Size: 8752
Installed-Size: 36
MD5sum: bbee1b183066c03726d7bcc230da5a02
Description: Linux kernel 2.6 image on PPro/Celeron/PII/PIII/P4 machines
 This package depends on the latest binary image for Linux kernel 2.6 on
 Pentium Pro/Celeron/Pentium II/Pentium III/Pentium 4 machines.

Package: linux-image-2.6.12-1-686
Source: linux-2.6
Version: 2.6.12-10
Priority: optional
Section: base
Maintainer: Debian Kernel Team <debian-kernel@lists.debian.org>
Depends: initrd-tools (>= 0.1.78), coreutils | fileutils (>= 4.0), module-init-tools (>= 0.9.13)
Suggests: linux-doc-2.6.12 | linux-source-2.6.12, lilo (>= 19.1) | grub, fdutilsConflicts: hotplug (<< 0.0.20040105-1)
Provides: linux-image, linux-image-2.6
Architecture: i386
Filename: deb/linux-image-2.6.12-1-686_2.6.12-10_i386.deb
Size: 16685742
Installed-Size: 47432
MD5sum: 7f9901e267894a3cc4a78f5d16db695f
Description: Linux kernel 2.6.12 image on PPro/Celeron/PII/PIII/P4 machines
 This package provides the binary image and pre-built loadable modules for
 Linux kernel 2.6.12 on Pentium Pro/Celeron/Pentium II/Pentium III/Pentium
 4 machines.
 .
 This packages is produced using an updated kernel packaging system and
 replaces older kernel-image packages

familyroom:~/deb#
 
Old 11-10-2005, 11:57 PM   #8
bhomass
Member
 
Registered: Nov 2005
Posts: 69

Rep: Reputation: 15
thanks, I was just reaching the same conclusion. the problem is not in Packages.gz.

I followed thru with
deb file:/root debs/ in sources.list
apt-get update
then apt-get install kernel-image-2.6-686

I get this following error

debian:~# apt-get install kernel-image-2.6-686
Reading Package Lists... Done
Building Dependency Tree... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.

Since you only requested a single operation it is extremely likely that
the package is simply not installable and a bug report against
that package should be filed.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
kernel-image-2.6-686: Depends: linux-image-2.6-686 but it is not going to be installed
E: Broken packages

Do you know what this means?

then I tried apt-get install linux-image-2.6.14-1-686

debian:~# apt-get install linux-image-2.6.14-1-686
Reading Package Lists... Done
Building Dependency Tree... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.

Since you only requested a single operation it is extremely likely that
the package is simply not installable and a bug report against
that package should be filed.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
linux-image-2.6.14-1-686: Depends: yaird but it is not installable or
initramfs-tools but it is not installable o
linux-initramfs-tool but it is not installa
E: Broken packages


all these stuff: yaird, initramfs-tools, etc. have no installation candidate. so what to do?
 
Old 11-11-2005, 12:19 AM   #9
haertig
Senior Member
 
Registered: Nov 2004
Distribution: Debian, Ubuntu, LinuxMint, Slackware, SysrescueCD
Posts: 2,032

Original Poster
Rep: Reputation: 309Reputation: 309Reputation: 309Reputation: 309
Not sure why you're failing. It worked for me without a hitch.

The one thought that comes to mind ... are you running in multi-user mode? remember, when I did this I was on a very minimal installation and running in single-user mode. I'm not sure if this makes a difference for the install.

Here's how to get to single-user mode:

First - you do know about virtual consoles, right? You change to these with a three-keys-pressed-together sequence. <ctrl><alt><F1> ... <ctrl><alt><F2> ... <ctrl><alt><F3> ... etc. Your graphical desktop is on virtual terminal 7. So make sure you understand you can go to a text virtual terminal by typing <ctrl><alt><F1> and can get back to your graphical desktop by hitting <ctrl><alt><F7>.

With that out of the way, hit <ctrl><alt><F1> to go to a new terminal. Login as root there. Then type "telinit 1". You will come down to single-user. Now cd to /root/deb (I supposed you don't really have to do this). Now run "apt-get install kernel-image-2.6-686".

[edit]Oops. I made an assumption there. If you're on a multi-user box and other people are logged in doing things, "telinit 1" will probably piss them off! I was assuming you're the only current user on the system. Single-user mode means, well, single user. And that's you. Eveybody else will be unceremoneously logged off.[/edit]

I hope it will work this time! If so, reboot. You can type "reboot" in your virtual terminal to do this (duh!)

If it didn't work, type "telinit 2" to come back up to multiuser mode, and hope that somebody more knowledgeable than me will post the solution in this thread. Hope it works, but I'm out of suggesstions if it doesn't. Could be something specific to the 2.6.14 kernel you're working with. I was using 2.6.12

BTW, the source of that message " ** Packages in archive but missing from override file: **" is because you are specifying /dev/null as your override file. Think of this as "the empty file" in this context, so of course things are "missing" in an empty file!

Last edited by haertig; 11-11-2005 at 12:26 AM.
 
Old 11-11-2005, 09:01 PM   #10
bhomass
Member
 
Registered: Nov 2005
Posts: 69

Rep: Reputation: 15
well, I could get 2.6.8 kernel from the stable branch and install fine, just as you described. rebooted and the whole system worked great.

again, I tried to install 2.6.14 from the 2.6.8 configuration, but the same errors.

2.6.12 is no longer available. unless you know of a place to find it. it may be that 2.6.14 is truely "unstable". I may have to wait til it makes into the stable stage.

But thank much. I am very glad to have 2.6.8 working!
 
Old 11-11-2005, 09:42 PM   #11
bhomass
Member
 
Registered: Nov 2005
Posts: 69

Rep: Reputation: 15
ok, I got it.

the mistake was manually downloading the 3 files instead of using synaptic. synaptic knows how to include all the dependencies.

what I finally did was to have synaptic install 2.6.14, and the rest worked like a charm.
 
Old 11-12-2005, 01:23 PM   #12
haertig
Senior Member
 
Registered: Nov 2004
Distribution: Debian, Ubuntu, LinuxMint, Slackware, SysrescueCD
Posts: 2,032

Original Poster
Rep: Reputation: 309Reputation: 309Reputation: 309Reputation: 309
Quote:
Originally posted by bhomass
ok, I got it.
Great! Glad to hear it. I'm no expert on all of this so I was hoping I wasn't leading you terribly astray. I did what I had to to get my box running the way I wanted, and it all seemed to work. This does not imply that I'm an expert by any means!

I think today I might try recompiling my kernel from source. Just because. I'm sure I'll find some need to do this in the future, so I'll start experimenting now to learn the procedure when I'm not presurring myself to get it done quickly to accomplish some specific goal. Learn in advance of actual need.
 
Old 11-13-2005, 12:58 AM   #13
bhomass
Member
 
Registered: Nov 2005
Posts: 69

Rep: Reputation: 15
you are too modest. your posting saved me a couple weeks.

if you gain some good insights about recompiling the kernel, certainly like to hear it!
 
  


Reply


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
Howto Boot to CLI w/ Debian Sarge 3.1 renato167 Debian 3 10-25-2005 03:42 AM
howto create boot disc on debian sarge ? cccc Debian 6 10-18-2005 04:26 PM
Kernel Upgrade from Sarge 2.4 Jaster Debian 16 11-23-2004 12:15 AM
Howto upgrade from sid to sarge? andymadigan Debian 9 08-02-2004 10:17 PM
New kernel boot: no initial console found taids Arch 4 08-16-2003 01:51 PM


All times are GMT -5. The time now is 01:52 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration