TechNotes: Fixing SuSE 7.3 - page 2
When Little Problems Get Big
When installed using the YaST2 graphical configurator -- the default -- systems with the G-400 video card experience a variety of problems, depending in large measure on the kind of install being done: An "update" install works poorly, while a full install on a clean system in some cases goes into an endless loop, failing at the point where the machine reboots. Presuming a successful install, users are limited to VGA -- 640x480, 16 colors -- when a full install is done, though if there is an existing /etc/X11/XF86Config an upgrade can provide higher-quality video. What does not work is a switch from virtual terminals or a shutdown of the X Windows System and a return to a text console.
The problem is that the Linux-2.4.10-GB kernel shipped with SuSE 7.3 has framebuffers enabled, which does not work with the G-400 and XFree86-4.1. The solution in short is to recompile the kernel, eliminating the MGA framebuffer support. This suggestion was made by SuSE user Jon Pennington, and it turns out to be the right answer. But for those new to Linux, it's a little more complicated than that short description suggests.
Here, then, is the recipe.
When booting from CD or floppy, choose the text-based installation. Make your selections as you will. Do not choose to configure XFree86 now. Do make sure that the kernel source package is installed, which you can do after you have chosen the general type of system you wish to install by choosing "Detailed selection . . ."
After the installation and reboot, log in as a user (or as root if you prefer, though it's seldom necessary to log in as root). Your desktop of choice will appear in due course. It will look terrible. From its menu, open a terminal window. Type
suand when prompted enter the root password (you need not su root and enter the password if you're logged in as root). Then do the following:
# cd /usr/src/linux [this changes to the kernel source directory]
# make mrproper ["Mr. Proper" is the German equivalent of "Mr. Clean," it's a joke, but it has a real purpose -- making sure that the kernel source is pristine]
# make menuconfig [which makes kernel configuration easier]
Soon, you'll have a menu of choices for kernel configuration.
Scroll down until you get to the next-to-last line in the menu, "Load an Alternate Configuration File." Choose it and, when prompted, backspace to remove ".config," and type in "/boot/vmlinuz.config" and hit enter.
When you are returned to the main menu, scroll up six lines to "Console drivers --->" and, when it's highlighted, hit enter. In the resulting submenu Scroll down to "Frame-buffer support --->" and again hit enter. The top line will look like this: "[*] Support for frame buffer devices (EXPERIMENTAL)" Highlight it and hit the space bar. Most of the page will disappear, as will the asterisk between the brackets on that line. Use the right arrow key to highlight "Exit" and hit enter.
At the next screen, do the same. At the main menu, do the same. You will get a dialog asking " Do you wish to save your new kernel configuration?" to which the answer is "Yes."
You will be returned to the command prompt, at which you do:
# make dep
When the prompr returns, type:
# make bzImage [yes, case matters]
Your new kernel will now compile. It will take from a few minutes to perhaps an hour, depending on the speed of your machine and the amount of memory you have available. When it is done, you now should make corresponding kernel modules:
# make modules
And when they have finished compiling -- which will probably take longer than compiling the kernel itself did:
# make modules_install
You are not done yet. As with all things connected with kernel compilation and invocation, there is nothing difficult involved, but precision is essential. Instructions must be followed exactly. There are several possible ways of proceeding; what follows is one that is easy and that works.
At the prompt:
# cd arch/i386/boot
Midnight Commander will start, and in the left pane will be the contents of the kernel source tree's boot directory. Use the down arrow to highlight the file named "bzImage." Hit the tab key to change to the right pane and hit enter to go up a directory level. Keep highlighting the top line (/..) and hitting enter until you are at the top of the entire filesystem. The "/usr" directory will be highlighted. Use the arrow keys to scroll up to "/boot" and hit enter. Then hit tab to return to the first pane, where bzImage will be highlighted. Hit F5. In the resulting dialog, in which you're asked if you'd like to copy bzImage to /boot, on the line where "/boot" appears, change it to "/boot/vmlinuz-2.4.10-MGA" and hit enter. You'll see that the file gets copied under the new name.
Still in Midnight Commander, climb out of the /boot directory and scroll down to /etc, then hit enter. Scroll down through the various subdirectories to the section listing individual files, and find the file named "lilo.conf." Highlight it and hit F4, which will open it in Midnight Commander's editor. You will see a section (a "stanza" in the trade) that looks like this:
# image = /boot/vmlinuz root = /dev/hda2 label = linux
(It may vary as to the "root =" line. This does not matter.) Your job now is to create a duplicate of this stanza that points to your new kernel while still leaving your old kernel available in case the new one does not work. In the editor, add the stanza, so that that section now looks like this (with the "root" line differing as is appropriate for your system -- maintain whatever is already there):
# image = /boot/vmlinuz-2.4.10-MGA root = /dev/hda2 label = linux # image = /boot/vmlinuz root = /dev/hda2 label = linux-original
Double check your work. When you are certain that you have it right -- capitalization counts -- hit F2 to save your file, then F10 to exit the editor, and F10 again to exit Midnight Commander.
Now, from the prompt, do:
It should return this:
Added linux * Added linux-original Added memtest86
If it returns any error, go back and check your editing of /etc/lilo.conf. The asterisk, by the way, specifies the default kernel -- the one that gets booted unless you specify a different one at boot time. (And now both the new one and the old one will be on the boot menu, so if the new one does not for some reason work, you can boot the other to sort it all out.)
Exit from the terminal and shut down your machine. When you restart, you should have a kernel that works properly. And if you needed these instructions, you have probably compiled your first kernel, in which case congratulations -- you have a new feather in your cap and have taken your first step toward becoming a kernel hacker.
- 1Linux Top 3: Alpine Linux 3.4, deepin 15.2 and Linux Lite 3.0
- 2Linux 4.7 Set to Boost Live Patching, Security and Power Management
- 3Linux 4.6 Charred Weasel adds USB 3.1 Support
- 4Linux Top 3: OpenIndiana 2016.04, Ubuntu 16.04 and Debian's New Leader
- 5Linux Top 3: KaOS 2016.04, TurnKey 14.1 and pfSense 2.3