kfoewfj9042u890jf8035vj3489vjn385vn358vhn358vh35809hv5
vgj34ivh38gfh3789vh34280vh408923vh835809vh358hb+3hb+035b
gvjbvh3589hv8vhj 3pçgjk 204guj340935nb3r5jbitbç
gvjriovbhj83409hvnuvb3r8hv3r8ivbheruobniernb er9jhb439ugj423
__________________________________________________________________________________________________
tunnelling ssh
so to make use of vncserver:
+--------------------------------------------+
|ssh -L 5901:localhost:5901 USER@REMOTE_IP |
+--------------------------------------------+
prompt pass and leave open.
in remote machine (hereby) lets check server is up and runnin
for rpi, maight have to do this:
+-------------------------------------+
| $ sudo apt install tightvncserver |
| $ tightvncserver |
| $ vncpasswd |
+-------------------------------------+
after that create init.d script...
+-------------------------------------+
| sudo nano /etc/init.d/vncboot |
+-------------------------------------+
...........................................................
#! /bin/sh
# /etc/init.d/vncboot
### BEGIN INIT INFO
# Provides: vncboot
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Start VNC Server at boot time
# Description: Start VNC Server at boot time.
### END INIT INFO
USER=pi
HOME=/home/pi
export USER HOME
case "$1" in
start)
echo "Starting VNC Server"
#Insert your favoured settings for a VNC session
su - $USER -c "/usr/bin/vncserver :1 -geometry 1280x600 -depth 24"
;;
stop)
echo "Stopping VNC Server"
/usr/bin/vncserver -kill :1
;;
*)
echo "Usage: /etc/init.d/vncboot {start|stop}"
exit 1
;;
esac
exit 0
...........................................................
after this done, change permissions on vncboot file recently created
+--------------------------------------+
| $ sudo chmod 755 /etc/init.d/vncboot |
+--------------------------------------+
Now leave this terminal and go to local machine, the one you are using ;-)
as root, install:
+---------------------------------+
| apt-get install xtightvncviewer |
+---------------------------------+
then promt -not as root!-:
+-----------+
| vncviewer |
+-----------+
and fill server and port (if copnfigured as uphere, yourser.ver:5901)
and password created...
Renember, in server side, to stop the server:
+----------------------------------------+
| vncserver –kill :1 (pick your display) |
+----------------------------------------+
...and to start it again
+-------------------------------------------+
| vncserver :1 –geometry 1024x600 –depth 24 |
+-------------------------------------------+
4 example!
=)
__________________________________________________________________________________________________
Oh!. Sorry. What you were looking for:
+----------------------------------------------------+
| scp /path/to/file username@a:/path/to/destination |
| |
| scp username@b:/path/to/file /path/to/destination |
+----------------------------------------------------+
Really. This command is most amazing!!!
__________________________________________________________________________________________________
sources:
https://www.techrepublic.com/article/how-to-connect-to-vnc-using-ssh/
https://librebit.github.io/raspberry/raspbian/vnc/server/2016/09/14/habilitar-vnc-server-en-raspberry-pi.html
https://www.tightvnc.com/vncviewer.1.php
fewrhufio43qh8f843yt14789tyty 9pyhfewu8fy 8247r bh7r575kj
tr76498 75 bn7t58041 7rbn57n8 nt0 t3rqq3er qergeqrg3qr9
t 9886 8n9pq3fuiq3r`f82134f80 98f4¡3 9gae50giq3 ger f
refgq953qt 14¡39ie0fi w'782481yhru ogu0984239 tu423pgi0df