DAHDI-Remove-Uninstall-Reinstall-Upgrade
Topic: How to remove reinstall upgrade dahdi driver in my asterisk server
Introduction:
Overview:
In this Blog topic i will be covering the steps to remove or uninstall the dahdi driver, followed to that either reinstall same dahdi version or installing the latest version of dahdi.
Steps to remove - reinstall dahdi
Step 1: Stop Dahdi Service
Before removing the dadhi, stop the dahdi services from asterisk service and linux services.
Run the below command to stop dadhi running under asterisk
asterisk -rx "module unload chan_dahdi.so"systemctl stop dadhi
Step 2: Removing-Uninstall Dahdi
Next you need to find the dahdi modules drivers which are installed in the server, if multiple drivers modules are installed you need to remove all before removing the actual dahdi driver.
Command to check the list of dahdi modules installed
lsmod | grep dahdi
you will get the below output
Now uninstall all the modules which shown in above pic
modprobe -r wctc4xxp wctdm24xxp wcte12xp xpp dahdi_transcode wcb4xxpmodprobe -r wctdm wcfxo wctdm24xxp wcte11xp wct1xxp wcte12xpmodprobe -r dahdi_voicebus wct4xxp wctdm24xxp
Finally remove the actual dahdi driver by running below command
modprobe -r dahdi
Step 3: Reinstalling or Upgrade to Latest Dahdi
Download the latest dahdi driver from the below link.
cd /usr/src/
wget https://downloads.asterisk.org/pub/telephony/dahdi-linux-complete/dahdi-linux-complete-current.tar.gz
If want to download a specific version of dahdi, check out the below link for asterisk archive repository
https://downloads.asterisk.org/pub/telephony/dahdi-linux-complete
Installing the Dahdi,
Run the below command to unzip and install the dahdi
cd /usr/src/tar -xvzf dahdi-linux-complete-current.tar.gzlscd dahdi-linux-complete-2.10.1+2.10
note: replace the dahdi version 2.10.1
make clean
make allmake installmake config
Step 4: Configuring the Dahdi
If you have any digium telephony card installed or need to generate and install dahdi dummy driver ,run the below commands
dahdi_genconf -vdahdi_cfg -vsystemctl restart dahdiasterisk -rx "module load chan_dahdi.so"
Step 5: Troubleshoot- status check
Run the below commands to check the status of dahdi service
dahdi_cfg -vasterisk -rx "dahdi show status"
If still dahdi version show old version after running dahdi_cfg -v
then follow the below steps
Then run the below commands to remove the old version
rpm -qa | grep "dahdi"
rpm -qa | grep "dahdi"dahdi-linux-devel-2.4.1-70.el5dahdi-tools-2.4.1-68.el5dahdi-linux-2.4.1-70.el5dahdi-linux-kmdl-2.6.18-238.9.1.el5.goPAE-2.4.1-70.RHL5
run the below command for each package outputs to remove the particular dahdi rpms
rpm -e --nodeps "dahdi-linux-devel-2.4.1-70.el5"rpm -e --nodeps "dahdi-tools-2.4.1-68.el5"rpm -e --nodeps "dahdi-linux-2.4.1-70.el5"rpm -e --nodeps "dahdi-linux-kmdl-2.6.18-238.9.1.el5.goPAE-2.4.1-70.RHL5"