Wrong device-names in udev - Unable to open master device '/dev/zap/ctl'

Bug #64059 reported by Anders Wallenquist
22
This bug affects 1 person
Affects Status Importance Assigned to Milestone
zaptel (Debian)
Fix Released
Unknown
zaptel (Ubuntu)
Invalid
Low
Unassigned
Nominated for Karmic by David Stansby

Bug Description

After loading modules zaptel and wcte11xp new devices are created:

zap14 zap2 zap25 zap30 zap8
zap1 zap15 zap20 zap26 zap31 zap9
zap10 zap16 zap21 zap27 zap4 zapchannel
zap11 zap17 zap22 zap28 zap5 zapctl
zap12 zap18 zap23 zap29 zap6 zappseudo
zap13 zap19 zap24 zap3 zap7 zaptimer

But zttest, zttmonitor and chap_zap (asterisk) are expecting:

/dev/zap/*

As described here there are some files needed in /etc/udev/rules.d/ to get this to work:

http://asterisk.gnuinter.net/files/digium/zaptel/README.udev

Something like this would do the work:

vim /etc/udev/rules.d/51-zaptel.rules

# Section for Zaptel devices
KERNEL="zapctl", NAME="zap/ctl", GROUP="asterisk", OWNER="asterisk"
KERNEL="zaptimer", NAME="zap/timer", GROUP="asterisk", OWNER="asterisk"
KERNEL="zapchannel", NAME="zap/channel", GROUP="asterisk", OWNER="asterisk"
KERNEL="zappseudo", NAME="zap/pseudo", GROUP="asterisk", OWNER="asterisk"
KERNEL="zap0-9*", NAME="zap/%n", GROUP="asterisk", OWNER="asterisk"

Tags: bitesize
Revision history for this message
Lionel Le Folgoc (mrpouit) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. You reported this bug a while ago and there hasn't been any activity in it recently. We were wondering is this still an issue for you? Thanks in advance.

Changed in zapata:
status: New → Incomplete
Revision history for this message
Sebastian Rode (sebastian-ro-deactivatedaccount) wrote :

We are closing this bug report because it lacks the information we need to investigate the problem, as described in the previous comment. 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 zapata:
status: Incomplete → Invalid
Revision history for this message
eldorel (eldorel) wrote :

The previous poster has not needed to respond to this bug, but it is still an issue.

This bug doesn't reference the error messages that you receive during the problem, so most people searching for a solution won't find this.

Unable to open master device '/dev/zap/ctl' is the text of the actual error.

I ran into this problem today while installing a new tdm400p.

These entries should be appended to /etc/udev/rules by default when installing the zaptel-modules and/or zaptel-source, or at the least there should be a prompt at some point.

note: I have confirmed this problem on both dapper and gutsy today, with a tdm400p, an a400p clone and a x100p clone, on 2 different systems. (all while hunting for the solution listed here)

Greg

Changed in zapata:
status: Invalid → New
Revision history for this message
eldorel (eldorel) wrote :

Sorry, forgot to specify the module I was using. It was wctdm.

Revision history for this message
eldorel (eldorel) wrote :

Amusingly, the udev permissions line listed above does not work. For thos of you who find this later here's the file i used.

vim /etc/udev/rules.d/51-zaptel.rules

# Section for Zaptel devices
KERNEL="zapctl", NAME="zap/ctl", GROUP="asterisk", OWNER="asterisk"
KERNEL="zaptimer", NAME="zap/timer", GROUP="asterisk", OWNER="asterisk"
KERNEL="zapchannel", NAME="zap/channel", GROUP="asterisk", OWNER="asterisk"
KERNEL="zappseudo", NAME="zap/pseudo", GROUP="asterisk", OWNER="asterisk"
KERNEL="zap0-9*", NAME="zap/%n", GROUP="asterisk", OWNER="asterisk"

this was tested and works on both servers, will all of my cards. (so far. No warranty and all that...)

Greg

Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

Thanks for reporting this bug and any supporting documentation. Since this bug has enough information provided for a developer to begin work, I'm going to mark it as confirmed and let them handle it from here. Thanks for taking the time to make Ubuntu better!

Changed in zapata:
status: New → Confirmed
description: updated
Changed in zapata:
assignee: nobody → stefanlsd
status: Confirmed → In Progress
Revision history for this message
Stefan Lesicnik (stefanlsd) wrote :

Thanks for reporting this bug. Attached is the debdiff. (I had to use pbuilder build --twice to get the package to build with pbuilder).

Revision history for this message
Stefan Lesicnik (stefanlsd) wrote :
Revision history for this message
Stefan Lesicnik (stefanlsd) wrote :

Can one of the maintainers check the following as the above patch may already be applied in by udev

Intrepid udev contains

grep -A5 -i Zaptel /etc/udev/rules.d/20-names.rules

# Zaptel devices, group under /dev/zap
KERNEL=="zapctl", NAME="zap/ctl"
KERNEL=="zaptimer", NAME="zap/timer"
KERNEL=="zapchannel", NAME="zap/channel"
KERNEL=="zappseudo", NAME="zap/pseudo"
KERNEL=="zap[0-9]*", NAME="zap/%n"

and /etc/udev/rules.d/40-permissions.rules contains
SUBSYSTEM=="zaptel", GROUP="dialout"

Is the problem here maybe that the group is set to dialout and not asterisk which the application is suspecting?
I will unsubscribe ubuntu-universe-sponsers for now until we can clean this up.

Changed in zaptel:
importance: Undecided → Low
Changed in zaptel:
status: Unknown → New
Revision history for this message
Scott James Remnant (Canonical) (canonical-scott) wrote :

udev policy is that the group must be a system group.

asterisk should be in that group, not the other way around.

Revision history for this message
Stefan Lesicnik (stefanlsd) wrote :

The udev rules do create /dev/zap/* but with the group dialout. I think the problem here is that asterisk expects /dev/zap/* to belong to group asterisk. As Scott mentions above, the group must be a system group.

Can users using asterisk add the asterisk user to the dialout group, or change the group ownership manually in udev / chown the file before starting Asterisk.

If there are no objections, could we mark this bug as invalid?

Revision history for this message
Stefan Lesicnik (stefanlsd) wrote :

I am marking this bug as invalid. Please feel free to re-open this bug if you think this is still a problem and needs to be discussed and investigated further. Thanks for reporting this!

Changed in zaptel:
assignee: stefanlsd → nobody
status: In Progress → Invalid
Revision history for this message
nlinux (mekelly5) wrote :

This bug is still valid, I'm seeing this exact problem with a fresh Jaunty install, but the fix is not working. No idea how to get rid of the wrong /dev/zapctl and get the correct /dev/zap/ctl at thispoint. :(

Changed in zaptel (Ubuntu):
status: Invalid → Confirmed
Revision history for this message
Stefan Lesicnik (stefanlsd) wrote :

nlinux: Could you try the fix described here and let us know...

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=495459

Thanks!

Revision history for this message
nlinux (mekelly5) wrote : Re: [Bug 64059] Re: Wrong device-names in udev - Unable to open master device '/dev/zap/ctl'

The last patch, "autoudev", in that thread fixed the problem correctly. I
would suggest packaging up and including it.

Thanks again for the quick response,

Mark

On Fri, Jun 19, 2009 at 9:42 PM, Stefan Lesicnik <email address hidden> wrote:

> nlinux: Could you try the fix described here and let us know...
>
> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=495459
>
> Thanks!
>
> --
> Wrong device-names in udev - Unable to open master device '/dev/zap/ctl'
> https://bugs.launchpad.net/bugs/64059
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in “zaptel” source package in Ubuntu: Confirmed
> Status in “zaptel” source package in Debian: New
>
> Bug description:
> After loading modules zaptel and wcte11xp new devices are created:
>
> zap14 zap2 zap25 zap30 zap8
> zap1 zap15 zap20 zap26 zap31 zap9
> zap10 zap16 zap21 zap27 zap4 zapchannel
> zap11 zap17 zap22 zap28 zap5 zapctl
> zap12 zap18 zap23 zap29 zap6 zappseudo
> zap13 zap19 zap24 zap3 zap7 zaptimer
>
> But zttest, zttmonitor and chap_zap (asterisk) are expecting:
>
> /dev/zap/*
>
> As described here there are some files needed in /etc/udev/rules.d/ to get
> this to work:
>
> http://asterisk.gnuinter.net/files/digium/zaptel/README.udev
>
> Something like this would do the work:
>
> vim /etc/udev/rules.d/51-zaptel.rules
>
> # Section for Zaptel devices
> KERNEL="zapctl", NAME="zap/ctl", GROUP="asterisk", OWNER="asterisk"
> KERNEL="zaptimer", NAME="zap/timer", GROUP="asterisk", OWNER="asterisk"
> KERNEL="zapchannel", NAME="zap/channel", GROUP="asterisk", OWNER="asterisk"
> KERNEL="zappseudo", NAME="zap/pseudo", GROUP="asterisk", OWNER="asterisk"
> KERNEL="zap0-9*", NAME="zap/%n", GROUP="asterisk", OWNER="asterisk"
>
>
>

Revision history for this message
Stefan Lesicnik (stefanlsd) wrote :

Debdiff for Karmic attached.

nlinux: are you able to apply this diff and build to test it functions as it should before I upload. (should apply against Jaunty also)

Thanks

Revision history for this message
eldorel (eldorel) wrote :

I'll be testing this in the lab sometime this week, is there any additional data that you need logged?

Also, is this debdiff hardy compatible as well? If I remember correctly I had to manually adjust this the last time I did an install.

Changed in zaptel (Debian):
status: New → Won't Fix
Changed in zaptel (Debian):
status: Won't Fix → Fix Released
Revision history for this message
David Stansby (dstansby-deactivatedaccount) wrote :

Nominated for karmic, because that is the last Ubuntu release with zaptel in the repos

Revision history for this message
papukaija (papukaija) wrote :

Thank you for reporting this bug to Ubuntu. Zaptel is currently only available in Hardy's repository. However, it reached EOL on May 12, 2011. Therefore, I'm closing this bug for those reasons.

Please see this document for currently supported Ubuntu releases:
https://wiki.ubuntu.com/Releases

Please feel free to report any other bugs you may find.

Changed in zaptel (Ubuntu):
status: Confirmed → Invalid
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.