How to completely remove DAHDI and reinstall DAHDI

    In this Article we are going to learn how to completely remove or uninstall the DAHDI driver and reinstall latest or same version of DAHDI in asterisk based servers.  Due to server crash or planning to install the latest version of DAHDI you may want to remove the DAHDI driver then this article is for you.

how to remove dahdi - reinstall dahdi

What is DAHDI? 

Digium Asterisk Hardware Device Interface (DAHDI) 
    DAHDI is a collection of open source drivers, for linux, that are used to interface with a variety of telephony related hardware. 
It consists of two parts.
The DAHDI-Linux project contains the individual board drivers for the supported hardware. 
The DAHDI-Tools project contains an assortment of user space utilities that are used to setup and test the drivers.   
  Asterisk is a Open source Communication software , You can use Asterisk to build communications applications, things like business phone systems (also known as IP PBXs), call distributors, VoIP gateways and conference bridges.

Why we need to remove/uninstall DAHDI?

    If you are planning to use the latest DAHDI driver or your current DAHDI deriver crashed or creating issue then you might need to remove or reinstall the DAHDI driver.this Blog topic I will be covering the steps to remove or uninstall the DADHI driver, followed to that either reinstall same DAHDI version or installing the latest version of DAHDI.

Steps to uninstall-Reinstall DAHDI

    Follow the below steps to remove/uninstall DAHDI and install the same or latest version of DAHDI driver

Step 1: Stop Dahdi Service

    Before removing the DAHDI, stop the DAHDI services from asterisk service and linux services.
Run the below command to stop dadhi running under asterisk 

asterisk -rx "module unload"
systemctl stop dadhi

Step 2: 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 

asterisk dahdi reinstall

Now uninstall all the modules which shown in above pic

modprobe -r wctc4xxp wctdm24xxp wcte12xp xpp dahdi_transcode wcb4xxp
modprobe -r wctdm wcfxo wctdm24xxp wcte11xp wct1xxp wcte12xp
modprobe -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/

If want to download a specific version of dahdi, check out the below link for asterisk archive repository

Installing the Dahdi,
Run the below command to unzip and install the dahdi

cd /usr/src/
tar -xvzf dahdi-linux-complete-current.tar.gz
cd dahdi-linux-complete-2.10.1+2.10
note: replace the dahdi version 2.10.1
make clean
make all
make install
make 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 -v
dahdi_cfg -v
systemctl restart dahdi
asterisk -rx "module load"

Step 5: Troubleshoot- status check

    Run the below commands to check the status of dahdi service

dahdi_cfg -v
asterisk -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"
check the outputs , below is the one i got from my server
rpm -qa | grep "dahdi"

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"

once done again follow the above steps to reinstall the DAHDI latest


    Hope this article helps you to uninstall or remove the DAHDI from your asterisk server. For professional support reach me on skype to telegram id:striker24x7
  • Ajit Kumar
    Ajit Kumar April 4, 2022 at 11:27 AM

    How to Reinstall or upgrade the dahdi driver to latest version

Add Comment
comment url