guacd(서버) · guacamole-client(WAR) · 데이터베이스 · WAS 까지 한 번에 세운다. WAS 는 Apache Tomcat 을 먼저 올려 둔다.
공식 문서: https://guacamole.apache.org/doc/gug/guacamole-native.html
의존성 패키지 설치
sudo apt install -y build-essential
필수 필요 패키지 (Debian)
sudo apt install -y libcairo2-dev libjpeg62-turbo-dev libpng-dev libtool-bin uuid-dev libossp-uuid-dev freerdp2-x11
# 추가 기능 의존성 패키지
# RDP 지원
sudo apt install -y freerdp2-dev
# 세션 녹화 관련
sudo apt install -y libavcodec-dev libavformat-dev libavutil-dev libswscale-dev
# Kubernetes, telnet 등 텍스트 렌더링
sudo apt install -y libpango1.0-dev
# ssh, ftp 지원
sudo apt install -y libssh2-1-dev
# vnc 지원
sudo apt install -y libvncserver-dev
추가 저장소 활성화 (Redhat 계열)
아래 선택 의존성 중 ffmpeg-devel · libvncserver-devel 은 RHEL 계열 기본 저장소에 없다. EPEL · RPM Fusion · CRB 를 먼저 열어둔다. 공식 문서의 의존성 목록은 패키지 이름까지만 적고 저장소 활성화는 다루지 않으므로, 이 단계는 배포판 쪽 준비로 본다.[1]
# config-manager 플러그인과 EPEL
dnf install -y 'dnf-command(config-manager)' epel-release
# RPM Fusion — ffmpeg-devel 이 여기 있다
dnf install -y --nogpgcheck https://mirrors.rpmfusion.org/free/el/rpmfusion-free-release-$(rpm -E %rhel).noarch.rpm
# CodeReady Builder — devel 패키지 다수가 여기 있다
# RHEL · Rocky 9 계열은 crb, 8 계열은 powertools
dnf config-manager --set-enabled crb
dnf update -y
# 소스 빌드 도구
dnf groupinstall -y "Development Tools"
필수 필요 패키지 (Redhat)
sudo dnf install -y cairo-devel libjpeg-turbo-devel libpng-devel libtool libuuid-devel
# 추가 기능 의존성 패키지
# RDP 지원
sudo dnf install -y freerdp-devel
# 세션 녹화 관련
sudo dnf install -y ffmpeg-devel
# Kubernetes, telnet 등 텍스트 렌더링
sudo dnf install -y pango-devel
# ssh, ftp 지원
sudo dnf install -y libssh2-devel
# vnc 지원
sudo dnf install -y libvncserver-devel
# 소스코드 다운로드 및 압축 해제
curl -L -o guacamole-server-1.6.0.tar.gz "https://apache.org/dyn/closer.lua/guacamole/1.6.0/source/guacamole-server-1.6.0.tar.gz?action=download"
tar -xvzf guacamole-server-1.6.0.tar.gz
cd guacamole-server-1.6.0
# 빌드
./configure --with-systemd-dir=/usr/local/lib/systemd/system
...중략...
------------------------------------------------
guacamole-server version 1.6.0
------------------------------------------------
Library status:
freerdp ............. yes (2.x)
pango ............... yes
libavcodec .......... yes
libavformat ......... yes
libavutil ........... yes
libssh2 ............. yes
libssl .............. yes
libswscale .......... yes
libtelnet ........... no
libVNCServer ........ yes
libvorbis ........... no
libpulse ............ no
libwebsockets ....... no
libwebp ............. no
wsock32 ............. no
Protocol support:
Kubernetes .... no
RDP ........... yes
SSH ........... yes
Telnet ........ no
VNC ........... yes
Services / tools:
guacd ...... yes
guacenc .... yes
guaclog .... yes
FreeRDP plugins: /usr/lib/x86_64-linux-gnu/freerdp2
Init scripts: no
Systemd units: /usr/local/lib/systemd/system
Type "make" to compile guacamole-server.
# Make
make
...
make all-recursive
make[1]: Entering directory '/root/temp/guacamole-server-1.6.0'
Making all in src/libguac
make[2]: Entering directory '/root/temp/guacamole-server
...중략...
make[2]: Leaving directory '/root/temp/guacamole-server-1.6.0/src/guaclog'
make[2]: Entering directory '/root/temp/guacamole-server-1.6.0'
make[2]: Leaving directory '/root/temp/guacamole-server-1.6.0'
make[1]: Leaving directory '/root/temp/guacamole-server-1.6.0'
# make install
make install
...중략...
make[1]: Entering directory '/root/temp/guacamole-server-1.6.0'
make[2]: Entering directory '/root/temp/guacamole-server-1.6.0'
make[2]: Nothing to be done for 'install-exec-am'.
make[2]: Nothing to be done for 'install-data-am'.
make[2]: Leaving directory '/root/temp/guacamole-server-1.6.0'
make[1]: Leaving directory '/root/temp/guacamole-server-1.6.0'
# 라이브러리 시스템 캐시 업데이트
ldconfig
# Guacamole server binary
/usr/bin/guacd
# Guacamole server libraries
/lib
libguac-client-rdp.a
libguac-client-rdp.la
libguac-client-rdp.so -> libguac-client-rdp.so.0.0.0
libguac-client-rdp.so.0 -> libguac-client-rdp.so.0.0.0
libguac-client-rdp.so.0.0.0
libguac-client-ssh.a
libguac-client-ssh.la
libguac-client-ssh.so -> libguac-client-ssh.so.0.0.0
libguac-client-ssh.so.0 -> libguac-client-ssh.so.0.0.0
libguac-client-ssh.so.0.0.0
libguac-client-vnc.a
libguac-client-vnc.la
libguac-client-vnc.so -> libguac-client-vnc.so.0.0.0
libguac-client-vnc.so.0 -> libguac-client-vnc.so.0.0.0
libguac-client-vnc.so.0.0.0
libguac-terminal.a
libguac-terminal.la
libguac-terminal.so -> libguac-terminal.so.2.0.0
libguac-terminal.so.2 -> libguac-terminal.so.2.0.0
libguac-terminal.so.2.0.0
libguac.a
libguac.la
libguac.so -> libguac.so.25.0.0
libguac.so.25 -> libguac.so.25.0.0
libguac.so.25.0.0
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/lib
/usr/local/lib/systemd/system/guacd.service 에 파일이 위치하게 된다.# /lib/systemd/system/guacd.service
[Unit]
Description=Guacamole Server
Documentation=man:guacd(8)
After=network.target
[Service]
Environment="GUACAMOLE_HOME=/etc/guacamole"
User=daemon
ExecStart=/usr/local/sbin/guacd -f -L debug
Restart=on-abnormal
StandardOutput=file:/var/log/guacd/guacd.log
StandardError=file:/var/log/guacd/guacd.log
[Install]
WantedBy=multi-user.target
# maven 빌드를 위한 사전 작업 (JDK, maven, nodejs)
sudo apt install -y nodejs npm openjdk-17-jdk maven build-essential
# npm 업그레이드
sudo npm install -g n
sudo n 20
# npm 설치
sudo npm install -g npm
sudo npm install -g jsdoc
export JAVA_HOME=/lib/jvm/java-17-openjdk-amd64
# 소스코드 다운로드 및 압축 해제
curl -L -o guacamole-client-1.6.0.tar.gz "https://apache.org/dyn/closer.lua/guacamole/1.6.0/source/guacamole-client-1.6.0.tar.gz?action=download"
tar -xvzf guacamole-client-1.6.0.tar.gz
cd guacamole-client-1.6.0/
sudo npm install -g jsdoc
...중략...
added 172 packages, and audited 173 packages in 7s
...후략
vi guacamole-client-1.6.0/guacamole-common-js/pom.xml
<!-- Generate documentation using JSDoc -->
<execution>
<id>generate-docs</id>
<goals>
<goal>npx</goal>
</goals>
<!-- 아래 phase 수정 -->
<!-- <phase>package</phase> -->
<phase>none</phase>
<configuration>
<arguments>jsdoc -c jsdoc-conf.json</arguments>
</configuration>
</execution>
# debug logs 출력
# mvn clean package -X -DskipTests -Dfrontend.skip=true
mvn clean package -DskipTests -Dfrontend.skip=true
...중략...
[INFO] guacamole-auth-sso-dist ............................ SUCCESS [ 2.796 s]
[INFO] guacamole-auth-totp ................................ SUCCESS [ 4.302 s]
[INFO] guacamole-history-recording-storage ................ SUCCESS [ 1.037 s]
[INFO] guacamole-vault .................................... SUCCESS [ 0.125 s]
[INFO] guacamole-vault-base ............................... SUCCESS [ 2.369 s]
[INFO] guacamole-vault-ksm ................................ SUCCESS [ 8.465 s]
[INFO] guacamole-vault-dist ............................... SUCCESS [ 1.202 s]
[INFO] guacamole-display-statistics ....................... SUCCESS [ 0.469 s]
[INFO] guacamole-example .................................. SUCCESS [ 5.430 s]
[INFO] guacamole-playback-example ......................... SUCCESS [ 2.026 s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 19:42 min
[INFO] Finished at: 2025-10-15T15:49:30+09:00
[INFO] ------------------------------------------------------------------------
curl -L -o guacamole-auth-jdbc-1.6.0.tar.gz "https://apache.org/dyn/closer.lua/guacamole/1.6.0/binary/guacamole-auth-jdbc-1.6.0.tar.gz?action=download"
tar -xvzf guacamole-auth-jdbc-1.6.0.tar.gz
cd guacamole-auth-jdbc-1.6.0
cat schema/*.sql | psql -U guacamole -W -h localhost -d guacamole -f -
cp guacamole-client-1.6.0/guacamole/target/guacamole-1.6.0.war $TOMCAT_HOME/webapps/guacamole.war
# rm /usr/local/lib/systemd/system/guacd.servic
# /lib/systemd/system/guacd.service
[Unit]
Description=Guacamole Server
Documentation=man:guacd(8)
After=network.target
[Service]
Environment="GUACAMOLE_HOME=/etc/guacamole"
User=daemon
ExecStart=/usr/local/sbin/guacd -f -L debug
Restart=on-abnormal
StandardOutput=file:/var/log/guacd/guacd.log
StandardError=file:/var/log/guacd/guacd.log
[Install]
WantedBy=multi-user.target
# 계정 생성
groupadd -g 1000 guacamole
useradd -g 1000 -u 1000 -m -d /home/guacamole guacamole
# Guacamole home 설정
sudo -u guacamole echo "export GUACAMOLE_HOME=/etc/guacamole" >> /home/guacamole/.bashrc
# 설정 디렉토리 생성
mkdir /etc/guacamole
mkdir /etc/guacamole/lib
mkdir /etc/guacamole/extensions
# guacamole postgresql auth 라이브러리
cp ./guacamole-auth-jdbc-1.6.0/postgresql/guacamole-auth-jdbc-postgresql-1.6.0.jar /etc/guacamole/extensions/
#chown -R guacamole:guacamole /etc/guacamole
# JDBC driver
curl -L -o /etc/guacamole/lib/postgresql.jar https://jdbc.postgresql.org/download/postgresql-42.7.8.jar
# guacamole.properties
cat <<EOF | sudo tee -a /etc/guacamole/guacamole.properties
guacd-hostname:${GUACD_HOSTNAME}
guacd-port:4822
auth-provider:net.sourceforge.guacamole.net.auth.postgresql.PostgreSQLAuthenticationProvider
postgresql-hostname:localhost
postgresql-port:5432
postgresql-database:guacamole
postgresql-username:guacamole
postgresql-password:${REDACTED}
libguac-log-level:debug
EOF
auth-provider는 0.9.x 시절 속성이다. 1.6.0 공식 설정 문서의 속성 목록에 없고, JDBC 인증은GUACAMOLE_HOME/extensions/에 넣은guacamole-auth-jdbc-postgresql-1.6.0.jar를 기동 시 자동으로 읽어 동작한다. 위 블록의auth-provider줄은 없어도 된다.libguac-log-level도 공식 속성 목록에 없다 — guacd 로그 수준은 아래guacd.conf의[logging] level이나 명령줄-L로 정한다.[2]
cat <<EOF | sudo tee -a /etc/guacamole/guacd.conf
[daemon]
bind_host = 0.0.0.0
bind_port = 4822
[logging]
# error, warning, info, debug, trace
level = debug
syslog = no
log_file = /var/log/guacd.log
EOF
# /lib/systemd/system/tomcat.service
systemctl restart tomcat
# /usr/local/lib/systemd/system/guacd.service
systemctl enable guacd --now
systemctl restart guacd
연결이 붙지 않을 때는 guacd 를 포그라운드로 띄워 로그를 직접 본다. 이때는 systemd 유닛을 멈추고 돌린다.
systemctl stop guacd
/usr/local/sbin/guacd -f -b 0.0.0.0 -l 4822 -L debug
| 옵션 | 뜻 |
|---|---|
-b HOST |
접속 대기 주소 |
-l PORT |
접속 대기 포트. 기본 4822 |
-L LEVEL |
로그 수준. trace · debug · info · warning · error, 기본 info |
-f |
백그라운드로 넘어가지 않고 포그라운드로 실행 |
-p FILE |
데견 프로세스의 PID 를 적을 파일 |
-C FILE · -K FILE |
SSL/TLS 인증서 · 개인키 |
-v |
버전만 찍고 종료 |
옵션과 로그 수준은 guacd(8) 맨페이지 기준이다.[3]
powershell 관리자 권한으로 실행
# 백업 (대체)
reg export "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp" "$env:USERPROFILE\Desktop\RDP-Tcp-backup.reg"
# 값 설정
$path = 'HKLM:\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp'
Set-ItemProperty -Path $path -Name SecurityLayer -Value 1 -Type DWord
Set-ItemProperty -Path $path -Name UserAuthentication -Value 0 -Type DWord
# (선택) 원격 데스크톱 서비스 재시작 — 주의: 연결이 끊깁니다.
Restart-Service -Name TermService -Force
guacamole-server 빌드 의존성 (RHEL/CentOS 필수 · 선택 패키지) — 2026-09-20 확인. https://guacamole.apache.org/doc/gug/guacamole-native.html ↩︎
Apache Guacamole 1.6.0 설정 속성 목록 — 2026-09-20 확인. https://guacamole.apache.org/doc/gug/configuring-guacamole.html ↩︎
guacd(8) 맨페이지 — 2026-09-20 확인. https://github.com/apache/guacamole-server/blob/main/src/guacd/man/guacd.8.in ↩︎