Rate This Document
Findability
Accuracy
Completeness
Readability

Error "cannot connect to X server" Reported During the Verification

Symptom

During the verification, a message is displayed stating "PipedViewerPQ: cannot connect to X server".

Key Process and Cause Analysis

X11-forwarding is not enabled.

Conclusion and Solution

  1. Exit from the current screen.
    CTRL+ Z
  2. Run the following command:
    yum install -y xorg-x11-xauth xorg-x11-fonts* xorg-x11-font-utils xorg-x11-fonts-Type1 xclock
  3. Modify the /etc/ssh/sshd_config file.
    1. Open the /etc/ssh/sshd_config file.
      vi /etc/ssh/sshd_config
    2. Press i to enter the edit mode and change the value of X11Forwarding in line 100 to yes.

      After performing 3.a, press Esc, type :set nu, and press Enter to display the line number.

    3. Press Esc, type :wq!, and press Enter to save the file and exit.
  4. Restart the SSHD service.
    systemctl restart sshd

    Open the SSH window again and connect to the server. If X11-forwarding is ticked, it is enabled successfully.

  5. Perform 7 again.