1

I have installed Ubuntu 20.04 and I love it: it's really fast and great. However I have some software that is not yet supported and I need to have Ubuntu 18.04 on the same computer. What would be the best option to achieve it? Do I need to start from clean disk to make new partition? What about a Ubuntu 18.04 virtual machine?

Thank you

ldias
  • 2,055
redpill
  • 13
  • 1
    We don't know what the "best" option for you is, since we don't know your constraints or preferences. Since this seems to be question about VMs, then the obvious answer is to create an 18.04 VM right beside your 20.04 VM(?). If you clarify what your question really is, we can offer better advice. – user535733 Apr 25 '20 at 15:34
  • I just wanted to ask : " How to install Ubuntu 20.04 on the same drive with ubuntu 18.04? " but I saw this related question. I have sdb1 as / ext4 for 20.04 and sdb4 with sdb5 as / ext4 and sdb6 as /home ext4 on my drive. I installed 20.04 using live cd and command "ubiquity -b" command to install without boot loader. That formatted sdb3 (swap) and sdb1 partitions and the installation finished. Them I ran "sudo update-grub" and the new installation appeared. My problem is that I receive the "no init found error" when I try to boot into the new 20.04 installation. – marius-ciclistu May 03 '20 at 20:24
  • Also if you happen to have 2 hard drives on your computer, the issue disappears if you can install each ubuntu distribution on a separate drive, with its separate swap, root and maybe home partition. – marius-ciclistu May 03 '20 at 20:27
  • I just solved my issue by booting into the 20.04 with Avanced from GRUB and then with the second from the top option. I'll post an answer as a summary. – marius-ciclistu May 03 '20 at 21:10

3 Answers3

2

1. How to install Ubuntu 20.04 on the same drive with ubuntu 18.04:

Use a separate partition as / (root) ext4 on the same drive:

example sdb4 as / ext4 and sdb5 as /home ext4 for 20.04 and sdb2 as / ext4 and sdb3 as /home ext4.

sdb1 (swap) will be used for both distributions.

UPDATE: I installed also with bootloader and it worked ok. If you install with below ubiquity -b then when the kernel is updated in the installation that was installed without grub (20.04 in this example), the "old" grub is not updated.

Install 20.04 using live cd -> try ubuntu -> in terminal run command ubiquity -b to install without boot loader (grub).

Reboot into the old distribution 18.04 and run in terminal sudo update-grub.

Reboot after the update finishes.

Choose Advanced for 20.04. Then second option from the top.

2. If you happen to have 2 hard drives on your computer:

Install each ubuntu distribution on a separate drive, with its separate swap, root and home partition.

Note UPDATE: for 2nd option and first with boot loader:

When you update the kernel in one of the distributions, the default grup will be the one that was last updated by the kernel update and the default Ubuntu from the top of the GRUB will be also the one that had its kernel updated last.

Example: Given the above situation your grup will have:

Ubuntu

Advanced...

Ubuntu 20.04

Advanced...

...

...

You update the kernel on 20.04 =>

Ubuntu

Advanced...

Ubuntu 18.04

Advanced...

...

...
marius-ciclistu
  • 262
  • 6
  • 19
0

If you want 18.04 on the same computer, you've two options: either create a virtual machine or dual boot Ubuntu 18.04 with current 20.04.

The best option depends on your system specifications. Like, if you have a better processor, high ram, and free space, the best option would be a virtual machine. For the same, you can either use VirtualBox or GNOME boxes.

Secondly, you can also dual boot by allocating space for Ubuntu 18.04 that will utilize the system resource power as an individual operating system.

For a better answer, can you elaborate on your system specs?

sarru1291
  • 792
0

Create installation media for Ubuntu 18.04 and install it alongside your current installation. Use the 18.04 installation solely for the software that you need and then when your software supports 20.04, you can delete the 18.04 partition.

ldias
  • 2,055
  • What happens when you install 20.04 alongside 18.04? On which partition gets installed the 20.04? For example I want it to be on sdb1 while 18.04 is on sdb5. – marius-ciclistu May 03 '20 at 20:30
  • @marius-ciclistu If I understand correctly, you already have 20.04 installed and wish to use software that is only compatible with 18.04. When you boot from the installation media, select install alongside ubuntu 20.04. I also believe you can manually choose where to install. Above all back up your data and don't format/create partitions unless your 100% sure of what your doing. – ldias May 03 '20 at 22:22
  • @Idias My situation was opposite. I have 18.04 that supports php 7.2 for example. The new 20.04 will only support php 7.4, so I need both distros on the same drive. I installed 20.04 as I described above, on a new partition. Now I wait for a kernel update in 20.04 to update the GRUB, or overwrite the grub from 18.04 so that 20.04 will be the default. I was curious of how the "alongside" works in term of partitions, because I suspect it will install the new OS in the same partition with the old ubuntu. – marius-ciclistu May 04 '20 at 07:41