Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

USB Operation not permitted

106 views
Skip to first unread message

Chris

unread,
Aug 7, 2007, 8:37:30 PM8/7/07
to
Outside of my kerboard, mouse, and thumbdrives, I am unable to use the USB
ports as a regular user. I have to use 'kdesu gnomad2' to access my
Creative Zen V and 'kdesu kooka' to scan from my HP PSC 1350. Now I am
unable to print!?!

Could there be a problem with udev? Anyone know which file needs to be
edited to allow user access to USB again?

Thanks

--
Chris

Rajko M.

unread,
Aug 9, 2007, 9:18:55 AM8/9/07
to
Chris wrote:

Hi Chris,

Use command
mount
to find out how is recognized your printer, scanner etc.
then look in
/etc/udev/rules.d/50-udev-default.rules
and edit permissions that are set with keywords "MODE" and "GROUP".
It can be that you have only to add your user to group that controlls device
ie. to existing group lp for printer. Scanner has no group defined in
rules, but you can add it.

This worked here though I don't know would that survive update of udev.

For more information on udev please see manual (man udev).

--
Regards,
Rajko.

Chris

unread,
Aug 9, 2007, 10:06:20 AM8/9/07
to
Rajko M. wrote:

Thanks Rajko, my printer and scanner are now working. However, I gnomad2
gives me this error with my Creative Zen V:

usb_claim_interface(): Operation not permitted
LIBMTP PANIC: Unable to initialize device 1
LIBMTP PANIC: configure_usb_devices() error code: 7 on line 1781
LIBMTP_Get_First_Device: Error Connecting
PDE device NULL.

It looks like the usb_claim_interface() is causes the other errors to occur.

I have added /etc/udev/rules.d/60-libmtp.rules added and the /dev/usbdev*
devices is created with perms 666.

Do you have any other ideas?

Thanks.

--
Chris

Rajko M.

unread,
Aug 9, 2007, 5:52:59 PM8/9/07
to
Chris wrote:

> Thanks Rajko, my printer and scanner are now working. However, I gnomad2
> gives me this error with my Creative Zen V:
>
> usb_claim_interface(): Operation not permitted

This can be for various reasons.

> LIBMTP PANIC: Unable to initialize device 1
> LIBMTP PANIC: configure_usb_devices() error code: 7 on line 1781
> LIBMTP_Get_First_Device: Error Connecting
> PDE device NULL.
>
> It looks like the usb_claim_interface() is causes the other errors to
> occur.

Right.

> I have added /etc/udev/rules.d/60-libmtp.rules added and the /dev/usbdev*
> devices is created with perms 666.

I would rather create group scanner and add user to that group. Than 660
will work.

> Do you have any other ideas?

What is version of your gnomad2.
I see gnomad2 version 2.8.12-1.guru.suse102 for x86_64 architecture.
Do you know what version worked?

It can be that some update broke permissions, for instance using different
device names, or limiting permissions for some devices.

See what happens if you just hookup device without starting gnomad2. Look
in /var/log/messages. The relevant lines will be at the end of file so you
can start console and run
tail -f /var/log/messages
than connect Zen. Than if device is recognized run gnomad2 first as user and
than as root, and watch what is going on in console.

--
Regards,
Rajko.

Chris

unread,
Aug 10, 2007, 10:24:03 AM8/10/07
to
Rajko M. wrote:
>> Do you have any other ideas?
>
> What is version of your gnomad2.
> I see gnomad2 version 2.8.12-1.guru.suse102 for x86_64 architecture.
> Do you know what version worked?
>
> It can be that some update broke permissions, for instance using different
> device names, or limiting permissions for some devices.
>
> See what happens if you just hookup device without starting gnomad2. Look
> in /var/log/messages. The relevant lines will be at the end of file so you
> can start console and run
> tail -f /var/log/messages
> than connect Zen. Than if device is recognized run gnomad2 first as user
> and than as root, and watch what is going on in console.
>

I've edited libmtp in /etc/udev/rules.d so that its placed in the audio
group. I also made my user account a member of that group. I still get the
Operation not permitted error.

As root, I can fully access the Zen V using gnomad2 and amarok (I used kdesu
to launch the programs).

/var/log/messages shows that the device is seen and the "Creative Zen V...."
string is printed.

This is definately a permissions issue. All the mtp-* tools fail with the
same error when I use them as a user. If I use them as root, they all work.

udev seems to be creating the proper devs in /dev:
crw-rw-rw- 1 root audio 189, 388 2007-08-10 11:19 /dev/4-2
crw-rw-rw- 1 root audio 254, 10 2007-08-10 11:19 /dev/usbdev4.5_ep00
crw-rw-rw- 1 root audio 254, 11 2007-08-10 11:19 /dev/usbdev4.5_ep02
crw-rw-rw- 1 root audio 254, 12 2007-08-10 11:19 /dev/usbdev4.5_ep82
crw-rw-rw- 1 root audio 254, 13 2007-08-10 11:19 /dev/usbdev4.5_ep83


AFAIK, libusb is being used. Here is my libusb entry in udev/rules.d:
# libusb device access
SUBSYSTEM=="usb_device", ACTION=="add", PROGRAM="/bin/sh -c 'K=%k;
K=$${K#usbdev}; printf bus/usb/%%03i/%%03i $${K%%%%.*} $${K#*.}'",
NAME="%c", MODE="0666"

I believe I changed the MODE from 0660 to 0666 (I can't remember).


--
Chris

Chris

unread,
Aug 10, 2007, 10:30:36 AM8/10/07
to
Here is the strace of mtp-detect run as a user (below).

It appears that opening /proc/bus/usb/004/005 as Read-Write fails and is
then opened as Read-Only.

open("/proc/bus/usb/004/005", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/004/005", O_RDONLY) = 4
ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc98e14) = -1 EPERM (Operation not
permitted)

Does anything pop-out at you?


--- strace mtp-detect ---

execve("/usr/bin/mtp-detect", ["mtp-detect"], [/* 84 vars */]) = 0
brk(0) = 0x804c000
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0xb7f2b000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or
directory)
open("/etc/ld.so.cache", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=139819, ...}) = 0
mmap2(NULL, 139819, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7f08000
close(3) = 0
open("/usr/lib/libmtp.so.5", O_RDONLY) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\0M\0\000"..., 512)
= 512
fstat64(3, {st_mode=S_IFREG|0755, st_size=119568, ...}) = 0
mmap2(NULL, 121920, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0xb7eea000
fadvise64(3, 0, 121920, POSIX_FADV_WILLNEED) = 0
mmap2(0xb7f05000, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED
MAP_DENYWRITE, 3, 0x1a) = 0xb7f05000
close(3) = 0
open("/usr/lib/libusb-0.1.so.4", O_RDONLY) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\320\22"..., 512) =
512
fstat64(3, {st_mode=S_IFREG|0755, st_size=31572, ...}) = 0
mmap2(NULL, 34040, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0xb7ee1000
fadvise64(3, 0, 34040, POSIX_FADV_WILLNEED) = 0
mmap2(0xb7ee7000, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED
MAP_DENYWRITE, 3, 0x5) = 0xb7ee7000
close(3) = 0
open("/lib/libc.so.6", O_RDONLY) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\340`\1"..., 512) =
512
fstat64(3, {st_mode=S_IFREG|0755, st_size=1491141, ...}) = 0
mmap2(NULL, 1234372, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0xb7db3000
fadvise64(3, 0, 1234372, POSIX_FADV_WILLNEED) = 0
mmap2(0xb7edb000, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED
MAP_DENYWRITE, 3, 0x128) = 0xb7edb000
mmap2(0xb7ede000, 9668, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED
MAP_ANONYMOUS, -1, 0) = 0xb7ede000
close(3) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0xb7db2000
set_thread_area({entry_number:-1 -> 6, base_addr:0xb7db28d0, limit:1048575,
seg_32bit:1, contents:0, read_exec_only:0, limit_in_pages:1,
seg_not_present:0, useable:1}) = 0
mprotect(0xb7edb000, 4096, PROT_READ) = 0
mprotect(0xb7f05000, 4096, PROT_READ) = 0
munmap(0xb7f08000, 139819) = 0
brk(0) = 0x804c000
brk(0x806d000) = 0x806d000
open("/usr/lib/gconv/gconv-modules.cache", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=25460, ...}) = 0
mmap2(NULL, 25460, PROT_READ, MAP_SHARED, 3, 0) = 0xb7f24000
close(3) = 0
open("/dev/bus/usb", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = -1
ENOENT (No such file or directory)
open("/proc/bus/usb", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 3
fstat64(3, {st_mode=S_IFDIR|0755, st_size=0, ...}) = 0
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
getdents64(3, /* 7 entries */, 4096) = 176
close(3) = 0
open("/proc/bus/usb", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 3
fstat64(3, {st_mode=S_IFDIR|0755, st_size=0, ...}) = 0
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
getdents64(3, /* 7 entries */, 4096) = 176
getdents64(3, /* 0 entries */, 4096) = 0
close(3) = 0
open("/proc/bus/usb/004", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 3
fstat64(3, {st_mode=S_IFDIR|0555, st_size=0, ...}) = 0
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
getdents64(3, /* 4 entries */, 4096) = 96
open("/proc/bus/usb/004/005", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/004/005", O_RDONLY) = 4
ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc98e14) = -1 EPERM (Operation not
permitted)
read(4, "\22\1\0\2\377\0\0@\36\4PA\0\1\1\2\3\1", 18) = 18
read(4, "\t\2\'\0\1\1\20\300", 8) = 8
read(4, "\372\t\4\0\0\3\0\0\0!\7\5\2\2\0\2\0\7\5\202\2\0\2\0\7\5"..., 31) =
31
close(4) = 0
open("/proc/bus/usb/004/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/004/001", O_RDONLY) = 4
ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc98e14) = -1 EPERM (Operation not
permitted)
read(4, "\22\1\0\2\t\0\1@\0\0\0\0\6\2\3\2\1\1", 18) = 18
read(4, "\t\2\31\0\1\1\0\340", 8) = 8
read(4, "\0\t\4\0\0\1\t\0\0\0\7\5\201\3\4\0\f", 17) = 17
close(4) = 0
getdents64(3, /* 0 entries */, 4096) = 0
close(3) = 0
open("/proc/bus/usb/004/005", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/004/005", O_RDONLY) = 3
ioctl(3, USBDEVFS_IOCTL, 0xbfc98e10) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/004/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/004/001", O_RDONLY) = 3
ioctl(3, USBDEVFS_IOCTL, 0xbfc98e10) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/003", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 3
fstat64(3, {st_mode=S_IFDIR|0555, st_size=0, ...}) = 0
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
getdents64(3, /* 3 entries */, 4096) = 72
open("/proc/bus/usb/003/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/003/001", O_RDONLY) = 4
ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc98e14) = -1 EPERM (Operation not
permitted)
read(4, "\22\1\20\1\t\0\0@\0\0\0\0\6\2\3\2\1\1", 18) = 18
read(4, "\t\2\31\0\1\1\0\340", 8) = 8
read(4, "\0\t\4\0\0\1\t\0\0\0\7\5\201\3\2\0\377", 17) = 17
close(4) = 0
getdents64(3, /* 0 entries */, 4096) = 0
close(3) = 0
open("/proc/bus/usb/003/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/003/001", O_RDONLY) = 3
ioctl(3, USBDEVFS_IOCTL, 0xbfc98e10) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/002", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 3
fstat64(3, {st_mode=S_IFDIR|0555, st_size=0, ...}) = 0
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
getdents64(3, /* 4 entries */, 4096) = 96
open("/proc/bus/usb/002/003", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/002/003", O_RDONLY) = 4
ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc98e14) = -1 EPERM (Operation not
permitted)
read(4, "\22\1\0\2\0\0\0\10m\4\32\300\0\31\1\2\0\1", 18) = 18
read(4, "\t\2\"\0\1\1\0\240", 8) = 8
read(4, "1\t\4\0\0\1\3\1\2\0\t!\20\1\0\1\"2\0\7\5\201\3\4\0\n", 26) = 26
close(4) = 0
open("/proc/bus/usb/002/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/002/001", O_RDONLY) = 4
ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc98e14) = -1 EPERM (Operation not
permitted)
read(4, "\22\1\20\1\t\0\0@\0\0\0\0\6\2\3\2\1\1", 18) = 18
read(4, "\t\2\31\0\1\1\0\340", 8) = 8
read(4, "\0\t\4\0\0\1\t\0\0\0\7\5\201\3\2\0\377", 17) = 17
close(4) = 0
getdents64(3, /* 0 entries */, 4096) = 0
close(3) = 0
open("/proc/bus/usb/002/003", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/002/003", O_RDONLY) = 3
ioctl(3, USBDEVFS_IOCTL, 0xbfc98e10) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/002/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/002/001", O_RDONLY) = 3
ioctl(3, USBDEVFS_IOCTL, 0xbfc98e10) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/001", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 3
fstat64(3, {st_mode=S_IFDIR|0555, st_size=0, ...}) = 0
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
getdents64(3, /* 3 entries */, 4096) = 72
open("/proc/bus/usb/001/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/001/001", O_RDONLY) = 4
ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc98e14) = -1 EPERM (Operation not
permitted)
read(4, "\22\1\20\1\t\0\0@\0\0\0\0\6\2\3\2\1\1", 18) = 18
read(4, "\t\2\31\0\1\1\0\340", 8) = 8
read(4, "\0\t\4\0\0\1\t\0\0\0\7\5\201\3\2\0\377", 17) = 17
close(4) = 0
getdents64(3, /* 0 entries */, 4096) = 0
close(3) = 0
open("/proc/bus/usb/001/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/001/001", O_RDONLY) = 3
ioctl(3, USBDEVFS_IOCTL, 0xbfc98e10) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/004/005", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/004/005", O_RDONLY) = 3
ioctl(3, USBDEVFS_CONTROL, 0xbfc98e2c) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/004/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/004/001", O_RDONLY) = 3
ioctl(3, USBDEVFS_CONTROL, 0xbfc98e2c) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/003/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/003/001", O_RDONLY) = 3
ioctl(3, USBDEVFS_CONTROL, 0xbfc98e2c) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/002/003", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/002/003", O_RDONLY) = 3
ioctl(3, USBDEVFS_CONTROL, 0xbfc98e2c) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/002/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/002/001", O_RDONLY) = 3
ioctl(3, USBDEVFS_CONTROL, 0xbfc98e2c) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/001/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/001/001", O_RDONLY) = 3
ioctl(3, USBDEVFS_CONTROL, 0xbfc98e2c) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 3
fstat64(3, {st_mode=S_IFDIR|0755, st_size=0, ...}) = 0
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
getdents64(3, /* 7 entries */, 4096) = 176
getdents64(3, /* 0 entries */, 4096) = 0
close(3) = 0
open("/proc/bus/usb/004", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 3
fstat64(3, {st_mode=S_IFDIR|0555, st_size=0, ...}) = 0
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
getdents64(3, /* 4 entries */, 4096) = 96
open("/proc/bus/usb/004/005", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/004/005", O_RDONLY) = 4
ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc99264) = -1 EPERM (Operation not
permitted)
read(4, "\22\1\0\2\377\0\0@\36\4PA\0\1\1\2\3\1", 18) = 18
read(4, "\t\2\'\0\1\1\20\300", 8) = 8
read(4, "\372\t\4\0\0\3\0\0\0!\7\5\2\2\0\2\0\7\5\202\2\0\2\0\7\5"..., 31) =
31
close(4) = 0
open("/proc/bus/usb/004/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/004/001", O_RDONLY) = 4
ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc99264) = -1 EPERM (Operation not
permitted)
read(4, "\22\1\0\2\t\0\1@\0\0\0\0\6\2\3\2\1\1", 18) = 18
read(4, "\t\2\31\0\1\1\0\340", 8) = 8
read(4, "\0\t\4\0\0\1\t\0\0\0\7\5\201\3\4\0\f", 17) = 17
close(4) = 0
getdents64(3, /* 0 entries */, 4096) = 0
close(3) = 0
open("/proc/bus/usb/004/005", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/004/005", O_RDONLY) = 3
ioctl(3, USBDEVFS_IOCTL, 0xbfc99260) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/004/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/004/001", O_RDONLY) = 3
ioctl(3, USBDEVFS_IOCTL, 0xbfc99260) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/003", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 3
fstat64(3, {st_mode=S_IFDIR|0555, st_size=0, ...}) = 0
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
getdents64(3, /* 3 entries */, 4096) = 72
open("/proc/bus/usb/003/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/003/001", O_RDONLY) = 4
ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc99264) = -1 EPERM (Operation not
permitted)
read(4, "\22\1\20\1\t\0\0@\0\0\0\0\6\2\3\2\1\1", 18) = 18
read(4, "\t\2\31\0\1\1\0\340", 8) = 8
read(4, "\0\t\4\0\0\1\t\0\0\0\7\5\201\3\2\0\377", 17) = 17
close(4) = 0
getdents64(3, /* 0 entries */, 4096) = 0
close(3) = 0
open("/proc/bus/usb/003/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/003/001", O_RDONLY) = 3
ioctl(3, USBDEVFS_IOCTL, 0xbfc99260) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/002", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 3
fstat64(3, {st_mode=S_IFDIR|0555, st_size=0, ...}) = 0
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
getdents64(3, /* 4 entries */, 4096) = 96
open("/proc/bus/usb/002/003", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/002/003", O_RDONLY) = 4
ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc99264) = -1 EPERM (Operation not
permitted)
read(4, "\22\1\0\2\0\0\0\10m\4\32\300\0\31\1\2\0\1", 18) = 18
read(4, "\t\2\"\0\1\1\0\240", 8) = 8
read(4, "1\t\4\0\0\1\3\1\2\0\t!\20\1\0\1\"2\0\7\5\201\3\4\0\n", 26) = 26
close(4) = 0
open("/proc/bus/usb/002/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/002/001", O_RDONLY) = 4
ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc99264) = -1 EPERM (Operation not
permitted)
read(4, "\22\1\20\1\t\0\0@\0\0\0\0\6\2\3\2\1\1", 18) = 18
read(4, "\t\2\31\0\1\1\0\340", 8) = 8
read(4, "\0\t\4\0\0\1\t\0\0\0\7\5\201\3\2\0\377", 17) = 17
close(4) = 0
getdents64(3, /* 0 entries */, 4096) = 0
close(3) = 0
open("/proc/bus/usb/002/003", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/002/003", O_RDONLY) = 3
ioctl(3, USBDEVFS_IOCTL, 0xbfc99260) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/002/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/002/001", O_RDONLY) = 3
ioctl(3, USBDEVFS_IOCTL, 0xbfc99260) = -1 EPERM (Operation not permitted)
close(3) = 0
open("/proc/bus/usb/001", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 3
fstat64(3, {st_mode=S_IFDIR|0555, st_size=0, ...}) = 0
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
getdents64(3, /* 3 entries */, 4096) = 72
open("/proc/bus/usb/001/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/001/001", O_RDONLY) = 4
ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc99264) = -1 EPERM (Operation not
permitted)
read(4, "\22\1\20\1\t\0\0@\0\0\0\0\6\2\3\2\1\1", 18) = 18
read(4, "\t\2\31\0\1\1\0\340", 8) = 8
read(4, "\0\t\4\0\0\1\t\0\0\0\7\5\201\3\2\0\377", 17) = 17
close(4) = 0
getdents64(3, /* 0 entries */, 4096) = 0
close(3) = 0
open("/proc/bus/usb/001/001", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/001/001", O_RDONLY) = 3
ioctl(3, USBDEVFS_IOCTL, 0xbfc99260) = -1 EPERM (Operation not permitted)
close(3) = 0
fstat64(1, {st_mode=S_IFCHR|0600, st_rdev=makedev(136, 1), ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0xb7f23000
write(1, "Found non-autodetected device \"C"..., 61) = 61
open("/proc/bus/usb/004/005", O_RDWR) = -1 EACCES (Permission denied)
open("/proc/bus/usb/004/005", O_RDONLY) = 3
ioctl(3, USBDEVFS_CLAIMINTERFACE, 0xbfc992c4) = -1 EPERM (Operation not
permitted)
dup(2) = 4
fcntl64(4, F_GETFL) = 0x2 (flags O_RDWR)
fstat64(4, {st_mode=S_IFCHR|0600, st_rdev=makedev(136, 1), ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0xb7f22000
_llseek(4, 0, 0xbfc99158, SEEK_CUR) = -1 ESPIPE (Illegal seek)
write(4, "usb_claim_interface(): Operation"..., 47) = 47
close(4) = 0
munmap(0xb7f22000, 4096) = 0
write(1, "Connection error.\n", 18) = 18
write(1, "No devices.\n", 12) = 12
exit_group(0) = ?


--
Chris

Chris

unread,
Aug 10, 2007, 10:34:41 AM8/10/07
to
Chris wrote:

> Here is the strace of mtp-detect run as a user (below).
>
> It appears that opening /proc/bus/usb/004/005 as Read-Write fails and is
> then opened as Read-Only.
>
> open("/proc/bus/usb/004/005", O_RDWR) = -1 EACCES (Permission denied)
> open("/proc/bus/usb/004/005", O_RDONLY) = 4
> ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc98e14) = -1 EPERM (Operation not
> permitted)
>
> Does anything pop-out at you?

As a long shot I changed the perms of /proc/bus/usb/004/005 from 644 to 666.
Now both gnomad2 and amarok work using my user account!?!

Now I just need to figure out what sets the perms of this when the device is
connected. AFAICT, the 004/005 can be anything as it depends on which USB
port the Zen V is connected and how many times it is reconnected.

--
Chris

Chris

unread,
Aug 10, 2007, 12:53:37 PM8/10/07
to
Chris wrote:

Ok, I solved the problem by recompiling my kernel and turning on
CONFIG_USB_DEVICE_CLASS. This is a deprecated feature that is turned off by
default in the 2.6.22 kernel.

--
Chris

Rajko M.

unread,
Aug 10, 2007, 10:27:18 PM8/10/07
to
Chris wrote:

> Chris wrote:
>
>> Chris wrote:
>>
>>> Here is the strace of mtp-detect run as a user (below).
>>>
>>> It appears that opening /proc/bus/usb/004/005 as Read-Write fails and is
>>> then opened as Read-Only.
>>>
>>> open("/proc/bus/usb/004/005", O_RDWR) = -1 EACCES (Permission denied)
>>> open("/proc/bus/usb/004/005", O_RDONLY) = 4
>>> ioctl(4, USBDEVFS_CONNECTINFO, 0xbfc98e14) = -1 EPERM (Operation not
>>> permitted)
>>>
>>> Does anything pop-out at you?

Nothing now :-)

>> As a long shot I changed the perms of /proc/bus/usb/004/005 from 644 to
>> 666. Now both gnomad2 and amarok work using my user account!?!
>>
>> Now I just need to figure out what sets the perms of this when the device
>> is connected. AFAICT, the 004/005 can be anything as it depends on which
>> USB port the Zen V is connected and how many times it is reconnected.
>
> Ok, I solved the problem by recompiling my kernel and turning on
> CONFIG_USB_DEVICE_CLASS. This is a deprecated feature that is turned off
> by default in the 2.6.22 kernel.
>

Glad to hear that.
It will be valuable help to troubleshoot similar problems that other users
have.

The usb devices are defined here in
/sys/bus/usb/devices
not in
/proc/bus/usb
which is empty.

Kernel is 2.6.18.8-0.5-default (last openSUSE 10.2).
grep USB_DEVICE /boot/config-2.6.18.8-0.5-default
gives only
CONFIG_USB_DEVICEFS=y
The same is in previous kernel 2.6.18.8-0.3-default, and all USB devices
here work without permission problems including Canon camera, though it is
faster to pick up images using card reader.

The 10.3 Beta 1 kernel configuration gives:
grep USB_DEVICE /boot/config-2.6.22.1-16-default
CONFIG_USB_DEVICEFS=y
# CONFIG_USB_DEVICE_CLASS is not set
Second is not even mentioned in earlier configuration. Strange for
depreciated feature, but this is openSUSE kernel where feature can be
removed completely, so it will not appear in .config.

BTW, if you have interest take part in 10.3 Beta testing.
The Beta 1 is somewhat raw comparing to Alpha 7, but it is quite stable and
fast. The list for discussions is opensuse...@opensuse.org.
More information on http://en.opensuse.org/Communicate

Now boot in 10.3 and have a fun.

--
Regards,
Rajko.

0 new messages