Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Whenever a command is "unable to lock the administration directory", is there any way to easily detect what process is running that is using sudo?

share|improve this question
up vote 2 down vote accepted

in a terimnal, enter top command. you can see the list of processes and the second column is the user that is running the process. check that column for root. Also you can filter the processes with respect to the user running them. To show all processes being run by root, enter top -u root.

share|improve this answer
look for dpkg, synaptic, or similar processes. Its typically something that is accessing package stuff that generates that error. – Thomas Ward Mar 26 '11 at 15:49

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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