Installing Web Server in FreeBSD 6.0 with Apache 2.2, MySQL 5.0 and PHP 5 – Part 5 Cài đặt Web Server trong FreeBSD 6,0 với 2,2 Apache, MySQL 5.0 và PHP 5 - Phần 5

Installing Apache 2.2, MySQL 5 and PHP 5 in FreeBSD 6.0 for a Reliable Web Server Cài đặt Apache 2.2, MySQL 5 và PHP 5 in FreeBSD 6,0 cho một máy chủ web đáng tin cậy

Part 5 – Installing PHP Hypertext Preprocessor Scripting Language 5 and PHP 5 Extensions Phần 5 - Cài đặt PHP Hypertext Preprocessor Scripting Ngôn ngữ 5 và PHP 5 Extensions

  1. Install by enter the following commands on FreeBSD OS command line, wait for previous command to finish before running the next command: Cài đặt bằng cách nhập vào các lệnh sau trên FreeBSD dòng lệnh điều hành, chờ lệnh trước đó để kết thúc trước khi chạy lệnh sau:

    cd /usr/ports/lang/php5 cd / usr/ports/lang/php5
    make install clean thực hiện cài đặt sạch

  2. If you're prompted, select “use Apache 2.x instead”. Nếu bạn được nhắc, chọn "sử dụng Apache 2.x thay vì".
  3. Continue with the following commands to install PHP5 extensions and modules to enable the support of the modules in Apache: Tiếp tục với các lệnh sau để cài đặt phần mở rộng PHP5 và mô-đun để kích hoạt sự hỗ trợ của các module trong Apache:

    cd /usr/ports/lang/php5-extensions cd / usr/ports/lang/php5-extensions
    make config làm cho config

  4. At Options for php5-extension 1.0 menu, select all PHP extensions and modules that you may use with Apache webserver. Tại Options for php5-mở rộng 1,0 menu, chọn tất cả các phần mở rộng PHP và các module mà bạn có thể sử dụng với máy chủ web Apache. This is a part of the configuration for PHP, where you need to enable features of PHP that come in modules, such as ability to manage user sessions, interface with databases and many others. Đây là một phần của cấu hình cho PHP, khi bạn cần phải kích hoạt tính năng của PHP có sẵn trong mô-đun, chẳng hạn như khả năng quản lý phiên người sử dụng, giao diện với cơ sở dữ liệu và nhiều người khác. Default extensions such as ctype functions support, HASH Message Digest Framework support, session support and etc have been selected. Mặc định phần mở rộng như hỗ trợ chức năng ctype, HASH Message Digest Framework hỗ trợ, hỗ trợ phiên làm việc và vv đã được chọn. Other popular extensions that you most likely to be in used are MySQL database support and GD library support. Các phần mở rộng phổ biến nhất mà bạn có khả năng được sử dụng trong cơ sở dữ liệu MySQL được hỗ trợ và hỗ trợ thư viện GD. Use space bar to select or unselect the extensions and press Enter when done. Sử dụng không gian thanh để chọn hoặc bỏ chọn các phần mở rộng và nhấn Enter khi thực hiện xong.
  5. Continue the installation of php5-extensions with the following commands: Tiếp tục cài đặt của php5-phần mở rộng với các lệnh sau đây:

    make install clean thực hiện cài đặt sạch

  6. If there are any message the pops up and prompts you to select some options or configurations, you can just accept the default settings by pressing Enter. Nếu có bất kỳ thông báo bật lên và sẽ nhắc bạn lựa chọn một số tùy chọn hoặc cấu hình, bạn chỉ có thể chấp nhận các thiết lập mặc định bằng cách nhấn Enter. Some modules that may prompt you for action include php5-gd, php5-mbstring and php5-sqlite. Một số module có thể nhắc bạn cho hành động bao gồm php5-gd, php5-mbstring và php5-SQLite.
  7. Edit the Apache configuration file in order to enable Apache web server to load the PHP modules when initialization: Chỉnh sửa file cấu hình Apache để kích hoạt máy chủ web Apache để nạp module PHP khi khởi tạo:
    1. Go to Apache configuration file location by cd /usr/local/etc/apache2/ Go to Apache vị trí tập tin cấu hình của cd / usr/local/etc/apache2 /
    2. Edit Apache configuration file by vi httpd.conf Apache sửa file cấu hình bằng vi httpd.conf
    3. Search for LoadModule lines, after the last LoadModule line, but within the same section, add the following 2 lines: Tìm dòng LoadModule, sau khi dòng LoadModule cuối, nhưng trong phần đó, thêm 2 dòng sau:

      AddType application/x-httpd-php .php AddType application / x-httpd-php. Php
      AddType application/x-httpd-php-source .phps AddType application / x-httpd-php-source. Phps

  8. Optionally, copy /usr/local/etc/php.ini-recommended or /usr/local/etc/php.ini-dist to /usr/local/etc/php.ini (in same directory), which will enable you to tune and change the default settings of behaviours of PHP. Tùy chọn, sao chép thư mục / usr / local / etc / php.ini-recommended hoặc / usr / local / etc / php.ini-dist vào / usr / local / etc / php.ini (trong cùng thư mục), mà sẽ cho phép bạn điều chỉnh và thay đổi các thiết lập mặc định của hành vi của PHP.
  9. Start the Apache HTTP web server by using apachectl start (or restart Apache HTTP web server by using apachectl restart). Bắt đầu máy chủ web Apache HTTP bằng cách sử dụng bắt đầu apachectl (hoặc khởi động lại máy chủ web Apache HTTP bằng cách sử dụng apachectl khởi động lại). apachectl is located in /usr/local/sbin, if you encounter Command not found problem, try to change directory to its location. apachectl nằm trong / usr / local / sbin, nếu bạn gặp Lệnh không được tìm thấy vấn đề, hãy thử thay đổi thư mục đến vị trí của nó.
  10. PHP5 installation done. PHP5 cài đặt hoàn tất.

A web server has been setup with the FreeBSD with Apache, MySQL and PHP. Một máy chủ web đã được thiết lập với FreeBSD với Apache, MySQL và PHP. The document root of the web server (where you should put your HTML and PHP files is at /usr/local/www/apache22/data/ and you will need a SecureFTP (SFTP) client such as WinSCP to upload your files to web server securely. Các tài liệu gốc của máy chủ web (nơi bạn nên đặt HTML và PHP tập tin của bạn là lúc / usr/local/www/apache22/data / và bạn sẽ cần một SecureFTP (SFTP) khách hàng như WinSCP để tải lên tập tin của bạn lên web server cách an toàn.

IMPORTANT : The page is machine translated and provided "as is" without warranty. Quan trọng: Sửa là máy dịch và cung cấp "như là" không có bảo hành. Machine translation may be difficult to understand. Máy dịch thuật có thể khó hiểu. Please refer to Vui lòng tham khảo original English article bản gốc tiếng Anh bài viết whenever possible. bất cứ khi nào có thể.


27 Responses to “Installing Web Server in FreeBSD 6.0 with Apache 2.2, MySQL 5.0 and PHP 5 – Part 5” 27 Responses to "Cài đặt Web Server trong FreeBSD 6,0 với 2,2 Apache, MySQL 5.0 và PHP 5 - Phần 5"

Pages: [2] Trang: [2] 1 1 » » Show All Hiển thị tất cả

  1. data trucker dữ liệu Trucker
    May 13th, 2009 08:18 Ngày 13 Tháng Năm 2009 08:18
    27 27

    This php setup doesn't support mysql element. Điều này thiết lập php không hỗ trợ phần tử mysql. Drupal can't detect that mysql is running… I hope this could be modified and be of help to others. Drupal không thể phát hiện ra rằng mysql đang chạy ... Tôi hy vọng điều này có thể được sửa đổi và được giúp đỡ cho người khác.

  2. fred fred
    November 25th, 2008 10:40 Ngày 25 tháng 11 2008 10:40
    26 26

    This is a fine series of articles! Đây là một loạt điều tốt đẹp!

    The only real change I would suggest is executing portsnap or cvsup after the base installation, before installing apache, mysql and php. Các chỉ thực sự thay đổi tôi sẽ đề nghị được thực hiện portsnap hoặc cvsup sau khi cài đặt cơ bản, trước khi cài đặt apache, mysql và php.

Pages: [2] Trang: [2] 1 1 » » Show All Hiển thị tất cả

Leave a Reply Để lại một trả lời

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> Bạn có thể sử dụng các thẻ: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime = ""> <em> <i> <q <strike> <strong>

Subscribe to comments feature has been disabled. Thuê bao với ý kiến đều đã bị vô hiệu hoá. To receive notification of latest comments posted, subscribe to Để nhận được thông báo mới nhất đăng ý kiến, đăng ký với My Digital Life Comments RSS feed My Digital Life kiến RSS feed or hoặc register to receive đăng ký để nhận được new comments in daily email digest. Các ý kiến mới trong email tiêu hàng ngày.
Custom Search

New Articles Bài viết mới

Incoming Search Terms for the Article Tìm đến các Điều khoản Điều

freebsd apache2 freebsd apache2 - -- how to load mysql.so on apache22 using freebsd làm thế nào để tải mysql.so ngày apache22 sử dụng freebsd - -- freebsd apache php mysql freebsd apache php mysql - -- apache22 php apache22 php - -- install php freebsd cài đặt php freebsd - -- enable apache en freebsd cho phép apache en freebsd - -- freebsd apache php5 freebsd apache php5 - -- freebsd php extensions freebsd php phần mở rộng - -- freebsd install php-mbstring freebsd cài đặt php-mbstring - -- freebsd mysql-server php freebsd mysql-server php - -- freebsd install apache php freebsd cài đặt php apache - -- install apache+php freeBSD cài đặt apache + php FreeBSD - -- installing php on freebsd cài đặt php trên freebsd - -- php source installation mysql configuration php mã nguồn cài đặt cấu hình mysql - -- apache22 php freebsd apache22 php freebsd - -- apache freebsd config apache freebsd config - -- apache2 freebsd apache2 freebsd - -- freebsd php5 ports freebsd php5 cảng - -- freebsd apache2 php freebsd apache2 php - -- freebsd apache2 php5 freebsd apache2 php5 - -- freebsd web server freebsd web server - -- install php extension freebsd cài đặt phần mở rộng php freebsd - -- phpextensions freebsd phpextensions freebsd - -- apache22 php enable apache22 php cho phép - -- apache php mysql freebsd apache php mysql freebsd - -- apache22 php5 enable apache22 php5 bật - -- freebsd apache 2.2 mysql freebsd 2,2 apache mysql - -- freebsd apache22 enable php freebsd apache22 phép php - -- freebsd php mysql freebsd php mysql - -- freebsd php install freebsd php cài đặt - -- freebsd+apache2+module freebsd + + apache2 module - -- freebsd php mysql apache freebsd php mysql apache - -- install apache22 mysql php freebsd cài đặt apache22 php mysql freebsd - -- istall apache 2 php mysql in freebsd istall apache 2 php mysql trong freebsd - -- php+freebsd php + freebsd - -- apache2 php5 configuration freebsd apache2 php5 cấu hình freebsd - -- freebsd php module apache2 freebsd php module apache2 - -- freebsd apache 2 freebsd apache 2 - -- freebsd apache test load freebsd apache thử tải - -- freebsd php extensions location freebsd php mở rộng địa điểm - -- php5 freebsd php5 freebsd - -- php5-extensions freebsd php5-extensions freebsd - --