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

parsedump: Simplify by using poi instead of regex #290

Conversation

EchterAgo
Copy link

Instead of using dt on OpenZFS!cbuf and checking the output we can just use poi(OpenZFS!cbuf) in the .writemem command.

Instead of using `dt` on `OpenZFS!cbuf` and checking the output we can
just use `poi(OpenZFS!cbuf)` in the `.writemem` command.

Signed-off-by: Axel Gembe <[email protected]>
@EchterAgo EchterAgo marked this pull request as ready for review October 15, 2023 05:25
@EchterAgo
Copy link
Author

@andrewc12
Copy link

Dang thats better.

Does this script work for you?
I kept having problems with paths/names being wrong for python and cdb.

@andrewc12 andrewc12 merged commit f8bcabb into openzfsonwindows:zfs-Windows-2.2.0-release Oct 15, 2023
16 of 17 checks passed
@EchterAgo
Copy link
Author

Dang thats better.

Does this script work for you? I kept having problems with paths/names being wrong for python and cdb.

It works for me with some adjustments. I guess we should improve it to use os.environ["ProgramFiles(x86)"], os.environ["windir"] and maybe read the OpenZFS install location from registry. Maybe also have a --zfspath command line override. I can add that.

@EchterAgo EchterAgo deleted the simplify_parsedump branch October 15, 2023 05:38
@andrewc12
Copy link

I think cdb installs in a different place if you install it as part of the win sdk vs directly from the msi.

We might need to check multiple locations

@EchterAgo
Copy link
Author

EchterAgo commented Oct 15, 2023

I'd also really like it to support a KDB connection to a different machine. That would be really helpful to automate remote analysis on certain conditions like low memory, I'd need that for #283

@EchterAgo
Copy link
Author

I think cdb installs in a different place if you install it as part of the win sdk vs directly from the msi.

We might need to check multiple locations

Do you know the other location? I only have these:
image

@andrewc12
Copy link

Yes
"C:\Program Files\Windows Kits\10\Debuggers\x64\cdb.exe"
like in this script

@EchterAgo
Copy link
Author

EchterAgo commented Oct 15, 2023

I think stack = run("k ; q") is also not needed, it is part of !analyze -v

@EchterAgo
Copy link
Author

We could also add some more info like !stacks and !memusage

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants