Download your favorite Linux distribution at LQ ISO.
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 10-16-2009, 03:48 PM   #1
LQ Newbie
Registered: Apr 2009
Location: Toronto, Ontario, Canada
Distribution: Fedora 11 X64
Posts: 8

Rep: Reputation: 0
Is it possible to Move and utilize root /boot and Swap dir to temporary location?

I'll start by explaining what my system layout currently is.

I have Fedora 11 X64 installed on my system, it is an HP Dv9380ca laptop. My system has 2 hdd /dev/sda /dev/sdb. During the setup i set my home directory to reside on /dev/sdb. After booting i realized that my root and swap partition are part of a volume group name vg_sharpfed and are set in fstab as:

/dev/mapper/vg_sharpyfed-lv_root / ext4 defaults 1 1
/dev/mapper/vg_sharpyfed-lv_swap swap swap defaults 0 0


Output of Fdisk -l /dev/sda

Disk /dev/sda: 120.0 GB, 120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x1aecda8d

Device Boot Start End Blocks Id System
/dev/sda1 * 1 26 204800 83 Linux
Partition 1 does not end on cylinder boundary.
/dev/sda2 26 14593 117013441 8e Linux LVM

My /dev/sda2 partitions is 100gigs and set as an LVM. Essentially what i am getting at is, if it's possible to temporarily copy / /boot and swap to my second partition, edit grub if needed and fstab to mount to the temp locations, format sda to ext4 create partitions for / /boot and swap partitions, then copy back the original directories edit required fstab to mount the original locations and no longer have them contained in a Logical volume.

Is it possible to do this at all? If so what method is best.

Old 10-16-2009, 04:06 PM   #2
Senior Member
Registered: Mar 2004
Location: UK
Distribution: CentOS 6/7
Posts: 1,375

Rep: Reputation: 217Reputation: 217Reputation: 217
Swap shouldn't be a problem, as there is functality to create swap partitions around, and if sda2 is an LVM then you can resize it and add the Swap within the LVM. /boot can't exist within an LVM I am afraid and grub itself would need to be reconfigured (possibly reinstalled) to see another location for /boot as to the current directory. You can make a back-up of the /boot configuration and copy it back later if that's what your getting at but this may not correctly refer to your new set-up if you are creating new partitions and moving everything around. backing up the data you want to keep and reinstalling from scratch, unless you have ALOT of data would probably be a less painful experience (even tho it sounds like a more painful one...).
Old 10-16-2009, 04:30 PM   #3
LQ Newbie
Registered: Apr 2009
Location: Toronto, Ontario, Canada
Distribution: Fedora 11 X64
Posts: 8

Original Poster
Rep: Reputation: 0
So essentially it is a more tedious process then a simple reinstall...I guess that is my best option...Well thank you for your quick response, and i'm going to go with you backup/reinstall suggestion.
Old 10-17-2009, 03:05 AM   #4
Registered: Jan 2009
Location: Canada
Distribution: CentOS 6.3, Fedora 17
Posts: 247

Rep: Reputation: 51
First, is there any particular reason why you don't want to stick with the LVM2 (which is the default install). It will give you flexibility in expanding your / filesystem in the future by adding drives/partitions.
As said in previous post it is much easier just to reinstall if you don't want the LVM rather than doing all that temporary copying, especially if it's a fairly fresh install. Luckily your home is a separate drive so you won't lose your personal settings. Just use your current /home during the new install.


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
Web Root Dir Change and New Dir Added issue in CentOS 5 Ginnyz Linux - Server 2 06-01-2009 09:29 PM
notification-daemon temporary file location? eleifsp Linux - Software 1 01-27-2009 01:33 AM
location of temporary files in linux ritam_bkp Linux - Newbie 5 11-13-2008 01:41 PM
Move swap from SAN boot disk to local gbarnas Linux - General 3 02-21-2006 10:28 AM
Setup is unable to find a hard disk location to store temporary files. Klas Linux - Software 2 02-14-2006 07:47 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:15 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