安装所需要的组件.
由于CentOS没有官方FFmpeg rpm软件包,我们可以使用第三方YUM源(Nux Dextop)完成此工作.
yum -y install epel-release
rpm -Uvh http://li.nux.ro/download/nux/dextop/el7/x86_64/nux-dextop-release-0-5.el7.nux.noarch.rpm
yum install cairo-devel libjpeg-turbo-devel libpng-devel uuid-devel libjpeg-devel freerdp-devel pango-devel libssh2-devel libtelnet-devel libvncserver-devel pulseaudio-libs-devel openssl-devel libvorbis-devel libwebp-devel ffmpeg-devel libwebsockets-devel freerdp-plugins git libtool java-1.8.0-openjdk-devel wget tomcat mariadb-server dejavu-lgc-sans-mono-fonts -y
安装Guacamole Server
git clone https://github.com/apache/guacamole-server.git
cd guacamole-server
autoreconf -fi
./configure --with-init-dir=/etc/init.d
make && make install && ldconfig

安装Guacamole Client
先下载Apache-maven,安装Client需要
wget http://mirror.bit.edu.cn/apache/maven/maven-3/3.6.1/binaries/apache-maven-3.6.1-bin.tar.gz
tar -zxvf apache-maven-3.6.1-bin.tar.gz
git clone https://github.com/apache/guacamole-client.git
cd guacamole-client/
~/apache-maven-3.6.1/bin/mvn package
cp guacamole/target/guacamole-1.1.0.war /var/lib/tomcat/webapps/guacamole.war

创建数据库
create database guacamole;
create user guacamole@localhost identified
by 'guacamole';
grant all privileges on guacamole.* to
guacamole@localhost identified by 'guacamole';
flush privileges;
导入数据库
cat guacamole-client/extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-mysql/schema/*.sql | mysql -u root -p guacamole
创建目录
mkdir /etc/guacamole
mkdir /etc/guacamole/extensions
mkdir /etc/guacamole/lib
cp guacamole-client/extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-mysql/target/guacamole-auth-jdbc-mysql-1.1.0.jar /etc/guacamole/extensions/
wget https://dev.mysql.com/get/Downloads/Connector-J/mysql-connector-java-5.1.47.tar.gz
tar -zxvf mysql-connector-java-5.1.47.tar.gz
cp mysql-connector-java-5.1.47/mysql-connector-java-5.1.47.jar /etc/guacamole/lib/
vi /etc/guacamole/guacamole.properties
然后贴入以下内容
#Hostname and port of guacamole proxy
guacd-hostname: localhost
guacd-port: 4822
#MySQL properties
mysql-hostname: localhost
mysql-port: 3306
mysql-database: guacamole
mysql-username: guacamole
mysql-password: guacamole
启动tomcat及guacd
/etc/init.d/guacd start
systemctl restart tomcat mariadb
打开防火墙8080端口
firewall-cmd --add-port=8080/tcp --permanent
firewall-cmd --reload
如果访问有问题,尝试关闭SELINUX
Username:guacadmin
Password:guacadmin

正文完