Thanks for support,
The reason is because I didn't enable it for CLI profile. Here is the mine after enable it:
# php --version
PHP 8.1.2-1ubuntu2.14 (cli) (built: Aug 18 2023 11:41:11) (NTS)
Copyright (c) The PHP Group
Zend Engine v4.1.2, Copyright (c) Zend Technologies
with Xdebug v3.1.2, Copyright (c) 2002-2021, by Derick Rethans
But even after I enable it for CLI profile, the breakpoint is still not work. Btw, here is the latest 20-xdebug.ini
:
zend_extension=xdebug.so
xdebug.mode=develop,trace,debug
xdebug.client_host = 127.0.0.1
xdebug.client_port = 9003
xdebug.start_with_request=trigger
xdebug.remote_autostart=1
xdebug.remote_enable=1
I tried with xdebug.start_with_request=yes
and it didn't work as well.