Swap partition

Swap partition

Post by Wai W » Sat, 05 Feb 2000 04:00:00



Hi all,
    Where first installed RH6.1, I set the swap partition size to 16M. Now I
realize I need bigger swap partition, and I do have a partition set aside
for it. Any one know how to point the swat partition to a different one?

Thanks

 
 
 

Swap partition

Post by Dr H. T. Leu » Sat, 05 Feb 2000 04:00:00


Did you try "man -k swap" first? It isn't really an big secret.  

You need to do two things:

(1) "mkswap" the new partition to prepare it. ("man mkswap" for details). basically
this formats the partition to swap format. So be careful. You probably want -v1 to
generate the newer format swap partitions - no major difference, just that you can
go over 128Mb with it. (old format can't go over).

(2) edit /etc/fstab  to add/modify the swap entries. You can have both the
new and the old entries. (linux can swap on multiple partitions if necessary).
Then reboot to have it taking effect. "man fstab" for details, but really, you can
simply duplicate/modify the existing swap entry. Just copy/modify that line.

If you don't want to reboot just yet, you can also "swapon" the new one manually
rightaway, and "swapoff" the old one. Again, "man swapon", "man swapoff" for
details.

Note these are rather dangerous changes, so make sure that you type everything
correctly before pressing return, etc.

|> Hi all,
|>     Where first installed RH6.1, I set the swap partition size to 16M. Now I
|> realize I need bigger swap partition, and I do have a partition set aside
|> for it. Any one know how to point the swat partition to a different one?
--
          --------------------------------------------------
"What you don't care cannot hurt you."            Chap. 7a, AMS-NS

 
 
 

Swap partition

Post by Michael Fauro » Sat, 05 Feb 2000 04:00:00


:     Where first installed RH6.1, I set the swap partition size to 16M.
: Now I realize I need bigger swap partition, and I do have a partition
: set aside for it. Any one know how to point the swat partition to a
: different one?

There's a couple of different ways of doing this, but what will
probably be the easiest is the following:

1)      Edit /etc/fstab.  Modify the current entry for the swap
        partition and change the device from where the current swap
        partition is, to where the new one will be.

2)      Using fdisk insure that the new swap partition has been setup
        with a partition ID of 82 (Linux swap).

3)      Prepare the partition to be used for swap by issuing the
        following command:

        mkswap -c /dev/hdXX

4)      reboot.

--
------------------------------------------------------------------------------
 Michael | mfaurot  | One way to stop a runaway horse is to bet on him.
 Faurot  | atww.net |

 
 
 

Swap partition

Post by Peter Samuels » Sun, 06 Feb 2000 04:00:00


[Michael Faurot]

Quote:> 4) reboot.

Why?

It sounds like you have a Windoze mentality, i.e. "I made a change to
the system, better reboot just in case."  That attitude bothers me,
even though I know it isn't *your* fault -- I suppose years of working
with Microsoft products conditions a person to think that way.

In this case I cannot think of *any* reason to have to reboot, unless
you happen to *like* looking at the BIOS memory test blinkenlights.

Peter

 
 
 

1. MS-DOS Swap File vs. Swap Partition

Hello, All;

What performance difference, if any, should I expect to see between a
native Linux swap partition and a swap file residing on an MS-DOS
partition?

I'm currently using my Microsoft Windows swap file as a Linux swap
file, and I'm considering adding a dedicated Linux swap partition as
well.  If there's no performance benefit, I may as well just use a
larger Windows swap file.

Bruce

2. Debian NFS problems

3. Swap file VS Swap partition

4. starting problems on DEC Unix 4.0d

5. 20+ meg Swap partition setup, but top only reports 860k of swap available...

6. Latest 'Stable' v2.0.xx release past v2.0.14?

7. Installing Win/Linux shared swap on old swap partition

8. bootup messages

9. Linux Swap Partition and Win3.1 Swap File

10. Swap File vs. Swap Partition - which is better?

11. swap file instead of swap partition

12. swap file vs swap partition

13. Why swap partition not swap file?