Hướng dẫn cài xrdp cho centos 6 năm 2024

Xin chào các bạn, Orange Pi 5 Plus quả là một máy tính nhúng mạnh mẽ, hơn nữa lại còn được hỗ trợ bởi nhiều hệ điều hành khác nhau, trong đó bản porting Centos này cực kỳ tuyệt vời. Như đã giới thiệu trước đây tại Các hệ điều hành cho Orange Pi 5 Plus, chúng ta có thể tải về bản Centos 7 GNOME Desktop tại github này https://github.com/leeboby/centos-images. Tại đó cũng có bản Minimal là CLI nhưng vì tôi sẽ hướng dẫn thêm cài RDP để remote từ xa và aaPanel để quản lý Web service nên tôi sẽ dùng bản GNOME Desktop.

Các hệ điều hành cho Orange Pi 5 Plus

Đầu tiên bạn cần:

  • Orange Pi 5 Plus, bản 8GB hay 16GB RAM tùy theo nhu cầu của bạn
  • thẻ nhớ microSD 16GB tối thiểu, nguồn type-c 5v 3A hoặc 4A
  • bạn cũng sẽ cần màn hình để thao tác, cùng với chuột và bàn phím
  • có thể mua thêm vỏ mica kèm tản và quạt để Orange Pi chạy ổn định hơn
  • hoặc mua thêm ổ ssd nvme 2280 để lưu trữ (nếu bạn định cài cloud storage server.

Đầu tiên bạn tải về file img của hệ điều hành, nó sẽ có tên dạng như vậy opi5plus-centos-7.2009-aarch64-gnome-20230611.img, sử dụng Win32DiskImager hoặc Etcher để flash nó vào thẻ nhớ trên máy tính. Bạn sẽ cần đầu đọc thẻ microSD nếu máy tính bạn chưa có. Sau đó cắm vào Orange Pi 5 Plus và cắm nguồn để khởi động, cắm dây LAN, cắm màn hình và bàn phím như một máy tính thông thường. Hệ thống sẽ khởi động các dòng lệnh và sau đó sẽ hiện lên các bảng câu hỏi để cài đặt Centos, dễ hơn cài windows rất nhiều. Sau khi hoàn thiện các bước này bạn đã có Centos 7 với desktop GNOME như hình bên dưới

Hướng dẫn cài xrdp cho centos 6 năm 2024

Cài XRDP để remote desktop trên Orange Pi 5 Plus

Để remote từ máy tính khác vào Pi thông qua ứng dụng Desktop Remote trên Windows, bạn cần cài đặt XDRP. Các bước cài đặt như sau:

1. Cập nhật hệ thống, khi chạy lệnh này sẽ mất khá lâu, lấy 1 cốc cafe trong lúc chờ $ sudo yum -y update

2. Cài repo và cài đặt XRDP $ sudo yum install -y epel-release $ sudo yum install -y xrdp $ sudo systemctl enable xrdp $ sudo systemctl start xrdp

3. Mở firewall cho cổng 3389 của XRDP $ sudo firewall-cmd --add-port=3389/tcp --permanent $ sudo firewall-cmd --reload

4. Kiểm tra lại xem service XRDP đã chạy chưa $ sudo systemctl status xrdp

Nếu mọi việc OK, bạn sẽ có thể sử dụng máy tính Windows để remote desktop trên Centos 7

Hướng dẫn cài xrdp cho centos 6 năm 2024

Cài aaPanel quản lý web service.

Như đã giới thiệu trước đây aaPanel là một phần mềm miễn phí rất mạnh để quản lý các webserver, trên đó bạn có thể tự động cài LAMP hoặc LNMP tùy thích. Có thể quản lý các docker hoặc ứng dụng docker, rồi sử dụng reversed proxy để mở cổng ra web service.

Bạn có thể tạo các website tĩnh, website với PHP không hoặc với cả PHP và MySQL, thậm chí còn có thể quản lý các ứng dụng NodeJS thông qua việc quản lý các phiên bản nodejs và npm ngay chính tại giao diện quản lý.

Bạn có thể xem thêm về aaPanel tại đây Hướng dẫn cài đặt Server Management aaPanel cho Orange Pi 3 LTS hoặc Orange Pi 4 LTS

Đối với bản Centos này bạn chỉ cần đơn giản chạy lệnh này là xong yum install -y wget && wget -O install.sh http://www.aapanel.com/script/install_6.0_en.sh && bash install.sh aapanel

Sau khi quá trình cài dặt kết thúc, bạn vào giao diện web tại http://IP_của_PI và hoàn tất quá trình cài đặt

Hướng dẫn cài xrdp cho centos 6 năm 2024

Tôi đang có ý định mở cổng internet tại văn phòng, và sử dụng Orange Pi 5 Plus như một webserver host luôn các ứng dụng cần thiết cho Orange Pi, vì thực sự là với cấu hình như vậy Orange Pi 5 Plus vượt xa các gói VPS mà tôi đang sử dụng.

As you reviewed the install VNC on CentOS Linux article, we are going to learn you how to install XRDP and remote to CentOS 6, that you can remotely connect to Centos 6 easily and without any additional settings. You may regret to work with VNC after watching the VNC server setup process. Because it has many steps and is a bit difficult for people who don’t have enough experience with Linux. XRDP is a very efficient tool that after installing it with the help of VNC Server, you will be able to remotely use your Windows desktop remote software to your Linux and use it.

Table of Contents

Install and set the prerequisite to remote Centos 6

1- First, connect to your Centos 6 server via the terminal.

2- Then enter the following command to get the latest software upgrades.

yum upgrade

3- Then enter the following command to install Xorg and the corresponding font.

yum -y install xorg-x11-fonts-Type1 xorg-x11-fonts-truetype

Note: After entering the above command, Xorg may be installed by default and no operation will be performed.

4- In this step, we will go to install the X window desktop environment.

yum -y groupinstall "X Window System" "Desktop"

This step of the installation may take some time, Be patient until it is fully installed.

5- After installing the X window environment, install the Epel Repository.

Install EPEL Repository on Centos 6 32-bit version

rpm -Uvh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm

Install EPEL Repository on Centos 6 64-bit version

rpm -Uvh http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm

After installing and setting the prerequisites, we will continue to install XRDP.

Buy Linux Virtual Private Server

Install XRDP and set it up

1- First, install XRDP and VNC Server by entering the following command.

yum install xrdp tigervnc-server

2- Then start the xrdp service.

service xrdp start

3- Enter the following commands to start the xrdp service and vnc server by default after the centos 6 reboot.

chkconfig xrdp on  chkconfig vncserver on

4- At the end, open the remote port to the server by entering the following command in your firewall.

iptables -A INPUT -p tcp -m state --state NEW -m tcp --dport 3389 -j ACCEPT

5- Then enter the following commands in order to save the changes in IPtables and then restart the iptables service.

service iptables save  service iptables restart

After completing the above steps, we will go to the remote to Centos 6.

remote to Centos 6

1- Open the Windows desktop remote window.

To open this window, search for the phrase remote desktop connection in the Start bar. Or open the run window with Winkey + r and enter mstsc and click OK.

Hướng dẫn cài xrdp cho centos 6 năm 2024

2- Then enter the IP of your centos 6 server and click Connect.

3- After a few seconds, the following similar window will open to confirm the connection, click Yes.

If you do not intend to ask this question for the next time, check the box in the same window.

Hướng dẫn cài xrdp cho centos 6 năm 2024

4- Then enter your Centos 6 username and password on the opened page and enter your Linux desktop environment.

After a few seconds, the Centos 6 desktop will be displayed.

Hướng dẫn cài xrdp cho centos 6 năm 2024

At this point, the XRDP and Remote installation tutorial for Centos 6 is complete.

Hướng dẫn cài xrdp cho centos 6 năm 2024

Dear user, we hope you would enjoy this tutorial, you can ask questions about this training in the comments section, or to solve other problems in the field of Eldernode training, refer to the Ask page section and raise your problems in it.