You cannot be logged in as the current user you are renaming, so do one of the following…

Replace oldname with your old username and newname with the new username…

  1. Rename the login username: usermod -l **newname oldname**
  2. Update the home directory: usermod -d /home/**newname** -m **newname**
  3. Update primary group: groupmod -n **newname oldname**
  4. Rename the full name: chfn -f "**FULL NAME**" **newname**
  5. Logout and login as new user: logout

Disable root account (if you enabled it):

  1. Delete the password: sudo passwd -d root
  2. Lock the account: sudo passwd -l root