Accel-ppp debug

I will give an example of accel-ppp build with debugging information support, for example, in order to find out the cause of the crash.

I recommend to see my article:
Accel-ppp installation

To see debug information, you need to install accel-ppp by adding:


If you need to identify the cause of the leakage of RAM, then add another:


Suppose we collect so:

cd /opt/
git clone git:// accel-ppp-code
mkdir /opt/accel-ppp-code/build
cd /opt/accel-ppp-code/build
make install

Add the parameters to /etc/sysctl.conf, which let us specify where to store the core files and that the name of the program and the pid number should be specified in the name:


Apply the changes:

sysctl -p

Disable the limit on the size of core files:

ulimit -c unlimited

In order not to be reset after a system restart, add to /etc/security/limits.conf:

* soft core unlimited

Now for the test, you can create a file with the code in which there is an error:

int main() {
  *(char *)0 = 0;
  return 0;


gcc file.c



Make sure there is a segfault error in dmesg:

dmesg -T

Also make sure that the core -… file is created in the /root/ directory.
Now, similarly, when accel-ppp is crash, a core file will be created.

If the core files are empty, then you need to run accel-ppp in GDB:

apt install gdb
gdb --args /usr/sbin/accel-pppd -p /var/run/ -c /etc/accel-ppp.conf

If you run into GDB, then you need to turn off the log rotation, otherwise, after the rotations, you must constantly type “continue”.
If necessary, I cleaned the logs like this:

echo "" > /var/log/accel-ppp/emerg.log
echo "" > /var/log/accel-ppp/auth-fail.log
echo "" > /var/log/accel-ppp/accel-ppp.log

In order not to keep the terminal open with GDB, run it in screen so that you can disconnect from the server and then return to the open window, for example, create a window with the name “accel”:

screen -S accel
gdb --args /usr/sbin/accel-pppd -p /var/run/ -c /etc/accel-ppp.conf

To disconnect from the window, press Ctrl+A D, and in order to connect, type the command:

screen -r accel

If accel-ppp has crash, then to view more detailed information, run the commands:

bt full

In the configuration of accel-ppp, you can also enable more detailed logs, for example:


See my articles:
How to install and use Screen
How to update accel-ppp

Leave a comment

Leave a Reply