BLYNK
HOME       📲 GETTING STARTED       📗 DOCS       ❓HELP CENTER       👉 SKETCH BUILDER

Blynk Server on RPi 3 (Solved)

rpi

#1

Hi,

i am very new to Blynk app and it is the first time i set up an local server. After having some trouble to connect a node mcu to the server, cam facing something different now. I could not find the right answer here.

  1. Autostart is not working if i use following Giude

Also all other things i found in this community seems not to work. Any ideas?

  1. If i start the Blynk serve via ssh (terminal on my macbook) it works smooth as peanut butter, but as soon as i close the terminal window, the server seems to shut down. Same if i do this locally on my Pi

Is this normal?


#2

Yes.

Your issue is Linux related, not Blynk specific. Search this forum and/or Google for the many different ways to run a Linux script (in this case your Server) at boot up, or via a terminal command and have it stay running upon the terminal closure. Although that last one is as simple as adding a space and & at the end of the command.


#3

Allright,

so will try to something on google and reply or better put a description here. So anyone else can find it.

Thanks @Gunner


#4

Dixi,

Check out my post for the answer here: Help needed with running local server at start-up, Rasp Pi 3

==========================================================
Here is my cheat sheet, hopefully it will help:

HOW TO CONFIGURE BLYNK LOCAL SERVER:

1 - Login to Raspberry Pi
2- Open Terminal
3- Install Java8
sudo apt-get install oracle-java8-jdk

4- Check Java version
java -version

5- Create Blynk directory
Mkdir Blynk

6- Change directory from root “pi” to “Blynk” directory
cd Blynk

7- Download Blynk server file package
wget “https://github.com/blynkkk/blynk-server/releases/download/v0.39.4/server-0.39.4-java8.jar”

8- Manual start Blynk server
java -jar server-0.39.4-java8.jar -dataFolder /home/pi/Blynk

9- At this point, the Blynk Server successfully started. Take a note on login ID and password for the web portal. To get out of this terminal windows, press CTRL+C

10- Enable Blynk server auto start each time power failure or hardware reboot
a. Open Terminal and type: sudo leafpad
b. Browse to FileSystem\etc\rc.local then add this line as below then save it.
java -jar /home/pi/Blynk/server-0.39.4-java8.jar -dataFolder /home/pi/Blynk &

         c. At the Terminal, type: crontab –e
        d. Add the following line then save it.
                @reboot java -jar /home/pi/Blynk/server-0.39.4-java8.jar -dataFolder /home/pi/Blynk &
        e.  Reboot the server then Blynk should automatically start

#5

EDIT… Makes no sense.


#6

Hey Key,

you are a champion…

i downloaded

https://github.com/blynkkk/blynk-server/releases/download/v0.39.4/server-0.39.4-java8.jar

an manually copied it into Pi/Blynk/ as i saw it wasn’t there.

now it seems to work… Thanks a lot .

Any idea why the file wasn’t in there?


#7

Great to heard it works for you. :slight_smile:

it could be at the root of PI, it’s depended on what directory when you run the download command.

FYI, if this problem solved, please change your post to “SOLVED”