Friday, September 09, 2005

Fun with FreeBSD 5.4 chapter 2.0

Installing MySQL from ports with a custom data directory the quick and dirty way:

cd /usr/ports/databases/mysql41-server/
make install clean
cp /usr/local/share/mysql/my-medium.cnf /etc/my.cnf
mkdir /data/db
/usr/local/bin/mysql_install_db --user=mysql --datadir=/data/db
chown -R mysql /data/db/mysql/
chgrp -R mysql /data/db/mysql/
/usr/local/bin/mysqld_safe --user=mysql --datadir=/data/db &
/usr/local/bin/mysqladmin --user=root password 'newpassword'
/usr/local/bin/mysqladmin --user=root --password=newpassword shutdown
vi /etc/rc.conf
# added 08/29/2005 grouchy@root mysql installation

When installing PHP extensions if you are going to use GD or Imagick, both require ghostscript and X11 - two large chunks you might want to consider installing from CD if possible or do as I did and said "screw it" and did not install them (most wiki's I've looked at want one or the other for thumbnailing).

No comments: