Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HAWQ-1480 - Added documentation for packcore utility #123

Closed
wants to merge 3 commits into from

Conversation

outofmem0ry
Copy link
Contributor

No description provided.

@outofmem0ry
Copy link
Contributor Author

@dyozie this PR is pending for review. The packcore utility is already committed in hawq branch. This PR addresses its usage.

Copy link
Contributor

@janebeckman janebeckman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am assuming the commands are issued by gpadmin. It would be more consistent with our other documents if the code snippets were individual lines, prefaced with a "$" prompt, with the "or" between them as plaintext (not part of the code block).


## <a id="packcore_definition"></a>Packcore

Packcore utility helps in packing a core file with its context – executable, application and system shared libraries from the current environment. This information can be later unpacked on a different system and can be used for debugging. Packcore takes a core file, extracts the name of the binary which generated the core and executes `ldd` (List Dynamic Dependencies) to get the required information into a single tar archive.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Packcore utility helps pack a core file with its context, including the executable, application, and shared system libraries from the current environment. This information can be unpacked for later debugging on a different system. Packcore extracts the name of the binary that generated the core from the core file, then executes ldd (List Dynamic Dependencies) to create a single tar archive containing the core file information.


## <a id="core_file_definition"></a>Core file

Core file is a disk file that records the image of a process' memory in case the process crashes or terminates abruptly. This image can be later used to debug the state of process at the time when it was terminated. This information can be very useful to debug the cause failure.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A core file is a disk file that records the memory image of a running process in the event the process crashes or terminates abruptly. The information in this image is useful for debugging the state of a process at the time when it was terminated.


### <a id="using_packcore"></a>Using packcore

The packcore utility is located under `${GPHOME}/sbin`. Following are the options for packing a core file:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Run one of the following commands to pack a core file:


./packcore -b|--binary $GPHOME/bin/postgres <core_file>
```
Once finished the utility will create a tar file named `packcore-<core_file>.tgz`. This file can be later unpacked on another system and used for debugging.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When processing is completed, the utility creates a tar file in the format: packcore-<core_file>.tgz. Unpack this file on another system to use it for debugging.

@outofmem0ry
Copy link
Contributor Author

@janebeckman Thank you for the review. Incorporated your review comments in the latest commit.

@@ -117,6 +117,9 @@
<li>
<a href="/docs/userguide/2.2.0.0-incubating/admin/logfiles.html">HAWQ Administrative Log Files</a>
</li>
<li>
<a href="/docs/userguide/2.2.0.0-incubating/admin/packcore.html">HAWQ packcore utility</a>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is very minor - how about capitalizing the U in "utility"?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lisakowen changed the heading format to make it similar to naming convention of other headings.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @outofmem0ry - merging this in now.

@asfgit asfgit closed this in bce28fa Oct 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants