A backend will need to have mysql-server installed as well as mythtv-backend. Mythtv-backend doesn't depend on mysql-server since the mysql server can be located elsewhere on your network. Also, if this is a secondary backend, don't install mythtv-database or mysql-server. Just configure this backend to connect to the master backend instead.
- Install the mythtv software.
From Synaptic Package Manager, Search for mysql. Choose mysql-server. Search for mythtv. Choose mythtv-frontend, mythtv-backend, and mythtv-database. Press the apply button and mythtv will be installed.
- Behind the scenes, a mythtv user will be created in PAM as well as mysql. The database will be installed into mysql and the initial configuration performed.
- You will be asked for the password to the root account of mysql. By default, there is no password.
Next, you need to edit the mysql configuration to allow outside hosts to connect:
$ sudo nano /etc/mysql/my.cnf
Look for the line that reads:
and comment out that line by placing a # at the beginning.
Then, restart mysql:
$ sudo /etc/init.d/mysql restart
Next, add yourself and any other users that need MythTV acces to the mythtv group.
- To add users to the mythtv group, use this command:
# sudo usermod -a -G mythtv USERNAME
- Where USERNAME is the name of the user you are adding to the mythtv group.
VERY IMPORTANT: If you do not add your main user account to the mythtv group, you will get the dreaded database errors when you run mythtv-setup! For the addition to the group to take effect, a fresh login needs to occur-- so log out of your current session and then log back in right now.
Now it's time to set up MythTV
See MythTV_mythtvsetup for details on running mythtv-setup.
Filling the Database
The last step before starting the backend, is to fill the database with program guide data.
# sudo mythfilldatabase
Depending on the number of channels, the server load and the speed of your internet connection, this may take a few minutes.
Start the Backend Server
When The database fill is complete, the backend will automatically restart. Check to be sure it is running and that it started correctly:
To check that the backend in now running:
$ ps -p `cat /var/run/mythtv/mythbackend.pid`
If you don't see output like:
PID TTY TIME CMD 30711 ? 00:00:00 mythbackend
then there was an error.
Next, check the backend log file for obvious errors:
$ more /var/log/mythtv/mythbackend.log
Also, see Troubleshooting for more help.
- Test the Frontend. Once your backend is fully configured and running, launch the frontend from a terminal window.
Just watch for any error messages in the terminal. As long as this is free from errors, you can launch from the icon in the Sound & Video group from now on.