If you're using other Linux distributions
like Red Hat, CentOS, Fedora, when you install those
distributions even Kali Linux, you can install server version or desktop
version and you can install both server and desktop version in graphical user interface mode.
But in Ubuntu, when you install Ubuntu server, it does not include graphical user interface and
the reason is obvious. Because server is optimized to handle specific services and designed to run
server oriented tasks by careful allocation of resources. But if you want to install GUI in your
Ubuntu server for some reason, maybe you find some application easy to manage using GUI, you can
easily add desktop environment in your server. Since Ubuntu 20.04, it uses the same kernel
for both desktop environment and server version and that means you can use same packages in both
versions interchangeably and you can easily switch from desktop version to server and vice versa
if you need to consider the resources. But just keep in mind that desktop environment consumes
more resources than text-based server version, and if you want to take advantage of desktop
environment but want to use minimal resources you can use some of the lightweight display
managers like slim or lightdm. The default display manager for Ubuntu is a gdm3, which uses
more resources, it's more resource intensive display manager than the other lightweight
managers that I just mentioned. And if resource is not an issue for you, I recommend you getting
gdm3. So in this video, I'm going to show you how to install graphical mode in your Ubuntu server
by using gdm3 as a display manager and we'll use Ubuntu default desktop environment which is Gnome.
So let's get our repository up to date first. In Ubuntu, you can use "sudo apt-get update" to
update your repository and we can run another command after that is done using && sign and "sudo
apt-get upgrade" will actually upgrade your system and -y will answer yes if it will ask you yes
and no questions. So asking me for my password. And after our repository is up
to date, we are going to install the "tasksel" utility which allows us to install
the related package automatically using text user interface and comes very handy when we install
display manager and desktop environment later. So let's do that. Let me clear the
screen. "sudo apt-get install tasksel" Yes. So this is where upgrade
-y answered yes for me. And it's done. So next step would be installing
a display manager. which takes care of loading desktop environment and also authenticate users
in GUI environment and we're going to install the default display manager which is gdm3. But if
you want to install lighter version you can use a slim or lightdm. "apt-get install slim or lightdm"
and hit enter. In our case, I'm going to do gdm3 yes And our next step would be actually installing the
desktop environment. So we updated our repository, upgraded our system for latest packages, then
installed "tasksel" to select the tasks that we're going to install later and just installing display
manager gdm3. And after this is done, we are going to install default desktop for Ubuntu, which is
Gnome desktop. A lot of packages and libraries uh and dependencies to be installed and this
is why you have to be careful when you install GUI in your server, because it can take a lot
of resources and your server might be overloaded or it might take away some resources that you can
allocate to some other services otherwise. So it's good to learn but I'm not sure if it's a good
idea to have your server running with the desktop environment all the time, because when you are
remoting into your server, usually using SSH, you will not get the graphical mode even if you
have graphical mode installed in your servers. In my case this Ubuntu is installed in VirtualBox
along with other machines but I have installed latest Ubuntu on my laptop which is a dual boot
system with Windows 10 and I have started using Ubuntu desktop primarily. It looks like that is
finished. So now let's install the Gnome desktop, and for that we just have to run the "tasksel"
from command line. Do "sudo tasksel". So now it's uh giving us the text base
interface to select the packages we need. You can use up and down arrow key to move your
selection and when you reach to the package that you want to install, just hit the spacebar and
the asterisk will be displayed and then hit tab to go to the "OK" button and just install. So
you see on the, list you have a lot of other options; Ubuntu minimal desktop, Ubuntu MATE
desktop, that's also another desktop environment and we're going to install
Ubuntu desktop so click OK. So a lot of packages. So let's fast forward. Okay we're almost there,
95% done. It's done now and let's go ahead and start the service. "sudo service
gdm3 start". I see the mouse here. So this is without reboot. There you go. So this
is it. This is how you can install or convert your text based Ubuntu server into graphical
user interface desktop. We have a Home, file manager and then you have a Trash and all
that and then you can access terminal from here. And if you want, you can add it
to the favorite. Right click and click on add to favorite so it will stay
on this left side and I usually like to turn off the bell so it
doesn't give me the annoying bill sound when there's a
problem with the command or, and my favorite is
gray on black, scrolling I usually turn off and that's it. You can actually hit f11 to go to the
full screen mode, f11 come back again and then let me restart because my
display setting is not optimized. So resolution. Okay let me
try this one. Much better. So it looks like I didn't
have to restart. Here you can change background, appearance,
how you want to do notifications. So you can customize your desktop in many
ways. So let me restart the server. I just want to make sure that the
graphical mode comes up by default. Okay as you saw that graphical mode
came up as a default and you can use Software Update here to install any
new software or update your software using graphical user interface mode.
You don't have to run apt-get commands. And one thing you'll notice on Ubuntu is, let me
run this update first and I'll show you. So Ubuntu has started installing snap as a part of packages.
So snap is a bundle of packages which has all the dependencies and libraries bundled together so
you don't have to worry about the dependencies and library. So Ubuntu Software installer by
default launch and install snaps but if you want to install in a traditional way, you can
always do "apt-get install" command. The only problem with the snap is the space. I'll create a
separate video and talk about how to clean up your Ubuntu machine, desktop or server, especially
if you're running into desktop environment. I just talked about space and then it gave
me this error. So I have option to examine. So it's giving me how this space is being used.
So it could be my snap and maybe the cache also. And it could be the journal log. 136 MB not that much.
How about snaps. So 314 MB. It will start building once you start
using more and more. So this video is just about how to install graphical user interface or desktop
environment in your Ubuntu server which does not have a graphical user interface. And since you
already saw that as soon as I installed and ran graphical user interface, my system gave me the
error message that I'm running out of the space. So in my next video, I'm going to create and
list few steps that you can take to clean up your Ubuntu server or desktop environment. So
this is it for this video. I just wanted to show you how to convert your text base
Ubuntu server into into a graphical mode and use like a Windows computer. So if you're
liking my videos or format that I'm creating since last few weeks, let me know in the comment
box and if there's any topic that you think I should cover in the server, networking,
cybersecurity, firewall and cryptography, you can tell me that in the comment box as well
and I'll try to cover them as much as I can. Until then, take care and thanks for
watching. I'll see you in the next video.