°Ô½Ã¹° 259°Ç
   
[CentOS 7 / Fedora 23 / RHEL 7.2]VNC Server install|
±Û¾´ÀÌ : theko ³¯Â¥ : 2016-11-17 (¸ñ) 22:32 Á¶È¸ : 3423
1. Install
CentOS & RHEL 
yum install tigervnc-server

Fedora 
dnf install tigervnc-server

2. ¼­ºñ½º ÆÄÀÏ »ý¼º ¹× º¯°æ
CentOS & Fedora 
Two users
cp /lib/systemd/system/vncserver@.service /etc/systemd/system/vncserver@:1.service  
# »ç¿ëÀÚ 1 / 5901 Port / Á¢¼ÓÁÖ¼Ò : 192.168.110.106:1

cp /lib/systemd/system/vncserver@.service /etc/systemd/system/vncserver@:2.service  
# »ç¿ëÀÚ 2 / 5902 Port / Á¢¼ÓÁÖ¼Ò : 192.168.110.106:2

vi /etc/systemd/system/vncserver@:1.service
[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 <USER> -c "/usr/bin/vncserver %i"
PIDFile=/home/<USER>/.vnc/%H%i.pid
ExecStop=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :'

<USER> ºÎºÐ¸¸ »ç¿ëÀÚ ID·Î º¯°æ 
Sample : 

[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 oracle -c "/usr/bin/vncserver %i"
PIDFile=/home/oracle/.vnc/%H%i.pid
ExecStop=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :'

RHEL 7
Single user
cp /lib/systemd/system/vncserver@.service /etc/systemd/system/vncserver@.service
vi /etc/systemd/system/vncserver@.service # À§¿Í µ¿ÀÏ
 
Two users
vncserver-USER@.service ·Î »ý¼º  # USER ¸íÀº ½ÇÁ¦ »ç¿ëÀÚ ID
cp /lib/systemd/system/vncserver@.service /etc/systemd/system/vncserver-oracle@.service
vi /etc/systemd/system/vncserver-oracle@.service # À§¿Í µ¿ÀÏ

cp /lib/systemd/system/vncserver@.service /etc/systemd/system/vncserver-mysql@.service
vi /etc/systemd/system/vncserver-mysql@.service # À§¿Í µ¿ÀÏ
 
3. VNC Password ¼³Á¤
ÇØ´ç °èÁ¤À¸·Î ·Î±×ÀÎ Çؼ­ ¿¹ : su - oracle
vncpasswd  # ·Î±×ÀÎ Æнº¿öµå¿Í´Â ¹«°üÇÔ

4. ¹æÈ­º® µî·Ï
CentOS & Fedora 
firewall-cmd --zone=public --add-service vnc-server
# --permanent ¿É¼Ç»ý·« - Àá½Ã¸¸ »ç¿ëÇÔ
firewall-cmd --reload
firewall-cmd --list-all

RHEL 7
º° ´Ù¸¥ ¼³Á¤¾øÀÌ ±×³É Á¢¼ÓµÊ(?)

5. VNC ¼­ºñ½º ½ÃÀÛ
CentOS & Fedora 
systemctl daemon-reload
systemctl start vncserver@:1
systemctl status vncserver@:1 
# enable »ý·« - Àá½Ã¸¸ »ç¿ëÇÔ. ÇÊ¿äÇϸé vncserver@:2 µµ ÇÔ²² ½ÃÀÛ

RHEL 7
Single user
systemctl start vncserver@:1   #  vncserver@:display_number
systemctl daemon-reload
systemctl start vncserver@:1
systemctl status vncserver@:1 

Two users
systemctl start vncserver-oracle@:1  # systemctl start vncserver-USER@:display_number
systemctl daemon-reload
systemctl start vncserver-oracle@:1
systemctl status vncserver-oracle@:1

6. VNC View ·Î Á¢¼Ó
vncpasswd ·Î ÀÔ·ÂÇÑ ¾ÏÈ£¸¦ ÀÔ·Â


[Ãâó] [CentOS 7 / Fedora 23 / RHEL 7.2]VNC Server install|ÀÛ¼ºÀÚ ¶§¸±°Å¾ß

À̸§ Æнº¿öµå
ºñ¹Ð±Û (üũÇÏ¸é ±Û¾´À̸¸ ³»¿ëÀ» È®ÀÎÇÒ ¼ö ÀÖ½À´Ï´Ù.)
¿ÞÂÊÀÇ ±ÛÀÚ¸¦ ÀÔ·ÂÇϼ¼¿ä.
   

miwit.com sir.co.kr DNS Powered by DNSEver.com DNS Powered by DNSEver.com