how to make changes to exisiting cinder code and debug

asked 2014-07-03 01:50:01 -0500

anuragbharati gravatar image

updated 2014-07-03 04:43:52 -0500

Hello, I've installed openstack (havana) and cinder according to (docs). Now I want to put my own log statements and tried following:

1) tried existing code to print my own logs  
msg = _("cinder test log")

2) tried to use exception
msg = _("cinder test exception")
raise exc.HTTPNotFound(explanation=msg)

3) tried logging module
msg = _("cinder logging")

Editing following file "/usr/lib/python2.7/dist-packages/cinder/api/v2/" and to see result of changes restarting cinder-api and checking in log files, but none of them is working.

edit retag flag offensive close merge delete


Did you set debug=True in /etc/cinder/cinder.conf ?

dachary gravatar imagedachary ( 2014-07-05 05:33:17 -0500 )edit

Thanks Dachary for replying, I made that change in config file. I want functions to log their name when they are called. Say, when I execute "cinder list", in log I want the functions entry that where called.

anuragbharati gravatar imageanuragbharati ( 2014-07-08 06:17:58 -0500 )edit