Enableing swap partition on install

Posted on 2004-11-28
Last Modified: 2010-04-20
Hi, I am trying to set up a linux on a older machine 133 with only 16Mb of ram, but after the install starts in prints an error that I have not enaugh memory. I have made a swap partition of 200Mb but it does'nt mouts it automaticaly. I have tryed to pass the kernel the 'swapon /dev/hda5' but thoes'nt seems to work either. On other places I have found that I should write the 'swapon /dev/hda5'  but does not specifiy where. Actualy I am looking for the kernel param that would enable swap automaticaly and I could continue with my install
Thanx in advance!
Question by:Xumxum
    LVL 3

    Expert Comment

    Try installing using text mode.  

    Most distributions use a ram disk and syslinux for the actual install program so they won't use a swap partition on the harddrive.

    Author Comment

    I was installing in text mode!
    LVL 38

    Expert Comment


       First, please run "fdisk -l /dev/hda" to check partition /dev/hda5 is swap type (id 82)
         Device Boot    Start       End    Blocks   Id  System
    /dev/hda5   *         1       255   2048256   82  Linux swap   <== Id is 82

       Then edit /etc/fstab and add:
    /dev/hda5               swap                    swap    defaults        0 0

       Besides, you can add "swapon /dev/hda5" in
    /etc/rc.d/rc.local     for (Fedora/RedHat)
    /etc/rc.d/boot.local  (SuSE)
    /etc/init.d/local  (Debian) (If not there, create one with first line "#!/bin/sh" )
    to turn on swap at boot.

       Which Linux do you use? RedHat or Mandrake ?


    Author Comment

    I can't install it , so therefore I can't edit /etc/fstab or any other files... daaa ,that is my problem , that I can't install it! And it is surely a swap partition, I have mounted it and used it under knopix (bootable linux from cdrom) By the way, I am trying to set up RedHat 7.3, but I would like to set up fedora 3 but my machine won't boot fedora 3 only redhat 7.3., that would be my other problem!
    LVL 38

    Accepted Solution

    > would like to set up fedora 3 but my machine won't boot fedora 3
    Fedora has some issues with old CDROM. As for your P133 16MB RAM, I'm not sure it meet the hardware
    requirement of Fedora. If it meets, then Fedora will be very very slow.

    You can install Knoppix on hard disk, too.

    Or customerize your Knoppix CD:

    LVL 40

    Assisted Solution

    As far as I know you can't get the installer to use a swap partition. You might be able to install 7.3 by connecting this disk to another machine with sufficient memory, but it will be terribly slow. I'd suggest looking around for some used memory. For a machine of that age it should be pretty cheap (or even free).
    LVL 3

    Assisted Solution

    If you really feel adventurous, you can edit the initial ram disk used during install.

    First backup your original iso

    Mount the iso image of the first cd
    mount -t iso9660 -o loop FC3-i386-disk1.iso /mnt/isoimage

    Then go into there and grab the initrd.img file
    cp /mnt/isoimage/isolinux/initrd.img /tmp/initrd.img.orig

    This is a compressed filesytem image so extract it first
    cd /tmp
    cp initrd.img.orig initrd.gz
    gunzip initrd.gz

    Now mount the filesystem image
    mount -o loop ./initrd /mnt/somewhere

    go into /mnt/somewhere and make any changes you want
    when you are done:
    unmount /mnt/somewhere
    gzip initrd
    mv initrd.gz initrd.img

    cp initrd.img /mnt/isoimage/isolinux/
    umount isoimage
    burn cd with new iso image

    Featured Post

    Free Trending Threat Insights Every Day

    Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

    Join & Write a Comment

    Suggested Solutions

    Introduction We as admins face situation where we need to redirect websites to another. This may be required as a part of an upgrade keeping the old URL but website should be served from new URL. This document would brief you on different ways ca…
    The purpose of this article is to fix the unknown display problem in Linux Mint operating system. After installing the OS if you see Display monitor is not recognized then we can install "MESA" utilities to fix this problem or we can install additio…
    Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
    Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

    732 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now