In this tutorial, we will guide you on how to disable guest accounts in Ubuntu.
By default in Ubuntu, the guest account is disabled. The guest account is a user account which enables you to use the system with limited permission rights. This how to disable guest accounts in ubuntu tutorial will come in handy for all those users you have created a guest account before and now want to disable it.
Step 1 – Open Terminal
First of all, you will need to login to any account which has full rights to the root account.
Once logged in, open up the terminal application and type in the following command:
“gksudo gedit /etc/lightdm/lightdm.conf”
This command will bring us to the lightdm.conf. As the extension suggests, lightdm is a configuration file.
Step 2 – Edit lightdm.conf
In ubuntu, to turn off guest accounts we will need to edit the Lightdm.conf, which is a configuration file, in order to disable the guest account. Once the request has been sent, you will be asked to type in the password.
Step 3 – Change value to false
With the configuration file opened up, you will see that at the last line, notice that the value assigned to “allow-guest is “true”. Simply change it to false in ubuntu to turn off guest accounts. Save the changes you made to the configuration file in order to proceed further.
Step 4 – Restart desktop session
Now move back to the terminal and type the following:
“sudo restart lightdm”
This will restart the desktop session.
Step 5 – Disabled guest account
Notice at the login screen, there is no guest account. This means that the guest account has been disabled.