Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/regex/19.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ubuntu 已请求X11转发,但未设置显示_Ubuntu_X11_Nvidia Jetson - Fatal编程技术网

Ubuntu 已请求X11转发,但未设置显示

Ubuntu 已请求X11转发,但未设置显示,ubuntu,x11,nvidia-jetson,Ubuntu,X11,Nvidia Jetson,我想在连接到Jetson Xavier nx的macOS上启用x11转发。但是,在连接时: sudo ssh -Xvvv id@host 连接成功建立。但在详细的日志中,我得到以下信息: debug3: send packet: type 50 debug2: we sent a password packet, wait for reply debug3: receive packet: type 52 debug1: Authentication succeeded (password).

我想在连接到Jetson Xavier nx的macOS上启用x11转发。但是,在连接时:

sudo ssh -Xvvv id@host
连接成功建立。但在详细的日志中,我得到以下信息:

debug3: send packet: type 50
debug2: we sent a password packet, wait for reply
debug3: receive packet: type 52
debug1: Authentication succeeded (password).
Authenticated to proto1 ([192.168.1.106]:22).
debug1: channel 0: new [client-session]
debug3: ssh_session2_open: channel_new: 0
debug2: channel 0: send open
debug3: send packet: type 90
debug1: Requesting no-more-sessions@openssh.com
debug3: send packet: type 80
debug1: Entering interactive session.
debug1: pledge: exec
debug3: receive packet: type 80
debug1: client_input_global_request: rtype hostkeys-00@openssh.com want_reply 0
debug3: receive packet: type 91
debug2: channel_input_open_confirmation: channel 0: callback start
debug1: X11 forwarding requested but DISPLAY not set
debug2: fd 4 setting TCP_NODELAY
debug3: ssh_packet_set_tos: set IP_TOS 0x48
debug2: client_session2_setup: id 0
debug2: channel 0: request pty-req confirm 1
debug3: send packet: type 98
debug1: Sending environment.
debug3: Ignored env TERM
debug3: Ignored env SSH_AUTH_SOCK
debug3: Ignored env PATH
debug1: Sending env LANG = en_US.UTF-8
debug2: channel 0: request env confirm 0
debug3: send packet: type 98
debug3: Ignored env HOME
debug3: Ignored env MAIL
debug3: Ignored env LOGNAME
debug3: Ignored env USER
debug3: Ignored env SHELL
debug3: Ignored env SUDO_COMMAND
debug3: Ignored env SUDO_USER
debug3: Ignored env SUDO_UID
debug3: Ignored env SUDO_GID
debug3: Ignored env __CF_USER_TEXT_ENCODING
debug2: channel 0: request shell confirm 1
debug3: send packet: type 98
debug2: channel_input_open_confirmation: channel 0: callback done
debug2: channel 0: open confirm rwindow 0 rmax 32768
debug3: receive packet: type 99
debug2: channel_input_status_confirm: type 99 id 0
debug2: PTY allocation request accepted on channel 0
debug2: channel 0: rcvd adjust 2097152
debug3: receive packet: type 99
debug2: channel_input_status_confirm: type 99 id 0
debug2: shell request accepted on channel 0

为了使X11转发工作,必须在连接时设置显示变量。手动设置显示,如下所示:

export DISPLAY=http://localhost:22

也不行。如何启用X11转发?

当然,这里不应该有
http://
,我认为您的
:22
来自SSH端口,而不是您应该使用的X11显示号码。您在本地计算机上的显示几乎总是
:0.0
,如果您在计算机上
echo$DISPLAY
时,yoiu还没有看到这一点,则可能是出了问题

首先确保您可以单独在Mac上运行X11应用程序。您可能需要安装

尝试在不使用sudo的情况下运行;也许root不允许在Mac上与您的X11对话。另外,也可以在
xterm
窗口中尝试
ssh-X
(手动打开XQuartz时应该会打开,或者可以从其菜单启动),以确保它选择正确的显示

export DISPLAY=http://localhost:22