LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE
User Name
Password
SUSE / openSUSE This Forum is for the discussion of Suse Linux.

Notices


Reply
  Search this Thread
Old 04-23-2015, 01:19 AM   #1
Chris Gidden
LQ Newbie
 
Registered: Aug 2010
Location: London
Distribution: currently openSuSE 13.2, win7&8
Posts: 4

Rep: Reputation: 0
Rearranging mount points


We have a standard install with version 13.2 and BTRFS in two partitions all except /home in partition one and /home in partition two

/srv is going to be grown substantially so want it to be mounted on partition two and need to be still from root ie /srv

end result should be partition one all directories as before less /srv and partition two /home and /srv.

Can this requirement be met and if so how to move /srv to partition two?
If it cannot be met I suppose it would have to be achieved buy linking which I suppose is a soft link.
Advice would be appreciated
Chris
 
Old 04-23-2015, 02:15 AM   #2
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,847

Rep: Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309Reputation: 7309
I'm really sorry, but do not understand. Can you post the output of the command mount?
 
Old 04-23-2015, 01:06 PM   #3
fatmac
LQ Guru
 
Registered: Sep 2011
Location: Upper Hale, Surrey/Hants Border, UK
Distribution: Mainly Devuan, antiX, & Void, with Tiny Core, Fatdog, & BSD thrown in.
Posts: 5,491

Rep: Reputation: Disabled
You could copy /svr to the other disk, & change your /etc/fstab entry.
 
Old 04-24-2015, 04:12 PM   #4
Chris Gidden
LQ Newbie
 
Registered: Aug 2010
Location: London
Distribution: currently openSuSE 13.2, win7&8
Posts: 4

Original Poster
Rep: Reputation: 0
This would be the relevant part of mount


/dev/sda3 on /.snapshots type btrfs (rw,relatime,ssd,space_cache)
/dev/sda4 on /home type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /srv type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /var/tmp type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /var/spool type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /var/opt type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /var/log type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /var/lib/named type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /var/lib/mailman type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /usr/local type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /var/crash type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /opt type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /var/lib/pgsql type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /tmp type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /boot/grub2/i386-pc type btrfs (rw,relatime,ssd,space_cache)
/dev/sda3 on /boot/grub2/x86_64-efi type btrfs (rw,relatime,ssd,space_cache)

you will see the /srv is mounted on sda3 and /home is mounted on sda4, both directly at the root level.
It is obvious that sda3 can hold all the root directories and subsdirs. The system has mounted the /home directory on sda4. What is not apparant here is that some of directories are actually sub-volumes as well and all is fine except they cannot be moved in the same way across partitions because they are subvols. and partition manager handles some of the operation for the BTRFS.

The crux question is can sda4 have both /home and /srv subvolumes and is it logical. If there was a sda5 the /home on sda4 and /srv on sda5 would be fine. I hope this clarifies my problem I am trying to solve of getting both /home and /srv on sda4.

Last edited by Chris Gidden; 04-25-2015 at 12:26 AM.
 
Old 04-26-2015, 12:27 PM   #5
Chris Gidden
LQ Newbie
 
Registered: Aug 2010
Location: London
Distribution: currently openSuSE 13.2, win7&8
Posts: 4

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by fatmac View Post
You could copy /svr to the other disk, & change your /etc/fstab entry.
this does not work as it is a subvolume
 
Old 04-26-2015, 12:28 PM   #6
Chris Gidden
LQ Newbie
 
Registered: Aug 2010
Location: London
Distribution: currently openSuSE 13.2, win7&8
Posts: 4

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by Chris Gidden View Post
this does not work as it is a subvolume
Also would like it to remain a sub-volume as then snapper will also work well with this in btrfs
 
Old 04-27-2015, 11:57 AM   #7
ember1205
Member
 
Registered: Oct 2014
Posts: 176

Rep: Reputation: 16
The general practice for doing something like this is as follows:

Create the location you want to use as the "new" area. Restart the system from a Live CD or something so that the entire active filesystem is available without locks. Mount the "old" location and the "new" location onto the running system. Copy all of the data from the "old" location to the "new" location. Modify the /etc/fstab of the active system to mount the "new" location instead of the "old" one. Restart.

Why can't you use this method for what you're trying to accomplish here?

Create the subvolume on the second partition/disk, mount it to the active filesystem, copy all of the data over, edit /etc/fstab to mount the new subvolume, reboot.
 
  


Reply



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] enabling KDE to auto-mount devices set to BSD-type mount points in fstab? dchmelik Linux - Software 10 07-18-2015 04:50 AM
[SOLVED] enabling KDE to auto-mount devices set to BSD-type mount points in fstab? dchmelik Calculate 1 07-12-2013 01:47 AM
[SOLVED] NFS mount points don't mount during boot Quakeboy02 Debian 11 06-16-2013 07:11 AM
mount one device to two mount points secretlydead Linux - General 3 03-28-2007 05:30 AM
SCRIPT: check if auto-mount mount-points are still mounted markus1982 Linux - Software 0 05-25-2003 05:48 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE

All times are GMT -5. The time now is 01:59 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
Open Source Consulting | Domain Registration