Using PuTTY to send or retrieve files through a SSH connection via SECOMEA SiteManager -37356
Using PuTTY to send or retrieve files through a SSH connection via SECOMEA SiteManager - 37356
Send files through SSH connection via SECOMEA SiteManager -37356
Example is valid for:
CB3 Software version: 3.3 or newer
Note that older or newer software versions may behave differently.
Purpose:
To enhance the remote connectivity of a UR robot using SECOMEA products.
For basic GateManager/LinkManager/SiteManager setup, check here.
Step One: Install PuTTY from the Internet.
We will be using "pscp.exe" to actually transfer file.s PuTTY includes pscp, but you can also download pscp separately if you so choose.
Step Two: Ready your SiteManager for incoming SSH connections
Opening SSH only requires replacing or adding a few lines in SiteManager.
To access SiteManager, first login to LinkManager Mobile or GateManager using the SECOMEA-provided login. Click the SiteManager Device and then the 'www' button.
Instead of a UR Ethernet device, we’re going to add a new Generic Agent and add some information to the IP address GENERIC -> Device agent with parameters: IP tcp=22 service=rdp,22
Click here for a reference on the SECOMEA page
Step Three: Open the SSH Connection through Putty
So, from here we have a 2 step process: 1) Open an SSH tunnel from our device to the robot via the SiteManager 2) Actually use pscp to copy files to/from the robot.
The non-intuitive part of this is that each of these kind of looks like a new connection, and the SiteManager will only accept one external connection at a time. So! If you have a VNC session going, close it out. Then, through GateManager or LinkManager Mobile, select the RDP agent and activate it.
Via GateManager:
Via LinkManager Mobile:
You are now ready to create the SSH tunnel using PuTTY (or the SSH client of your choice)
This is very easily done, just type in the RDP URL using port 3389.
Troubleshooting tip: If you see this error, it means you have another connection (or connection attempt) ongoing:
Find what it might be and disable it, or it could be your prior connection attempt slowly shutting itself down. In the latter case, wait a few seconds before clicking the error away and proceeding. Go back to LinkManager or SiteManager (whichever you chose to use), and click the RDP popup off then on again, then reopen PuTTY and try to connect again. |
If successful, you’ll be able to remote login to the UR Robot!
Username: root
Password: easybot
At this point the SSH connection is open, and the Secomea product has accepted one connection.
Step Four: Using pscp to transfer files
Now that the SSH connection is made, we need to go back to to LinkManager or SiteManager (whichever you chose to use), and click the RDP popup off then on again. Now the Secomea product is ready for another connection!
- Open a Command Prompt (easiest way for me is to click the Start/Windows button and type command, then click the ‘Command Prompt’ option that pops up.)
- Navigate to the folder where pscp.exe is.
- Type: “pscp -P 3389 [Source Path] [Destination Path]
That’s it! Now, the name of our robot is going to be the RDP address provided by the Secomea. Here’s what it might look like in practice:
C:\temp\ is where pscp.exe is located.
Coincidentally, it’s also where my test file, test2.txt, is located.
My robot destination is root@gm22.secomea.com:/programs/
root is the username.
@gm22.secomea.com is the connection destination
The colon (:) goes between the connection destination and the hard drive location
/programs/ indicates that I want the text file to get dropped into the /programs/ directory.
Once you hit enter, you’ll need to type in the password (easybot), and the transfer will begin.
If you get a failure like “Network Error: Software caused connection abort”, then go turn the RDP off and on again via LinkManager Mobile or SiteManager, whatever you used before. |
If you want to call pscp.exe from any folder:
Find the instructions for doing so here.
Batch Copying of Files:
From the command prompt, once you’ve navigated to your folder containing pscp.exe, just type pscp to see all its options, including batch copy.
Copying multiple files from different places: You can only send a small number of files through pscp before the SiteManager will begin locking you out. You’ll start getting “Network Error: Software caused connection abort” instead of a prompt for a password.
Just go back to LinkManager Mobile or SiteManager and re-open the RDP prompt. Just hit close to go back screen and then click RDP again. You should then begin to copy more files!
Finally:
If you do anything to break the SSH connection (closing PuTTY, unplugging your model, losing WiFi, rebooting SiteManager, whatever), you’ll need to head all the way back up to the “Step Three” section near the very top of this article.