INSTALL WORDPRESS,APACHE,PHP & MYSQL

Develop your own WORD PRESS – BLOG SITE


Pre-Installation process:
Make sure these paths are added

/usr/sbin:/usr/bin:/usr/bin/nsr:/usr/ccs/bin:/usr/local/bin


Installation of Apache:

1. you can download the software from : http://httpd.apache.org/download.cgi
2. installable: httpd-2.2.8.tar.gz
3. If gz file
Run the cmd:
gunzip httpd-2.2.8.tar.gz

4. Extract the file :
Run the cmd to extract the tar file:
tar –xvf httpd-2.2.8.tar


5. Configure Apache:
./configure --prefix=/usr/local/apache2


6. Build the File:
make

7. Install the built source
make install

8. To start/stop server

Path: $APACHE-HOME/bin
./apachectl start/stop/restart



9. Access the server
http:///



10. TroubleShooting

When encoutering the below problem while running make command do the following

line 5904: ar: command not found

Solution: add /usr/ccs/bin to the PATH in /etc/profile and then run the command.

Reference forum link: http://forum.java.sun.com/thread.jspa?threadID=5214471&messageID=9869011

11. The httpd.conf file has to be configured in which the document root should be added where the Wordpress is to be placed, see the httpd.conf file for more details.


Installation of MySql:


1). Download mysql-5.0.51.tar
from address given below (as a mirror image) :

http://dev.mysql.com/get/Downloads/

2). Keep the downloaded file to the /opt/portal/ directory. If the extn of the file is tar.tar ,change the file extension to .gz. Then gunzip the file by using the gunzip command as

gunzip

3). tar -xvf mysql-5.0.51.tar

4) mv mysql-5.0.51 MySql

5) Link the MySql Folder to mysql folder by going to /usr/local/ and running the command as

ln -s /app/blog/Mysql/ mysql



*** Rather than creating a link , we can directly put the contents of mysql-5.0.51.tar
in /usr/local/mysql

Build the File:
make

make test

Install the built source

make install
6) Follow the steps as given in "INSTALL-BINARY" file in MySql folder.

7)PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:


MySql/bin/mysqladmin -u root password 'new-password'


8)We can check the mysql is running or not by using the command as

ps -ef |grep mysql

9) When the server is up, Enter mysql mode by using the following command:

mysql --user=username(e.g.root) --password

press enter.

then you will be asked for the password of user. Enter the password.

10) Create a DB using the following command:

create database tatasky_blogdb;


GRANT ALL PRIVILEGES ON tatasky_blogdb.* TO 'blog' IDENTIFIED BY ‘blog123’;



This command is to provide user blog all the privilages over tatasky_blogdb from local environment (provided '@localhost') .

GRANT ALL PRIVILEGES ON tatasky_blogdb.* TO 'blog' @ ‘PBLOGA01.tatasky.com' IDENTIFIED BY 'blog123';

This command is to provide user blog all the privilages over tatasky_blogdb from local environment (provided '@ PBLOGA01.tatasky.com ') .




IDENTIFIED BY clause is to provide the password for the user.




Installation of php:

1. you can download the software from : http://httpd.apache.org/download.cgi
2. installable: php5.0..tar.gz
3. If gz file
Run the cmd:
gunzip php-5.2.5.tar.gz

4. Extract the file :
Run the cmd to extract the tar file:
tar –xvf php-5.2.5.tar

5. Configure php:

./configure --with-apxs2=/usr/local/bin/apxs
--with-mysql=/usr/local/
--with-mysqli=/usr/local/mysql/bin/mysql_config
--with-zlib

6. Build the File:
make

7. Compile the file

make test

8. Install the built source

make install

9. finally

make clean

Now installation of PHP is done

After these installation are complete, installation of WORDPRESS is two page job,
Installation of WORDPRESS
1. Unzip the package in an empty directory.
2. Open up wp-config-sample.php with a text editor like WordPad or similar and fill in your database connection details.
3. Save the file as wp-config.php , and change the required parameters in the config file
// ** MySQL settings ** //
define('DB_NAME', 'putyourdbnamehere'); // The name of the database
define('DB_USER', 'usernamehere'); // Your MySQL username
define('DB_PASSWORD', 'yourpasswordhere'); // ...and password
define('DB_HOST', 'localhost'); // 99% chance you won't need to change this value
define('DB_CHARSET', 'utf8');
define('DB_COLLATE', '');

// Change SECRET_KEY to a unique phrase. You won't have to remember it later,
// so make it long and complicated. You can visit http://api.wordpress.org/secret-key/1.0/
// to get a secret key generated for you, or just make something up.
define('SECRET_KEY', 'put your unique phrase here'); // Change this to a unique phrase.

// You can have multiple installations in one database if you give each a unique prefix
$table_prefix = 'wp_'; // Only numbers, letters, and underscores please!

// Change this to localize WordPress. A corresponding MO file for the
// chosen language must be installed to wp-content/languages.
// For example, install de.mo to wp-content/languages and set WPLANG to 'de'
// to enable German language support.
define ('WPLANG', '');

/* That's all, stop editing! Happy blogging. */

define('ABSPATH', dirname(__FILE__).'/');
require_once(ABSPATH.'wp-settings.php');
?>
4. Upload everything.
5. Open /wp-admin/install.php in your browser. This should setup the tables needed for your blog. If there is an error, double check your wp-config.php file, and try again. If it fails again, please go to the support forums with as much data as you can gather.
6. Note the password given to you.
7. The install script should then send you to the login page. Sign in with the username admin and the password generated during the installation. You can then click on 'Profile' to change the password.


After the completion of installation, use the wordpress manual to customize your wordpress,

1 comments:

Abdul Khader said...

Dai roomy..what's this man..?
Ada paavi..college le irkrapo java,php laam enanu kooda theryama irundaye da..Ipa matum epdi da?....LOL!!