Linux solution xhost: Unable to open display

Source: Internet
Author: User
Startx startup graph interface. If xhost +

Practical Tips: Procedure for setting xhost in Linux

Step 1: Use root to log on to Linux and start the VNC service;

Step 2: Set export display = localhost: 1 (1 indicates that VNC is started on the first TTY) based on the port of the VNC. For more information about starting VNC, see Attachment 1;

Step 3: Execute xhost + and prompt "Access Control Disabled, clients can connect from any host.

The operation logs in Linux are as follows:

[Root @ localhost ~] # Vncserver

New 'localhost: 1 (Root) 'desktop is localhost: 1

Starting applications specified in/root/. VNC/xstartuplog file is/root/. VNC/localhost: 1.log

[Root @ localhost ~] # Export display = localhost: 1

[Root @ localhost ~] # Xhost +

Access Control Disabled, clients can connect from any host 

When xhost is set, the problem of unable occurs. The appeal method can be used.

 

Or Alt + F7

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.