Unable to write to new partitions
Colin Watson
cjwatson at ubuntu.com
Sun Mar 18 11:44:21 UTC 2018
On Sat, Mar 17, 2018 at 11:50:32PM +0800, Bret Busby wrote:
> On 17/03/2018, Colin Watson <cjwatson at ubuntu.com> wrote:
> > This is dangerous and you should undo it as soon as possible ("sudo
> > chmod 660 /dev/sda18 /dev/sda19"). Otherwise-unprivileged processes on
> > your system don't need the ability to write to the *device nodes*.
>
> Done. Did not solve problem.
I didn't expect it to solve the problem; it was just a mistake that
needed to be undone.
> Used chmod 666
There's been an awful lot of verbiage on this thread, and while it was
accurate for technical users it didn't clearly and concisely point out
the mistake here, so I'll summarise.
chmod 666 equates to the symbolic mode "rw-rw-rw-", i.e. read and write
permissions for everyone. However, a directory must also be executable
in order to be able to open files inside it. Therefore this should have
been chmod 777 ("rwxrwxrwx").
It's entirely irrelevant which of your multiple installed operating
systems you do this from. The actual storage of owners and groups of
files and directories uses numeric IDs, and root is always 0, so root on
each of your OSes is equivalent for this purpose.
Note that world-writable files and directories are common security
vulnerabilities, and you should consider instead restricting the ability
to write to these file systems to just those users that actually need
it.
Regards,
--
Colin Watson [cjwatson at ubuntu.com]
More information about the ubuntu-users
mailing list