Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 379975 - net-dialup/capi4k-utils doesn't create device node /dev/capi20
Summary: net-dialup/capi4k-utils doesn't create device node /dev/capi20
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: Normal normal with 1 vote (vote)
Deadline: 2017-07-05
Assignee: No maintainer - Look at https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers if you want to take care of it
URL:
Whiteboard:
Keywords: NeedPatch, PMASKED
Depends on:
Blocks:
 
Reported: 2011-08-20 15:14 UTC by Navid Zamani
Modified: 2017-07-05 10:40 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Navid Zamani 2011-08-20 15:14:53 UTC
This is not the same problem as that other "capi20 missing" bug from a year ago.

Apparently, udev doesn’t create /dev/capi20 anymore, and hence /etc/init.d/capi, and all services depending on it, fail.
When running “mknod /dev/capi20 c 68 0”, it works again. But of course I don’t know what permissions, user/group and symlinks it were supposed to have, and what other related devices (“/dev/{capi,isdn}/*”?) might be missing too.
And so, only restoring the original udev rules might make it clean again.

Reproducible: Always

Steps to Reproduce:
1. Make sure your kernel supports CAPI and the CAPIfs (deprecated, but still needed for CAPI)
2. /etc/init.d/capi start # or restart
Actual Results:  
/etc/init.d/capi fails because /usr/sbin/capiinit can’t find /dev/capi20 or related files. But since /usr/sbin/capiinit’s output is redirected to /dev/null, no error is shown, except for the [ !! ].

Expected Results:  
Since udev created /dev/capi20 and related files properly, /usr/sbin/capiinit can load, and hence “/etc/init.d/capi start” succeeds.

This stopped working a couple of weeks ago.

The whole situation for running capisuite is desperate. Since apparently /etc/init.d/capi can't handle mISDN in a way that makes it usable as CAPI (e.g. for capisuite), and the fcpci driver has to be manually compiled and installed to access my card and be able to continue running my answering machine on it at all.

Maybe it would be better to just explain how to run /etc/init.d/capi in a way that mISDN and avmfritz (the mISDN version of fcpci) can be used below capisuite…
Comment 1 Rafał Mużyło 2011-08-20 17:47:02 UTC
Try moving most of it into a forum question (you may drop a link to it here, if you like).

The initial part of the problem seems to lie in the init script - it seems it should check for /dev/capi, not /dev/capi20 - see if this helps to get things started.
Comment 2 Navid Zamani 2011-08-20 18:29:55 UTC
(In reply to comment #1)
> it seems it
> should check for /dev/capi, not /dev/capi20 - see if this helps to get things
> started.

Well, that wouldn’t work, since /usr/sbin/capiinit still expects /dev/capi20.
But ln -s /dev/capi /dev/capi20 worked. Obvious, since they both have the same device numbers.

But the more important question is: Who went and renamed the device without checking with its init script first?

––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––

So let’s correct this bug to:

Please either undo the renaming of the device node (simple and obvious choice), or change the init script, net-dialup/capi4k-utils, and everything else that accesses the file. :)
Comment 3 Navid Zamani 2011-08-20 18:46:30 UTC
Ok, the symlink does work for capi but not for capisuite. I had to undo everything, and 

> mknod /dev/capi c 68 0

otherwise it wouldn’t work.
Also, after a reboot, the device node is gone again, obviously.

So this needs permanent fixing like described in the last comment.
Comment 4 Rafał Mużyło 2011-08-20 19:28:04 UTC
Once again, forum would be a better place for this.

/dev/capi is the proper name for the node -the only possible fix for udev would be adding a /dev/capi20 symlink and setting the group to uucp.

So, what did you mean by "does work for capi but not for capisuite" ?
Comment 5 Navid Zamani 2011-08-20 20:01:45 UTC
(In reply to comment #4)
> Once again, forum would be a better place for this.

The /etc/init.d/capi script doesn’t work, capiinit fails, and you tell me it’s my problem and not a bug? … Please! ;)

> /dev/capi is the proper name for the node -the only possible fix for udev would
> be adding a /dev/capi20 symlink and setting the group to uucp.

Well, I have no problem with the name change. If the software is changed with it, so that it still works. That’s a reasonable expectation, isn’t it? ^^

uucp? I thought dialup… Ok, I’ll just see whatever it was back when it still worked, when it’s added to the current udev. Since currently /dev/capi is just root:root.

> So, what did you mean by "does work for capi but not for capisuite" ?

In its logs, CapiSuite says:

> CapiSuite 0x5ab69958: Can't start Capi abstraction. The given error message was: CapiError: Error in CAPI20_ISINSTALLED: CAPI not installed. occured in \  Capi::getCapiInfo()
Comment 6 Rafał Mużyło 2011-08-20 20:19:55 UTC
:roll: have patience

The real problem here is that both capi4k-utils and capisuite aren't alive upstream anymore.

There might be a need for a patch to capi4k-utils after we're done.

For the moment:
- change /dev/capi20 to /dev/capi anyway (I'd say that this will be the proper long term solution anyway, not adding a legacy symlinks to udev)
- create /dev/capi20 symlink to /dev/capi

Post what capisuite prints afterwards.
Comment 7 Navid Zamani 2011-08-20 20:32:01 UTC
(In reply to comment #6)
> The real problem here is that both capi4k-utils and capisuite aren't alive
> upstream anymore.

Aaaah, capi4k-utils too? See, I didn’t know that.

I’m completely open to a replacement. As long as the script I use as my “answering machine” in capisuite would still works.
Because, well, I’s a long-grown complex intelligent system that is closer to a AI butler taking calls than to an answering machine. :)
I know that Asterisk is a huge overengieered mess, which makes it really hard to adapt my script to it. (Yes, *that* really would have to go to the forums rather than this bug. So I’ll stop about that now. :)

> There might be a need for a patch to capi4k-utils after we're done.

Yes, most likely.

> For the moment:
> - change /dev/capi20 to /dev/capi anyway (I'd say that this will be the proper
> long term solution anyway, not adding a legacy symlinks to udev)

OK…

> - create /dev/capi20 symlink to /dev/capi

That’s what I already had done back in comment #3/#2. And while /etc/init.d/capi starts,

> Post what capisuite prints afterwards.

this is what CapiSuite said:

> CapiSuite 0x5ab69958: Can't start Capi abstraction. The given error message was: CapiError: Error in CAPI20_ISINSTALLED: CAPI not installed. occured in \  Capi::getCapiInfo()
Comment 8 Rafał Mużyło 2011-08-20 22:11:54 UTC
The ebuild's version is capi4k-utils-20050718 - looking at the calendar, I wouldn't call that "alive".

As I said, have patience or most likely result will be like bug 346179.

That error comes actually from capi4k-utils after open(capidevname, O_RDWR) fails.
Unfortunately, that's sort of hardcoded (it's either /dev/capi20 or /dev/isdn/capi20)
What's the output of 'groups' for root and 'ls -l /dev/capi' ?
Comment 9 William Hubbs gentoo-dev 2012-03-22 15:59:34 UTC
I am assigning this to the capi4k maintainers since it isn't really a
udev bug and since there has been no activity on it for months.
I think that capi4k should be patched for this.
Comment 10 Pacho Ramos gentoo-dev 2016-01-30 16:24:22 UTC
CCing treecleaners
Comment 11 Pacho Ramos gentoo-dev 2016-08-22 15:51:48 UTC
This has still many reverse deps... but I don't know what alternative is being used in other distributions as we are the only ones still having this package :/
Comment 12 Navid Zamani 2016-08-22 18:29:18 UTC
If it’s just me…: I fully migrated to SIP, and have no use for this anymore.
(It served me well in protecting me from a telephone stalker for years.)

If nobody complains, I have no objections with deprecating this package.
Comment 13 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2017-06-05 16:23:40 UTC
# Michał Górny <mgorny@gentoo.org> (05 Jun 2017)
# (on behalf of Treecleaner project)
# Abandoned upstream and downstream. Reported not to work. CAPI flags
# in reverse dependencies are masked for some time already.
# Removal in 30 days. Bug #379975.
net-dialup/capi4k-utils
Comment 14 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2017-07-05 10:40:54 UTC
commit 70ce185e0296b1895ec3fc9ec69ef9857f940c14
Author:     Michał Górny <mgorny@gentoo.org>
AuthorDate: Wed Jul 5 12:19:20 2017
Commit:     Michał Górny <mgorny@gentoo.org>
CommitDate: Wed Jul 5 12:35:15 2017

    net-dialup/capi4k-utils: Remove last-rited pkg, #379975