Advertisement
metalx1000

basic vnc setup

Aug 16th, 2022 (edited)
1,518
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.53 KB | Source Code | 0 0
  1. ####on server/remote machine
  2. #install
  3. sudo apt install x11vnc
  4.  
  5. #start without password
  6. x11vnc -rfbauth -auth ~/.Xauthority -display :0
  7.  
  8. #create password (by default it's stored in ~/.vnc/passwd)
  9. x11vnc -storepasswd
  10.  
  11. #start server
  12. x11vnc -rfbauth ~/.vnc/passwd -auth ~/.Xauthority -display :0
  13.  
  14.  
  15. #on client/local machine
  16. #install
  17. sudo apt install tigervnc-viewer
  18.  
  19. #connect
  20. vncviewer <ip address>
  21.  
  22.  
  23. ###Through SSH Tunneling###
  24. #on the client
  25. ssh user@host -L 5900:localhost:5900 x11vnc -localhost -viewonly
  26. vncviewer
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement