Debugging Yate Client on Windows
This page purpose is to describe how to debug Yate Client on Windows platforms.
Contents |
Introduction
In this page we assume Yate is installed in the default path: c:\Program Files\Yate.
If you installed it in another location replace the path to install location in the commands given in this page.
Configuration files are located in conf.d folder: c:\Program Files\Yate\conf.d.
The configuration files are installed with sample extension (e.g. yate-qt4.conf.sample). If you need to edit a configuration file rename it by removing the sample extension (e.g. yate-qt4.conf.sample -> yate-qt4.conf).
NOTE
Windows may hide file extensions. In the Explorer window you may see a yate-qt4.conf file. Check the file type, if it says is a SAMPLE file then the file you are see is yate-qt4.conf.sample.
To show file extensions:
Control Panel -> Folder Options. In the View page uncheck Hide extensions for known file types option.
Enhanced debug
Command line options
-vvvvv: Increase debug level. More messages will be put in the log.
-Dt: Show debug message time. Each debug line will be prefixed with time ellapsed from program start.
-l logfile: Log to file named logfile. Messages are appended to file if exists. The file is created if not found.
-tl logfile: Log to file named logfile. The file is truncated if exists.
-c path_to_conf: Start with configuration files in path_to_conf folder.
Enabling message sniffer
The message sniffer is entity who dumps Yate internal messages to log file.
To enable it you must set in yate-qt4.conf:
[general] msgsniff=yes
Open a console window
To start Yate from a command line you must open a console window.
From Start Menu choose "Run..." option.
Type cmd in the edit box and then press the 'Ok' button.
Start Yate Client with logging
You need to run Yate in the install directory (with default paths to configuration files, modules ...).
In the console type:
c: cd c:\Program Files\Yate yate-qt4 -Dt -vvvvv -l yatelog.txt
The log file is created in program start directory: c:\Program Files\Yate\yatelog.txt.
You can create a batch file (a file with bat extension, e.g. yate-qt4.bat), copy the above lines in it and run it by mouse double click (or click, depending on system settings). The file location is not important, it may be located on your desktop.
Frequently asked questions
I can't rename a configuration file
Make sure it is not already opened for editing.
If you don't have write permission on the folder or file, you can copy all configuration files in another location (e.g. c:\yate-conf) and start with it:
yate-qt4 -Dt -vvvvv -c c:\yate-conf -l yatelog.txt
I can't find the log file
You may not have write permissions on install folder.
Create a log file in a location you have write permission.
The location may be your documents folder. On Windows XP, if you are logged in as Guest this can be C:\Documents and Settings\Guest\My Documents
yate-qt4 -Dt -vvvvv -l "C:\Documents and Settings\Guest\My Documents\yatelog.txt"
Notice the quotes around log file path: they must be used when passing a path containing spaces in a command line option.
See also