becgiggs 2021-12-20 17:52 采纳率: 0%
浏览 81
已结题

vscode 在ubuntu下面,postgresql 调试,attach报错:Password: [1] + Stopped (tty output)

问题遇到的现象和发生背景

vscode调试postgresql,f5启动,要是lacuch模式就能进main里面的断点,可attach的时候,也能提示是否授权,选Y以后,就直接推出了,jobs stopped 。
如果不是调试模式,正常数据库操作都是可以的。
select * from t1;也进不了断点,报错正常的断点都进不去。

    {
        "name": "postgres --help",
        "type": "cppdbg",
        "request": "launch",
        "program": "/usr/local/pgsql/bin/postgres",
        "args": [
            "--help"
        ],
        "stopAtEntry": false,
        "cwd": "${fileDirname}",
        "environment": [],
        "externalConsole": false,
        "MIMode": "gdb",
        "setupCommands": [
            {
                "description": "Enable pretty-printing for gdb",
                "text": "-enable-pretty-printing",
                "ignoreFailures": true
            }
        ]
    },
    {
        "name": "initdb",
        "type": "cppdbg",
        "request": "launch",
        "program": "/usr/local/pgsql/bin/initdb",
        "args": [
            "-D",
            "<datadir>"
        ],
        "stopAtEntry": false,
        "cwd": "${fileDirname}",
        "environment": [],
        "externalConsole": false,
        "MIMode": "gdb",
        "setupCommands": [
            {
                "description": "Enable pretty-printing for gdb",
                "text": "-enable-pretty-printing",
                "ignoreFailures": true
            }
        ]
    },
    {
        "name": "postgres backend",
        "type": "cppdbg",
        "request": "attach",
        "program": "/usr/local/pgsql/bin/postgres",
        "processId": "${command:pickProcess}",
        "MIMode": "gdb",
        "setupCommands": [
            {
                "description": "Enable pretty-printing for gdb",
                "text": "-enable-pretty-printing",
                "ignoreFailures": true
            }
        ]
    
问题相关代码,请勿粘贴截图
运行结果及报错内容

==== AUTHENTICATING FOR org.freedesktop.policykit.exec ===
Authentication is needed to run `/usr/bin/gdb' as the super user
Authenticating as: ubuntt,,, (pg)
Password: [1] + Stopped (tty output) /usr/bin/pkexec "/usr/bin/gdb" --interpreter=mi --tty=${DbgTerm} 0<"/tmp/Microsoft-MIEngine-In-bxee44gi.4p3" 1>"/tmp/Microsoft-MIEngine-Out-yczbw40g.ttw"
You have stopped jobs.

我的解答思路和尝试过的方法
我想要达到的结果

怎么才能进planner.c里面的断点啊。

  • 写回答

1条回答 默认 最新

  • 有问必答小助手 2021-12-21 18:14
    关注

    你好,我是有问必答小助手,非常抱歉,本次您提出的有问必答问题,技术专家团超时未为您做出解答


    本次提问扣除的有问必答次数,将会以问答VIP体验卡(1次有问必答机会、商城购买实体图书享受95折优惠)的形式为您补发到账户。


    因为有问必答VIP体验卡有效期仅有1天,您在需要使用的时候【私信】联系我,我会为您补发。

    评论

报告相同问题?

问题事件

  • 系统已结题 12月28日
  • 创建了问题 12月20日

悬赏问题

  • ¥15 基于卷积神经网络的声纹识别
  • ¥15 Python中的request,如何使用ssr节点,通过代理requests网页。本人在泰国,需要用大陆ip才能玩网页游戏,合法合规。
  • ¥100 为什么这个恒流源电路不能恒流?
  • ¥15 有偿求跨组件数据流路径图
  • ¥15 写一个方法checkPerson,入参实体类Person,出参布尔值
  • ¥15 我想咨询一下路面纹理三维点云数据处理的一些问题,上传的坐标文件里是怎么对无序点进行编号的,以及xy坐标在处理的时候是进行整体模型分片处理的吗
  • ¥15 CSAPPattacklab
  • ¥15 一直显示正在等待HID—ISP
  • ¥15 Python turtle 画图
  • ¥15 stm32开发clion时遇到的编译问题