Sometimes the x2go client will no longer connect to the x2go server on your target VM. Verify that:

  1. x2go client is configured correctly [https://carleton.ca/scs/2021/ssh-connection-with-x2go-remote-desktop-client/]
  2. Internet connection & Cisco VPN is working [Remote Access (VPN)]
  3. ssh connection (non-graphical) is working to the server [Secure Shell (ssh)]

If all 3 are verified then it is likely your x2go session on the target machine (server VM) is the problem and then continue with the following steps.

Once you login to the server using x2go, the x2go session is saved in your account profile. In rare instances these files can be ‘corrupt’ and are causing your connection to fail.

Here are the steps to delete all the x2go settings on the server:

  1. ssh to your server using a non-graphical ssh client (putty for Windows for example). NOTE, once logged in you can check the file: .xsession-x2go-HOSTNAME-errors if that shows anything obvious. If not proceed.
  2. Then remove the following files in your root (~) homedirectory:
    • rm -rf .x2go
    • rm .Xauthority
    • rm .xsession-x2go*
    • rm -rf .cache/sessions
    • rm -rf .cache/fontconfig
    • sudo rm -rf /tmp/.X11-unix
    • sudo rm -rf /tmp/.ICE-unix

3. Now you have reset your x2go settings on the server: logout and try connecting again using your x2go client.

NOTE: It’s also worth checking if your instance ran out of disk space? If your disk is full then x2go can no longer write session data to disk and it will no longer let you login. Use the command ‘df -h’ and check how much space you left on your VM? If you are at 100% you will need to free space on your disk.