LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 02-12-2009, 01:24 AM   #16
bsurfin
Member
 
Registered: May 2004
Location: Kalispell Montana
Distribution: Kubuntu ( Current Version )
Posts: 112

Rep: Reputation: 15

Ok I got it, I did make the /var/www/html directory and finished installing, then it didn't work, so I moved the directory "phpmyadmin" to the /var/www/htdoc/ directory and voila it works just fine.

anyway that is strange why I am missing the html directory, but instead have a htdoc directory.

Thanks for the tutorial, Very Helpful
 
Old 02-12-2009, 02:33 AM   #17
mRgOBLIN
Slackware Contributor
 
Registered: Jun 2002
Location: New Zealand
Distribution: Slackware
Posts: 999

Rep: Reputation: 227Reputation: 227Reputation: 227
I think it's a typo in the original post.

If you have a look at the /etc/httpd/httpd.conf you'll see the "DocumentRoot" directive that points to the default directory /var/www/htdocs.

You can change the document root to something else if you want to but do read the comments and suggestions in the httpd.conf file and be sure you understand the effects of the different options there.

If you make any changes to the httpd.conf file you will need to restart the httpd server.
 
Old 06-10-2009, 07:21 PM   #18
phunkymunky
Member
 
Registered: Aug 2003
Location: Glasgow, Scotland
Distribution: Slackware 14.0, Debian 7.0
Posts: 60

Rep: Reputation: 22
bsurfin that should probably be /var/www/htdocs not /var/www/html

Last edited by phunkymunky; 06-10-2009 at 07:22 PM. Reason: oops already fixed :)
 
Old 06-10-2009, 07:54 PM   #19
bgeddy
Senior Member
 
Registered: Sep 2006
Location: Liverpool - England
Distribution: slackware64 13.37 and -current, Dragonfly BSD
Posts: 1,810

Rep: Reputation: 227Reputation: 227Reputation: 227
... Proofreading can be very important - especially when posting instructions ...
 
Old 06-28-2009, 11:25 AM   #20
Luxr
Member
 
Registered: Jun 2009
Distribution: Slackware Current
Posts: 30

Rep: Reputation: 15
Question

Quote:
Originally Posted by Penthux View Post
After a new install of Slackware 12.2, I carried out the following procedures to get everything working successfully right out of the box.
The server is a standalone system, used for testing and educational purposes, so please bear that in mind.

NB: Throughout this post when you see a single # at the start of a line it means you are typing the commands as root user. You should not include the #, only the text after it.

### setup Apache with php enabled
Login as root user on your Slackware box and type:
# pico -w /etc/httpd/httpd.conf

Press CTRL+w to search and type mod_php.conf to find this line:
#Include /etc/http/mod_php.conf
Uncomment it, just remove the # from the begining of the line.

Also find the following line:
DirectoryIndex index.html
Change it to this:
DirectoryIndex index.html index.htm index.php default.htm

Save the file and exit ( press CTRL+x ). Now type this:
# chmod 755 /etc/rc.d/rc.httpd
# /etc/rc.d/rc.httpd start

If the httpd server is not already running, you should have Apache and php running. Your web file root directory is: /var/www/htdocs
If you receive the message "httpd (pid 12345) already running" (NB: pid is just here for example and can be any value), type this:
# /etc/rc.d/rc.httpd restart

Open your browser and go to http://localhost/ and you should see this big bold message on a blank white page: It Works!

### Extra - test php is working ###
To test php is working, back on the command line type this:
# pico -w /var/www/htdocs/info.php

Copy and paste the following text into the pico text editor, or type it:
<?php
phpinfo();
?>

Press CRTL+x and save the file as info.php, or any filename you like with the .php extension.

In your browser go to http://localhost/info.php (or the filename you chose, obviously!)
You should be presented with a nice page full of information which means php is working perfectly.


### setup MySQL (secure installation)
Still logged in as root user, to setup MySQL type this:
# chmod 755 /etc/rc.d/rc.mysqld
# mysql_install_db
# chown -R mysql:mysql /var/lib/mysql
# cp /usr/share/mysql/mysql.server /etc/rc.d/rc.mysql
# chmod 755 /etc/rc.d/rc.mysql
# /etc/rc.d/rc.mysql start
# /usr/bin/mysqladmin -u root password 'password'
** ( NB: the password for MySQL root user will now be: password )
# mysql_secure_installation

Enter your password when requested ( password is: password ), follow the prompts, answering ALL questions. Then type:
# /etc/rc.d/rc.httpd restart

Now the MySQL database should be running too.

#### install phpMyAdmin 3.1.1
Again, as root user type:
# cd /var/www/html
# wget http://ovh.dl.sourceforge.net/source...english.tar.gz
# tar zxvf phpMyAdmin-3.1.1-english.tar.gz
# mv phpMyAdmin-3.1.1-english phpmyadmin
# cd phpmyadmin
# cp config.sample.inc.php config.inc.php
# pico -w config.inc.php

Now edit this line by putting anything between the quotes:
( The example here is 'your_text', you can use any letter or number combination but NO special chars! )
$cfg['blowfish_secret'] = 'your_text'; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */

Also change 'cookie' to 'http' on this line:
$cfg['Servers'][$i]['auth_type'] = 'http';
exit and save ( press CRTL+x )
# /etc/rc.d/rc.httpd restart

Open your browser and go to http://localhost/phpmyadmin/ and you should be presented with either a login prompt or the phpMyAdmin interface, depending on your selections during the MySQL secure install process.

user: root
password: password

NB: if you changed the mysql root password, during the secure installation, use the new password.

### eof

I thought this might be a good idea for new(ish) Slackware users as there seems to be a little confusion about setting up Apache/php/MySQL.
Any corrections, additions, advice, suggestions or otherwise are, of course, gladly welcome. :>

Hello bro, i follow up your tutorials but i can find that phpmyadmin on my browser.
i got this report
Not Found

The requested URL /phpmyadmin was not found on this server.


on this steps ="# cd /var/www/html" i made directory for html. because not such as dir report for it.

any advise for fix it bro?
thanks for share..
 
Old 06-28-2009, 03:05 PM   #21
bgeddy
Senior Member
 
Registered: Sep 2006
Location: Liverpool - England
Distribution: slackware64 13.37 and -current, Dragonfly BSD
Posts: 1,810

Rep: Reputation: 227Reputation: 227Reputation: 227
I'm afraid you really haven't been paying attention in this thread. Look again :
Quote:
bsurfin that should probably be /var/www/htdocs not /var/www/html
You should not have created /var/www/html as this is a useless directory. The default setting of DocumenRoot is /var/www/htdocs. You could possibly fix it by moving everything over and trying to run phpmyadmin again in the browser. This will move the files - do it as root :
Code:
mv  /var/www/html/* /var/www/htdocs/
If all is well you can get rid of the useless directory with this as root:
Code:
rmdir /var/www/html

Last edited by bgeddy; 05-19-2011 at 09:16 PM.
 
Old 05-19-2011, 08:05 PM   #22
farmerdave
Member
 
Registered: Mar 2008
Location: Adelaide, Australia
Distribution: Arch, Slackware 13.37
Posts: 101
Blog Entries: 1

Rep: Reputation: 16
Thanks for the contributors here. I have followed these principles for Slackware 13.37, it is still relevant. Just make sure you read each reply to find out which information you need before making changes to your system.
 
Old 10-07-2012, 11:44 PM   #23
petoeah
LQ Newbie
 
Registered: Oct 2012
Posts: 1

Rep: Reputation: Disabled
thank you, i just followed your instruction and it is working succesfully (slackware 14)
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
deb 4.0: how to install apache2, mysql 4.1, php 4 and phpmyadmin tonguim Debian 10 11-09-2007 11:39 AM
Problems with apache/php/mysql/phpmyadmin Using DEBIAN antinull Linux - Server 4 11-06-2007 05:02 PM
install Apache, MySQL, PHP, and phpMyAdmin for offline use? Kandiman Ubuntu 4 03-01-2007 02:35 PM
How do I know that apache, MySql, PHP, phpMyAdmin is Installed AskMe Linux - Newbie 7 02-04-2004 06:27 PM


All times are GMT -5. The time now is 01:51 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration