Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to realize Linux remote Desktop with TigerVNC

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

This article mainly introduces "how to use TigerVNC to achieve Linux remote desktop". In daily operation, I believe many people have doubts about how to use TigerVNC to achieve Linux remote desktop. The editor consulted all kinds of materials and sorted out simple and easy-to-use methods of operation. I hope it will be helpful for you to answer the doubt of "how to use TigerVNC to achieve Linux remote desktop"! Next, please follow the editor to study!

Tigervnc configuration

1. Confirm that SSH is running

two。 Install TigerVNC Server

Yum install tigervnc-server

Already installed

Yum info tigervnc-server

You can view what has been installed

3. Configure display resolution, products, and users

Edit / etc/sysconfig/vncservers

Refer to the last two lines commented out and add 2 lines

VNCSERVERS= "2:myname"

VNCSERVERARGS [2] = "- geometry 1024x768-nolisten tcp"

In this step, get rid of-localhost.

4. Configure VNC desktop environment and password

Log in to Linux with the user name configured above, and then start vncserver, and then vncserver loads the local path and environment information of the corresponding user, thereby storing the VNC authentication, log, etc. of the user to the corresponding path.

Command line execution:

$vncserver

When executing for the first time, you will be prompted to set the password, and you can enter it according to the prompt.

You will require a password to access your desktops.

Password:

Verify:

Xauth: creating new authority file / home/xf/.Xauthority

New 'xf:1 (xf)' desktop is xf:1

Creating default startup script / home/xf/.vnc/xstartup

Starting applications specified in / home/xf/.vnc/xstartup

Log file is / home/xf/.vnc/xf:1.log

As shown above, the .vnc directory and several files are generated under the current user directory.

5. Start the VNC Server service

Log in as an administrator and stop the service first

# service vncserver stop

If you see an error message, it doesn't matter, it just means that the service has not been started.

Start the service

# service vncserver start

I didn't use the firewall in step 6 and step 7 in the original text, because they have been turned off directly.

8. Configure port forwarding on the router

I don't have a router. Skip it.

9. Install the VNC client

Windows system can use VNC Viewer,Fedora Linux to have its own Remote Desktop Viewer, and you can also choose to install other good client software, such as TightVNC client.

10. Connect to the VNC server

You should be able to connect at this time and access it from another machine.

Enter the name or IP address of the remote machine at the connection address. The default port is 5902, such as:

10.0.10.208:5092

Press the prompt to enter the password set by the user with vncserver when logging in, and you should be able to see the remote desktop normally. Note that VNC launches a completely different second desktop, and desktop preferences can be configured separately from the desktop that the user logs in directly on the Linux machine.

11. Connect via SSH Tunnel (SSH Tunnel)

SecureCRT first creates a connection to the target Linux server, then options menu-> session options-> connection-> Port forwarding, add "add" in the "local port forwarding" point, write a descriptive name such as "VNC" in the name, and then write down the port used by the remote VNC server on both the local port and the remote port, which is 5902. Exit and reconnect.

twelve。 Server-side security settings

Log in as an administrator

Edit / etc/sysconfig/vncservers

Put

VNCSERVERARGS [2] = "- geometry 1024x768-nolisten tcp"

Plus

VNCSERVERARGS [2] = "- geometry 1024x768-nolisten tcp-localhost"

And then

# service vncserver restart

Then you must maintain the SecureCRT connection state, and then open the VNC client. At this time, the address of the connection server should be changed from the previous ip address: 5902 to localhost:5902, and you can connect.

At this point, the study on "how to use TigerVNC to achieve Linux remote Desktop" is over. I hope to be able to solve your doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report