1. Linux installation (root user operation) 1. Install vncserver; 2. Install vncviewer; 3. Stop and disable the firewall; systemctl stop firewalld.service systemctl disable firewalld.service 4. Install Linux graphical desktop yum groupinstall "GNOME Desktop" "Graphical Administration Tools" 2. Configuration 1. Modify the startup file Fill it with the following content: VNCSERVERS="1:root" VNCSERVERARGS[1]="-geometry 1200x800" gnome-session & Indicates that the window is based on the geome desktop configuration 2. Create a new configuration file, taking window No. 1 as an example (you can also open multiple windows at the same time, just change the number), the method is as follows: cp /lib/systemd/system/[email protected] /lib/systemd/system/vncserver@:1.service Or add another window: cp /lib/systemd/system/[email protected] /lib/systemd/system/vncserver@:2.service Edit /lib/systemd/system/vncserver@:1.service and set the user root related parameters. The final content is as follows: [Unit] Description=Remote desktop service (VNC) After=syslog.target network.target [Service] Type=forking # Clean any existing files in /tmp/.X11-unix environment ExecStartPre=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :' ExecStart=/usr/sbin/runuser -l root -c "/usr/bin/vncserver %i" PIDFile=/root/.vnc/%H%i.pid ExecStop=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :' [Install] WantedBy=multi-user.target #Start window 1 vncserver :1 # View the startup list status vncserver -list The result of a successful startup should be as follows:
View the log to obtain the port number: cat /root/.vnc/eunke-network002:1.log If the startup fails, enter the folder, delete the X1 file, and restart Window 1: cd /tmp/.X11-unix rm -rf X1 # Kill window 1 vncserver -kill :1 #Start window 1 vncserver :1 4. Install VNC viewer on Windows 1. 64bit download address: https://www.realvnc.com/download/file/viewer.files/VNC-Viewer-6.19.923-Windows-64bit.exe 2. After installation, enter IP: port as follows: After pressing Enter, the remote Linux desktop will be opened. Summarize The above is the operation method of installing the graphical interface of Linux introduced by the editor. I hope it will be helpful to everyone. If you have any questions, please leave me a message and the editor will reply to you in time. I would also like to thank everyone for their support of the 123WORDPRESS.COM website! You may also be interested in:
|
<<: Problems and solutions of using jsx syntax in React-vscode
>>: About React Native unable to link to the simulator
Preface Whether it is a stand-alone lock or a dis...
A list is defined as a form of text or chart that...
Table of contents 1. child_process 2. Command exe...
1. Related concepts 1.1 Jenkins Concepts: Jenkins...
Solution: Add the following code in <head>: ...
Many people have encountered this error when star...
The implementation principle of chain programming...
This article shares the specific code of js to im...
Table of contents question background Idea & ...
Create a new project test1 on Code Cloud Enter th...
Preface Recently I encountered a deadlock problem...
It is almost a standard feature for websites nowa...
Shell is a program written in C language, which i...
1. Permanent modification, valid for all users # ...
Table of contents Prerequisites RN passes value t...