<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	>
<channel>
	<title>Comments on: How to move mysql database to another drive or partition</title>
	<atom:link href="http://www.ubuntu-howto.info/howto/how-to-move-mysql-databases-to-another-location-partition-or-hard-drive/feed" rel="self" type="application/rss+xml" />
	<link>http://www.ubuntu-howto.info/howto/how-to-move-mysql-databases-to-another-location-partition-or-hard-drive</link>
	<description>Stuff I learnt by doing and I'm happy to share</description>
	<pubDate>Wed, 10 Mar 2010 23:30:36 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.7.1</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Jay</title>
		<link>http://www.ubuntu-howto.info/howto/how-to-move-mysql-databases-to-another-location-partition-or-hard-drive/comment-page-1#comment-2181</link>
		<dc:creator>Jay</dc:creator>
		<pubDate>Tue, 05 Jan 2010 15:27:28 +0000</pubDate>
		<guid isPermaLink="false">http://www.ubuntu-howto.info/?p=4#comment-2181</guid>
		<description>Thanks, using RH5 and worked perfect. Thanks again!</description>
		<content:encoded><![CDATA[<p>Thanks, using RH5 and worked perfect. Thanks again!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: didik</title>
		<link>http://www.ubuntu-howto.info/howto/how-to-move-mysql-databases-to-another-location-partition-or-hard-drive/comment-page-1#comment-2174</link>
		<dc:creator>didik</dc:creator>
		<pubDate>Fri, 04 Dec 2009 03:48:48 +0000</pubDate>
		<guid isPermaLink="false">http://www.ubuntu-howto.info/?p=4#comment-2174</guid>
		<description>what meaning `wpdb' ?

root@smm:/var/lib/mysql# ls -l
total 4130784
drwx------ 2 mysql mysql       4096 2009-11-02 19:53 backup
-rw-r--r-- 1 root  root           0 2009-07-19 19:47 debian-5.0.flag
-rw-rw---- 1 mysql mysql 3491758080 2009-12-03 09:30 ibdata1
-rw-rw---- 1 mysql mysql  367001600 2009-12-03 09:30 ib_logfile0
-rw-rw---- 1 mysql mysql  367001600 2009-12-03 09:30 ib_logfile1
drwxr-xr-x 2 mysql root        4096 2009-07-20 02:49 mysql
-rw------- 1 root  root           8 2009-07-30 03:53 mysql_upgrade_info
drwxr-xr-x 2 root  root        4096 2009-12-03 21:23 smm_server
root@smm:/var/lib/mysql#  mkdir /var/www/mysql_datadir
root@smm:/var/lib/mysql#  chown -R mysql:mysql /var/www/mysql_datadir
root@smm:/var/lib/mysql#  cp -r mysql /var/www/mysql_datadir/
root@smm:/var/lib/mysql#  cp -r wpdb /var/www/mysql_datadir/
cp: cannot stat `wpdb': No such file or directory</description>
		<content:encoded><![CDATA[<p>what meaning `wpdb&#8217; ?</p>
<p>root@smm:/var/lib/mysql# ls -l<br />
total 4130784<br />
drwx&#8212;&#8212; 2 mysql mysql       4096 2009-11-02 19:53 backup<br />
-rw-r&#8211;r&#8211; 1 root  root           0 2009-07-19 19:47 debian-5.0.flag<br />
-rw-rw&#8212;- 1 mysql mysql 3491758080 2009-12-03 09:30 ibdata1<br />
-rw-rw&#8212;- 1 mysql mysql  367001600 2009-12-03 09:30 ib_logfile0<br />
-rw-rw&#8212;- 1 mysql mysql  367001600 2009-12-03 09:30 ib_logfile1<br />
drwxr-xr-x 2 mysql root        4096 2009-07-20 02:49 mysql<br />
-rw&#8212;&#8212;- 1 root  root           8 2009-07-30 03:53 mysql_upgrade_info<br />
drwxr-xr-x 2 root  root        4096 2009-12-03 21:23 smm_server<br />
root@smm:/var/lib/mysql#  mkdir /var/www/mysql_datadir<br />
root@smm:/var/lib/mysql#  chown -R mysql:mysql /var/www/mysql_datadir<br />
root@smm:/var/lib/mysql#  cp -r mysql /var/www/mysql_datadir/<br />
root@smm:/var/lib/mysql#  cp -r wpdb /var/www/mysql_datadir/<br />
cp: cannot stat `wpdb&#8217;: No such file or directory</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: cablop.net &#8211; Software Tips &#187; Mover los archivos de las bases de datos de MySQL a otra ruta en Ubuntu</title>
		<link>http://www.ubuntu-howto.info/howto/how-to-move-mysql-databases-to-another-location-partition-or-hard-drive/comment-page-1#comment-2167</link>
		<dc:creator>cablop.net &#8211; Software Tips &#187; Mover los archivos de las bases de datos de MySQL a otra ruta en Ubuntu</dc:creator>
		<pubDate>Wed, 14 Oct 2009 01:27:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.ubuntu-howto.info/?p=4#comment-2167</guid>
		<description>[...]  How to move mysql database to another drive or partition [...]</description>
		<content:encoded><![CDATA[<p>[...]  How to move mysql database to another drive or partition [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: 天龙</title>
		<link>http://www.ubuntu-howto.info/howto/how-to-move-mysql-databases-to-another-location-partition-or-hard-drive/comment-page-1#comment-2166</link>
		<dc:creator>天龙</dc:creator>
		<pubDate>Wed, 14 Oct 2009 00:23:27 +0000</pubDate>
		<guid isPermaLink="false">http://www.ubuntu-howto.info/?p=4#comment-2166</guid>
		<description>no need to tar the files

why do you go the complex way if you have the simple way?

sudo cp -rp anything to/new/location

the key is the -p parameter in the cp command, that preserve file permissions and the r made it recursive, so each file is copied recursively preserving its own permissions

but, i have to admit to tar the files will give you an extra backup</description>
		<content:encoded><![CDATA[<p>no need to tar the files</p>
<p>why do you go the complex way if you have the simple way?</p>
<p>sudo cp -rp anything to/new/location</p>
<p>the key is the -p parameter in the cp command, that preserve file permissions and the r made it recursive, so each file is copied recursively preserving its own permissions</p>
<p>but, i have to admit to tar the files will give you an extra backup</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: James Wickett</title>
		<link>http://www.ubuntu-howto.info/howto/how-to-move-mysql-databases-to-another-location-partition-or-hard-drive/comment-page-1#comment-1019</link>
		<dc:creator>James Wickett</dc:creator>
		<pubDate>Tue, 14 Apr 2009 01:20:11 +0000</pubDate>
		<guid isPermaLink="false">http://www.ubuntu-howto.info/?p=4#comment-1019</guid>
		<description>Using tar is better than copy when moving files like this.  That way you leave file perms the same.</description>
		<content:encoded><![CDATA[<p>Using tar is better than copy when moving files like this.  That way you leave file perms the same.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: kAEoReN</title>
		<link>http://www.ubuntu-howto.info/howto/how-to-move-mysql-databases-to-another-location-partition-or-hard-drive/comment-page-1#comment-554</link>
		<dc:creator>kAEoReN</dc:creator>
		<pubDate>Sat, 28 Mar 2009 00:44:07 +0000</pubDate>
		<guid isPermaLink="false">http://www.ubuntu-howto.info/?p=4#comment-554</guid>
		<description>root@ks368546:/home/admin/mysqldb# /etc/init.d/apparmor restart
grep: /proc/modules: No such file or directory
ls: nie ma dost\u0119pu do /sys/module/apparmor: No such file or directory
grep: /proc/modules: No such file or directory
ls: nie ma dost\u0119pu do /sys/module/apparmor: No such file or directory
grep: /proc/modules: No such file or directory
ls: nie ma dost\u0119pu do /sys/module/apparmor: No such file or directory
FATAL: Could not load /lib/modules/2.6.28.1-xxxx-std-ipv4-32/modules.dep: No such file or directory
Loading AppArmor module: Failed.</description>
		<content:encoded><![CDATA[<p>root@ks368546:/home/admin/mysqldb# /etc/init.d/apparmor restart<br />
grep: /proc/modules: No such file or directory<br />
ls: nie ma dost\u0119pu do /sys/module/apparmor: No such file or directory<br />
grep: /proc/modules: No such file or directory<br />
ls: nie ma dost\u0119pu do /sys/module/apparmor: No such file or directory<br />
grep: /proc/modules: No such file or directory<br />
ls: nie ma dost\u0119pu do /sys/module/apparmor: No such file or directory<br />
FATAL: Could not load /lib/modules/2.6.28.1-xxxx-std-ipv4-32/modules.dep: No such file or directory<br />
Loading AppArmor module: Failed.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: fade</title>
		<link>http://www.ubuntu-howto.info/howto/how-to-move-mysql-databases-to-another-location-partition-or-hard-drive/comment-page-1#comment-471</link>
		<dc:creator>fade</dc:creator>
		<pubDate>Sun, 22 Mar 2009 18:49:20 +0000</pubDate>
		<guid isPermaLink="false">http://www.ubuntu-howto.info/?p=4#comment-471</guid>
		<description>Don Long's advice worked for me. Thanks

@imwaltraud
"You should also move the ibdata1, ib_logfile0 and ib_logfile1 files. If you don’t all your InnoDB tables will be gone."

Those files get recreated at the new location on rebooting.</description>
		<content:encoded><![CDATA[<p>Don Long&#8217;s advice worked for me. Thanks</p>
<p>@imwaltraud<br />
&#8220;You should also move the ibdata1, ib_logfile0 and ib_logfile1 files. If you don’t all your InnoDB tables will be gone.&#8221;</p>
<p>Those files get recreated at the new location on rebooting.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: jay</title>
		<link>http://www.ubuntu-howto.info/howto/how-to-move-mysql-databases-to-another-location-partition-or-hard-drive/comment-page-1#comment-341</link>
		<dc:creator>jay</dc:creator>
		<pubDate>Sun, 08 Mar 2009 09:42:30 +0000</pubDate>
		<guid isPermaLink="false">http://www.ubuntu-howto.info/?p=4#comment-341</guid>
		<description>i done this without any issue
thanks</description>
		<content:encoded><![CDATA[<p>i done this without any issue<br />
thanks</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: imwaltraud</title>
		<link>http://www.ubuntu-howto.info/howto/how-to-move-mysql-databases-to-another-location-partition-or-hard-drive/comment-page-1#comment-146</link>
		<dc:creator>imwaltraud</dc:creator>
		<pubDate>Tue, 03 Feb 2009 19:01:24 +0000</pubDate>
		<guid isPermaLink="false">http://www.ubuntu-howto.info/?p=4#comment-146</guid>
		<description>You should also move the ibdata1, ib_logfile0 and ib_logfile1 files. If you don't all your InnoDB tables will be gone.</description>
		<content:encoded><![CDATA[<p>You should also move the ibdata1, ib_logfile0 and ib_logfile1 files. If you don&#8217;t all your InnoDB tables will be gone.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: cactus</title>
		<link>http://www.ubuntu-howto.info/howto/how-to-move-mysql-databases-to-another-location-partition-or-hard-drive/comment-page-1#comment-103</link>
		<dc:creator>cactus</dc:creator>
		<pubDate>Sat, 10 Jan 2009 05:31:23 +0000</pubDate>
		<guid isPermaLink="false">http://www.ubuntu-howto.info/?p=4#comment-103</guid>
		<description>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
emember to update apparmor on hardy:
nano /etc/apparmor.d/usr.sbin.mysqld
add the new location:
/var/www/mysql_datadir/ r,
/var/www/mysql_datadir/** rwk,

restart apparmor:
/etc/init.d/apparmor restart
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

needed this for ubuntu 8.10</description>
		<content:encoded><![CDATA[<p>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~<br />
emember to update apparmor on hardy:<br />
nano /etc/apparmor.d/usr.sbin.mysqld<br />
add the new location:<br />
/var/www/mysql_datadir/ r,<br />
/var/www/mysql_datadir/** rwk,</p>
<p>restart apparmor:<br />
/etc/init.d/apparmor restart<br />
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~</p>
<p>needed this for ubuntu 8.10</p>
]]></content:encoded>
	</item>
</channel>
</rss>
