Score:0

Secondary internal HDD keeps changing permission to read only in Ubuntu 20.04

cn flag

I have 2 HDDs:

  • 80 GB dedicated for Ubuntu 20.04
  • 1 TB for storage

The 1 TB HDD keeps changing permission to read only though I have changed it several times using this command:

sudo chown $USER:$USER /mnt/stuff

I am tired of changing it again and again. Why is this happening and what is the permanent solution for this issue?

guiverc avatar
cn flag
If a *file-system* was mounted as RW (read-write) and *flips* to RO (read-only), it's usually a sign of errors/problems being detected on the file-system and the flipping to RO is to prevent data-loss. The messages found in logs will confirm reason for flip. I'd suggest checking drive health (if the drive is good, it's PSU or power-supply is next thing to check). https://help.ubuntu.com/community/Smartmontools
Milind Khobragade avatar
cn flag
@guiverc where can I find these logs to check the reason?
guiverc avatar
cn flag
If it's the current session (ie. since boot), I'd look via `dmesg`. Messages may also appear in systemd journals (`journalctl`) which allows you to look beyond the current session (ie. prior boots)
Milind Khobragade avatar
cn flag
dmesg command shows lot of things. I don't know which information to look at. `blk_update_request: I/O error, dev sdb, sector 522806727 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 0` Is above line means anything ralated to my issue?
guiverc avatar
cn flag
I/O error means the drive maybe failing; so check it's health using the drive's inbuilt SMART (self-monitoring advanced ...) as per the link with the prior command (you didn't say if you're using desktop or server, but if using a desktop you can use GUI tools too to check the health). You should **not** use the drive until you've concluded it's safe to use, as each use maybe bringing it closer to *dead* & SMART reads from chips so won't impair any life left; leaving more life to recover data from the drive.
Milind Khobragade avatar
cn flag
`EXT4-fs warning (device sdb1): ext4_clear_journal_err:5658: Filesystem error recorded from previous mount: IO failure` `EXT4-fs warning (device sdb1): ext4_clear_journal_err:5660: Marking fs in need of filesystem check.` `EXT4-fs (sdb1): warning: mounting fs with errors, running e2fsck is recommended` what to do?
guiverc avatar
cn flag
If it's *logical* errors and not *hardware*; you can `fsck` (file-system check) your drive and any *logical* errors will be fixed & you won't see issues again. Repeated issues usually mean it's hardware though (be it the drive failing, or bad power (good devices behave badly if they don't have good power) etc... Don't bother with `fsck` until you know drive is healthy though (the more you use the drive; the greater data loss you risk)
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.