Asterisk does not execute "hang-up" command after

I run asterisk under FC5, asterisk-1.2.13, libpri-1.2.4 and zaptel-1.2.10.

When a user is not available the voicemail functions prompts the caller to
leave a message which is recored. But when the caller hangs-up, the
"hangup" command is not executed and the landline remains busy. I need to
do a “/etc/init.d/asterisk restart” to open the line again.
Incoming calls via SIP work no problem; the hangup command is executed!!

My /etc/zaptel.conf looks like this (this installation is based in Spain):
loadzone = es
defaultzone= es
fxsks=1

The zapata.conf looks like this:
[channels]
usecallerid=yes
busydetect=yes
hidecallerid=no
callwaiting=no
threewaycalling=yes
transfer=yes
echocancel=yes
echotraining=yes
; define channels
context=incomingsignalling=fxs_ks
channel => 1

And /etc/asterisk/extensions.conf" is set to:
incoming]
exten => s,1,Answer()
exten => s,2,Background(enter-ext-of-person)
exten => 100,1,Dial(${100},10,r)
exten => 100,2,VoiceMail(u100@default)
exten => 100,3,Hangup()
exten => 100,102,VoiceMail(b100@default)
exten => 100,103,Hangup()
exten => 101,1,Dial(${101},10)
exten => 101,2,Playback(vm-nobodyavail)
exten => 101,3,Hangup()
exten => 101,102,Playback(tt-allbusy)
exten => 101,103,Hangup()
exten => i,1,Playback(pbx-invalid)
exten => i,2,Goto(incoming,s,1)
exten => t,1,Playback(vm-goodbye)
exten => t,2,Hangup()

Thank you in advance for your help.

Salu2, Wolfgang

But when the caller hangs-up, the “hangup” command is not executed and the landline remains busy

The hangup command is not called when an user hangs up.
The channel that was handling the call detects the hangup and releases the call resources.
In your case the zapata channel driver needs to be configured properly to detect the hangup. Try to set busycount in zapata.conf.

incoming calls via SIP work no problem

Thats because SIP calls are same in all countries because SIP is a standard.

Analog lines were implemented differently by diff countries and so we face such problems.

Have you seen this link
voip-info.org/wiki/view/Aste … ions+Spain

Well thanks, but still, the error is still the same. The file looks like this now:
[channels]
usecallerid=yes
busydetect=yes
busycount=4
hidecallerid=no
callwaiting=no
threewaycalling=yes
transfer=yes
echocancel=yes
echotraining=yes
; define channels
context=incoming
signalling=fxs_ks
channel => 1
Is this allright?

The indications.conf file was set correctly.

Try here
asteriskguru.com/tutorials/r … email.html

Quote from site…

The correct choice for the signalling= line depends on your carrier.
When you call them with this question they probably wont have a clue what you are talking about so trying several might be a good idea.

Kewl start is the best option there is, but it might not work in your situation, try to call your telco and ask for "disconnect supervision"
In this case, the telco will cut the power on the 2 telephone lines for a small period of time or will reverse the polarity on the lines.

(You could check this by calling to that pstn line, and connecting a phone with a lighted keypad and without external power supply there).
If the lights go out when the other end disconnects, the telco has disconnect supervision.

Loop start does not send a hangup signal, you will need the busydetect parameter.