0

I have installed Ubuntu-desktop 20.04LTS on my laptop. Now I would like to have Ubuntu server. I can download Ubuntu server 22.04 or 20.04 from ubuntu.com. I do not want to lose any files that I have on Ubuntu-desktop.

Is there a way of doing this? And can I pick Ubuntu server 22.04 or do I have to stick with 20.04?

Will the Ubuntu server replace the Ubuntu desktop or do they go together?

johannes
  • 147
  • I had a desktop installation on 20.04lts … when I replaced the computer, I used the original as a Minecraft server for my son & his friends. I don’t think you’ll experience any loss of performance using your desktop installation as a server. If you do want to change to server, I’d suggest back up all your files, perform a clean install of Ubuntu server (which will lose your files), then replace your files from backup. – Will Jun 11 '22 at 19:48

1 Answers1

2

A good way to think about "Desktop" and "Server" is that they are really just different default installations of a preselected group of packages.

Of course:

  • Desktop: Focuses on packages that would be useful to an end-user. Besides the graphical desktop itself, it includes browsers, file managers, productivity applications, etc. etc.

  • Server: Much more minimal installation. Designed to be run and operated in a headless environment (i.e. without a monitor).

Both of these have a set of packages that are common to both (e.g. Bash, Systemd). In fact, Server is practically just a subset of Desktop, although there are a few packages in Server that aren't in Desktop -- Things like tmux which, again, are designed for a command-line oriented experience.

With all that in mind, the idea of "installing Server" on top of (or even replacing) Desktop doesn't really make much sense.

Once you've installed either Server or Desktop, there's nothing that prevents you from installing any package in the Ubuntu repositories. So if there's a daemon that you want, just install it under Desktop -- It will work the same regardless.

I originally thought you might want to replace Desktop with just a server installation, but given your final sentence:

Will the Ubuntu server replace the Ubuntu desktop or do they go together?

That doesn't seem to be the case.

It's also possible to go "the other way." If you had originally installed Server, you could install the graphical applications from Desktop without needing to reinstall Ubuntu itself. See this question for details.

And can I pick Ubuntu server 22.04 or do I have to stick with 20.04?

You do need to be using packages from one release. If you need a package from 22.04, it's best to upgrade to 22.04. If you can wait, the supported LTS-to-LTS update will be available August 4th, 2022. At that point, you can:

sudo do-release-upgrade

If you need it now, you can use the -d/--devel-release option to force an upgrade:

sudo do-release upgrade -d
NotTheDr01ds
  • 17,888
  • 2
    Nowadays the desktop is the server edition plus the desktop itself. Since systemd there is only 1 switch where the system decides to start a tty session or to start the desktop component. All other settings are identical. – Rinzwind Jun 11 '22 at 19:26
  • 1
    @Rinzwind Mostly. As of 22.04 even, Server still includes (for example) tmux by default, but Desktop does not. So Desktop isn't a true superset of Desktop; just mostly, right? – NotTheDr01ds Jun 11 '22 at 19:38