Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] CASAOS mount external drives only in read only, then requires editing too many files to override this. #1103

Open
PeterRichardsWA opened this issue May 21, 2023 · 25 comments
Assignees
Labels
bug Something isn't working

Comments

@PeterRichardsWA
Copy link

Describe the bug
when adding a large external drive with casaos, on my newly acquired ZIMAboard system, i had to jump through hoops to mount the drive in read/write mode for use as a PLEX media server in order to be able to add and delete files as needed to manage the library.

when mounting a drive using the storage manager, this process should be automated in the GUI from the web page to make it monumentally easier to work with. the drive was a pre-existing exFAT drive with 12 TB of movies on it, so moving all the data off, then reformatting with casaos, and then loading them back on would have taken a very long time.

To Reproduce
Steps to reproduce the behavior:
mount an external exFAT drive and attempt to write data to it. cant be done unless you edit the conf file for mounted drives during the linux boot up.

Expected behavior
i would expect a more robust mounting tool other than the one provided on the web gui. it is so basic its painful. even when I DO mount a drive using this tool, it constantly barks at me on reboots that the system has "found new storage" and prompts me to mount it again, even though its mounted.

Screenshots
none needed

Desktop (please complete the following information):
mac os ventura 13.4
imacpro/macbook pro 2021 m1 max
chrome/duckduck/safari

Logs

run following command to collect corresponding logs:
logs are unneeded as this is a known issue with exfat drives on linux. there is a way to get around it, but it requires editing a few files that only a very confident and experienced user would know how to do. not someone using casaos web front end.

@PeterRichardsWA PeterRichardsWA added the bug Something isn't working label May 21, 2023
@sanyer
Copy link

sanyer commented May 25, 2023

I'm experiencing issue of the same kind.
But while NTFS is mounting properly as rw, hfsplus keeps mounting as ro even after installing needed packages.

@LinkLeong LinkLeong assigned LinkLeong and unassigned tigerinus May 26, 2023
@LinkLeong
Copy link
Collaborator

What is your version of casaos?

@sanyer
Copy link

sanyer commented May 29, 2023

@LinkLeong v0.4.3

@LinkLeong
Copy link
Collaborator

@PeterRichardsWA Sorry to take so long to reply to you, we have been working intensively on the problem, I understand that there are two problems
1:The disk is mounted normally?
2: by manually mounting the message will still pop up?

@LinkLeong
Copy link
Collaborator

I'm experiencing issue of the same kind. But while NTFS is mounting properly as rw, hfsplus keeps mounting as ro even after installing needed packages.

Are you talking about permission issues?

@sanyer
Copy link

sanyer commented Jul 5, 2023

I'm experiencing issue of the same kind. But while NTFS is mounting properly as rw, hfsplus keeps mounting as ro even after installing needed packages.

Are you talking about permission issues?

I don't know what exactly you mean, but the symptoms of my problem are the same as the issue reporter's.
The only difference is that I use HFS-formatted drive instead of exFAT.

@LinkLeong
Copy link
Collaborator

LinkLeong commented Jul 6, 2023

We perfected the problem of mounting a disk without partition, I don't know if it applies to your problem, can you take a screenshot of lsblk? By the way, mark which disk is not mounted properly.

@geofbirchall
Copy link

Having the same issue. Added the drive and reformatted as ext4. Was unable to add the drive to the merged storage. The checkbox was underwater. Opened a cli window and reformatted from there. Drive was mounted as RW and everything was good.

@sanyer
Copy link

sanyer commented Jul 8, 2023

We perfected the problem of mounting a disk without partition, I don't know if it applies to your problem, can you take a screenshot of lsblk? By the way, mark which disk is not mounted properly.

❯ sudo lsblk
[sudo] password for casaos:
NAME         MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda            8:0    0   1.8T  0 disk
└─sda1         8:1    0   1.8T  0 part /mnt/Storage1_EXT_DISK
sdb            8:16   0 931.5G  0 disk
├─sdb1         8:17   0 786.1G  0 part /media/BIG_HDD
└─sdb2         8:18   0 145.4G  0 part /media/casaos/BIG_HFS
mmcblk0      179:0    0  29.1G  0 disk
├─mmcblk0p1  179:1    0   512M  0 part /boot/efi
├─mmcblk0p2  179:2    0  27.7G  0 part /
└─mmcblk0p3  179:3    0   977M  0 part [SWAP]
mmcblk0boot0 179:256  0     4M  1 disk
mmcblk0boot1 179:512  0     4M  1 disk
❯ mount
...
/dev/sdb2 on /media/casaos/BIG_HFS type hfsplus (ro,nosuid,nodev,relatime,umask=22,uid=1000,gid=1000,nls=utf8,uhelper=udisks2)
...

@raller1028
Copy link
Contributor

raller1028 commented Jul 20, 2023

@sanyer What partition types are mounted by /media/casaos/BIG_HFS
Can you provide me with your /etc/udevil/udevil.conf ?

@sanyer
Copy link

sanyer commented Jul 20, 2023

@raller1028 partition type hfsplus and udevil.conf is standard, I didn't change it. I also never heard about this file. I can see that it supplies default mounting options for different file systems and I also see that it has nothing for hfsplus, I'll try adding.

Ok, udevil.conf didn't change anything, but if I run sudo mount -t hfsplus -o remount,force,rw /media/casaos/BIG_HFS it gets properly mounted as rw.

@raller1028
Copy link
Contributor

@sanyer If there are no other problems, could you please close this?

@sanyer
Copy link

sanyer commented Jul 31, 2023

@raller1028 But was this fixed?

@raller1028
Copy link
Contributor

image
@sanyer Sorry to take so long to reply to you. We tried to mount 2 hfsplus formatted disks using automount, and both were rw. Can you try the way we formatted the disks, and then automounted them after formatting, to see if there is still a read-only problem after mounting?

formatting commands

 apt install hfsprogs
 mkfs.hfsplus /dev/sda1

@sanyer
Copy link

sanyer commented Sep 24, 2023

image

@sanyer Sorry to take so long to reply to you. We tried to mount 2 hfsplus formatted disks using automount, and both were rw. Can you try the way we formatted the disks, and then automounted them after formatting, to see if there is still a read-only problem after mounting?

formatting commands


 apt install hfsprogs

 mkfs.hfsplus /dev/sda1

I will try remounting again. Will first update system and restart. But formatting might be tricky, I'll have to find where to store the files.

@johnbbbbbb
Copy link

I'm also experiencing the same issue with an exfat drive mounted and not being writable. This is on a fresh install of CasaOS 0.4.4.2.

mount gives:
/dev/sdb2 on /media/devmon/MediaServer type exfat (rw,nosuid,nodev,noatime,uid=300,gid=1001,fmask=0022,dmask=0022,iocharset=utf8,errors=remount-ro)

I'd be happy to provide any other info that may help solve this issue.

According to this post exfat drives should mount with dmask=0002,fmask=0113 but I'm very far from experienced on this, just relaying my search results.

I'd also be interested to hear if there is anything I can do to fix it before an eventual update.

@sunbird-sameer
Copy link

Disable the "automount usb drive" from the casaos UI's settings and reboot.

Screenshot 2024-03-11 174834
Screenshot 2024-03-11 174841

The Problem is mainly caused because the casaos install automounts the drive, which the base os is supposed to do automatically,
thus preventing r/w rights of the normal users and causing the problem.

This is the explanation I assume.
And the Solution WORKS.

@bzumik1
Copy link

bzumik1 commented Jun 2, 2024

I am facing exactly same issue, fresh installation of ubuntu server and casaos.

@sunbird-sameer
Copy link

sunbird-sameer commented Jun 3, 2024

I am facing exactly same issue, fresh installation of ubuntu server and casaos.

Server device??
Ubuntu lite or desktop environment?

Try this (mentioned above)
https://youtu.be/pi9LfXtVqqA?si=-6ag6HUj2t6wS1Xy

@bzumik1
Copy link

bzumik1 commented Jun 3, 2024

Thanks @sunbird-sameer I got it working by disabling the auto mount and mounting the drive manually. But still this bug needs fix.

@sunbird-sameer
Copy link

As CasaOS is designed mainly for zima board, I think they kept it toggled on by default, as I believe even though it is running on debian back-end, a lot is done through the CasaOS interface

@gudge25
Copy link

gudge25 commented Aug 22, 2024

same here on debian OS
/dev/sdb on /media/devmon/sdb-usb-ST1000LM_024_HN- type exfat (rw,nosuid,nodev,noatime,uid=300,gid=1001,fmask=0022,dmask=0022,iocharset=utf8,errors=remount-ro)

only devmon have full access
image

where we can change devmon automount options ?

@gudge25
Copy link

gudge25 commented Sep 20, 2024

sorted with applying latest /etc/udevil/udevil.conf from developer site
and use umask=0000 in order to have 777 permissions

@sanyer
Copy link

sanyer commented Sep 25, 2024

sorted with applying latest /etc/udevil/udevil.conf from developer site and use umask=0000 in order to have 777 permissions

Could you please elaborate more on this?

@gudge25
Copy link

gudge25 commented Sep 25, 2024

sorted with applying latest /etc/udevil/udevil.conf from developer site and use umask=0000 in order to have 777 permissions

Could you please elaborate more on this?
external storage is mounted by udevil
here is their site https://ignorantguru.github.io/udevil/

and here is latest file version

https://raw.githubusercontent.com/IgnorantGuru/udevil/ce9f1c5f811e34913b050aed193a39a63ac81e73/etc/udevil.conf

so what I did. i save current udevil.conf as udevil.conf.bak
replaced original with file from github

and first trued to. mount /unmount manually in order to check errrrs (/dev/sda in my case)

sudo udevil mount /dev/sda
sudo unmount /dev/sda

after there were no errors during mount try
and no errors in

grep devmon /var/log/syslog*

I restarted and now it is mounted with 777 permission

@sanyer думаю має бути зрозуміло зараз

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

10 participants