Latest LQ Deal: Latest LQ Deals
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 12-05-2002, 08:21 PM   #1
LQ Newbie
Registered: Dec 2002
Location: Auckland
Distribution: Mandrake 9.0
Posts: 4

Rep: Reputation: 0
Question swap-space fstab problem


I am new to Linux, and have purchased, and am having trouble enabling the swap partition on my mandrake 9.0 installation. The problem seems to be in 'fstab'. When linux is booting, an error appears invlaid argument whilst trying to mount the swap space (I think that's what its trying to do). What is the correct syntax for a swap entry in fstab?

The system has already been installed, and otherwise seems to be functioning fine. There is no Windows installation on the box.

The problem is kind of frustrating, as the machine is reasonably speced, but when there are a few big apps open, it tends to grind to a halt.

Any help with this would be greatly appreciated.

Old 12-05-2002, 08:32 PM   #2
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917
/dev/hdaX swap swap defaults 0 0

Replace the X with the number of your swap
partition ....

easy way to find it is

for IDE-drives

fdisk -l /dev/sdX | grep swap

for SCSI ...


Old 12-06-2002, 01:15 AM   #3
LQ Newbie
Registered: Dec 2002
Location: Auckland
Distribution: Mandrake 9.0
Posts: 4

Original Poster
Rep: Reputation: 0

Hi Tink,

That didn't work. The contents of my frive space appears as follows
Device Boot Start End Blocks Id System
/dev/ide/host0/bus0/target0/lun0/part1 * 1 388 3116578+ 83 Linux
/dev/ide/host0/bus0/target0/lun0/part2 389 2434 16434495 f Win95 Ext'd (LBA)
/dev/ide/host0/bus0/target0/lun0/part5 389 438 401593+ 82 Linux swap
/dev/ide/host0/bus0/target0/lun0/part6 439 2434 16032838+ 83 Linux

which seems kind of weird to me, I haven't seen these kind of paths before?!?

So when I tried adding the following line to my fstab:
/dev/ide/host0/bus0/target0/lun0/part5 swap swap defaults 0 0

I still get the error 'Invalid argument' when booting.

NB. I get just the same error, if after booting I do the following command:
[root@localhost mark]# swapon -a
swapon: /dev/ide/host0/bus0/target0/lun0/part5: Invalid argument

Any idea what's going on here? - it's got me stumped.

Old 12-06-2002, 12:23 PM   #4
Registered: Dec 2002
Location: North West England
Distribution: fedora
Posts: 52

Rep: Reputation: 15
If you have the src installed take a look at
(might be under /usr/src/linux ) ?
Otherwise google for it
Apparently the device names have changed under defvs to give more flexibility for ide & scsi instead of the old /dev/hda & /dev/sda
Can you check your version of modutils ?
rpm -q modutils
and check mkswap --version


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
how to reduce swap space and reclaim the space grantm Linux - Newbie 7 08-16-2012 08:05 AM
problem with swap entry in /etc/fstab? kpachopoulos Linux - General 1 10-26-2005 05:19 PM
How to unmount actual swap and mount a new(bigger) swap space? isaac Linux - Newbie 1 06-06-2004 02:23 AM
linux booting problem with non-initialized swap space the_twister Linux - General 1 09-04-2003 01:11 PM
swap-space fstab problem MarkGraham Linux - Newbie 0 12-05-2002 08:06 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:16 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration