cannot remount /dev/sda2 read-write, is write-protected
From the comments...
You don't need to install smartmontools
to check SMART status. Just start the Disks
application, select the disk, select SMART Data & Tests
.
@heynnema I selected Smart Data & Tests
and I try the tests
in the Overall Assessment I have Disk is OK, 5776 bad sectors
Because of the number of bad sectors, your hard disk may be defective.
Be prepared to backup your data, if possible.
However, lets try the following test.
To check the file system on your Ubuntu partition...
- boot to the GRUB menu
- choose Advanced Options
- choose Recovery mode
- choose Root access
- at the # prompt, type
sudo fsck -f /
- repeat the
fsck
command if there were errors - type
reboot
If for some reason you can't do the above...
- boot to a Ubuntu Live DVD/USB
- start
gparted
and determine which /dev/sdaX is your Ubuntu EXT4 partition - quit
gparted
- open a
terminal
window - type
sudo fsck -f /dev/sdaX
# replacing X with the number you found earlier - repeat the fsck command if there were errors
- type
reboot
Slim
I'm a passionate fullstack javascript engineer, and I'm always looking for new things to learn.
Updated on September 18, 2022Comments
-
Slim over 1 year
I'm using ubuntu 16.04LTS on intel Core i3-6006U, 2.0GHz Asus pc.When I boot the pc I realized that there are some hard drive problems and it's not able to boot on ubuntu. I tried the answer mentioned in this question: fsck error on boot: /dev/sda6: UNEXPECTED INCONSISTENCY; RUN fsck MANUALLY and I run this command:
fsck -fy /dev/sda2
After that I rebooted the pc and it's able to boot on ubuntu successfully.However when I run :
apt-get update
I got many warnings and errors mentioned that
the file system is read-only
.I tried different propositions mentioned in this question: How to fix “sudo: unable to open … Read-only file system”? such as:
sudo fsck -Af -M
-
mount -o remount /
it returns :mount: cannot remount /dev/sda2 read-write, is write-protected
and the other solutions mentioned in the question but no vain.How can I fix this? Should I reinstall ubuntu or does this due to a hardware problem?
-
Fabby about 6 years
sudo apt install smartmontools
then asudo smartctl --all /dev/sda
What's the output? Please edit your answer and put the output there. -
Slim about 6 years@Fabby I'm not able to install smartmontools
-
Fabby about 6 yearsWhat's the error message?
-
Slim about 6 years`E: failed to fetch tn.archive.ubuntu.com/ubuntu/pool/main/s/smartmontools/… Could not open file /var/cache/apt/archives/partial/smartmontools_6.4+svn4214-1_amd64.deb - open (30: Read-only file system) [IP: 91.189.88.162 80]
-
Fabby about 6 yearsSorry, I should have said: Boot from a live USB and do that there...
-
Slim about 6 years@Fabby I'm using another pc to ask my question because I'm not able to open neither a browser neither to plug a usb key to copy the error into a file and paste it in my question.
-
dpb about 6 years@para008 -- he means, boot up to a live USB version of Ubuntu, and run the commands there. Your disk has the possibility of being damaged, and that is what @Fabby is wanting you to check with
smartmontools
. This page may also be interesting... help.ubuntu.com/community/DataRecovery -
Boris Hamanov about 6 yearsYou don't need to install
smartmontools
to check SMART status. Just start theDisks
application, select the disk, selectSMART Data & Tests
. -
Slim about 6 years@heynnema I selected Smart Data & Tests and I try the tests
-
Slim about 6 yearsin the Overall Assessment I have Disk is OK, 5776 bad sectors
-
anonymous2 about 6 yearsWith that many bad sectors, it could well be your hard drive which is causing you problems.
-
Slim about 6 yearsI tried this but it does not work and I'm not able to reinstall ubuntu from a bootable usb key.I think that the hard disk was defected.
-
Boris Hamanov about 6 yearsI didn't ask you to reinstall Ubuntu. Which of the above methods in my answer did you try, and how far did you get? Did you receive any error messages?
-
Slim about 6 yearsI tried the second and I didn't get any errors
-
Boris Hamanov about 6 yearsIt sounds like your hard disk is bad. Connect an external USB hard disk drive or flash key, boot to a Ubuntu Live DVD/USB, and backup your important files to the external.