So it appears as if it is running, but the app keeps telling me “getting data from server failed. Try later” any suggestions or am i missing something?
Blynk Server successfully started.
All server output is stored in folder '/home/develop/./logs' file.
Did you do any configuring of the server.properties file and how do you start your server? The path given there is a bit weird to me, should not be ./ in it.
@Dmitriy I am connected via the Wi-Fi on the same network as the computer running the server (connected via Ethernet to router). At one point I tried shutting off the mobile data but ended up with the same result.
@Lichtsignaal brings up a good point as well. When I attempted to change the folder location in the code below, it always reverted back to saving the admin and log folders in the root folder.
I did not configure any of the server.properties file. I started the server in the same manor one would for the raspberry-pi
java -jar server-0.12.2.jar -dataFolder /home/pi/Blynk - Original code java -jar server-0.12.2.jar -dataFolder /home/develop/Blynk -Code run in terminal All server output is stored in folder '/home/develop/./logs' file. -Result after server started
@Lichtsignaal ,below is the blynk.log file you requested
12:23:58.739 INFO - Using data dir '/home/develop/Blynk'
12:23:58.963 INFO - Initializing mail transport. Username : example@gmail.com. SMTP host : smtp.gmail.com:587
12:23:59.685 INFO - Plain tcp/ip hardware server port 8442.
12:23:59.688 INFO - Enabling SSL for hardware.
12:23:59.691 WARN - ATTENTION. Certificate /home/develop and key /home/develop paths not valid. Using embedded certs. This is not secure. Please replace it with your own certs.
12:24:00.696 INFO - SSL hardware port 8441.
12:24:00.760 INFO - Enabling HTTPS for admin UI.
12:24:00.760 WARN - ATTENTION. Certificate /home/develop and key /home/develop paths not valid. Using embedded certs. This is not secure. Please replace it with your own certs.
12:24:00.971 INFO - HTTPS admin UI port 7443.
12:24:00.985 INFO - Enabling SSL for application.
12:24:00.986 WARN - ATTENTION. Server certificate paths cert : '/home/develop', key : '/home/develop' - not valid. Using embedded server certs and one way ssl. This is not secure. Please replace it with your own certs.
12:24:01.166 INFO - Application server port 8443.
12:24:01.183 INFO - Enabling HTTP for app.
12:24:01.183 INFO - HTTP for app port 8080.
Also, It seems that when I try an IP that is incorrect, it quickly responds server failed, but when I attempt to connect to the real IP it takes 10-15 seconds.
I added the server.properties file, reorganized the folder structure and ended up with the following
Thanks again!
16:46:27.326 INFO - Using data dir ‘/home/develop/Blynk’
16:46:27.332 DEBUG - Starting reading user DB.
16:46:27.422 DEBUG - Reading user DB finished.
16:46:27.572 INFO - Initializing mail transport. Username : example@gmail.com. SMTP host : smtp.gmail.com:587
16:46:28.415 DEBUG - hard.socket.idle.timeout = 15
16:46:28.416 INFO - Plain tcp/ip hardware server port 8442.
16:46:28.417 INFO - Enabling SSL for hardware.
16:46:28.426 WARN - ATTENTION. Certificate /home/develop/Blynk/server and key /home/develop/Blynk/server paths not valid. Using embedded certs. This is not secure. Please replace it with your own certs.
16:46:29.437 INFO - SSL hardware port 8441.
16:46:29.544 INFO - Enabling HTTPS for admin UI.
16:46:29.546 WARN - ATTENTION. Certificate /home/develop/Blynk/server and key /home/develop/Blynk/server paths not valid. Using embedded certs. This is not secure. Please replace it with your own certs.
16:46:29.737 INFO - HTTPS admin UI port 9443.
16:46:29.751 INFO - Enabling SSL for application.
16:46:29.751 WARN - ATTENTION. Server certificate paths cert : ‘/home/develop/Blynk/server’, key : ‘/home/develop/Blynk/server’ - not valid. Using embedded server certs and one way ssl. This is not secure. Please replace it with your own certs.
16:46:29.921 DEBUG - app.socket.idle.timeout = 600
16:46:29.922 INFO - Application server port 8443.
16:46:29.932 INFO - Enabling HTTP for app.
16:46:29.933 INFO - HTTP for app port 8080.
That’s it yeah. You may have to enable the telnet program form Add/Remove Windows Components though. If that works, e.g. it doesn’t time out, than your server configuration is most likely ok.
@Dmitriy I ran the netstat with and without the Server Running. As you can see below, it recognizes the ports are open, but don’t list the full IP. Is that an issue?
Linux these days activates SELinux by default I think, that is just the one thing that doesn’t get activated in Raspbian, so hence, it’s not in the documentation, but @Dmitriy could make an entry
I hope this isn’t considered hijacking someone else’s thread but if so, say so and I’ll start a new one.
I’m running into a similar problem running the 12.1 and 12.4 server code (haven’t tried the intermediate versions) on Linux Mint 17.
When I first installed 12.1 around Christmas time, it worked just fine. I haven’t been able to use it in the intervening weeks and now I’m finding that I can’t connect to the server from my android app and ffailes with “getting data from server failed”
The only things that have changed on this machine are: 1 reboot and regular system updates.
I’ve tried stopping and starting the servers and doing another reboot cycle and no dice. Another server (prosody) on this machine is working just fine.
I’ve also tried disabling the firewall (ufw disable). No luck.
netstat shows that blynk is listening on the correct ports but based on the log output, it’s never receiving requests.
In the intervening time I had also rooted my phone and installed a firewall and blynk didn’t have internet access (because I wasn’t using it regularly).
On the other hand, the Mint firewall is now enabled and I’ve got everything but the blynk and prosody ports locked down so that’s one good thing to come out of this afternoon.