LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 12-06-2013, 03:29 PM   #1
dalponis
Member
 
Registered: Jan 2006
Location: Alberta, Canada
Distribution: Fedora 19 x86_64
Posts: 96

Rep: Reputation: 15
crontab -e @reboot doesn't always work


Here's my crontab -e...

Teamspeak starts no problem. But my two minecraft servers don't like starting 100% of the time.

Sometimes Parcore starts...
The other FTB starts...

What do?
Attached Thumbnails
Click image for larger version

Name:	crontab-e.png
Views:	58
Size:	41.6 KB
ID:	14160  

Last edited by dalponis; 12-06-2013 at 03:42 PM. Reason: Simplified my crontab -e
 
Old 12-06-2013, 03:43 PM   #2
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
/path/to/java perhaps?
 
Old 12-06-2013, 03:46 PM   #3
dalponis
Member
 
Registered: Jan 2006
Location: Alberta, Canada
Distribution: Fedora 19 x86_64
Posts: 96

Original Poster
Rep: Reputation: 15
Okay...

Here are my new settings. FTB and Parcore still don't start... This version doesn't work either

What do?
Attached Thumbnails
Click image for larger version

Name:	newSettings.jpg
Views:	27
Size:	108.2 KB
ID:	14161  

Last edited by dalponis; 12-06-2013 at 04:38 PM. Reason: New Settings
 
Old 12-06-2013, 04:52 PM   #4
dalponis
Member
 
Registered: Jan 2006
Location: Alberta, Canada
Distribution: Fedora 19 x86_64
Posts: 96

Original Poster
Rep: Reputation: 15
Here's my last attempt at trying to get it to work.

I can manually call these scripts. But only one will start with crontab -e
Attached Thumbnails
Click image for larger version

Name:	newSettings.jpg
Views:	23
Size:	133.7 KB
ID:	14162  
 
Old 12-06-2013, 05:05 PM   #5
dalponis
Member
 
Registered: Jan 2006
Location: Alberta, Canada
Distribution: Fedora 19 x86_64
Posts: 96

Original Poster
Rep: Reputation: 15
I believe my issue to be the fact I'm using the wrong screen command.
 
Old 12-09-2013, 10:33 AM   #6
dalponis
Member
 
Registered: Jan 2006
Location: Alberta, Canada
Distribution: Fedora 19 x86_64
Posts: 96

Original Poster
Rep: Reputation: 15
Get this...

@reboot sleep 10

In between calling both ServerStart.sh... That fixed it. Wow. So cron tried to launch both screen -dmS's at the same time and confused it self?

Code:
@reboot /usr/local/games/minecraft/parcore/ServerStart.sh
@reboot /usr/local/teamspeak/ts3server_startscript.sh start
@reboot sleep 10
@reboot /usr/local/games/FTB/ServerStart.sh
Edit:

Nope. It worked once, not a second time. Ugh. What the hell!

Last edited by dalponis; 12-09-2013 at 10:42 AM. Reason: didn't work
 
Old 12-09-2013, 11:00 AM   #7
dalponis
Member
 
Registered: Jan 2006
Location: Alberta, Canada
Distribution: Fedora 19 x86_64
Posts: 96

Original Poster
Rep: Reputation: 15
I figured it out.

This time it seems to work...

crontab -e
Code:
@reboot /usr/local/teamspeak/ts3server_start.sh
@reboot /usr/local/games/ServerStart.sh
ServerStart.sh
Code:
#FTB Server Start
cd /usr/local/games/FTB/
screen -dmS FTB ...

#Parcore
cd /usr/local/games/minecraft/parcore/
screen -dmS Parcore ...
I called both screen commands from the same script, and now it works.

WTF?
 
  


Reply

Tags
crontab, screen



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Crontab doesn't work and #!/bin/bash -vx emmeteo Linux - Software 10 01-11-2013 11:36 AM
crontab -e doesn't work after upgrade gbltech Slackware 3 04-21-2009 10:42 AM
crontab -e username doesn't work BiThian Linux - General 3 10-13-2006 10:31 AM
Reboot doesn't work linuxi Ubuntu 9 05-03-2006 04:01 PM
crontab doesn't work, but everything is set correctly ttilt Linux - General 10 06-16-2005 05:44 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:50 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration