[mythtv-users] Moving my mysql database to another drive
Alex Tomlins
alex at tomlins.org.uk
Sun Jan 23 14:17:35 UTC 2011
On 23/01/11 06:12, Michael Rice wrote:
> I am having some problems that may be related to disk performance.
> (See http://www.mythtv.org/pipermail/mythtv-dev/2011-January/070387.html).
> I have an extra drive and I am thinking about moving the database to it
> to see if it helps the situation.
>
> If anyone has pointers/gotchas on doing this (especially on Fedora)
> I'd appreciate hearing about them. Is there any particular way I
> should format the drive to help performance?
I've done this in the past, and it's pretty straightforward. What I did
was the following:
1. Stop mysql
2. move the mysql data dit onto the new drive (/var/lib/mysql in my case
(I'm running Ubuntu))
3. create a symlink in the old location pointing to the new location
4. Start mysql again.
One gotcha with this for me was Apparmor. This prevented mysql from
starting. I just uninstalled it instead of reconfiguring it because I
didn't need it. I don't know if Fedora uses apparmor (or similar tools
like selinux) by default, but worth being aware of. It took me quite a
bit of head scratching before I spotted apparmor getting in the way.
An alternative approach that would avoid the apparmor issues would be to
use a bind mount instead of a symlink.
thanks,
Alex
--
Alex Tomlins
Email/Jabber: alex at tomlins.org.uk
There are two kinds of people in the world: those who finish what they started
More information about the mythtv-users
mailing list