Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Tutorial] How to make the BlissFlixx server start at boot
#1
Hi folks,

This is my first post here, and I'm glad to present to you the startup script.

Please note, this is the easiest using ssh, as you can just copy and paste the script, but not necessary. You can enable ssh in raspi-config. Read more about it here.

We'll get right into business with the script.

At first, type:
Code:
sudo nano /etc/init.d/superscript

This will open up the text file /etc/init.d/superscript.

Put the following code in it, any way you like (typing, pasting it, I recommend pasting though):

Code:
#!/bin/bash
cd /home/pi/blissflixx
sudo -u pi "./boot.sh"

Replace both "pi"'s with your username. We have to sudo the user because you cannot open BlissFlixx with elevated permissions.
Then, to save the script, press ctrl+x, then hit y for confirmation, and then enter/return.

This will save the script.
First off, make the script executable:
Code:
sudo chmod 755 /etc/init.d/superscript

Last thing to do is test the script by typing
Code:
/etc/init.d/superscript

Then, register it to start at boot:
Code:
sudo update-rc.d superscript defaults


And you're all done!
I hope you enjoyed my tutorial!
Have fun with it!

EDITED BY ADMIN 4 March 2016: Use new boot.sh script
Reply
#2
(03-28-2015, 08:21 AM)Stenl38 Wrote: Hi folks,

This is my first post here, and I'm glad to present to you the startup script.

Please note, this is the easiest using ssh, as you can just copy and paste the script, but not necessary. You can enable ssh in raspi-config. Read more about it here.

We'll get right into business with the script.

At first, type:

Code:
sudo nano /etc/init.d/superscript

This will open up the text file /etc/init.d/superscript.

Put the following code in it, any way you like (typing, pasting it, I recommend pasting though):


Code:
#!/bin/bash
cd /home/pi/blissflixx
sudo -u pi "./boot.sh"

Replace both "pi"'s with your username. We have to sudo the user because you cannot open BlissFlixx with elevated permissions.
Then, to save the script, press ctrl+x, then hit y for confirmation, and then enter/return.

This will save the script.
Test the script by typing
Code:
/etc/init.d/superscript

Last thing to do is to make it execute at startup. First off, make it executable:

Code:
sudo chmod 755 /etc/init.d/superscript

Then, register it to start at boot:

Code:
sudo update-rc.d superscript defaults


And you're all done!
I hope you enjoyed my tutorial!
Have fun with it!
Reply
#3
Thanks for posting this tutorial! I will try it out today.
Reply
#4
OK I went through the tutorial and it work great!

Only one small problem I found was that you need to make the script executable (chmod 755) before your step of testing the script by running:

Code:
/etc/init.d/superscript

Do mind editing your original post to fix this?

Thanks once again for doing this  Smile
Reply
#5
(03-28-2015, 12:04 PM)MrBliss Wrote: OK I went through the tutorial and it work great!

Only one small problem I found was that you need to make the script executable (chmod 755) before your step of testing the script by running:

Code:
/etc/init.d/superscript

Do mind editing your original post to fix this?

Thanks once again for doing this  Smile

I have fixed it.

Looking forward to the subtitle release Smile
Reply
#6
Hi,

I love the BlissFlixx project and spent time this weekend setting it up. Was successful and also torrented 2 movies today. Great work Mr. Bliss.

I thought of auto-start as a highly required feature and then I discovered this post which made me really happy.

I then tried setting up auto-start as mentioned in this thread but was not able to as everytime I rebooted, the blissflixx server did not start. I have followed the code as mentioned including the chmod requirement. Any way we can debug this?

This is the last of my requirements from Raspberry pi if it can auto-start blissflixx. I have tried other auto-start options as well - rc.local, crontab etc. but with no success.

Looking for a revert if the forum is still active. Great work again guys!

Thanks!
Reply
#7
Hi,

On startup does the boot script start? i.e does it say "Waiting for 10 seconds for WIFI to connect" on the console?

Also what happens if you attempt to start the service manually by running:

Code:
sudo /etc/init.d/superscript start
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)