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

Error shown on terminal:

sudo: unable to open /var/lib/sudo/jianyue/0: Read-only file system
W: Not using locking for read only lock file /var/lib/dpkg/lock
E: Unable to write to /var/cache/apt/
E: The package lists or status file could not be parsed or opened.

if you need more infos, please help.

share|improve this question
Please provide the output of the following command: mount | grep "^/dev". Just to check if your filesystem is mounted read-only – Salem Nov 4 '12 at 15:44
I have pasted the command you have told me to perform. Here is the result : /dev/sda6 on / type ext4 (rw,errors=remount-ro) – owl Nov 4 '12 at 15:46
Try this: cat /proc/mounts. And if you can please use to post output results. – Salem Nov 4 '12 at 16:09
Firstly, thank you for your reply. I have done what you told me to do. Here is the link : . – owl Nov 5 '12 at 9:18
Your Ubuntu was installed in Windows (using Wubi)? – Salem Nov 6 '12 at 13:41

try this in your terminal

sudo rm -rf /var/lib/dpkg/lock
share|improve this answer
Hello. Thanks for your reply. Unfortunately, I got this error : sudo: unable to open /var/lib/sudo/jianyue/0: Read-only file system rm: cannot remove `/var/lib/dpkg/lock': Read-only file system after I ran the command. – owl Nov 4 '12 at 15:47

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.