Step By Step: Install Wordpress Multiuser (WPMU) On FreeBSD 7
Wordpress is one of my favourite blog engines because it's easy and supports many plugins. Wordpress also available in multi-user mode which means a single Wordpress installation will cover many users with their own subdomain. This howto will show the steps taken to install Wordpress wpmu on a server running FreeBSD 7 stable.
1. Download latest wpmu file.
wget http://mu.wordpress.org/latest.tar.gz
2. Extract and rename:
pwd
/home/phantom/public_html
ls
info.php latest.tar.gz
tar xvfz latest.tar.gz && rm latest.tar.gz && mv wordpress-mu-1.5.1 wpmu
ls
info.php wpmu
3. Log in to your DNS server and change the DNS entry to allow wildcards. Ex:
+blog.bogus.com:172.88.1.4:86400
+*.blog.bogus.com:172.88.1.4:86400
Make for update:
make
/usr/local/bin/tinydns-data
Restart the dns service:
svc -t /var/service/dnscache/
svc -t /var/service/tinydns/
Testing dns:
dig blog.bogus.com
dns# dig blog.bogus.com
; <> DiG 9.4.2 <> blog.bogus.com
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 40754
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0
;; QUESTION SECTION:
;blog.bogus.com. IN A
;; ANSWER SECTION:
blog.bogus.com. 86400 IN A 172.88.1.4
;; Query time: 12 msec
;; SERVER: 172.88.1.1#53(172.88.1.1)
;; WHEN: Fri Jun 20 08:44:06 2008
;; MSG SIZE rcvd: 53
dig alam.blog.bogus.com
dns# dig alam.blog.bogus.com
; <> DiG 9.4.2 <> alam.blog.bogus.com
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 42517
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0
;; QUESTION SECTION:
;alam.blog.bogus.com. IN A
;; ANSWER SECTION:
alam.blog.bogus.com. 86400 IN A 172.88.1.4
;; Query time: 6 msec
;; SERVER: 172.88.1.1#53(172.88.1.1)
;; WHEN: Fri Jun 20 08:44:15 2008
;; MSG SIZE rcvd: 58
4. Switch to blog server and change httpd.conf entry:
ee /usr/local/etc/apache/httpd.conf
NameVirtualHost 172.88.1.4 <VirtualHost 172.88.1.4 > ServerAdmin [email protected] DocumentRoot /home/phantom/public_html/wpmu <Directory /home/phantom/public_html/wpmu > AllowOverride FileInfo Options </Directory> ServerName blog.bogus.com ServerAlias *.blog.bogus.com </VirtualHost>
Save and restart apache.
5. Make database and grant user.
mysql -uroot -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 46
Server version: 5.0.51a-log FreeBSD port: mysql-server-5.0.51a
Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the buffer.
mysql> show databases;
+——————–+
| Database |
+——————–+
| information_schema |
| mysql |
+——————–+
2 rows in set (0.02 sec)
mysql> create database wpmu;
Query OK, 1 row affected (0.01 sec)
mysql> grant all privileges on wpmu.* to alam@localhost identified by ‘doyanmakan’ with grant option;
Query OK, 0 rows affected (0.02 sec)
mysql> flush privileges;
Query OK, 0 rows affected (0.00 sec)
mysql>
6. Starting install, open a browser and type http://blog.bogus.com.
A chmod message will show up, just type this in the shell:
chmod 777 /home/phantom/public_html/wpmu /home/pahntom/public_html/wpmu/wp-content/
Refresh the browser.
Follow the steps :
- Choose subdomain
- Fill information according to step 5.
- Server address, let it as is.
- Site details, fill in proper entry.
Click Submit.
If everything works well you’ll see confirmation if the installation process went succesfully. Username and password generated.
7. Reset file into previous state.
chmod 755 /home/phantom/public_html/wpmu /home/phantom/public_html/wpmu/wp-content/
Done.
Administrator can add new themes, plugins to add more interactivity.