slackware设置LAMP - digwtx's Blog

slackware设置LAMP

digwtx posted @ 2009年8月12日 21:56 in Slackware , 1632 阅读

Apache2:

設定檔為/etc/httpd/httpd.conf,而網頁放置在/srv/httpd/htdocs/目錄中

替Apache2加上執行檔後啟動
# chmod +x /etc/rc.d/rc.httpd
# /etc/rc.d/rc.httpd start

打開Firefox在網址列打上http://localhost/,假如成功的話,會出現It works!

Mysql5:

先 vi /etc/rc.d/rc.mysqld 瞧瞧,會看到一堆英文......裡面有這兩行
# su - mysql
# mysql_install_db
給它照著打一遍

然後
# mv /etc/my-small.cnf /etc/my.cnf (my-small.cnf不一定適合你,請依需求自己換為my-huge.cnf,my-large.cnf或my-medium.cnf)
# chown -R mysql:mysql /var/lib/mysql/

啟動Mysql
# chmod +x /etc/rd.d/rc.mysqld
# /etc/rc.d/rc.mysqld start

接下來創個資料庫試試看,有沒有發現資料庫是Ro呀 ^^
# mysqladmin -u root password <Your_Pass_Word>
# mysqladmin -u root -p create ragnarok

測試一下有沒有乖乖的做事吧!
# mysql -u root -p

Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 1
Server version: 5.0.37 Source distribution

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql>
看到mysql>的提示符號就知道正常工作嚕

PHP5:

PHP5的設定檔php.ini和mod_php.conf都在/etc/httpd目錄下
# cd /etc/httpd/
# mv php.ini-recommended php.ini
# mv mod_php.conf.example mod_php.conf
# vi /etc/httpd/httpd.conf,去掉第472行的註解#,然後在DirectoryIndex index.html的後面加上 index.htm index.php,如下

#Include /etc/httpd/mod_php.conf
改為
Include /etc/httpd/mod_php.conf
.
DirectoryIndex index.html
改為
DirectoryIndex index.html index.htm index.php

然後重啟Apache2
# /etc/rc.d/rc.httpd restart

接下來測試PHP5有沒有正常
# vi /srv/httpd/htdocs/test.php,輸入以下內容

<html>
<head>
<title> PHP Test Script </title>
</head>
<body>
<?php
    phpinfo();
?>

</body>
</html>


然後Firefox網址列打上http://localhost/test.php,假如出現PHP的訊息頁就是成功了

 

Avatar_small
NBSE Plus One Previo 说:
2022年8月16日 21:34

The Nagaland 11th grade Important Question Paper 2023 was released in May of the previous year, and the exams were held in March. The 11th grade examinations were held in March this year, as they were the year before, and we anticipate that the May announcement of the Nagaland 11th Important Question Paper 2023 will be the same. NBSE Plus One Previous Paper 2023 Therefore, following the release of the Nagaland 11th Model Paper, all students who took these examinations and are currently anticipating the NBSE +2 Important Question Paper 2023 of these exams may check their Nagaland 11th Important Question Paper 2023 by utilising the official web portal site of this board.

Avatar_small
blockpost 说:
2022年9月11日 13:16

The most recent free-to-play first-person shooter game that can be played on both mobile devices and desktop PCs is called Blockpost. This game is a superb illustration of how cubic 3D game graphics and first-person shooter (FPS) gameplay can coexist seamlessly. With gamers from around the world, you will participate in fierce online firefights.

Avatar_small
run 3 说:
2022年10月07日 17:24

We get a lot of fun out of the various internet games available nowadays.

Avatar_small
milan 说:
2023年1月10日 22:11

Slackware is a great choice for setting up a LAMP server. It is a very stable and secure operating system, and the package manager peter veres photography artist makes it easy to install all of the necessary software. Apache, MySQL, and PHP will all run perfectly on Slackware, and you will have a robust and reliable server that can handle any load.

Avatar_small
blob opera 说:
2023年5月19日 16:39

I think this is one of the more important information for me personally.

Avatar_small
geometry dash 说:
2023年7月19日 17:45

We have a great time playing all of the numerous games that are available to us on the internet. In the normal flow of things to happen

Avatar_small
wordle today 说:
2023年7月19日 17:48

The various internet games that are accessible to us are a great source of entertainment, and we spend a lot of time participating in them. As is customary and appropriate, the following will occur:

Avatar_small
free games 说:
2023年7月20日 18:13

We have a terrific time taking part in all of the different games that we can access over the internet since there are so many of them. In accordance with the usual course of events to take place

Avatar_small
connections puzzle 说:
2023年10月23日 21:33

The diverse array of internet games available to individuals serves as a significant means of amusement, resulting in a substantial investment of time in their participation.

Avatar_small
mario games 说:
2023年10月26日 16:26

正是我所关心的! 请分享更多这样有用的信息!

Avatar_small
Eggy Car 说:
2023年11月28日 17:03

The information you provided was very helpful and helped me complete my project.

Avatar_small
boardmodelpaper.com 说:
2024年1月10日 13:36

The Board model paper" typically refers to a sample or model question paper that is designed by educational boards or institutions for various exams. These papers serve as practice material for students preparing for exams, providing them with an idea of the question format, difficulty level, and the type of content that may be covered in the actual examination. boardmodelpaper.com Model papers are usually created for specific subjects or courses. They cover a range of topics and chapters that students are expected to have studied during the academic term. Students often use these educational board model papers as an integral part of their exam preparation strategy, helping them familiarize themselves with the exam pattern and refine their understanding of the subject matter.

Avatar_small
Things to do 说:
2024年2月21日 19:22

Are you ready to embark on an unforgettable journey filled with incredible experiences? Start exploring things to do today and unlock a world of endless possibilities. Let's dive in and discover the best things to do post together!"

Avatar_small
1000 kwh battery 说:
2024年7月04日 19:35

For checked admirers of this string I will address is a free on the web! DIGIHUMAN anatomical model foundation model of anatomy

Avatar_small
1000 kwh battery 说:
2024年7月04日 19:35

 For the current condition you will start it is goliath, it again passes on a site a solid titanic page: youibot mobile autonomous robot amr robot

Avatar_small
Pokerogue 说:
2024年8月03日 08:34

The Nagaland 11th grade Important Question Paper 2023 reflects the structured approach to examinations, akin to strategic decision-making in games like Pokerogue. Just as players on the Pokerogue wiki analyze strategies to maximize their chances, students can similarly benefit from reviewing past papers to enhance their preparation. The consistency of exam dates, as noted, can help students plan their study schedules effectively. For those intrigued by gaming tactics, delving into Pokerogue strategies can provide an engaging diversion while studying. Students should stay updated via the official board portal to ensure they’re well-prepared for their exams and new gaming challenges.

Avatar_small
Friday Night Funkin 说:
2024年10月08日 10:58

To set up Apache2, you need to modify the configuration file at /etc/httpd/httpd.conf and place your web files in /srv/httpd/htdocs/. For MySQL, ensure you've configured and started it correctly, creating your database with commands like mysqladmin. It's as fun as playing Friday Night Funkin – both require practice!

Avatar_small
Slope Game 说:
2024年10月08日 17:16

To set up your Apache2 and MySQL, start by editing the configuration files and providing the right permissions. After configuring MySQL, create a database to test your setup. Don't forget to verify PHP by creating a test file. Meanwhile, take a break and play the Slope game—you'll enjoy the thrill of rolling down slopes while your server runs smoothly!

Avatar_small
Slope Unblocked 说:
2024年11月27日 15:13

To set up LAMP on Slackware, start by installing Apache, MySQL, and PHP. Configure each component to ensure compatibility. For a streamlined experience, check out Slope Unblocked for additional resources and guides. This setup will enhance your web development capabilities effectively.


登录 *


loading captcha image...
(输入验证码)
or Ctrl+Enter
Host by is-Programmer.com | Power by Chito 1.3.3 beta | © 2007 LinuxGem | Design by Matthew "Agent Spork" McGee