LinuxQuestions.org
Latest LQ Deal: Linux Power User 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 08-23-2011, 03:14 AM   #1
loveulinux
Member
 
Registered: Aug 2011
Posts: 68

Rep: Reputation: Disabled
How to merge two partitions as one


Hi...everybody
I wanted merge these below two partitions as one, because of less free space in each partition.
/dev/sda5 /data
/dev/sda6 /backup
For this I am thinking to unmount /backup partition & mount the nfs partitions with /backup and mount the /dev/sda6 with /backup_old. Then I will move all of the contents from /backup_old to /backup partition. Next how can I merge /dev/sda6(/backup_old) partition with /dev/sda5(/data) partition. This system is configured with hardware raid with 4 partitons(/, /home, /data /backup). Your kind response would realy be appreciated.

Last edited by loveulinux; 08-23-2011 at 03:16 AM. Reason: How to merge two partitions as one
 
Old 08-23-2011, 03:32 AM   #2
saikee
Senior Member
 
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Blog Entries: 1

Rep: Reputation: 112Reputation: 112
I don't know how the partitioning tools would react to a RAID set up but in a ordinary disk you simply deleted /dev/sda6 and use Gparted to extend sda5 the right hand side border to absorb the unallocated space left by sda6. Since both sda5 and sda6 are logical partitions and sda6 is at the end of the hard disk that will work as none of the two are required for booting.

Back up the data before committing the change.
 
1 members found this post helpful.
Old 08-23-2011, 04:14 AM   #3
loveulinux
Member
 
Registered: Aug 2011
Posts: 68

Original Poster
Rep: Reputation: Disabled
How to merge two partitions as one

Can I use gparted without reboot?


Quote:
Originally Posted by saikee View Post
I don't know how the partitioning tools would react to a RAID set up but in a ordinary disk you simply deleted /dev/sda6 and use Gparted to extend sda5 the right hand side border to absorb the unallocated space left by sda6. Since both sda5 and sda6 are logical partitions and sda6 is at the end of the hard disk that will work as none of the two are required for booting.

Back up the data before committing the change.
 
Old 08-23-2011, 02:41 PM   #4
saikee
Senior Member
 
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Blog Entries: 1

Rep: Reputation: 112Reputation: 112
Couldn't tell you.

I would have thought the change of data-only partitions should have no connection with rebooting. Gparted doesn't normally demand a reboot.
 
1 members found this post helpful.
Old 08-23-2011, 02:59 PM   #5
frieza
Senior Member
 
Registered: Feb 2002
Location: harvard, il
Distribution: Ubuntu 11.4,DD-WRT micro plus ssh,lfs-6.6,Fedora 15,Fedora 16
Posts: 3,200

Rep: Reputation: 397Reputation: 397Reputation: 397Reputation: 397
Quote:
Originally Posted by loveulinux View Post
Can I use gparted without reboot?
you should be able to change data partitions without a reboot, provided they are not mounted (changing mounted partition == bad)

changing the OS partition or swap partition should be done from a live cd however as they can't be effectively unmounted while the system is booted.

just make sure to edit your /etc/fstab when done to reflect the changes to your partition structure otherwise you will run into problems when you DO reboot the system
 
1 members found this post helpful.
Old 08-23-2011, 06:06 PM   #6
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian Jessie 8.4
Posts: 5,873

Rep: Reputation: 348Reputation: 348Reputation: 348Reputation: 348
I'm not certain how RAID handles it, but without RAID, if you change partitions in the manner described, it's best to reboot to reload the partition structure into the running kernel. Otherwise, when writing files into the new partition, you could get error messages about trying to write files beyond the limit of the old partition (as the kernel sees it). Rebooting informs the kernel of the new partition limits and avoids such error messages.
 
1 members found this post helpful.
  


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
[SOLVED] want to merge two partitions manishrajal Linux - Hardware 8 10-20-2010 09:35 PM
Need to merge partitions mruschmann Linux - Newbie 5 08-20-2010 08:00 AM
merge partitions. Bonsai_XYZ Linux - Software 5 07-25-2006 04:04 AM
merge partitions? Leonig Mig Linux - General 2 06-06-2005 12:15 PM
Is it possible to merge two partitions cheetahman SUSE / openSUSE 7 04-10-2005 09:05 PM


All times are GMT -5. The time now is 03:57 PM.

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