You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by "AcKing-Sam (via GitHub)" <gi...@apache.org> on 2024/03/18 13:33:09 UTC
[I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
AcKing-Sam opened a new issue, #32423:
URL: https://github.com/apache/doris/issues/32423
### Search before asking
- [X] I had searched in the [issues](https://github.com/apache/doris/issues?q=is%3Aissue) and found no similar issues.
### Description
Hi, everyone. I want to debug backend of Doris by using VSCODE. However, I tried the [official doc](https://doris.apache.org/community/developer-guide/be-vscode-dev/), I still can't lauch the GDB to debug. Could I get some help?
The below is my lauch.json
```json
{
"version": "0.2.0",
"configurations": [
{
"name": "(gdb) Launch",
"type": "cppdbg",
"request": "launch",
"program": "/home/qfshen/workspace/doris/output/be/lib/doris_be",
"args": [],
"stopAtEntry": false,
"cwd": "/home/qfshen/workspace/doris/output/be",
"environment": [{"name":"PALO_HOME","value":"/home/qfshen/workspace/doris/output/be/"},
{"name":"UDF_RUNTIME_DIR","value":"/home/qfshen/workspace/doris/output/be/lib/udf-runtime"},
{"name":"LOG_DIR","value":"/home/qfshen/workspace/doris/output/be/log"},
{"name":"PID_DIR","value":"/home/qfshen/workspace/doris/output/be/bin"}
],
"externalConsole": true,
"MIMode": "gdb",
"miDebuggerPath": "/usr/bin/gdb",
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
}
]
}
]
}
```
The doris location is correct:

Also, my gdb version is :

### Solution
_No response_
### Are you willing to submit PR?
- [ ] Yes I am willing to submit a PR!
### Code of Conduct
- [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "AcKing-Sam (via GitHub)" <gi...@apache.org>.
AcKing-Sam commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-2005832089
> > > I haven't used Launch debugging, but attach debugging doris is very convenient, maybe you can try to use lldb's attach debugging here is my config
> > > ```
> > > {
> > > "name": "CodeLLDB attach",
> > > "type": "lldb",
> > > "request": "attach",
> > > "program": "${workspaceFolder}/output/be/lib/doris_be",
> > > "pid": "${command:pickMyProcess}"
> > > }
> > > ```
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > > Simply select the be process that has been started and you're done!
> >
> >
> > Could you please tell me your dev environment, like size of RAM and number of cores? I doubt that it can't run because of the machine(for me, it's 4c8g ubuntu) :)
>
> My machine is 16c16g, despite that sometimes there's not enough RAM, 4c8g doesn't look like it's up to the minimum configuration
Thanks a lot for your kind help! It seems the machine setting is a reason.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-3288991807
We're closing this issue because it hasn't been updated in a while.
If you'd like to revive this issue, please reopen it and feel free a maintainer to remove the Stale tag!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "AcKing-Sam (via GitHub)" <gi...@apache.org>.
AcKing-Sam commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-2005784743
> I haven't used Launch debugging, but attach debugging doris is very convenient, maybe you can try to use lldb's attach debugging here is my config
>
> ```
> {
> "name": "CodeLLDB attach",
> "type": "lldb",
> "request": "attach",
> "program": "${workspaceFolder}/output/be/lib/doris_be",
> "pid": "${command:pickMyProcess}"
> }
> ```
>
> Simply select the be process that has been started and you're done!
Could you please tell me your dev environment, like size of RAM and number of cores? I doubt that it can't run because of the machine(for me, it's 4c8g ubuntu) :)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "koarz (via GitHub)" <gi...@apache.org>.
koarz commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-2005839520
> > > > I haven't used Launch debugging, but attach debugging doris is very convenient, maybe you can try to use lldb's attach debugging here is my config
> > > > ```
> > > > {
> > > > "name": "CodeLLDB attach",
> > > > "type": "lldb",
> > > > "request": "attach",
> > > > "program": "${workspaceFolder}/output/be/lib/doris_be",
> > > > "pid": "${command:pickMyProcess}"
> > > > }
> > > > ```
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > Simply select the be process that has been started and you're done!
> > >
> > >
> > > Could you please tell me your dev environment, like size of RAM and number of cores? I doubt that it can't run because of the machine(for me, it's 4c8g ubuntu) :)
> >
> >
> > My machine is 16c16g, despite that sometimes there's not enough RAM, 4c8g doesn't look like it's up to the minimum configuration
>
> Thanks a lot for your kind help! It seems the machine setting is a reason.
You're welcome. Try again with a new machine.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "AcKing-Sam (via GitHub)" <gi...@apache.org>.
AcKing-Sam commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-2006101703
@koarz Thanks again for your help! I used my local machine with LLDB's `attach` mode and it can debug successfully!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "morningman (via GitHub)" <gi...@apache.org>.
morningman closed issue #32423: [Enhancement] Doc about How to DEBUG using VSCODE?
URL: https://github.com/apache/doris/issues/32423
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "AcKing-Sam (via GitHub)" <gi...@apache.org>.
AcKing-Sam commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-2006105125
For this issue, it seems that the doc mentioned the machine request is at least ***10c16g*** to run debugger successfully.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "m719030572 (via GitHub)" <gi...@apache.org>.
m719030572 commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-2042004991
When try to gdb attach with process id, i get "DW_FORM_rnglistx index pointing outside of .debug_rnglists offset array [in module /root/doris/output/be/lib/doris_be]
(No debugging symbols found in output/be/lib/doris_be)"
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "AcKing-Sam (via GitHub)" <gi...@apache.org>.
AcKing-Sam commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-2030988972
@codeDing18 Hi, thanks for your suggestion! I compiled the BE by myself. The problem was handled after I changed another machine. ;)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "koarz (via GitHub)" <gi...@apache.org>.
koarz commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-2005767972
But it looks like the documentation's PALO_HOME hasn't been changed to DORIS_HOME, so I reckon I should need to use DORIS_HOME instead of PALO_HOME now
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "AcKing-Sam (via GitHub)" <gi...@apache.org>.
AcKing-Sam commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-2005781062
> I haven't used Launch debugging, but attach debugging doris is very convenient, maybe you can try to use lldb's attach debugging here is my config
>
> ```
> {
> "name": "CodeLLDB attach",
> "type": "lldb",
> "request": "attach",
> "program": "${workspaceFolder}/output/be/lib/doris_be",
> "pid": "${command:pickMyProcess}"
> }
> ```
>
> Simply select the be process that has been started and you're done!
Thanks for your help! I will try using `attach` instead of `launch` to debug.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "codeDing18 (via GitHub)" <gi...@apache.org>.
codeDing18 commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-2030985185
> For this issue, it seems that the doc mentioned the machine request is at least _**10c16g**_ to run debugger successfully.
hi,Is your BE compiled by yourself(`BUILD_TYPE=Debug sh build.sh`) or is it an official package?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "koarz (via GitHub)" <gi...@apache.org>.
koarz commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-2005761639
I haven't used Launch debugging, but attach debugging doris is very convenient, maybe you can try to use lldb's attach debugging
here is my config
```
{
"name": "CodeLLDB attach",
"type": "lldb",
"request": "attach",
"program": "${workspaceFolder}/output/be/lib/doris_be",
"pid": "${command:pickMyProcess}"
}
```
Simply select the be process that has been started and you're done!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "AcKing-Sam (via GitHub)" <gi...@apache.org>.
AcKing-Sam commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-2005782324
> But it looks like the documentation's PALO_HOME hasn't been changed to DORIS_HOME, so I reckon I should need to use DORIS_HOME instead of PALO_HOME now
Yes, I noticed this problem and I changed to `DORIS_HOME`, however it still did not work ;)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [I] [Enhancement] Doc about How to DEBUG using VSCODE? [doris]
Posted by "koarz (via GitHub)" <gi...@apache.org>.
koarz commented on issue #32423:
URL: https://github.com/apache/doris/issues/32423#issuecomment-2005812538
> > I haven't used Launch debugging, but attach debugging doris is very convenient, maybe you can try to use lldb's attach debugging here is my config
> > ```
> > {
> > "name": "CodeLLDB attach",
> > "type": "lldb",
> > "request": "attach",
> > "program": "${workspaceFolder}/output/be/lib/doris_be",
> > "pid": "${command:pickMyProcess}"
> > }
> > ```
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> > Simply select the be process that has been started and you're done!
>
> Could you please tell me your dev environment, like size of RAM and number of cores? I doubt that it can't run because of the machine(for me, it's 4c8g ubuntu) :)
My machine is 16c16g, despite that sometimes there's not enough RAM, 4c8g doesn't look like it's up to the minimum configuration
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org