Add to Watchlist

Post-Mortem Debugging with Heap-Dumps


Citation of segment
Embed Code
Purchasing a DVD Cite video
and next August we have only begun some truth with the topic of postmortem debugging with the dance let them FIL of and what is so that's probably rather known problem that editing C is explored and and the
various methods to to handle it them my talk is about postmortem departing it's
just a short I'm working on science including and signals so that the taxes the most of the time to some places like those in some program failures according to the grant me and said sometimes was a hot weapon used and so think of a March compute cluster once the dielectric lies on you know it's of those jobs and this this usually very common approach and the reward approach to use some some kind of postmortem analysis is to find the culture of a failure under classical approaches to create a quot and the contents supply and you can make it is in the body and analyze it and what unfortunately ties piousness has no use of a quantum so results that could be a chance for a little project and uh when I started in no wasn't market out what what actually works some kind so what does a lot of
previous knowledge and quantum state back into the origins of computers so that all of this stuff so found a classical quantum systems the programmers manual position system for online the lines that's this 2nd operating system right correlated so it really all and today almost every working system has feature to Kuwait and some of the memory of the program that constant fault conditions and people have used this hope awaiting level dance and to analyze interpreted languages and interpreted programs warning was in Opel native-code and so will in in this in the internet you can find the greatest the point of people appliances supplies and so that makes the results of of your projects and I simply got most of some of the components of reference section actually is complicated entirely dependent on the implementation and to compile all cheese and the compiler version and of weighting system so it's and not politically active that so it's of course possible to move society to to most of feature to rate of TomTom's operating writing system into center and so some people of features for interpreted languages and the most prominent examples of each of our so so the idea and implementation of Java dialectics support some kind of job done so and you can see that in the box tropical was hopelessness of those on the ongoing growth in 2 2 thousand 12 in the final release applied on what will have its ideas to catch an exception pick surprise factor and send you said the the postmortem function to analyze some because twice the and In the respects well about and and factors most serious to contain some and particularly objects and time while France was affecting and now we come to point out that some of you know I quoted in the name right and also the user chooses deployment long and the way he'd done at some still experimental markets currently 2 . 7 only because I stick in Liberia depend on students and it was altered and there's always experiment importance as the level it it may just be really what was the building blocks of importance basic idea similar as was applied on on some exception-handling code and sends equations down to code to ensure that the 2 results of in the program on indeed are used in a few lines of code from the finest by them what Yukos but found as a problem hence I can improve it turned out to be centrist humans left so it's time for a little
demonstration at a single civilian situation you installed and it'll pleasant gains for a partner for your kids or customers and she or he complains about some things that some questions requiring every now and then you have to catch up with and these note I used improper and I introduced box so that the Russians perfectly OK the here we are sold on
so 1st did not really have to to installment of phase installation to words that aren't so the it's a simple hasn't been stored point you don't already installed the dependence on their partners some equated little the pth scripts years and supplies installation is just you know about what's this kind of flights to talk because different wise and finds that during start up and find extension of PDH in site-packages intellectually it's what's that saying it into the they think the executes this flight and some sometimes just so we so it involves the pipe dumped package and standard justice and pompom on handle the exception and let's sketch of the suspect vs. says exceptions so let's play the game the water from the if
you don't just OK so I have
tried a little bit to find a solution rather than
reliable corrections and there's a clash and he got the message that we have here and the dump file that's fine so we can now notice into the pirates from simple system simply recall applies and minus m where he and so lots of
options so you can come up some arguments and the idea is simply to terms Poisson the foreign to the park and I want to use the plight of the progress of this included the results of the particles eclipsed by modules and it has a nice motivating pigeons upward spread from students here this is application and I have to tell plausibility program what you respect should be located since it's a long line here that's so that's the far land so and some have to go to the people of the universe and
years see only here we and method message and the bargain shows exceptions of was called and was at a good for object has no way at the poles of this is that the reason was expected and but the controls the last while the so have can you will 2nd yeah should be possible so you see here some more honest complicated conditions lenses at almost the mass of the so called and so we can look into the rebels books and history for instance on so here on volumes you in the US and you can find the courage to condolences for teams of scientists were from of the word itself and this complicated conditional cycles was a cautious calling only rarely flying actually I introduced code here is you can also look at other points and we get all the restaurants and you can for instance here look at this is almost as interesting we can look and see objects and here we have an interest in object because and game object was actually not really and data for some reasons it depends only on some resources or something outside so we get on so data object instances and so it doesn't hinder the bottom cousins OK objects inside the bonds and the just possible and you can also find someone you know has all those in active use so which
object of so we still and to analyze problem OK so far demonstration and like to
support annotation and
so on certification of supplied by the number of times moderates reticent where you have to set up some kind of exception handler you can have several ways to to do it so usually the 2nd most common and convertible is so but as a function of time and handled exceptions and it can register this is except that the call the error that sentences a what users and to that's called an unhandled exception of course and remains or it can got some decorated for function sole which this function words this exception political of and there was some low-level functions of that's documented and so the manual of the time then you have to install accurate customer was operator to send you any heap dumps for itself and then you have to wait and you have good luck you have to wait for program is the bond and finally you analyze it using a commentary by so how does this that with this work because we have that's a complicated question so that's divided into something more questions and the 1st question is what is the content of the information that you don't want that subsequently I'll have to
finish dividing him so and In
this means if there actually is uh suppliers and demand kind of mine message from out of and that's idea was to make a finding that human could we to some degree and to do so it contains some had those this information about supplies and so correlated so what and sense as a large quantity of
it contents information
some what distance is finally
broke its content of our complete the content is a compressed signal of a dictionary and the dictionary contains placed back supplies the exceptions that claims of selected on heightened that's Kansas stickers splicing of all postulates and then the transitive closure of the objects feature of all forms of wines cost and optional you can always includes all sets of the code objects from or sharing and some other interesting objects like supposes that he says that some of you coast and if you the equator down for instance on Linux system and underlying system the rental system in the you sometimes need to know how to interpret surpasses the user and so find themselves also called flies in the code objects then and celebrities and the like how does high heat and is constant rather than
basic ideas and simple quite dictionary was a condom because the answer's challenges into can pick up on most what classes sales some kind of state of this particularly in Python's very limited to preclude faint objects and objects designed to be because but surely not was saying and that 2nd challenges motives as much as wedding goes think of so let's warning answers time and changing the state of your program and if you have an exception could depend on suspension along the opposite so that's actually have an exception but also on of so how do we how can we get the average objects as over all and all of the above thinking and picking up this from 1 hundreds of data from what you have you can reach the exact description of all the little cold and at the time it sends a source of supplies and libraries and says or just found that implementation of sorts of because people module so the basic idea of suspended implementations to serialize data in a portable way portable between different pies conversion and it's really fast residents and 2nd implementation of typical of the picture of a spectrum of human centered beauty quite it and released as open source in 2010 and society of this module is to serialize right we have objects but not between Poisson Gaussian between different parts of the there is no written entirely applies and pilot done this test ecologically and at some additional features and so important features of fault and picking on picturing the basic ideas we don't and not required to serialized and distorted data and exact right just because we and not and drastic and continued to what in continuing of local to just want to look at the state so it's enough to focus on the state in a way that is useful for analysis but all so we can and we have another fortunately to sample problematical option so the 2nd challenge monitors wedding of that's not all perfect solution possible it would be found in an ideal world really have from research to stop or all kinds of things wide because and or quasi newton least as and not abusing corners but I can make some about solution and it's indeed possible to block puzzles what's slowness 2 don't really dance the system check intervals function and if you set it to write long interval or instant was present you could use upon the upon the context manager and sending send you effectively block elsewhere so you can books it's let's make a copy of the this local radicals so for
instance was in some friends and then you can actually pick you know this is hoping for a making it might sound could call and could the general because if you pick class has 1 a customer reviews law custom gets statements that or something that's that it's seismicity could actually make a call to an external C functions we could release and to put these together and then you get all of them so I should note finder note about the various support PDP and applied the already support postmortem debugging PDBsum nice if I am as you and postmortem implied in fuel need to who have considerable redundancy in tunnels by that supports the inspection of additional stick forums that that that which do not belong to that so-called customs wants instance so really useful feature because if you have multiple let's and you can use this customer wants to magnetic where simple to exist the norms of the so let's decide that it divides us what's of course exception yes and ordered should probably have some guy who wants to be the future flesh this post mortem departing on where the customs Wien's into the debugger consoles the test of this feature features but it's certainly accessible future it's 1
actually it's the moment at this usually we have a already here using the dominant 1 of the products and by the way to know because it's just that if you times of the calls variable parts of its probably due Tuesday testing and quality assurance and have to be have process that that not just very few parts and so on questions the memory usage is how reliable the concepts and very very important security yes so files containing enormous amount of information so only you have to handle them carefully and all of us is you pick your special object of something that's your mean come to have picked up the findings of program so you have to be sure you can't last source could and globally and then ask have you to Paul Watson but the appearance propriety of and there is a long time plan to support presents the already not only Rauschenberg the speed of the of performance on go so but thanks to my balls you know who is a publication of this code my colleague Tonya for testing and my wife is therefore 1 patients and
many hours in the evening when I had some of and here the references and probabilistic slides of lots some so many things that kind of
pensions and if they have 1 or 2 minutes for questions few
but quiz will will takes as much of the things forum greater 40 of them and which used to that's my probably only my impression that the canon doubles the differs for century project because actually and what you could do is to extend the bits of their reporting on the exception to include also other threats because action because most of the time what you need is just a trace the grades was the local variables and some of the source code to understand the problem but the core damage of the and over over that most of the time may for most of the projects you just need to report into this and the server although exceptions and you can like most about that's the area that's that's it and by heat and it's also possible didn't show it to limits and and the information that included to just start local squared it only depends on the application what you need and also other solutions like to look at the jungle of something like that right you got the right in the eyes of the the the the mass media this is and also yeah I can answer that that's surely possible but that depends on the inverse as information local running out of time if you do a photo the world's please join results like thank you very much and then this is a
Computer animation
Computer animation
Computer animation
Computer animation
Computer animation
Computer animation
Computer animation
Computer animation
Computer animation
Computer animation
Computer animation


Formal Metadata

Title Post-Mortem Debugging with Heap-Dumps
Title of Series EuroPython 2014
Part Number 75
Number of Parts 120
Author Kruis, Anselm
License CC Attribution 3.0 Unported:
You are free to use, adapt and copy, distribute and transmit the work or content in adapted or unchanged form for any legal purpose as long as the work is attributed to the author in the manner specified by the author or licensor.
DOI 10.5446/19943
Publisher EuroPython
Release Date 2014
Language English
Production Place Berlin

Content Metadata

Subject Area Information technology
Abstract Anselm Kruis - Post-Mortem Debugging with Heap-Dumps UNIX core-dumps, Windows minidumps or Java heap-dumps are well established technologies for post-mortem defect analysis. I'll present a similar technology for Python. An improved pickling mechanism makes it possible to serialise the state of a Python program for subsequent analysis with a conventional Python-debugger. ----- Post-Mortem Debugging with Heap-Dumps === UNIX core-dumps, Windows minidumps and analogous solutions of other operating systems are well established technologies for post-mortem defect analysis of native-code processes. In principle those dumps can be used to analyse „interpreted“ programs running within a native-code interpreter-process. However in practise this approach is tedious and not always successful. Therefore operating system independent dump methods were developed for some „interpreted“ languages. A prominent example are Java heap dumps. Unfortunately up to now there was no practically usable dump-method for Python. Various attempts were made to utilise OS-level dump methods. In 2012 Eli Finer published the Python module *pydump*. This module pickles the traceback of an exception and subsequently uses the pdb debugger to analyse the unpickled traceback. Unfortunately *pydump* fails on PicklingErrors. In my talk I'll present the Python package [*pyheapdump*]. It has the same operation principle as Eli's *pydump*, but is an independent implementation. *pyheapdump* uses an extended pickler ([sPickle] to serialise all relevant objects of a Python process to a file. Later on a fault tolerant unpickler recreates the objects and a common Python debugger can be used to analyse the dump. The pickler extensions make it possible to: * pickle and unpickle many commonly not pickleable objects. * replace the remaining not pickleable objects by surrogate objects so that the resulting object graph is almost isomorphic to the original object graph. Which objects are relevant? In its default operation mode *pyheapdump* uses the frame-stacks of all threads as start point for pickling. Following the usual rules for pickling the dump includes all local variables and all objects reachable from a local variable and so on. That is usually enough for a successful defect analysis. Compared with other Python post-mortem debugging methods *pyheapdump* has several advantages: * It is a pure Python solution and independent from the operation system. * Creation of the pyheapdump and fault analysis can be performed different computers. * It is not obstructive. It does not modify / monkey-patch or disturb the dumped process in any way, with the exception of loading additional modules. * If used with the Pydev-debugger, it supports multi-threaded applications. * If used with the Pydev-debugger and Stackless Python, it supports tasklets. The implementation of *pyheapdump* is fairly small, because it draws most of its functionality from the underlying sPickle package and from the new Stackless-Support of the Pydev-Debugger. Therefore it is - despite of its short history - already a useful piece of software. Outline of the talk --- 1. Introduction to the problem 2. Previous works 3. The concept of *pyheapdump* 4. Live demonstration 5. Open problems and further development 6. Questions and Answers
Keywords EuroPython Conference
EP 2014
EuroPython 2014

Related Material



  454 ms - page object


AV-Portal 3.7.0 (943df4b4639bec127ddc6b93adb0c7d8d995f77c)