Results 1 to 7 of 7

Thread: Moving a openSUSE installation, partitions, LVM (new linux user)

  1. #1

    Question Moving a openSUSE installation, partitions, LVM (new linux user)

    New to Linux (from 25 year of Windows with reasonable technical knowledge ) and I would welcome some advice of how to solve an issue regarding how SUSE installs (partitions and not LVM as CentOS) and moving an installation. Many thanks for any advice somebody can offer as to what may seem pretty obvious queries to established openSUSE users.

    To evaluate and choose between CentOS7 and openSUSE 13.2 I installed both on separate hard disks in same machine but have decided to go openSUSE route but wish to effectively move my openSUSE install to the SDD that the CentOS install is on. Situation is:

    • FIRST HDD - a 128GB SDD CentOS7 install -shows two partitions
      (i) /dev/sda1 (524MB) XFS Not Mounted but bootable (? a Rescue partition)
      (ii) /dev/sda2 a 128GB LMV2 PV partition
    • SECOND HDD - a 640GB traditional disk openSUSE installed-shows 4 partitions
      |(i) /dev/sdb1 1MB BIOS Boot
      (ii) /dev/sdb2 2GB - SWAP
      (iii) /dev/sdb3 43GB-(37GB free) EFI System (BIOS Bootable) BTRFS Mounted at Temp
      (iv) /dev/sdb4 595BG (594BG free) XFS basic Data type Mounted at Home
    • THIRD HDD - 250GB - /dev/sdc1 Ext4 - this has Clonezilla images of First and Second HDD

    Aim: Ideally to move my openSUSE installation from 640GB HDD2 to 128GSDD HDD1 in place

    Queries:

    1. CentOS seems to have installed and used much simpler LVM setup (assuming the smaller partition is a rescue). This look simpler as Linux is all is in one logical volume.
      Could I have installed openSUSE in this way (accepted defaults) rather than the multiple patrons it seems to have created?
      Could I change the existing openSUSE multiple partitions into similar system to CentOS or would it need reinstall.
    2. Looking to use Clonezilla to transfer I have created an image of HDD2 but now realise I cannot restore to smaller SDD HDD1 and would have to adjust the partition sizes on HDD2 first so total < 128GB and then remerge and then restore. However which ones can I do and how much as not sure which are which. sdb1 is very small and presumably related to Grub. sdb2 also small 2Gb and is a swap. sdb3 - is there where the OS is located - is 43GB but 37Gb free - how much is it safe to reduce it, if at all (why was 43Gb chosen?) and sdb4 seems to be user data with only 1 GB so easy to reduce and would be left over after the key sdb3 is altered.
      Would this all have been easier if I had used an LVM?
    3. I would be happy to reinstall a new installation of openSUSE to the SDD HDD1— BUT I would like to be able to copy all the settings and software configuration of the existing openSUSE HDD2 setup that I installed to test etc.
      Is there a way to backup settings and installed software of existing setup and copy them to new install.

  2. #2
    Join Date
    Nov 2009
    Location
    West Virginia Sector 13
    Posts
    15,746

    Default Re: Moving a openSUSE installation, partitions, LVM (new linux user)

    Well moving the root partition may be a bit complicated. It can be done but requires some acrobatics

    In any case easiest is to just reinstall to the drive you want root. In the installation you have complete control where everything goes how it is formatted etc.

    All your personal setting is in home in this case /dev/sdb4 apparently Do not format this partition just mount it as /home

    /dev/sda1 I don't know either mount it and see whats there. I doubt it is a rescue partition that is a Windows thing not a Linux thing.

    I assume this is a EFI BIOS based machine. I find it a bit odd that the EFI boot partition is on a separate drive from root which I guess is in /dev/sda2 the LVM partition or is root on /dev/sdb3. It is hard to tell from the info you have given.

    Ok maaybe better info is needed please show (use code tages (# in the html editor) for computer output please)

    gdisk /dev/sda
    gdisk /dev/sdb
    gdisk /dev/sdc
    mount

    That shows exactly what is on the disks and exactly what is mounted

  3. #3

    Default Re: Moving a openSUSE installation, partitions, LVM (new linux user)

    Many thanks. I decided in the end to take your advice and wipe system and do fresh reinstall to HDD sad and not accept default config but to use a LVM. I also took opportunity to chnage filesystem to btrfs etc..

    Only issue so far is when I use KDE partitioner manager to create new partition on sdb or sdc it defaults to owner being root and the single user (jsmith) created on install cannot create new folders or change permissions. I have managed to take ownership but a little hassle from command line. Is this because the single user jsmith is not an administrator and the install OpenSUSE proceedure just creates password for root same as first user?

    The only user of machine will be jsmith, how do I make jsmith and administrator, is this by adding it to the "root group" and will that then allow the user to add folders or chnage permissions even if the owner of partition is root?

  4. #4
    Join Date
    Aug 2010
    Location
    Chicago suburbs
    Posts
    12,631
    Blog Entries
    3

    Default Re: Moving a openSUSE installation, partitions, LVM (new linux user)

    I see that you resolved your main problem. So this is mainly comments.

    Quote Originally Posted by GoGas View Post
    I decided in the end to take your advice and wipe system and do fresh reinstall to HDD sad and not accept default config but to use a LVM.
    I use an LVM (actually an encrypted LVM).

    For your CentOS install, I would guess that "/dev/sda1" was for booting, and to load enough of the operating system to be able to read the LVM. You probably now have "/boot" (from opensuse) on a separate partition and for similar reasons.

    You see the LVM as simpler than having a bunch of partitions. However, most folk see that as more complex. If something breaks on your system and you have to boot a rescue disk, then it is more complicated to access the LVM, while accessing separate partitions is easier. I'm inclined to say that putting almost everything inside an LVM is more elegant but not as simple.

    Only issue so far is when I use KDE partitioner manager to create new partition on sdb or sdc it defaults to owner being root and the single user (jsmith) created on install cannot create new folders or change permissions. I have managed to take ownership but a little hassle from command line. Is this because the single user jsmith is not an administrator and the install OpenSUSE proceedure just creates password for root same as first user?
    Creating a new file system is always going to make it owned by root. That's because only root can create file systems. You were probably asked for the root password to create that file system.

    In a terminal session (at the command line, perhaps running "konsole" in KDE), you can use the "su" command to become root. As root, you can then use the "chown" command to change the owner of the top directory of your new file system. Administration in linux/unix is just different (better) than in Windows. You will get used to it soon enough.

    The only user of machine will be jsmith, how do I make jsmith and administrator, is this by adding it to the "root group" and will that then allow the user to add folders or chnage permissions even if the owner of partition is root?
    That's Windows style of thinking. You can setup the "sudo" command so that you are able to use it without a password or with your own password. The "ubuntu" folk would then call you an Administrator. But "Administrator" is really Windows. In unix, administrative stuff has to be done by the root user.

    The main thing with linux/unix, is that most of the time you don't need administrative privileges. When you do, simply open a command line session (perhaps with "konsole" or "xterm") and use "su" in that command line window. Some people keep one root command line session open, but others don't see a need for that. Some folk setup up public key authentication with the "ssh" command (there's a learning curve for that). And then they can become root with:
    Code:
    ssh root@localhost
    with no password requested. Other people setup "sudo" (you can configure that with Yast). I haven't much use "sudo" myself.

    I'm sure you will quickly find a congenial way of doing admin stuff. In the meantime, you can experiment with the different possibilities.
    openSUSE Leap 15.1; KDE Plasma 5;
    testing Leap 15.2Alpha

  5. #5

    Smile Re: Moving a openSUSE installation, partitions, LVM (new linux user)

    Quote Originally Posted by nrickert View Post
    I see that you resolved your main problem. So this is mainly comments.

    I use an LVM (actually an encrypted LVM).For your CentOS install, ........administrative stuff has t.
    Many thanks for your helpful extensive comments. I have spent some time going through and trying to adopt some of the principles you espouse and I am making some progress. Part of issue is unlearning the way Windows does things and learning the basic principles of linux. In this aspect the minor differences between distro do cause some confusion (CentOS uses LVH by default - openSUSE does not, Ubuntu uses Administratior concept OpenSUSE a does not etc..) These are somewhat minor but do have effects for switching from Windows and after looking around have settled on openSUSE for desktop/Server and Mint for my old Dell 630 - I find Mint the easiest for user transfering from Windows but is obviously not good for looking at integrating linux server (particularly MYSQL) inot Windows domains using AD.

  6. #6
    Join Date
    Nov 2009
    Location
    West Virginia Sector 13
    Posts
    15,746

    Default Re: Moving a openSUSE installation, partitions, LVM (new linux user)

    IMO you should get used to Linux with one distro before trying others. The little differences can get in the way of the general ideas. Underneath the little diferences Linux distros are all Unix

    Note that in Unix everything is a file .

    The difference in how Windows and Linux file systems works is the heart of things. Permissions in Linux are built in from the ground not bolted on as a second thought. A singel root in Liunx versus a different root for each device/partition in Windows (c:,d: etc). Basic ability to bolt on a partition to any point in the FS is easy and reliable in Linux awkward and not reliable in Windows.

    When I say all is a file look in (don't touch) the /proc directory. In there you will see all the process and kernel interfaces exposed etc all virtual files. /dev is all the hardware interfaces again virtual files. You won't find that in Windows LOL

  7. #7

    Smile Re: Moving a openSUSE installation, partitions, LVM (new linux user)

    Quote Originally Posted by gogalthorp View Post
    IMO you should get used to Linux with one distro before trying others.
    Note that in Unix everything is a file .
    This quote you mention I came across elsewhere and found very helpful - it should be displayed in the installation process of all linux distress.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •