0

For OpenSSH clients, X forwarding may be configured for all connection to any SSH server, as follows, in ~/.ssh/config:

ForwardX11 yes

Some servers are not configured for support of X forwarding, leading to the following warning:

X11 forwarding request failed

How may the warning be disabled through client configuration?

Note that the objective is not to allow X forwarding to the target server, which would of course carry the effect of removing the warning. The objective is simply to remove the warning. for any server, in spite of such a failure, such as not to clutter console output.

4
  • Do you want to disable this specific warning only? ssh -q suppresses most warnings, but at the moment I cannot test it against the warning you're asking about. Commented Nov 5, 2022 at 7:22
  • @Kamil, While the suggestion is good in principle, unfortunately it is not helpful for the immediate problem. First, it actually has no effect for the given warning. Second, the warning primarily has appeared when an SSH session is invoked by particular client applications, such as rsync. Of course, even if it worked, it would also suppress more than just the target warning.
    – brainchild
    Commented Nov 6, 2022 at 9:26
  • (1) I have just tested. In my tests -q does suppress X11 forwarding request failed on channel …. (2) There is rsync -e, e.g. rsync -e 'ssh -q' …. Alternatively (and more universally) you can put LogLevel QUIET or LogLevel FATAL in ssh_config. (3) "… more than just the target warning" – True, therefore I asked you if you want to disable this specific warning only. You have not addressed this clearly. Commented Nov 6, 2022 at 11:06
  • 1
    @Kamil, Yes, sorry, I have not answered the question. Ideally, I would wish to disable only the particular warning, without affecting any other.
    – brainchild
    Commented Nov 6, 2022 at 11:37

0

You must log in to answer this question.

Browse other questions tagged .