LinHES Forums
http://forum.linhes.org/

LinHES Stuck on blue screen on startup
http://forum.linhes.org/viewtopic.php?f=21&t=25669
Page 1 of 2

Author:  drhood [ Sat Feb 22, 2020 8:32 pm ]
Post subject:  LinHES Stuck on blue screen on startup

Hi All,

After upgrading to larger hard drives, I did a clean re-install of LinHES and restored the last system backup from the MythWeb interface. All was good for about a week (until today). Sign of trouble started after we noticed the entire recent week's of recording were grayed out and mythtv reporting the file was unavailable (older recordings were fine). We found the recent files stored in the system. In case the issue was caused by a broken database table, I did executed the optimize script. However, it was at this moment that the went awry. The system showed the message that the backend was unavailable. I waited 30 minutes and the system did not change. The optimize did not complete, and seemed hung. So, I rebooted and the system refuses to boot up except to a blue screen with the message that the system cannot connect to the backend.

I have restarted mysql (sudo sv start mysql) and the mythbackend (sudo sv start mythbackend); however, the frontend will not boot.

The only thing I could think that changed with the system was a LinHES update had occurred.

Any advice on recovering the system?

Grateful for any suggestions.

Author:  knappster [ Sun Feb 23, 2020 7:15 am ]
Post subject:  Re: LinHES Stuck on blue screen on startup

Have you checked the mythbackend log? It sounds like the system is booting, but that the backend is failing to start. Hopefully the logs would explain why. Perhaps the database is corrupted and you can find more information in the ".err" file in /data/srv/mysql.

In looking for the location of that file, I came across a thread (incidentally of yours) with some troubleshooting tips for recovering a corrupted mysql database:
viewtopic.php?f=5&t=24761

Maybe that will help?

Author:  drhood [ Sun Mar 01, 2020 12:21 pm ]
Post subject:  Re: LinHES Stuck on blue screen on startup

knappster wrote:
Have you checked the mythbackend log? It sounds like the system is booting, but that the backend is failing to start. Hopefully the logs would explain why. Perhaps the database is corrupted and you can find more information in the ".err" file in /data/srv/mysql.

In looking for the location of that file, I came across a thread (incidentally of yours) with some troubleshooting tips for recovering a corrupted mysql database:
viewtopic.php?f=5&t=24761

Maybe that will help?


Thanks knappster for the reply.

The linhes_mythbackend.log file did not contain information that gave me a clue.

The log file named linhes_myth_mtc.log does seem to contain useful information, which is that the mysql table inuseprograms could not be cleaned and running the optimize script fails with the following error message...

"Problem getting tables from the database"

I am now stuck as I don't know, cannot recall, or not found, how to resolve a connection issue with mysql.

Is it a misconfiguration of usename/password?

Is it a locked database table or something similar?

Any help troubleshooting mysql will be appreciated.

drhood

Author:  drhood [ Sun Mar 01, 2020 12:36 pm ]
Post subject:  Re: LinHES Stuck on blue screen on startup

I can add that when I run the command

Code:
sudo /usr/bin/mysqlcheck mythconverg


The following error appears...

Code:
Got error: 2002: Can't connect to local MySQL server through socket /var/run/mysqld/mysqld.sock' (2) when trying to connect

Author:  knappster [ Sun Mar 01, 2020 12:48 pm ]
Post subject:  Re: LinHES Stuck on blue screen on startup

Can you access the database using the command line?

Code:
mysql -u mythtv -pmythtv
use mythconverg;
select * from inuseprograms;

Author:  drhood [ Sun Mar 01, 2020 12:57 pm ]
Post subject:  Re: LinHES Stuck on blue screen on startup

knappster wrote:
Can you access the database using the command line?

Code:
mysql -u mythtv -pmythtv
use mythconverg;
select * from inuseprograms;


I can verify that I cannot access the database using the command line. The first command results in the following.

Code:
$ mysql -u mythtv -pmythtv
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

Author:  drhood [ Sun Mar 01, 2020 1:02 pm ]
Post subject:  Re: LinHES Stuck on blue screen on startup

drhood wrote:
knappster wrote:
Can you access the database using the command line?

Code:
mysql -u mythtv -pmythtv
use mythconverg;
select * from inuseprograms;


I can verify that I cannot access the database using the command line. The first command results in the following.

Code:
$ mysql -u mythtv -pmythtv
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)


Ooops!

I think I can....

When I enter the entire command...

Code:
mysql -u mythtv -pmythtv
use mythconverg;
select * from inuseprograms;


The following error appears...

Code:
bash: syntax error near unexpected token 'from'

Author:  drhood [ Sun Mar 01, 2020 1:10 pm ]
Post subject:  Re: LinHES Stuck on blue screen on startup

When I use the command

Code:
mysql -u mythtv -pmythtv
use mythconverg


The following output appears,

Code:
show warnings                      FALSE
plugin-dir                              (No default value)
default-auth                          (No default value)
histignore                              (No default value)
binary-mode                          FALSE
connect-expired-password    FALSE

Author:  drhood [ Sun Mar 01, 2020 1:23 pm ]
Post subject:  Re: LinHES Stuck on blue screen on startup

When I run the following command...

Code:
ps ax | grep mysql


The following appears...

Code:
 556 ?    S        0:00 /bin/sh /usr/bin/mysqld_safe --user=mysql
739   pts/4       R+ 0:00  grep mysql
928 ?   Ss    0:01  runsv mysql


Is the first line correct?

Any help clue/help will be greatly appreciated.

Author:  knappster [ Sun Mar 01, 2020 2:22 pm ]
Post subject:  Re: LinHES Stuck on blue screen on startup

Mine also includes the following process:
Code:
1797 ?        Sl     2:32 /usr/bin/mysqld --basedir=/usr --datadir=/data/srv/mysql --plugin-dir=/usr/lib64/mysql/plugin --user=mysql --log-error=linhes.err --pid-file=linhes.pid --socket=/var/run/mysqld/mysqld.sock --port=3306

What does
Code:
sudo sv status mysql
return? I presume that it will say that it is stopped. You could try
Code:
sudo sv start mysql
and it will most likely error out, but it might be useful data.

Do you have a file /etc/mysql/my.cnf?

Author:  drhood [ Sun Mar 01, 2020 2:52 pm ]
Post subject:  Re: LinHES Stuck on blue screen on startup

knappster wrote:
Mine also includes the following process:
Code:
1797 ?        Sl     2:32 /usr/bin/mysqld --basedir=/usr --datadir=/data/srv/mysql --plugin-dir=/usr/lib64/mysql/plugin --user=mysql --log-error=linhes.err --pid-file=linhes.pid --socket=/var/run/mysqld/mysqld.sock --port=3306

What does
Code:
sudo sv status mysql
return? I presume that it will say that it is stopped. You could try
Code:
sudo sv start mysql
and it will most likely error out, but it might be useful data.

Do you have a file /etc/mysql/my.cnf?


Thank you for the reply.
The
Code:
$ sudo sv status mysql
down: mysql: ls, normally up, want up
$ sudo sv start mysql
ok: run: mysql: (pid 30404) 0s
$sudo sv status mysql
run: mysql: (pid 31189) ls
$ mysql -u mythtv -pmythtv
Warning using a password on the command line can be insecure.
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)


Any help on how to troubleshoot will be appreciated.

Author:  knappster [ Sun Mar 01, 2020 6:52 pm ]
Post subject:  Re: LinHES Stuck on blue screen on startup

Could your database partition be full? What is the output of
Code:
df -h
?

Author:  drhood [ Sun Mar 01, 2020 7:49 pm ]
Post subject:  Re: LinHES Stuck on blue screen on startup

knappster wrote:
Could your database partition be full? What is the output of
Code:
df -h
?


There is plenty of available space.

The df -h command results in the following

14% used space (19 Gb available) in /
16% used space (2.2 Gb available) in /data/srv/mysql

Any assistance will be appreciated.

Author:  knappster [ Mon Mar 02, 2020 7:08 pm ]
Post subject:  Re: LinHES Stuck on blue screen on startup

This may have been overlooked earlier, but have you checked the contents of:
/data/srv/mysql/linhes.err

Author:  sparks [ Wed Mar 11, 2020 8:37 am ]
Post subject:  Re: LinHES Stuck on blue screen on startup

Have you checked for the existence of the socket, /var/run/mysqld/mysqld.sock?

s

Page 1 of 2 All times are UTC - 6 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/