Having 2 different UM on same disk

Hello.

After a project run longer then it should have I'm finally able to backup all my stuff and now I wanna do clean install of Ubuntu MATE 16.04, however I want to keep my existing install of 15.10 32 bit untouched for now and maybe later on I can install 16.10 on that part of the disk.

This is my current setup

I would like to have separated /home partition and also / or whatever is needed for OS to run. Is 20GiB enough or would it be better if it would be 40GiB for root? Should I use something more?

I would first need to shrink the existing sda1 right? Should I also format newly created partitions?

For swap I can just leave it as it is and don't need another one?

If my other (old) OS is 32bit, can I still make the new install of 64bit or is it better or less painful to install 32bit system?

I can go straight to usb boot and live session worked well I just don't have many experience with creating partitions and don't want to do something wrong and break system I also haven't install 64 bit system before.

Another question, when I install UM 16.04, will I still be able to see or use stuff that are saved on 15.10 or would be better to move those things on external disk and then move it on /home partition once installed?

Before doing anything, back up all personal files.

Log in a live session with your installation CD. Use Gparted to shrink your existing OS to leave an empty space on the drive. Then click the install icon on the live session desktop and choose “other” in the installation dialog. Then choose the empty space. You will also need to set your boot to “” on that space. You don’t need to touch swap. Once installed and logged in, you will also be able to access your home folder in your original installation’s partition from your second installation.

If you have not done this before, I would recommend doing a test run with it in Virtual box. That is to say, install UM. Then insert your ISO back into the virtual CD drive and reboot and then install UM again alongside the first installation. If you do this and it all goes well, you will then have the confidence to repeat it on your bare metal machine

Yes there is no problem in having both 32bits and 64bits distros on the same disk, grub will find them both and you will be able to boot in any of this.

Yep, you only need 1 swap, just leave it as it is, because if you format it, there is a chance that the UUID of the partition will change and then you will have to edit the /etc/fstab file

Indeed you need to shrink the first partition. You can do it from the live ubuntu by choosing try instead of install, then make the changes with gparted and do the installation after. The UUID of the first partition will change and I’m not sure if the installation of the new bootloader will fix this or if you will have to edit the fstab file (maybe someone can clarify this, or if you don’t want to wait just try it and if you can’t boot in your first installation then editing the fstab can be done really easily).

PRO TIP::stuck_out_tongue:
I’ve been experimenting with multiple distributions the past week and this is what I would do myself.

  1. Leave as little as possible for your first partition (in your case I would leave about 250 GB).
  2. For a / partition I usually give 70-100 GB, so give at least 40 if you don’t want more. I would create a 100GB / partition and a 500GB /home partition for your 2nd installation.
  3. For other installations (3rd,4th,…) just create / partition when you install them.
  4. The important part (if you wanna do it like a pro) ::stuck_out_tongue:
    On all the installations use the same username with the same uid and gid (I’m not sure if the username matters or just the uid).The first user on ubuntu has uid=1000 and gid=1000 by default so don’t change it (run id in terminal in order to find your uid and gid).
  5. After the installation is finished, move all your files from your first partition at your /home partition you created.
  6. On all your installations make them to mount the rest partitions at startup.

EXPLANATION:
Why did we do all that? First of all /home partition is really useful in order to keep your files safe (so even if your system breaks, you can reinstall it without loosing your files). So, what about steps 4-6? The uid is important to be the same on all users so that you can read the files on the rest partitions with the same permissions and not as just read only (if I have understood correctly, the files at ext partitions carry the owner and the permissions with them, it’s not like the ntfs partitions when you give them permissions the moment you mount them). So, now that you have done that, you can delete, for example, the folder ~/Documents on the first installation and create there a link to the Documents folder of the second installation’s /home partition. In that way you will have all your files in one place without wasting hard disk space. Furthermore, as you have user permissions at the other installations folders, you can create links to some configurations files as well.

Sorry if I wrote too much (you only asked simple questions) but I will finish that by describing my setup (maybe that way you understand anything of the above, because I can’t even understand it myself in the way I wrote it) :stuck_out_tongue: :

I have a 100GB / partition and a 200GB /home partition for my Ubuntu MATE installation. I also have 70GB / partition for my manjaro installation and a 70GB / partition for my openuse installtion. All my files are in the Ubuntu MATE’s /home partition. As you see in this image: http://imgur.com/a/mK35v on my manjaro home folder, most of the folders are links to my Ubuntu MATE home patition (so even if I have all my files accessible, the manjaro partition is only 20gb full). I also have links of the .thunderbird folder (which have the email profiles), the steamapps folder (so that the steam games are downloaded only once) and several other folders which I know the configurations doesn’t change between distributions. That’s why I recommend you to use 1 large home partition with all your files there and create the same user on all the other installations. That’s a short answer :stuck_out_tongue:

I backup most important stuff already, but just remembered that I still need to look into one folder for the things I might still need.

I like your idea to test it first in Virtual box. I already have installed UM 16.04 32bit from .iso, but can't get 64bit installed the same way as I get this message


Can't get it installed trough usb either, because Virtual box doesn't recognise my bootable usb.
Any ideas what I'm doing wrong?

Thanks for the long replay @ThanosApostolou I don't mind it being long, if it's explained well, I usually make quite long post too :wink:

I don't really know what fstab is or how to change it, a bit to technical for me right now, so not that easy... And If someone knows more please share.

Leave as little as possible for your first partition (in your case I would leave about 250 GB).
That's as little as possible for you?

Well I'm thinking if I will have to format this partition once I will get rid of 15.10 for 16.10 or so I don't really need 250GiB for it, so maybe it would be better to just delete stuff from now and move them to external disk and then back into home partition once I manage to create it?

How much empty space should be left on that disk then to function normally?

So everything from username to computer name should be the same in new install?

create there a link to
Ah that what this is for I was wondering once what that means/does...

I like the sound of it having all in one partition, like home, but will see how will I manage to do that, when I get that far.

The reason you cant install the 64 bit version after installing the 32 bit version on Virtualbox will be because, when you installed the 32 bit version on Virtualbox, you must have chosen a 32 bit CPU.

The thing you need to know is that a 32 bit OS can be installed on a 64 bit CPU. But, a 64 bit OS cannot be installed on a 32 bit CPU. This wont be a problem on your bare metal machine, whichever OS you install first, so long as your bare metal machine is 64 bit.

Ok yeah if you move your files to an external disk first then you will probably need less than 100gb (move them first and see how much space is neeeded).

Don’t worry about fstab now, if there is a problem ask here and we will help you.

The message you see means either that you have wrong settings at the virtualbox (you probably chose 32bit installation when you created the virtual machine) or that your CPU only supports 32bits and not 64bits operating systems. Post the output of the command lscpu (you should see something like CPU op-mode(s): 32-bit, 64-bit if the cpu is 64bits capable). If your cpu is only 32bits, then you can only install 32bits operating systems on that system unfortunately (maybe it’s time for hardware upgrade) :stuck_out_tongue:

Yes, that must have been the case. I will try one with 64bit CPU. Could do one install, but then my pc froze, I guess I was doing to much stuff at once, without thinking things trough first.

I was in process of doing just that when my pc stopped responding... the only thing working are sound&video from some livestream window and I can move mouse around but can't click on anything.

I have checked and it does support both 32bits and 64bits as it should, it's about 1,5yyears old and only ever run Ubuntu MATE on it :grin: Even my old laptop have option to run them both, but it has overheating problems so it was easier to just install 32bit on it.

Hopefully I can get it to stop somehow and then try again tomorrow when I won't be sleepy, because I notice I do to many mistakes or things just half way then.

1 Like

My Laptop is running UM on 61GiB ext4 partition of 120GiB SSD. Works just fine. The other 59GiB ext4 partition works just as well with another Ubuntu os. Both are 32bit versions and sharing a 4.3GiB swap. I use flashdrive or portable SSD to save important files to for backup.

See also:

I can't seems to get it to work on virtual box already... hopefully it will be better on actual disk later on.

So I get to the live session of Ubuntu MATE 16.04 64bit and tried to resize disk using gparted and got this error:

Is this only virtual box problem or can I have it later with my disk too? How to fix it?

Ok, I move most of my stuff on external drive, which means it's only about 73GiB used space now, so if I wanna make it own partition would 100GiB be enough free space left on that partition?

I’m not sure about the error. But if you see it on your real hard disk then you can run fsck manually to fix your problems (for some reason gparted demands a newer version, but it’s not necessary). If that’s the case, then the command I prefer to use is fsck.ext4 -f -y /dev/sda1 (assuming that /dev/sda1 is the problematic partition). For more info take a look here: https://help.ubuntu.com/community/FilesystemTroubleshooting.

100GB should be just fine, especially if you do what I described above (with the links and all that). But it depends of what you want to do. Because if don’t do the thing with the links then, for example, a modern game can take over 30GB space of its own nowadays so you may run out of space soon.

Ok, where do I put that into if it happens?

By changing partitions, this OS I have now (15.10) will be the default one? And then it will be another root and home partition after?

Ok, I haven’t played any new games in a long time, so I think I’m safe there, I will just have it for some testing/checking things out if it wont work in virtual box.

So I guess I can’t really use @stevecook172001 advice to try it first in virtual box.

I’m hoping all will go well trough and I will have some time to do it tomorrow.

The error is because you re trying to do stuff with the partition while it is being used and mounted. You have to boot a CD or thumb inside the VM.

First:
* You only need 1 partition for / for the system, all the other stuff goes inside it (/boot, /home, /swap)
* You can use 1 swap for all OSs.
* You can use 1 home for all OSs.
* You may not use swap or even make a partition for it.
* A partition for swap is preferable for different reasons.
* Partitions for other hierarchical parts of the system may be preferable (/home, /boot, /var/log).

If you want my recommendation, MBR is not a very good option for what you want. Use GPT, and do it now that you backed up everything: the wrong with this is that you wont be having your system 15.10. The good i that if you design the final setup then you can put it to work and you won’t behaving problems because you have already sort it out in the designing phase.

Why you wouldn’t achieve what you want? Because MBR Only allows you to have 4 partitions (in your case because adding more partitions to your extended partition is like nothing, a partition of 4GB?). If you want 3 OS in your drive as it is now, the most you’d get is this:

/15.10
/16.04
/16.10
/extended
/swap

No home as you want except if you do something like this:

/ 15.10
/16.04
/home
/extended
/swap


With a GPT partition table you can make 128 partitions, all of them primaries, but you can configure it to be able to put a lot more. This way you could make lots of partitions and lots of OS. Below just a simple :

/15.10
/var/log
/15.10
/var/log
/16.04
/var/log
/home
/BackupPartition
/swap


note: you can have partitions on different drives too and applies to MBR option too with its restrictions.

I finally manage to install new OS with new / and /home partition. The only difference is that I used 32-bit install, because I couldn’t get rid of uefi :angry: even if I disabled/enabled everything I should have it still wouldn’t let me do the “normal” install… Could be that because I never had Windows on it I couldn’t get to some advanced uefi setups. Then I just had enough after few hours and go for 32bit.

So I had to replace 64bit for 32bit usb stick and that didn’t work well at first, because it gave me message “Missing OS” when I used Unetbootin to create bootable USB (worked the first time with 64bit) and then use Mint Stick which worked great and I could finally install UM 16.04 in less then half an hour including doing/changing all the basic settings and install programs I use the most trough Welcome screen :smile:

Thanks @malwaredpc for your explanation, but that’s just a bit to complicated for me and I only wanted 2 OS to work together and so far that’s working fine.

Thanks @wolfman I used your tutorials quite a lot as it has lots of photos in it to make it clearer.

Also thanks to @ThanosApostolou and @stevecook172001 for all your help and @FatDad47 for sharing the way you use it, sadly I don’t own any ssd card yet.

3 Likes