Ask Your Question

How do I debug OpenStack?

asked 2013-04-05 19:10:34 -0500

anonymous user


updated 2014-09-09 13:50:16 -0500

Santosh_Parihar gravatar image

I stumbled upon an error that I cannot decipher: where do I find OpenStack's logs and how do I debug the system?

edit retag flag offensive close merge delete

5 answers

Sort by » oldest newest most voted

answered 2013-05-08 00:06:44 -0500

fifieldt gravatar image

updated 2013-10-30 13:02:34 -0500

smaffulli gravatar image
edit flag offensive delete link more

answered 2013-04-05 19:27:03 -0500

this post is marked as community wiki

This post is a wiki. Anyone with karma >75 is welcome to improve it.

Debugging a piece of code is an activity as important as writing it. The importance of debugging is much more noticeable on large projects like OpenStack, which require both developers and common users contribute and report when something is not going well.

Here are some pointers to collect useful logs and debugging processes.


Looking through the logs can be tricky... not if you know how to use regular expressions!

The first thing to do when we see a strange behavior that is repeated with the same input data, is to look at logs.

Logs are files, usually plain text and arranged chronologically, that contain information about the code that is executed to perform an action.

Analyzing the information found there, you may be able to detect what the problem is or, at least, where the error occurs.

The location of the logs in the system may vary depending on the implementation, but in GNU/Linux they usually are stored in /var/log.

In OpenStack the location of these logs varies according how have you deployed it: using DevStack or by hand, whether with the distribution repository packages you are using or from source.

If you're using DevStack keep in mind that by default, DevStack doesn’t log. To enable this option you will need to add the following lines to the localrc file.


– Name and location of the script logs. Without this line the output of this script will appear in the terminal where you run it, without being stored in any location.


– Location of the screen logs. DevStack runs OpenStack services under GNU Screen, thus providing the facility to view its current execution status. The logs simply store the output of these screens..


– Number of days to be logged. The old logs are replaced with the latest runs.

$DEST is the location in which the logs will be located. You can set this value as you wish.

Screen logs are just a record of the screens initiated by DevStack but you can check them anytime during the execution. The information provided is very useful to debug any OpenStack service.

GNU Screen provides the same functions as the DEC VT100 terminal, plus other aggregates. If you have no experience with this terminal, make sure to write down the following shortcuts.

 Attach to a screen      screen -r stack
 Switch screens          ctrl+a <screen no.>  (e.g. ctrl+a 1) 
 Scroll in a screen      ctrl+a esc and up/down arrows to scroll
 List screens        ctrl+a " and select the screen with up/down arrows
 Next screen         ctrl+a n 
 Detach from the screen  ctrl+a d

Manual deployment

Here you will find most services logs in /var/log/service, where service is the name of the desired service. For example, in /var/log/keystone you will find Keystone logs.

In my experience, the only service that differs from this default location is Horizon. You can find ... (more)

edit flag offensive delete link more


HI, are there any guide on debugging with eclipse and pydev with the latest branch. I have tried commented out eventlet.monkeypatch(os=False) and replaced it with eventlet.monkeypatch(all=False,socket=True,time=True,os=False) and added import sys;sys.path.append('path') but breakpoints are ignored

sak gravatar imagesak ( 2013-05-07 02:08:47 -0500 )edit

@sak thanks for asking. I believe yours would be a very good new question, more than a comment here. Do you mind posting it as a new question?

smaffulli gravatar imagesmaffulli ( 2013-05-07 12:05:23 -0500 )edit

cool. I have posted this as a new question:

sak gravatar imagesak ( 2013-05-08 03:05:22 -0500 )edit

answered 2013-10-30 08:38:57 -0500

RomilGupta gravatar image
edit flag offensive delete link more


works fine with as horizon ocata integration with eclipse!!! but use from the link above Run Configurations -> Arguments -> ${workspace_loc:openstack-dashboard}

Thomas Li gravatar imageThomas Li ( 2017-04-12 05:19:16 -0500 )edit

answered 2013-10-01 04:29:30 -0500

unmesh-gurjar gravatar image

updated 2013-10-01 04:30:55 -0500

edit flag offensive delete link more

answered 2013-10-03 05:56:11 -0500

sngirame gravatar image

Networking logs can be found at /var/log/quantum/

edit flag offensive delete link more

answered 2014-09-09 06:17:47 -0500

SGPJ gravatar image

You should be seeing logs under: /var/log/* dir under respective service.

edit flag offensive delete link more

answered 2013-10-29 12:27:03 -0500

maurosr gravatar image

updated 2013-10-30 13:03:31 -0500

smaffulli gravatar image

Just use pdb doesn't work fine with some projects like nova and or tempest, I'm not really sure, but I think it has something to do to how testr perform the tests run. Although there is valuable tip on testr page on the wiki

TL;DR: python -m discover my.tests.regex

edit flag offensive delete link more

answered 2014-09-15 02:41:36 -0500

updated 2015-07-16 04:11:53 -0500

Check this guide. It seems good.

edit flag offensive delete link more

Get to know Ask OpenStack

Resources for moderators

Question Tools



Asked: 2013-04-05 19:10:34 -0500

Seen: 9,763 times

Last updated: Jul 16 '15