I am working on an ubuntu 16.04 LTS,
The computer I am working on is temporarily in my possession, given to me by my employer. So at some point I have to give it back.
What exactly should I consider while cleaning up my activities before giving the computer back. I know about Dash history and cleaning that.
But is there anything else in particular that I need to consider to take care of? I don't wanna leave any trace of my activities behind.

  • Sudo apt-get install bleachbit -y – hello moto Jul 14 '18 at 10:07
  • @hellomoto .. and how should that command help ? – Soren A Jul 14 '18 at 10:17
  • Would it be an option to do a fresh install of 16.04 before returning the computer? – PerlDuck Jul 14 '18 at 15:01
  • Bleachbit runs an easy graphical version to clean up unused files and folders – hello moto Jul 15 '18 at 11:26
  • Delete all files in your user's home folder. Don't forget the hidden ones.
  • Use

    find / -user you_user_name

    to see if there are any other files belonging to your user and possibly remove them.

  • If you can use sudo: Check the log files in /var/log/ and maybe delete them.
  • This only finds files, who wants to do that manually, add in: find / type -user -exec rm -rfi "{}" \; – hello moto Jul 17 '18 at 10:04

The most reliable way to clean all of the user activity traces is to delete its current account completely and recreate it. But first it's worth to wipe securely your sensitive data to avoid its recovery in the future.


If your home directory resides in a HDD, clean sensitive files with wipe utility. Install it:

sudo apt install wipe

Wipe files, for example, run for the file verysecurefile.odt:

wipe verysecurefile.odt


wipe -h

for additional information on wipe using. If your home directory is on SSD - wipe is useless. The only SSD encryption can protect it from deleted data recovery.


Assume your current user name is bob and you want to remove safely all of its data, to be sure all of its activity traces is wiped.

Create second user alice:

sudo adduser alice

Change alice's shell to /bin/bash

sudo chsh -s /bin/bash alice

Add alice to sudo group

sudo adduser alice sudo

Log out from bob's account and log in as alice using Ubuntu GUI. Open terminal being in alice'saccount session and run:

sudo userdel -r bob

to wipe all of the bob's activity traces - the account itself, home directory etc. Create bob's account again:

sudo adduser bob

Change bob's shell to /bin/bash

sudo chsh -s /bin/bash bob

Add bob to sudo group

sudo adduser bob sudo

Log out from alice's account and log in as bob. From recreated bob's account session open terminal and delete alice's account completely:

sudo userdel -r alice

That's all.

  • Thanks for all the answers, this is what I was looking for, multiple options. – Dude Jul 15 '18 at 20:45

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.