XQuartz right away quits itself

x11xquartz

macOS Catalina Version 10.15.5

I have downloaded XQuartz from following page (https://www.xquartz.org/). The application installed and shown on the Utilities folder. When I open it, it is shown a second on the docker and always gone away (quits itself). It does not show up on the running applications, so I crashes due to some reason.

enter image description here

I don't know how can I fix this issue, since I am not able to open the application. Is there any way can I fix this issue?

Best Answer

I was able to solve it by running from the Terminal.

run_Xquartz() {
  [ $(ps aux | grep -E '[X]quartz' | wc -l) -gt 0 ] && echo 'Xquartz is already running' \
  || nohup /Applications/Utilities/XQuartz.app/Contents/MacOS/X11.bin > /dev/null 2>&1 &
}

$ run_Xquartz
  • If Xquartz is already running on the background it prints Xquartz is already running.
  • If Xquartz is not running on the background it runs it on the background using nohup.

=> When Xquartz starts running on the dock you will see it.