Problem: MySQL Connection On Boot
|
9th Feb, 2013, 08:47 PM
Post: #1
|
|||
|
|||
MySQL Connection On Boot
Morning All,
I'll start with this as a configuration query rather than a bug as is more likely to simply be I've done something wrong Setup: 1x D-Link Share-Centre NAS 1x Debian Server Running MySQL 1x Windows 7 Ultimate PC 2x Raspberry Pi Model B 512Mb Media is on the NAS XBMC database is on the Debian Server Setup From Here Raspberry Pi are both running XBian Alpha 4 + Frodo 12 Update From Here XBMC 12.0 Git:20130127-fb595f2 is the current version on all Devices Firstly and probably a little strange, everything work perfectly. All devices share the database, I can updated it from my PC and the PIs just work. However the PIs always need a kick when powered on or rebooted because they cant find the MySQL DB (Log Below) To get the PIs working all I need to to is SSH in and run /etc/init.d/xbmc restart and boom all is good in my world, however this is just a little irritating Initial thought was, ok it's not waiting for the network... Updated /etc/init.d/xbmc Modified Terminal # Required-Start: bootlocal Terminal # Required-Start: bootlocal $network $named $remote_fs Terminal # Required-Start: $all Tweaked /etc/init.d/xbmc Terminal ### END INIT INFO sleep 10 DESC=XBMC Obviously this isn't the best solution because when I come to do the next update I will have completely forgotten about this and it will all implode again. Is there a blatantly obvious setting that I'm missing to handle this ?? ------------------ XMBC Log From Boot Up------------------------ Log Details |
|||
9th Feb, 2013, 09:14 PM
Post: #2
|
|||
|
|||
RE: MySQL Connection On Boot
First of all, please post your logs on pastebin as stated in our forum rules.
Quote:Than copy the whole text from screen to clipboard. Upload the file on the services like http://pastebin.com/ and post the link in your post/thread. Second, bootlocal is already depends on $all so no need to change the dependency of XBMC. I'm also running my xbmc with an external mysql library and it just works out of the box. Does your debian machine go to sleep or something? pilight - modular domotica solution
|
|||
9th Feb, 2013, 09:46 PM
Post: #3
|
|||
|
|||
RE: MySQL Connection On Boot
I think xbmc's just having trouble resolving 'cdnsvr02' to an ip address, maybe xbmc starts before the dns server can be reached. Try adding cdnsvr02 to /etc/hosts with the fixed ip address and see if that helps, or reconfigure the advancedsettings.xml to use the ip instead of the hostname.
|
|||
20th Feb, 2013, 05:23 AM
Post: #4
|
|||
|
|||
RE: MySQL Connection On Boot
Firstly - apologies on the Log, edited and dealt with.
None of my Debian servers, nor the ESX that hosts them sleep. It's not a DNS issue as I get the same error if i change the xbmc config to the MySQL Server IP Address instead. Done some more digging and it's defiantly underlying network that's the cause, although still highly likely that I'm to blame Additional Setup Info Debian server CDNSVR01 handles, among other things, DHCP & DNS via dnsmasq. If I tail syslog on the CDNSVR01 the entries for the PI requesting it's DHCP lease occur after XBMC has already loaded. Add the delay back in and DCHP completes before XBMC loads. So my next logical question is... If XBMC has a dependency for bootlocal, bootlocal depends on $all and $all includes $network $named & $remote_fs why is XBMC loading before the network has finished starting up ? Sorry if the answers really obvious, but I've only recently started playing Linux based OS so I'm still finding my feet. Cheers, Swiss. |
|||
15th May, 2013, 03:54 PM
Post: #5
|
|||
|
|||
RE: MySQL Connection On Boot
I'd like to add that I have the same problem that Swiss did - not sure if you've solved it Swiss, but if you did I'd love to hear how!
Same deal - Xbian starts without network activity, can't connect to the MySQL database, logs show network connectivity after connection errors by timestamp. SSH restart of XBMC resolves the issue, as the network connection has established by then. Of note, my Pi is wireless - could the wifi networking not be accounted for in the boot dependencies? |
|||
19th May, 2013, 08:55 AM
Post: #6
|
|||
|
|||
RE: MySQL Connection On Boot
swiss you have cable connected or wifi ?
Please read rules and do a search before you post! . FAQs . How to post log file? . Looking for answers? Please start here |
|||
« Next Oldest | Next Newest »
|
Possibly Related Threads... | |||||
Thread: | Author | Replies | Views: | Last Post | |
Boot USB - No Network Connection | kgoerbig | 10 | 26,078 |
28th Jul, 2014 01:21 AM Last Post: IriDium |