x forwarding issue
I'm using MacBook Pro with M2 Pro, Ventura 13.4.1.
I'm trying to ssh to linux PC. So from my mac to linux.
I installed XQuartz 2.8.3.
'xclock' works on XQuartz terminal (before ssh). Right click XQuartz -> Applications -> terminal. 'xclock' works. I also tried sshing on this terminal and 'xclock' also works on linux side terminal. Of course it also works after ssh.
However, 'xclock' doesn't work in my mac terminal.
When I type 'xclock' (before ssh), output is: "Error: Can't open display: /private/tmp/com.apple.launchd.Su4Z2M2fv2/org.xquartz:0"
'echo $DISPLAY' gives me "/private/tmp/com.apple.launchd.Su4Z2M2fv2/org.xquartz:0"
In my mac terminal after ssh, when I type 'xclock', it gives me
"connect /private/tmp/com.apple.launchd.Su4Z2M2fv2/org.xquartz:0: Connection refused
Error: Can't open display: localhost:12.0"
I also tried editing 'etc/ssh/ssh_config' file. I made this modification:
ForwardAgent yes
ForwardX11 yes
It was like this before:
# ForwardAgent no
# ForwardX11 no
Any help is appreciated!! Thanks!
MacBook Pro 14″, macOS 13.4