Problem With Folder Permissions

11 respostas [Última entrada]
theblackpig

I am a member!

Desconectado
Joined: 09/13/2012

Having trouble gaining access to a folder and files.
I have a folder and files backed up on an external hard disc.
They are vmdk files for Virtualbox.
At the moment I cannot change the permissions of them. I've tried as Nautilus root but to no effect. Is ther a apt command that I can use?

lembas
Desconectado
Joined: 05/13/2010

The chown command allows you to change ownership. Start with the folder.

aliasbody
Desconectado
Joined: 09/14/2012

Changing permissions of a folder ? Well if it is an ntfs partition you might not have the ntfs writer tool, if so then do this in the terminal :

sudo apt-get install ntfs-3g

Then mont and unmont the partition and try again.

It it is a Linux-friendly (ext2,3,4 etc.. partitions), you can try the *Chuck Norris Mode* which is very extreme and might not be suitable for the long term (so make sure to take it back to other less permissive permissions once you've done with it), by doing this (I will take the foo.bin file as example) :

Defining Permission

sudo chmod 777 /media/MyMEDIA/foo.bin

But be careful with this one and use it only in last case.

PS: It is only this file, or any other file from the partition?

theblackpig

I am a member!

Desconectado
Joined: 09/13/2012

The disc is formatted fat 32 but there is only one folder and files that appear to be affected.I've tried this -
dhmod/Home/John/Folder Name

but I got the error John not known
What should the path be ?

jbar
Desconectado
Joined: 01/22/2011

chmod xyz /path/to/the/file

You missed the xyz numbers, which set the permissions to the file. And be careful with spaces in the path name, for example, '/home/user/my\ folder' instead of '/home/user/my folder'

Magic Banana

I am a member!

I am a translator!

Desconectado
Joined: 07/24/2010

As far as I know, FAT 32 does not support permissions. Not sure what the 'chmod' would do...

theblackpig

I am a member!

Desconectado
Joined: 09/13/2012

OK , did this

chmod 777/Home/john/virtualbox
and I get
chmod: missing operand after `777/Home/john/virtualbox'

Perhaps I did not explain very well what I'm trying to do.
If I right click on the folder and then on Properties and then on permissions I'm shown as 'Owner'
Down the bottom is a box to be ticked to 'Allow executing as a program'
It won't allow me to tick that box.

Magic Banana

I am a member!

I am a translator!

Desconectado
Joined: 07/24/2010

Are VMDK files supposed to be directly executed? I would believe they are supposed to be opened from VirtualBox.

Anyway, your error was to omit a space between 777 and /home/john/virtualbox and to write /Home instead of /home. But, again, there is no notion of permission on FAT filesystems. That probably explain why you cannot change them.

jbar
Desconectado
Joined: 01/22/2011

You're right. I have just tried to change permissions in a fat32 pendrive and nothing happens after executing chmod.

systemovich

I am a member!

Desconectado
Joined: 07/03/2012

There should be a space between 777 and /home/John/virualbox.

Also remember bash is case-sensitive.

lembas
Desconectado
Joined: 05/13/2010

If the path contains a space, e.g. New Folder it must be escaped

New\ Folder

sphynx
Desconectado
Joined: 11/30/2011

Or the entire expression quoted:

"New Folder"

One can find good documentation starting from https://gnu.org/software/bash/

Also, here is a good introduction to the command-line interface: http://flossmanuals.net/command-line/