Share your knowledge at the LQ Wiki.
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 03-06-2012, 06:54 AM   #1
LQ Newbie
Registered: Oct 2011
Posts: 20

Rep: Reputation: Disabled
Post Configuring swapfile error

I installed oracle linux 6 on my desktop but I forgot to configure the swapfile, I want to install oracle 11gr2 on it and it requires 2gig or ram, if I type the following commands on the terminal I get these

[root@localhost ~]# grep MemTotal /proc/meminfo
MemTotal: 1789764 kB
You have new mail in /var/spool/mail/root
[root@localhost ~]# grep SwapTotal /proc/meminfo
SwapTotal: 0 kB
[root@localhost ~]# df -k /tmp
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda4 100704696 5106508 90482644 6% /
[root@localhost ~]# df -k
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda4 100704696 5106508 90482644 6% /
tmpfs 894880 100 894780 1% /dev/shm
[root@localhost ~]#

How do I set the swap file to the required ram for oracle installation which requires 2gig any ideas on how I can go about it?
Old 03-06-2012, 07:00 AM   #2
Senior Member
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,748
Blog Entries: 11

Rep: Reputation: 233Reputation: 233Reputation: 233
You need a free partition on your disk. Check with fdisk -l

After verifying or creating a free partition (I'd say 4G of space is sufficent) you create your swap partition with mkswap /dev/name_of_your_part

Edit /etc/fstab and add the swap partition (Here is one for reference)
[root@casnode1 ~]# cat /etc/fstab
/dev/VolGroup00/LogVol00 /                       ext3    defaults        1 1
LABEL=/boot             /boot                   ext3    defaults        1 2
tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0
/dev/VolGroup00/LogVol01 swap                    swap    defaults        0 0
Activate the swappartition with swapon -a or reboot

Or is there some special "swap" for oracle itself?
Old 03-06-2012, 09:23 AM   #3
Senior Member
Registered: Jul 2007
Location: Directly above centre of the earth, UK
Distribution: SuSE, plus some hopping
Posts: 4,070

Rep: Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896Reputation: 896
Originally Posted by zhjim View Post
You need a free partition on your disk. Check with fdisk -l
Well, that isn't really correct. If you were going to use a partition for swap, you would need a partition, but the OP asks about a swap file, and you don't need a separate partition for that. Now
  • The use of a separate partition is more traditional in Linux and used to have significant performance advantages, but, some time ago, Andrew Morton claimed that the perf advantages no longer apply to any great extent. So, you might choose a swap file...but I don't know anyone who does, so I can't personally comment on any perf difference, or no. Just, there were some once, and the only people who use swap files are either Windows refugees who don't know better, or people who messed up partitioning and want a quick 'save' for the error....
  • It isn't really clear why the OP is asking about a swap file rather than a partition; is it a case of following some tut that talks of a swap file, or is it 'hadn't thought about it'?

and it requires 2gig or ram
I am reading that as '2 Gigs of RAM', although that could be wrong.

Note that, if it really uses 2 Gigs on a continuous basis, and you think that adding a little swap will just make the issues go away, that is probably wrong.
  • Actively using swap would slow things down; maybe that's tolerable, maybe it isn't. Really nothing about what has been said so far would answer that question
  • Adding swap to barely reach the minimum requirement may be problematic if anything else on this machine also takes a chunk of memory

Of course, you could get away with this if either
  • the requirement for RAM is an installation requirement, that isn't met in day-to-day use (but maybe the day-to-day requirement is larger, depending on what you are doing, and if you are running a large database, or databases, it probably will be)
  • this is something like a trial install or dev machine, which won't see much traffic and for which a little slowness isn't too high a price to pay


installation, linux, oracle11g

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
[SOLVED] Invalid swapfile Basher52 Linux - Software 2 04-27-2011 04:36 PM
using dapper swapfile unisol Ubuntu 1 12-27-2006 07:11 AM
How do I get my swapfile to work? Mr. New Linux - Newbie 2 01-01-2005 12:37 PM
SuSe swapfile Pond247 Linux - Newbie 0 09-19-2003 03:17 PM
Swapfile Shantesh Linux - Software 2 09-11-2003 09:11 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:48 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration