Page 1 of 1

[Solved] Ruby on Rails application could not be started

Posted: Tue Dec 14, 2010 7:16 pm
by cpromanec
Database problems. My hda system partition recently ran out of space. Since then (coincidence or not) I've been unable to access the http://hda dashboard or apps. Here's the text of what I get when I visit http://hda:
There appears to be a database problem.
Your config/database.yml may not be written correctly. Please check it and fix any errors.
Your database schema may be out of date or nonexistant. Please run rake db:migrate to ensure that the database schema is up-to-date.
The database server may not be running. Please check whether it's running, and start it if it isn't.

Error message:
Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) (Mysql::Error)

Exception class:
Mysql::Error

Application root:
/var/hda/platform/html
I can access the hda with putty, and access the shares. I found this post:http://forums.amahi.org/viewtopic.php?f=14&t=1395, but don't know enough to apply it, if the solution is in there. If someone notices that the answer is in there, what would I need to do to the following in my situation:
I did a forcece-reload of Squeezecenter and that fixed that but it also seems to have fixed the dashboard problem.
Any and all help would be greatly appreciated.

Re: Ruby on Rails application could not be started

Posted: Tue Dec 14, 2010 11:16 pm
by rgmhtt
Is mySQL running?

service mysqld status

I once stopped mysqld, and got the error you are seeing.

Re: Ruby on Rails application could not be started

Posted: Wed Dec 15, 2010 4:05 pm
by cpromanec
Thanks for replying rgmhtt, especially for including the command to run.
Unfortunately (so to speak), the output is that mySQL is running.

To add another piece of information for everyone info in hopes that it helps find a solution, my Amahi.org Control Panel states my hda's status as "Stopped", and there's a red "Delete" icon next to this.

Any ideas?

Re: Ruby on Rails application could not be started

Posted: Wed Dec 15, 2010 6:34 pm
by bigfoot65
As root try service hdactl restart.

Re: Ruby on Rails application could not be started

Posted: Wed Dec 15, 2010 7:30 pm
by cpromanec
Thanks for the reply bigfoot65. As root I tried service hdactl restart. "Stopping hdactl" and "Starting hdactl" both reported "ok". The Ruby on Rails error / problem still persists however.

Re: Ruby on Rails application could not be started

Posted: Wed Dec 15, 2010 7:53 pm
by bigfoot65
Do you have the latest platform? As root, do rpm -ql hda-platform. Should be 5.6-11. If not, do yum install hda-platform.

You may need to reboot your hda afterwards.

Re: Ruby on Rails application could not be started

Posted: Sat Dec 18, 2010 4:04 pm
by cpromanec
I checked for which version of the platform I was running, and it is the latest. I did a yum install hda-platform just for kicks and it naturally indicated that I had the latest version. Stumped and without options, as I was reading your post, I also typed "restart" into the cli and restarted. Great news, things are back and working again (except WebVNC which started working again after launching it on the hda itself). I had restarted the hda before, but from the box by pressing the restart button, not from the command line. Maybe the 'cleaner' restart was the solution? I don`t know. I`m just happy to get things back.

Thanks for responding rgmhtt and bigfoot65. I don`t think I`d ever have taken the route I did otherwise.