To have an administrator privileges, you have to add the user to sudo group.
Log in to your Ubuntu server using your root account or a sudo user if you already have.
While on the terminal type this command:
adduser your_username or sudo adduser your_username
Assign a password. Enter it twice. Now that you have created a user, we can proceed to add it to sudo group
Adding the user to sudo group:
usermod -aG sudo your_username
Swith to the the newly created user:
To make a test, type:
sudo ls -la /root
It will ask to enter the user password. If you got it right, you will see files displayed. But if it is not successful, you will get this report:
ls: cannot open directory ‘/root’: Permission denied