Cannot access camera to download photos

Bug #241399 reported by iroli
14
This bug affects 1 person
Affects Status Importance Assigned to Milestone
libgphoto2 (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

After my f-spot was not able to download photos from my camera (it already worked) I foudn out that /etc/udev/rules.d/45-libgphto2.rules was missing. Cameras ended up beeing ownd by root.root.

The following command created the file, but this shoudl be done in a post install script.
sudo sh -c "/usr/lib/libgphoto2/print-camera-list udev-rules mode 0660 group plugdev > /etc/udev/rules.d/45-libgphoto2.rules"

i've tried to reinstall (using dpkg -i /var/cache/apt/archvies/libgphoto2*) and trigger postinstall scripts that way, but taht dd not happen (no error was given), I assume the packages are broken.

regards
roland lezuo

Revision history for this message
Paul Worrall (nicknak) wrote :

Starting with Hardy, Ubuntu no longer uses device file ownership to control access to devices like cameras, scanners & memory sticks. Instead the HAL/ConsoleKit/PolicyKit system allows access to the device file for the currently active user by manipulating the ACLs on the device file. See https://wiki.ubuntu.com/DesktopTeam/Specs/HardyHardwareDetection for more info. The expected behaviour is for the device file to be owned by root.root, but if you use "getfacl /dev/bus/usb/BBB/DDD" you should see an Access Control List that grants your username rw- access.

The libgphoto2-2 postinst script now actually runs "/usr/lib/libgphoto2/print-camera-list hal-fdi > /usr/share/hal/fdi/preprobe/10osvendor/20-libgphoto2.fdi"

Having "said" all that, it obviously isn't working properly for you. To help the devs track down the problem, the following info would be useful:

1. The version of the libgphoto2-2 package you have installed

2. With the camera plugged in and switched on, use "lsusb" to find the Bus and Device number the camera is using and then attach the output of "lsusb -vs BBB:DDD" to this bug report (e.g. lsusb -vs 003:005 > lsusb.txt and then attach lsusb.txt)

3. Attach the output of "lshal" to this report.

Changed in libgphoto2:
status: New → Incomplete
Revision history for this message
iroli (roland-lezuo) wrote :

Okay, sorry for the confusion, the /etc/udev/rules.d is still full of config files and the libgphtot2 package contains an empty /etc/udev/rules.d directory.

libgphoto2-2 2.4.0-8ubuntu7
libgphoto2-port0 2.4.0-8ubuntu7

$ lsusb
Bus 002 Device 014: ID 04a9:30f8 Canon, Inc.
Bus 002 Device 001: ID 0000:0000
Bus 001 Device 003: ID 04f9:0027 Brother Industries, Ltd
Bus 001 Device 002: ID 046d:c016 Logitech, Inc. M-UV69a Optical Wheel Mouse
Bus 001 Device 001: ID 0000:0000

$ getfacl /dev/bus/usb/002/014
getfacl: Removing leading '/' from absolute path names
# file: dev/bus/usb/002/014
# owner: root
# group: root
user::rw-
group::rw-
other::r--

Revision history for this message
iroli (roland-lezuo) wrote :

Okay, sorry for the confusion, the /etc/udev/rules.d is still full of config files and the libgphtot2 package contains an empty /etc/udev/rules.d directory.

libgphoto2-2 2.4.0-8ubuntu7
libgphoto2-port0 2.4.0-8ubuntu7

$ lsusb
Bus 002 Device 014: ID 04a9:30f8 Canon, Inc.
Bus 002 Device 001: ID 0000:0000
Bus 001 Device 003: ID 04f9:0027 Brother Industries, Ltd
Bus 001 Device 002: ID 046d:c016 Logitech, Inc. M-UV69a Optical Wheel Mouse
Bus 001 Device 001: ID 0000:0000

$ getfacl /dev/bus/usb/002/014
getfacl: Removing leading '/' from absolute path names
# file: dev/bus/usb/002/014
# owner: root
# group: root
user::rw-
group::rw-
other::r--

Revision history for this message
iroli (roland-lezuo) wrote :
Revision history for this message
Paul Worrall (nicknak) wrote :

Thanks for reporting this bug and supporting information. I think this bug now has enough information for a developer to look at it so I'm marking it as "confirmed" to let them handle it from here. Thanks for taking the time to make Ubuntu better!

Changed in libgphoto2:
status: Incomplete → Confirmed
Revision history for this message
Jesse (jesse-cleverone) wrote :

Same problem here, also with a Canon camera

jesse@jesseee:~$ lsusb
Bus 005 Device 003: ID 0951:1606 Kingston Technology
Bus 005 Device 001: ID 0000:0000
Bus 004 Device 001: ID 0000:0000
Bus 003 Device 001: ID 0000:0000
Bus 002 Device 005: ID 05e3:1205 Genesys Logic, Inc. Afilias Optical Mouse H3003
Bus 002 Device 001: ID 0000:0000
Bus 001 Device 005: ID 04a9:30b5 Canon, Inc. PowerShot A75
Bus 001 Device 001: ID 0000:0000

jesse@jesseee:~$ getfacl /dev/bus/usb/001/005
getfacl: Removing leading '/' from absolute path names
# file: dev/bus/usb/001/005
# owner: root
# group: root
user::rw-
group::rw-
other::r--

Revision history for this message
Botkin (yupmanno) wrote :

I'm having a similar problem, if not the same. Using a Canon S5IS i can't use gthumb to unload pictures as i did in 7.04, i'm now running 8.10. As you van see below it seems i don't own any

my installed libgphoto2 packages are:
libgphoto2-port0 version 2.4.2-0ubuntu3
libgphoto2-2 version 2.4.2-0ubuntu3

winther@winther-laptop:~$ lsusb
Bus 005 Device 008: ID 04a9:3148 Canon, Inc.
Bus 005 Device 003: ID 0c45:62c0 Microdia Pavilion Webcam
Bus 005 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 002: ID 03f0:171d Hewlett-Packard Wireless (Bluetooth + WLAN) Interface [Integrated Module]
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 004: ID 046d:c01e Logitech, Inc. MX518 Optical Mouse
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

winther@winther-laptop:~$ getfacl /dev/bus/usb/005/007
getfacl: Removing leading '/' from absolute path names
# file: dev/bus/usb/005/007
# owner: root
# group: root
user::rw-
user:winther:rw-
group::rw-
mask::rw-
other::r--

Paul wrote in the first response:
 "The libgphoto2-2 postinst script now actually runs "/usr/lib/libgphoto2/print-camera-list hal-fdi > /usr/share/hal/fdi/preprobe/10osvendor/20-libgphoto2.fdi""

but i don't have that first folder/script. I can find /usr/lib/ but theres no "libgphoto2".

Revision history for this message
Martin Pitt (pitti) wrote :

Rasmus, your bug with gthumb is bug 287689 which was fixed in an update for 8.10.

iroli, jesse, do you still have this problem on current 8.10 plus updates or 8.04 plus updates? If so, please give me the output of "ck-list-sessions" and again the getfacl /dev/bus/whatever/it/is/for/you in a Terminal after you plugged in the camera. If ck-list-sessions is empty, and thus you didn't get an ACL. then it is a ConsoleKit problem.

If you did get an ACL, but photo import fails, then please install the "gphoto2" package, say "Unmount" in the dialog which pops up after plugging in a camera, and do in your Terminal:

  gphoto2 --debug --debug-logfile /tmp/gphoto.debug.txt -L

to get debugging information. Please attach /tmp/gphoto.debug.txt here.

Thanks!

Changed in libgphoto2:
status: Confirmed → Incomplete
Revision history for this message
Martin Pitt (pitti) wrote :

We are closing this bug report because it lacks the information we need to investigate the problem, as described in the previous comments. Please reopen it if you can give us the missing information, and don't hesitate to submit bug reports in the future. To reopen the bug report you can click on the current status, under the Status column, and change the Status back to "New". Thanks again!

Changed in libgphoto2 (Ubuntu):
status: Incomplete → Invalid
Revision history for this message
szczym (szczym) wrote :
Changed in libgphoto2 (Ubuntu):
status: Invalid → Confirmed
Revision history for this message
szczym (szczym) wrote :

Maybe more folks from forums will help with that bug ?
http://ubuntuforums.org/showthread.php?p=7881071#post7881071

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.