I’m playing with Blynk and NodeMCU dev board for a while.
As I own a Synology DS215J, I wanted to deploy a Blynk server on it.
Thanks to several posts by the community, I succeed to deploy and test it.
But I don’t really find a clear “How To”, so I decided provide a simple step-by-step guide.
I’m not a specialist but I hope this guide will help!
Don’t hesitate to add your comments or improve it.
Note : I’m facing a issue at the final step, for the one I don’t know how to fix it (see last point - 6)
1°) Setup and prepare your Synology
Login to DSM as admin and activate SSH / Telnet (Control Panel --> Terminal & SNMP --> Terminal tab --> Activate Telnet & SSH)
Install “Java8” package (Package Center --> Search “Java8” --> Install)
Create a new directory “Home/Blynk” via “File Station”
2°) Prepare your files
Via FTP, copy the 'server-x-x-x.jar" file into the new “Blynk” folder
Copy “server.properties” and “mail.properties” into the same folder (optional)
3°) Starts the server
On your local PC/MAC, connect to your Synology via SSH (For MAC : Terminal --> “ssh [useradmin]@[server_ip]” + input your password)
Once connected, check if the Java version is correct (“java -version” should give you “1.8.xxx”)
Start the Blynk server via the following command : “sudo java -jar server-0.16.4.jar” (more parameters available)
4°) Stops the server
You can stop your Blynk server by closing the terminal window (or CTRL+C on MAC Terminal)
If the process has been launch in a different way you can search the process ID of the Blynk server by using the following command when connected via SSH : “ps -ef | grep java” (ID = 2nd column)
When you’ve identified the process ID, kill it via the following command : “sudo kill -9 [ID]”
5°) [Optional] : Access your Blynk server over internet
If you need to access to your server outside your local network, you should activate and setup the “External access” (Control Panel)
Then, you have to re-direct the ports used by Blynk server on your router
6°) [QUESTION] Launch the Blynk Server at Synology startup
Does anyone has an idea on how to schedule and launch automatically Blynk server at Synology startup ?
Since I launch the Bylnk server via SSH, when I close the terminal the Blynk server is shutting down, which is a bit painfull
Update from @Lichtsignaal: If you start the blynk server followed by an “&” sign, it will continue to run in the background, not the best solution, but at least you can close your terminal
if you start the blynk server followed by an “&” sign, it will continue to run in the background, not the best solution, but at least you can close your terminal
I have no idea, the & trick comes from my Linux knowledge, but I have no idea about the Synology. I think there was someone else on the forum who also had this problem, but I’m not sure.
Have you considered using Docker in the DSM GUI? It’s very easy to setup once you know a few key steps.
Also auto restart, doesnt require SSH to start or configure.
I have installed blynk on my synology 415+ using
the docker pinya/blynk install
provided in the above link
Things seems to be running, and I have the log files
/volume1/docker/blynk/logs$ ls -l
total 184
-rwxrwxrwx 1 root root 0 Aug 18 19:25 admin.log
-rwxrwxrwx 1 root root 1510 Aug 18 20:22 blynk.log
-rwxrwxrwx 1 root root 85 Aug 18 19:25 postgres.log
-rwxrwxrwx 1 root root 156160 Aug 18 21:32 stats.log
-rwxrwxrwx 1 root root 12544 Aug 18 21:32 worker.log
But I have no idea how to configure the users on my blynk server.
Please provide some help in a very elementary way.