How can I mount my photo camera for a write access?

0

I plug a camera to ubuntu 11.10. It is automatically recognized and browsed with nautilus or through terminal. But when I copy files to my camera no copying happened. How can files be written to the camera?

Ayrat

Posted 2011-12-30T18:52:25.190

Reputation: 1

what kind of camera? – Journeyman Geek – 2011-12-31T05:15:49.647

Answers

1

You can choose different ways:

You can give write permission to mounted folder

Let say /media/cam is our mounting dir:

You can give sudo chmod 777 /media/cam -R command to make cam memory recursively writable.

Or you can mount your cam manually by giving read/write option to command, like:

Let say /dev/photo is the mountable device (Porbably it appears as /dev/sd**)

mount /dev/photo /media/cam -o defaults,user,rw

Another way is, if user permission is not granted for write, you can try write files as root:

sudo cp * /media/cam

Note: To identify which device your camera is on it may help to use sudo fdisk -l.
(See: http://www.ozzu.com/unix-linux-forum/accessing-usb-camera-ubuntu-without-gdm-running-t84169.html)

Sencer H.

Posted 2011-12-30T18:52:25.190

Reputation: 961

1chmod will be absolutely ineffective when run on FAT (vfat) filesystems, which all cameras use. The fake permissions can only be set at mount time using umask=, fmask= and/or dmask=. – user1686 – 2011-12-30T19:16:56.447

Of course you are right for non-EXT media, but mount point. If mount point permission isn't set right, can't write file. Even can't read anything.

Also you're right about umask and fmask/dmask. – Sencer H. – 2012-01-02T13:48:18.763

After mounting, the original permissions on the mount point do not matter anymore. They are completely ignored; only the mounted filesystem root's permissions are checked. (At least this is the case on Linux.) – user1686 – 2012-01-02T14:00:54.990

I just tried that with my fat32 formatted USB stick. It's automounted by my user. I logged in with other user and try to reach files in stick. But changedir command gives "permission denied". Then I checked mount point: device mounted by my username and granted full permission for my user, but there are no any permissions for group or guests ;) Looks like without giving permissions to others by my user or root, no body can reach to device... I don't say that is absolute, but it's possible.. – Sencer H. – 2012-01-04T10:13:29.337

0

When you say " no copying happened" you either mean:

1) You get a copy permission denied error

or

2) The files appear to copy over but when you unplug the camera they are not there

For case 1, RecNes's answer about mounting the camera will work fine. For case 2, you are removing the camera before it can finish writing to your camera. Run "sync" in the terminal, then remove the camera once the command completes. Or you can run "Safely remove" from nautilus.

Ark

Posted 2011-12-30T18:52:25.190

Reputation: 54