Difference between revisions of "Howto long-term debug with beroNet's tool "PowerDebug""

From berofix - professional SIP gateway
Jump to: navigation, search
(Install PowerDebug as Linux daemon)
Line 21: Line 21:
 
# Unpack zip-file to a directory you want to run this tool and receive traces
 
# Unpack zip-file to a directory you want to run this tool and receive traces
 
# You'll get a new directory named "powerdebug-<version>", in which <version> stands for the installed PowerDebug version.
 
# You'll get a new directory named "powerdebug-<version>", in which <version> stands for the installed PowerDebug version.
 +
# <span style="color:#FF0000">NOTICE: </span>If you don't have teh "JAVA_HOME" environment veriable set to the path where your Java VM is installed, don't forget to set this OR you could just change the "JH" variable which is defined at the beginning of the "Install-service.bat"
 
# Go to this directory and execute "install-service.bat" <span style="color:#FF0000"> as administrator </span>
 
# Go to this directory and execute "install-service.bat" <span style="color:#FF0000"> as administrator </span>
 
# If everything gone well, you should now have a new entry in the windows "Services" manager named "PowerDebug". If you want to remove the service, just execute "uninstall.bat", as administrator too.
 
# If everything gone well, you should now have a new entry in the windows "Services" manager named "PowerDebug". If you want to remove the service, just execute "uninstall.bat", as administrator too.

Revision as of 10:31, 3 March 2016

What is it ?

In many cases problems are not reproducable immediately because they are happening not every time. Or, sometimes audio would be needed inside the trace, and therefore the capacity doesn't reach, or, or, or. Like maybe some of you know, beroNet gateways have not much capacity to store traces, that's why often traces are not complete or overwritten with other data, and the sitiuation which was want to be investigated is not included. For all these cases we made "PowerDebug". This tool consists of a server and a client application. The server is written in Java and can run anywhere where a Java VM (JRE) is installed. The client is an App which can be installed on a beroNet gateway. The trace data will be sent from client to server over TCP/IP, and can be stored onto the server which has normally much more storing capacity as the gateway. Long-term debugging is now possible without big efforts.


Prerequisites


What do you need to run PowerDebug server/client:
Server

  • Java >= 1.7
  • adminstrative user rights to run server as a daemon (Windows service for example)
  • free hdd space to store traces
  • TCP ports 8888 and 2221 should not be assigned by other appliactions

Client

  • App-FS >= 3.0
  • adminstrative user rights to install the App


Install PowerDebug server as Windows Service

You want to run the server under Windows as Windows Service ? No problem, here are the steps you need to do so:

  1. Download PowerDebug-Package from here: powerdebug-0.9.0.BETA-windows.zip
  2. Unpack zip-file to a directory you want to run this tool and receive traces
  3. You'll get a new directory named "powerdebug-<version>", in which <version> stands for the installed PowerDebug version.
  4. NOTICE: If you don't have teh "JAVA_HOME" environment veriable set to the path where your Java VM is installed, don't forget to set this OR you could just change the "JH" variable which is defined at the beginning of the "Install-service.bat"
  5. Go to this directory and execute "install-service.bat" as administrator
  6. If everything gone well, you should now have a new entry in the windows "Services" manager named "PowerDebug". If you want to remove the service, just execute "uninstall.bat", as administrator too.
  7. Select this new entry and start the service
  8. Now it's time to check if the server is porperly working. For that you should open a browser and enter this url: http://localhost:8888
    You should see a gui like this:
    Server gui.png
    If you not see this gui, something gone wrong. In this case please refere to #Possible problems or contact support@beronet.com
  9. Last step is to install the client application onto the gateway. For this, you have to login to the gateway first. Go to the menu "Apps->Market", press "upload file" and choose the app-file which is in the directory "apps" which can be found in the installation dirctory of the server application. There must be a file named "powerdebug-<version>-app.tar.gz". Choose this file. After upload you will be asked if you really want to install, choose "yes". After installing the app you should find a new menu entry under "Apps"-menu named "powerdebug". Click this new item and you should be redirected to the powerdebug client gui:
    Client gui.png

Now everything seems to be ready to run.

Install PowerDebug as Linux daemon

To run server as daemon under linux just follow these steps:

  1. Download PowerDebug-Package from here: powerdebug-0.9.0.BETA-linux.tar.gz
  2. Unpack zip-file to /opt
  3. Change rights of the init script with:
    chmod ug+x ./powerdebug.sh
  4. Enter following command to start the server:
    ./powerdebug.sh start
  5. If you want to run the server at boot time, just copy powerdebug.sh to /etc/init.d and enter this command:
    sudo update-rc.d powerdebug.sh defaults
    This command is only for Debian based Linux distributions. You may have to investigate how to install init script on your distribution by yourself.
  6. Now it's time to check if the server is porperly working. For that you should open a browser and enter this url: http://localhost:8888
    You should see a gui like this:
    Server gui.png

Starting and stopping a trace

Where to find the traces

Possible problems