LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
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!

Notices


Reply
  Search this Thread
Old 03-09-2012, 07:11 AM   #1
chetan_linux
Member
 
Registered: Aug 2008
Posts: 61

Rep: Reputation: 1
swap


Hi,

I have added a new disk to production server. How to make it visible to os and how to configure it. I also want to add some space from that disk to swap space. Please help me out.
 
Click here to see the post LQ members have rated as the most helpful post in this thread.
Old 03-09-2012, 09:25 AM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 6,577
Blog Entries: 14

Rep: Reputation: 969Reputation: 969Reputation: 969Reputation: 969Reputation: 969Reputation: 969Reputation: 969Reputation: 969
What is your Linux distribution (e.g. RHEL, Suse, Ubuntu etc...) and version?

What is your current disk configuration? (e.g. partitions, logical volumes, metadisks) Providing a "df -h" output would be helpful.

How much swap do you currently have? (Run "swapon -s").
How much memory do you have? (Run "free" to get an approximate amount.)
How much swap do you want to add?
Why do you want to add swap?
 
3 members found this post helpful.
Old 03-09-2012, 11:26 AM   #3
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 17,916

Rep: Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689
Quote:
Originally Posted by chetan_linux View Post
Hi,

I have added a new disk to production server. How to make it visible to os and how to configure it. I also want to add some space from that disk to swap space. Please help me out.
Again, as with many of your other threads, have you even tried to look anything up? Just putting in "how to add swap space in Linux" into Google pulls this up:
http://www.thegeekstuff.com/2010/08/...dd-swap-space/

As MensaWater pointed out, you don't provide any details about your setup, so we can't be specific. Also, if you took your RHCE three years ago, shouldn't you know such things?
 
Old 03-09-2012, 12:38 PM   #4
smilemukul
Member
 
Registered: Jun 2009
Distribution: Redhat,CentOS,Ubuntu,Puppet
Posts: 292

Rep: Reputation: 34
The new disk can be visible to OS (Redhat,Fedora & CentOS) by running, echo - - - > /sys/class/scsi_host/host0/scan & new partition will be visible in fdisk -l or cat /proc/partition.Also first you have to create a partion from your new disk & then space partion/file will be created through mkswap & swapon
 
Old 03-09-2012, 09:00 PM   #5
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 6,577
Blog Entries: 14

Rep: Reputation: 969Reputation: 969Reputation: 969Reputation: 969Reputation: 969Reputation: 969Reputation: 969Reputation: 969
Quote:
Originally Posted by smilemukul View Post
The new disk can be visible to OS (Redhat,Fedora & CentOS) by running, echo - - - > /sys/class/scsi_host/host0/scan & new partition will be visible in fdisk -l or cat /proc/partition.Also first you have to create a partion from your new disk & then space partion/file will be created through mkswap & swapon
Unless he's using metadisks or LVM which is why I asked OP to answer questions about existing setup before blindly giving such advice.
 
1 members found this post helpful.
Old 03-10-2012, 04:26 AM   #6
smilemukul
Member
 
Registered: Jun 2009
Distribution: Redhat,CentOS,Ubuntu,Puppet
Posts: 292

Rep: Reputation: 34
The same can also be checked or scanned for new disk if they are not visible to the OS & this is not necessary that for this LVM is required as the mentioned command is used for scanning the added disk if they are not visible without reboot.
 
Old 03-13-2012, 08:49 AM   #7
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 6,577
Blog Entries: 14

Rep: Reputation: 969Reputation: 969Reputation: 969Reputation: 969Reputation: 969Reputation: 969Reputation: 969Reputation: 969
Quote:
Originally Posted by smilemukul View Post
The same can also be checked or scanned for new disk if they are not visible to the OS & this is not necessary that for this LVM is required as the mentioned command is used for scanning the added disk if they are not visible without reboot.
Perhaps but you also wrote:
Quote:
first you have to create a partion from your new disk & then space partion/file will be created through mkswap & swapon
I was suggesting that the OP didn't give us enough information to help and that your response might not be correct depending on his setup if he isn't just using partitions already.
 
  


Reply


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
Gparted says swap has 5 Gb, grep SwapTotal /proc/meminfo says swap has 800 Mb rickrandall Red Hat 3 02-24-2010 01:09 PM
Use Windows pagefile.sys (swap) as Linux swap? bluesword1969 Linux - General 3 02-19-2010 03:35 PM
Can swap file or a swap partition be mounted and read? Mr-Bisquit Linux - General 3 06-08-2009 03:16 PM
Linux swap / solaris not appearing as swap in Ubuntu? Erik_the_Red Linux - Newbie 1 07-30-2005 01:57 PM
How to unmount actual swap and mount a new(bigger) swap space? isaac Linux - Newbie 1 06-06-2004 02:23 AM


All times are GMT -5. The time now is 01:07 AM.

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