|
OpenBSD General Other questions regarding OpenBSD which do not fit in any of the categories below. |
|
Thread Tools | Display Modes |
|
||||
No write permission on USB devices.
With my previous installation I followed this guide, http://daemonforums.org/showthread.p...nt+normal+user, to enabled mounting USB devices and it worked perfectly. This time I followed the same steps, but it is not working completely. I can mount devices, read them and copy files from them, but I do not have write privileges, even when logged in as root.
Code:
$ sysctl -a | grep mount kern.usermount=1 Code:
$ groupinfo operator name operator passwd * gid 5 members root randicus My user is a member of the operator group. Yet, when attempting to write to devices: Code:
Permission denied (13) |
|
||||
Let's look at the requirements for usermount, rather than blindly guessing. Look at the mount(8) man page, which lists three requirements. All three must be satisfied.
Quote:
You have set this. 2. device special file The access rights are not set according to the man page.
3. Ownership of mount point You have not shared this information, but this is also a requirement. |
|
||||
Strange.
The other day I tried to create a mount point under /mnt as per section 1.8 in the guide before creating a ~/home/usb, but an error message was generated. I forget what it was, but I then went the /usb route. I must have made a very small typo that I was too tired to see. I tried it again today and it worked. I now have a mount point in /mnt and write permission to devices mounted there. Quote:
Code:
$ ls -l /dev/sd1i usb brw-r----- 1 root operator I am not that worried though. Since /mnt is now working properly, I have confusion but no problem using devices. |
|
||||
If you are mounting a FAT (MS-DOS) filesystem, there is no concept of owner/group and related access authorizations. Your mount(8) will call mount_msdos(8) -- its man page discusses how owner/group and access permissions are set or overridden at mount time. After all of the override options, comes this, highlight mine:
Quote:
Last edited by jggimi; 30th April 2016 at 01:22 PM. Reason: clarity |
|
|||
I personally prefer to use DOAS
I created an /etc/doas.conf file and added permissions for regular users. For more info take a look at DOAS.CONF(5) example: Code:
permit nopass user as root cmd mount permit nopass user as root cmd umount DOAS is much simpler and accomplishes the same thing with no headaches. |
|
||||
If I understood your situation correctly, then this might accomplish your goals:
$ doas chmod g=rw /dev/sd1i (This only needs to be done once).Then mount the drive: $ mount_msdos -o rw,nosuid,nodev /dev/sd1i ~/usb When you are finished accessing the drive: $ umount ~/usb The next time you plug in the drive, repeat the mount_msdos command. |
|
||||
DOAS is something to consider in the future. For now I was just puzzled why the procedure in that one part of jggimi's guide worked flawlessly last time, but had that small problem this time. The smartest thing I can do is assume I screwed up something somewhere. I gave up trying to get printers working on OpenBSD, because it is too difficult for my non-computer mind, so PEBCAK is a regular occurrence for me. I have no idea what I could have messed up following such a clear and easy guide, but with me anything is possible.
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
write file into usb - operation not supported | threaderslash | OpenBSD General | 8 | 2nd September 2011 04:57 PM |
/tmp on ram write denied | gosha | OpenBSD General | 8 | 29th March 2009 04:46 PM |
Why you should write a guide/howto in XML | J65nko | Guides | 4 | 19th October 2008 07:46 PM |
[F1] write usb modem driver | raixun | Programming | 7 | 17th July 2008 11:06 AM |
[VSFTPD] Can't write in directory | Sunsawe | General software and network | 7 | 1st June 2008 11:29 PM |