💥 10 Things You MUST DO After Installing Ubuntu Server 20.04 LTS

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello everyone welcome to skills built training youtube channel my name is sanya and this channel is all about showing you how to become an it pro fast so today we are going to discuss about 10 things you must do after installing ubuntu server 20.04 lts so let's get started [Music] ubuntu is one of the best linux distribution among all because of its feature so we will explore its server today and we will see what we can do after installing ubuntu 20.04 lts server the first thing that you can see here when you will install server you need to log in first login so here you need to write your username and then you need to write your password and then hit enter now here you can see welcome to ubuntu 20.04 lts now if i talk about the command prompt then the first thing that you can see here is the user name in my case it is sanya and then you can see the name of the server that is ubuntu whereas at the read symbol followed by the server name now here is the colon and then after it you can see the tilde it represents the directory i'm working in while the current directory is the home directory now if you want to see what's your current working directory you can simply write pwd and then hit enter and now here you can see right now i'm in the home directory so the first thing that you should do after installing ubuntu server is update and upgrade whenever you install an operating system or a server the first thing that you should do is update your system so for that you need to write sudo apt update and then hit enter it will ask for sudo password 132 packages can be upgraded so in order to upgrade the system you need to write sudo apt upgrade and then hit enter in order to continue press y as you can see server has been upgraded successfully now in order to change this to take effect you can restart your system so in order to reboot the server you need to write sudo reboot and then hit enter the next thing that i'm gonna tell you about is unattended upgrade packages in server there are few unattended upgrade packages that are installed by default although it is good to update and upgrade system manually but server should have unattended upgrade packages to update the processes as well so for that you need to write sudo apt install unattended hyphen upgrades and then hit enter it will ask for your pseudo password now it will allow the server to restart itself to complete the update procedure but to do so we need to install another packages too so write sudo apt install update hyphen notifier hyphen common and then hit enter now let's talk about server configuration so the next thing we are going to do is we are going to configure our server first we will do and configure application configure directory so for that you need to write cd forward slash etc forward slash ept forward slash ept dot conf dot d and then hit enter now we are in the new directory here you can see we were in the home directory before but now we are in this particular directory now if you want to see the content of the file you need to write ls and then hit enter now here you can see all the content that is present in this directory you can explore all of them one by one but i'm going to explore only few of them now to open any file in the editor to configure it you can use the nano command to open the editor so the first file that i'm gonna show you here is 50 and attended upgrade so for that you need to write pseudo nano 50 and attend it hyphen up crates and then hit enter now here you can see in this file you will be able to see different parts and i will explore few of them well the first part that i want to explore is unattended upgrade allowed origins basically in this file you need to check whether the few parts that are important they are working or not like if they are comment you can uncomment them and you can change few values inside them so if i talk about the first part that is unattended upgrade allowed origins then here you can see distro id distro code name security here you can see it is working properly and it is not a comment now coming down here you can see distro esm applications distro code name application security while it is also working properly and here the last line in this particular area is distro id esm distro code name infra security so basically in this section i was checking about the security well i want to see that if any line of code here is comment then i can make it and comment and i don't need to change any value here so it is perfectly okay now if i come towards the second part that is automatic reboot line now you have two ways either you can scroll down to search for it and it will take a lot of time or you can simply search for it by using control plus w command once you will click control plus w here you can see a search bar open here and here you can search for a value you can search for automatic reboot line and then you can hit enter now here you can see automatically reboot without confirmation you can see the first statement that is the file variable run reboot required is found after the upgrade it is comment will leave it as it is now if i come towards the next code that is unattended upgrade automatic reboot falls so the first thing that you need to do is make it uncomment and now after that change here the value false as true go here remove this value and make it true now this area is perfectly okay if you scroll down a bit here you can see unattended upgrade automatic reboot time and here you can basically change the time here you can see the time is 2 well you can change this time whatever suits you and you can also uncomment it now this will work perfectly fine now this will be the time when server will restart automatic upgrade now to save the changes press ctrl x and then press y and then press enter now the changes have been saved successfully now if i talk about the second file so for that again write ls to see the list of the files and then hit enter while the next file that i'm gonna explore in front of you is 20 auto up crates so for that you need to write sudo nano 20 auto hyphen upgrades and then hit enter now you can see only two lines here this file contain only two settings when the first line enable auto update and make sure that the software packages are up to date so that the server gets update available packages so here you need to see that the package list is 1 or not because 1 means enable and 0 means disable well if i talk about the second line then it will update itself here you can see 1 which means they are enable and it will upgrade itself and if it is not one you can make it one by simply changing the value now again press ctrl x to exit now if you want these changes to take effect you can reboot your system so for that you need to write sudo reboot and then hit enter now to check the status you need to write sudo system ctl status unattended hyphen upgrades and then hit enter it will ask for your pseudo password from here you can see the active status and then you can end it by simply pressing enter key the next thing that i am going to tell you that you should do after installing ubuntu server 20.04 lts is you can add user account so for that you need to write sudo add user and then you need to write the name of the user i want to write sanya khan now here you need to write the new password that you want to set for this new user after setting the password click enter and here you need to retype the password once you are done with it here you need to write the full name so i'm going to write the full name here and then hit enter now here you can see you need to write the room number well it is perfectly fine if you are not writing any value you can simply click enter it will give you the default value here you can write the fork font well there is no need to write it you can simply press enter it will give you the default value and here you need to write the home phone again enter and other you don't need to write anything here and then again press enter and now here you can see is the information correct well it is correct so you need to press y and then hit enter now here you can see a new user has been created successfully now if i go to the home directory you need to write cd forward slash and then name of the directory that is home and then hit enter this new account has its own home directory as well but you cannot perform admin tasks using this account so if you want to work with admin account in this new account you can create it so and you can also add admin privileges here to do so you need to enter pseudo user mode hyphen a hyphen capital g sudo and here you need to write the name of the account that was essentially sanya khan and then hit enter now here you need to write the password sorry here i didn't need to write the password so again you need to write so here you can see we are in the home directory now this new user has the admin rights so in order to see whether it is working properly or not let's log out first so for that you need to write exit and then hit enter now here you need to log in with the new id sanya han and here you need to write the password now let's try running an admin task in order to see whether it is working properly or not so for that you need to write sudo apt update and then hit enter and here you need to write the password for your this new account and here you can see it is working properly and all packages are up to date now if you want to go back to your original account all you need to do is simply log out so for that you need to write exit and then hit enter now here you can log in from your previous or original account so i'm gonna write its username here and password here now here you can see i'm again able to login from my original account well it is a bit difficult to continuously login and log out so instead of it you can actually switch accounts as well but temporarily so i will show you how you can switch your accounts using su command which means switch user so for that you need to write su and then hyphen and then the name of the account in which you want to switch or you want to switch into that is sanya khan and then hit enter now it will ask for your password i have successfully switched to my new account that was sanya khan so that is how you can actually switch between two accounts and now if you are not sure that you have switched successfully or not then you can actually use another command in order to figure out so here you can write who am i and then hit enter and here you can see the name of the user account that is sanya khan when you are ready to go back or switch to original user you can simply exit from this account and whenever you will log out as it is a temporary switch account so you will be go back to your original account well you can also become a root user in your new account this is helpful if you are willing to run administrative commands one after another it will also save you from typing pseudo command every single time so to switch into the root account you need to write sudo su and then hyphen and then enter now here you need to enter the password for your this new account now once you will do it here you can see from this prompt terminal you are a root user now now let's see whether it is working properly or not before creating a root user or becoming a root user we need to write pseudo apt updates but this time instead of writing sudo all i do is i'm going to write apt updates and then hit enter and here you can see invalid operation so basically it is not working properly while using root account you should remember one thing that you should be very careful so you don't do any damage to your system so exit as soon as possible so you will go back to your original account so clear it you can see another thing here instead of dollar sign you can see the hash sign here basically you are a root user right now so that is why you are able to see this sign here you can also see the list of all the user accounts that are available on your server so to see that list you need to write com10 hyphen you and then hit enter and here you can see all the system accounts that are available here in your server you can also see the accounts that you have created where i am able to see the accounts that i have created sanya and sanya khan now clear it now if you want to change the host name you can either change file installing the server but if you have not changed it then you can change it now it is possible to change it now so for that first you need to write host name and then hit enter now here you can see the host name is ubuntu if you want to see more details about it you need to write host name ctl and then hit enter it will give you complete details about the host name here you can see the host name is ubuntu and you can see the machine id boot id virtualization that is oracle you can see the operating system that is 20.04.3 the latest version and you can also see the kernel and architecture details now if you want to change the host name you need to write pseudo host name ctl set hyphen and here you need to write the host name and here you need to write the name in which you want to change into let's suppose i want to change it as s khan and then hit enter now see the host name of a server you need to write host name and then hit enter and here you can see instead of ubuntu the host name is s khan now here you can see the prompt has not changed yet to see the changes you need to write exec bash and then hit enter and here you can see our hostname has been changed successfully instead of ubuntu i am getting s khan here let's go back to your original account by simply pressing exit and then hit enter now i'm into my original account so clear it first the next thing that i'm going to show you is install secure shell ssh well ssh is a network protocol used for a secure connection between a client and a server each interaction between the server and a client is encrypted enabling ssh will allow you to connect to your system remotely and perform administrative tasks by default when ubuntu is first installed remote access via ssh is not allowed enabling ssh on ubuntu is fairly straightforward so to install it you need to write sudo apt install open ssh hyphen server and then hit enter it will ask for your sudo password in order to continue you need to press y and then hit enter while it has been installed successfully once the installation is complete the ssh server will start automatically you can verify that ssh is running by typing pseudo system ctl status ssh and then hit enter and here you can see it is active and it is running perfectly fine and here you can see some other details about it as well you can see its main id you can see the task and the memory it is using now if you want to disable the ssh server on your ubuntu system you need to write sudo system ctl disable hyphen now and then type ssh and then hit enter here you can see it has disabled it successfully later to re-enable it you need to write sudo system ctl enable double hyphen now and ssh and then hit enter now to check its status you need to write sudo system ctl status ssh and then hit enter and here you can see it is working and it is running now clear the terminal the next thing that i am going to tell you about is how you can add drive you can remotely connect to your server using ssh the first thing you should do is to see the drives connected to server so for that you need to write b ls key and then hit enter now here you can see the drives that are available in your server well i'm looking for the st8 drive currently it has two partitions the first partition is sda1 and the second is st82 well i want to delete a partition and create a new one you can create a new drive layout so for that you need to write sudo g disk forward slash dev forward slash sta and then hit enter here you can see partition table scan you need to press n and then hit enter here you can see the partition number you can create a new partition let's give it a number 1 and then hit enter now again you need to press enter well make things simple create single partitions for that you need to hit enter again you need to hit enter to accept default values now press w to accept and then hit enter you need to press 8 3 0 and then hit enter and here you can see change type of partition to linux file system now in order to see the status of the partition drive you need to write sudo gdisk hyphen l forward slash dev forward slash sda and then hit enter and then clear it now after creating partition we can format the drive as well here i will use ext4 instead of ntfs and fat32 that we use in windows so for that you need to write sudo mkfs.exe forward slash dev forward slash sda and then hit enter you need to press y in order to proceed now you can mount the drive as well unlike windows directories does not start with letters as operating system is present in root directory here we can have the option that is found we can mount drive within root directory first we will navigate this mount or mnt directory so for that you need to write cd forward slash mnt and then hit enter now here you can see we are in the mnt directory now create a mount directory using the mkdir so for that you need to write sudo mk directory and here you can give any name to your directory let's suppose drive 2 and then hit enter in order to see the list of the drives available here you need to press ls and then hit enter and here you can see we have the drive 2. in order to get into this drive you need to write cd and the name of the drive that is drive 2 and then hit enter now we are in the drive 2. in order to create a file in it you need to write sudo touch file and then hit enter now you need to press ls in order to see the content in this drive and here you can see we have the file here now clear it and go back by using cd double dot again cd double dot and then hit enter now clear it again the next thing that i'm gonna tell you is how you can enable firefall by default later versions of ubuntu should come with uncomplicated firewall or ufw you can check to see if ufw is installed or not by using this command to check its status so you need to write sudo ufw status and then hit enter and here you can see the status it is in active it is not installed or enabled now if it is not installed then you can install it simply by running this command sudo apt install ufw and then hit enter or if it is already installed in your system you can enable it simply by writing sudo ufw enable and then hit enter and here you can see firewall is active and enabled on system startup or you can also check its status sudo ufw status and then hit enter and here you can see the status that is active you can also disable it sometimes to perform few functions you need to write sudo ufw disable and then hit enter and here you can see firewall stopped and disabled on system startup now clear the terminal well the next thing that i'm gonna tell you is how you can install node.js well it is used for server-side programming and primarily deployed for non-blocking event-driven servers such as traditional websites and backend api services but was initially designed with real-time push-based architectures in mind every browser has its version of a gs engine and node so i will tell you how you can install it so for that you need to write curl hyphen s l https colon double forward slash deb dot note source dot com forward slash set up underscore eight dot x pipe sign sudo hyphen capital e bash hyphen and then hit enter here you can see deprecation warning it is telling me that it is not the latest version well you can install the latest version as well now clear it now the next thing that you should do after installing ubuntu server 20.04 lts is install enginex enginex is known for its high performance stability rich feature set simple configuration and low resource consumption nginx is open source software for web serving reverse proxy caching load balancing media streaming and more it started out as a web server designed for maximum performance and stability so in order to install it you need to write sudo apt install nginx and then hit enter in order to continue you need to press y and then hit enter nginx has been installed successfully you can also allow the system to take effect of these changes so for that you need to write sudo service nginx restart and then hit enter now clear the terminal so the last thing that i'm gonna tell you that you should do after installing ubuntu server is you should monitor your server yes you can monitor your server resources you can use multiple commands to monitor your server from different perspectives the first command that i'm gonna use is this top command now here you can see all the programs running on your server and using the resources of the server you can also see their id and you can see the user either they are the root user or not you can see the cpu they are using you can see the time and the command now to quit it you can simply press q and then hit enter now clear it and write here etch top and then hit enter it will give you a brief description about the tasks that are running here you can see tasks 32 and few of them are running and you can see the load average as well you can see the uptime cpu memory as well and the resources the programs are utilizing well it will give you a brief description and here you will be able to observe and monitor process more closely now if you want to see the details of a particular program so for that you need to press f3 first and then you need to write the name of the program let's suppose i wanna know the details of stop d and then hit enter it will give you the details of snap t again you need to press f3 and it will give you the details of next one next one next one here you can see i'm able to see all the details of snap t you can see the details about multi-party here you have all the programs that are running right now that is how you can monitor your server and you can see that how much amount of the cpu and server all the programs are consuming so that's it for today i hope you have enjoyed this video if you have any queries reach out to us in the comments below like this video subscribe to our channel and hit the bell icon i'll see you in the next video [Music] you
Info
Channel: SkillsBuild Training
Views: 2,048
Rating: undefined out of 5
Keywords: linux, It tips, ubuntu, It tip of the day, Things to do after installing ubuntu server 20.04, Linux for beginners, After install ubuntu server 20.04, Speed up ubuntu server 20.04, Things to do first ubuntu server 20.04, Customize ubuntu server 20.04, Things to do after installing ubuntu server, After installing ubuntu server, Ubuntu server after install, Ubuntu server 20.04, Ubuntu server 20.04 lst
Id: QBv5_WED2C8
Channel Id: undefined
Length: 28min 20sec (1700 seconds)
Published: Tue Oct 05 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.