Install XCache PHP Accelerator in Linux by Compiling from Source Instal PHP XCache Accelerator di Linux oleh kompilasi dari Sumber

XCache is an alternative yet fast and stable PHP accelerator and opcode cacher that is similar to the famous eAccelerator and APC (Alternative PHP Cache). XCache merupakan alternatif namun cepat dan stabil PHP accelerator dan opcode cacher yang mirip dengan yang terkenal dan eAccelerator APC (Alternative PHP Cache). XCache extension works by caching the compiled bytecode (opcode or intermediate code) form of PHP scripts to avoid the overhead to parse and compile PHP source code on every page request, and thus reduces server loads, boosts the performance of PHP scripts and increases the speed of PHP code from 2-10 times. XCache ekstensi bekerja dengan caching yang dikompilasi bytecode (opcode atau kode intermediate) berupa skrip PHP untuk menghindari overhead untuk parsing dan mengkompilasi kode PHP sumber permintaan pada setiap halaman, sehingga mengurangi beban server, meningkatkan kinerja script PHP dan meningkatkan kecepatan kode PHP 2-10 kali.

XCache supports all of the latest PHP cvs branches such as PHP 4.3, PHP 4.4, PHP 5.1 and PHP 5.2 on Linux server including CentOS which common used on cPanel and Plesk based web hosting server, and ThreadSafe/Windows web server. XCache mendukung semua terbaru PHP cvs cabang seperti PHP 4,3, 4,4 PHP, PHP 5,1 dan 5,2 PHP di Linux CentOS termasuk server yang umum digunakan pada cPanel dan Plesk server berbasis web hosting, dan ThreadSafe / Windows web server. XCache overcomes a lot of problems that exist on opcachers or accelerators such as unable to work with new PHP versions. XCache mengatasi banyak permasalahan yang ada di opcachers atau accelerators seperti tidak dapat bekerja dengan PHP versi baru. Beside, XCache also been Disamping, juga XCache benchmarked to be faster benchmarked menjadi lebih cepat than other opcode cachers. opcode cachers daripada lainnya.

This is a simple tutorial and guide on how to install XCache PHP cacher by manually compiling from source code package. Ini adalah tutorial sederhana dan panduan tentang cara menginstal XCache PHP cacher secara manual kompilasi dari source code paket. If you're using Wordpress or using XCache to speed up and improve Wordpress blog performance, you should first ensure that PHP is upgraded to latest version (PHP 5.2.1), as PHP 4 may cause some instability issue such as unable to post comment, partial page loading and etc. Anyway, PHP5 is always recommended if possible. Jika anda menggunakan Wordpress atau menggunakan XCache untuk mempercepat dan meningkatkan kinerja Wordpress blog, terlebih dahulu Anda harus memastikan bahwa PHP adalah meng-upgrade ke versi terbaru (PHP 5.2.1), seperti PHP 4 Mei menyebabkan ketidakstabilan beberapa isu seperti tidak dapat memposting komentar , sebagian halaman dan sebagainya Anyway, PHP5 selalu disarankan jika memungkinkan. And as with all PHP accelerator, XCache won't work with PHP suEXEC turns on. Dan sebagai dengan semua PHP accelerator, XCache tidak akan bekerja dengan PHP suEXEC ternyata di. PHP suEXEC must be disabled for XCache to work properly. PHP suEXEC harus dinonaktifkan untuk XCache untuk bekerja dengan baik.

Currently, XCache maintains 2 branches, ie version 1.0.3 and version 1.2.0. Saat ini, XCache memelihara 2 cabang, yaitu versi 1.0.3 dan versi 1.2.0. Both version is now stable release, with version 1.0.x recommended for PHP 4.3.x and 4.4.x, and version 1.2.x recommended for most version of PHP including 5.1.x and 5.2.x, except PHP 5.0.x series. Kedua versi rilis stabil sekarang, dengan versi 1.0.x dianjurkan untuk PHP 4.3.x dan 4.4.x, dan versi 1.2.x disarankan untuk sebagian besar versi PHP termasuk 5.1.x dan 5.2.x, kecuali PHP 5.0.x series. If you're using PHP4, try both version of XCache to pick the one most suitable for your application. Jika Anda menggunakan PHP4, coba kedua versi XCache untuk memilih salah satu yang paling sesuai untuk aplikasi Anda. To check which version of PHP you're usinng, issue command php -v or setup a PHP file with the following content, then call the file from web browser: Untuk memeriksa versi PHP anda usinng, mengeluarkan perintah php-v PHP atau setup sebuah file dengan isi sebagai berikut, kemudian memanggil file dari web:

<?php <? php
phpinfo(); phpinfo ();
?> ?>

  1. Change to user local source directory such as /usr/local/src by using following command: Ubah untuk pengguna sumber direktori lokal seperti / usr / src dengan menggunakan perintah berikut:

    cd /usr/local/src cd / usr / local / src

  2. Retrieve and download the source package of the version of XCache you choose to install. Mengambil dan men-download paket source dari versi XCache Anda memilih untuk menginstal.

    wget http://210.51.190.228/pub/XCache/Releases/xcache-1.0.3.tar.gz (for XCache 1.0.3) wget http://210.51.190.228/pub/XCache/Releases/xcache-1.0.3.tar.gz (untuk XCache 1.0.3)

    or atau

    wget http://210.51.190.228/pub/XCache/Releases/xcache-1.2.0.tar.gz (for XCache 1.2.0) wget http://210.51.190.228/pub/XCache/Releases/xcache-1.2.0.tar.gz (untuk XCache 1.2.0)

  3. Untar, unzip, unpack or extract the archive with one of the following commands: Untar, unzip, mengekstrak sari atau arsip dengan salah satu perintah berikut:

    tar -zxf xcache-*.tar.gz tar-zxf xcache-*. tar.gz
    gzip -dc xcache-*.tar.gz | tar -x gzip-dc xcache-*. tar.gz | tar-x

  4. Go into the xcache directory with source content: Masuklah ke dalam direktori xcache dengan sumber konten:

    cd xcache cd xcache

  5. Trigger PHP building environment: Memicu PHP membangun lingkungan:

    phpize phpize

  6. Optional but recommended practice is to build XCache outside of source directory: Opsional tetapi amalan yang dianjurkan untuk membangun XCache di luar direktori sumber:

    mkdir ../xcache-build mkdir .. / xcache-membangun
    cd ../xcache-build cd .. / xcache-membangun

  7. Run the configure with the option that you want, the basic is as below which will enable the XCache by default: Jalankan configure dengan opsi yang Anda inginkan, dasar adalah sebagai berikut yang akan mengaktifkan XCache secara baku:

    ../xcache/configure –enable-xcache .. / xcache / configure-enable-xcache

    You can list out all available options by using ../xcache/configure –help command, which will display the following: Anda bisa daftar semua pilihan yang tersedia dengan menggunakan .. / xcache / configure-help perintah, yang akan menampilkan sebagai berikut:

    –enable-xcache Include XCACHE support. -Enable-xcache Sertakan XCACHE dukungan.
    –enable-xcache-optimizer XCACHE: (N/A) -Enable-xcache-optimasi XCACHE: (N / A)
    –enable-xcache-coverager XCACHE: Enable code coverage dumper -Enable-xcache-coverager XCACHE: Aktifkan kode cakupan dumper
    –enable-xcache-assembler XCACHE: (N/A) -Enable-assembler xcache-XCACHE: (N / A)
    –enable-xcache-disassembler XCACHE: Enable opcode to php variable dumper -Enable-xcache-disassembler XCACHE: Aktifkan opcode ke variabel php dumper
    –enable-xcache-encoder XCACHE: (N/A) -Enable-xcache-encoder XCACHE: (N / A)
    –enable-xcache-decoder XCACHE: (N/A) -Enable-xcache-decoder XCACHE: (N / A)
    –enable-xcache-test XCACHE: Enable self test - FOR DEVELOPERS ONLY!! -Enable-xcache-test XCACHE: Aktifkan diri tes - Untuk Pengembang ONLY!!

  8. Compile the source with following command: Mengkompilasi source dengan perintah berikut:

    make membuat

    Ensure that no error occurred. Memastikan bahwa tidak ada kesalahan.

  9. If you haven't already using root account, su to root user. Jika Anda belum menggunakan akun root, su ke root.
  10. Install XCache binary with the following command: Instal XCache binary dengan perintah berikut:

    make install make install

    Ensure that no error occurred, and note down the extension installation path of the xcache.so. Memastikan bahwa tidak ada kesalahan, dan catatan bawah ekstensi instalasi jalan yang xcache.so.

  11. Next, XCache need to be configured and enabled in PHP.INI file. Selanjutnya, XCache perlu dikonfigurasi dan diaktifkan dalam file php.ini. Locate the correct location of php.ini configuration file by using Cari lokasi yang benar php.ini file konfigurasi dengan menggunakan phpinfo() phpinfo () function (see sample listed above to check version of PHP). fungsi (lihat contoh yang tercantum di atas untuk memeriksa versi PHP). In web hosting environment, normally it's located in /etc or /usr/local/lib. Di web hosting lingkungan, itu biasanya terletak di / etc atau / usr / local / lib. If the install of PHP parses the /etc/php.d/ folder, then simply create a file in that folder named “xcache.ini” or copy over the sample xcache.ini came with source package. Jika menginstal PHP mem-parsing / etc / php.d / folder, maka cukup membuat file di folder itu bernama "xcache.ini" atau menyalin contoh di atas xcache.ini datang dengan sumber paket.

    Change back to xcache source unpack directory, and run the following command with root user: Kembali ke xcache direktori sumber mengekstrak, dan menjalankan perintah berikut dengan root:

    cat xcache.ini >> /etc/php.ini cat xcache.ini>> / etc / php.ini
    $EDITOR /etc/php.ini $ Editor / etc / php.ini

    Note: change to the path of php.ini accordingly Catatan: perubahan ke jalan yang sesuai php.ini

    This will append the default XCache configuration to the end of php.ini. Ini akan menambahkan konfigurasi default XCache ke akhir php.ini. Alternatively, you can copy and paste the following text into the php.ini file yourself too: Sebagai alternatif, Anda dapat menyalin dan menyisipkan teks berikut ke dalam file php.ini sendiri terlalu:


    [xcache-common]
    ;; install as zend extension (recommended)
    zend_extension = /usr/local/lib/php/extensions/no-debug-non-zts-xxx/xcache.so
    ;; install as zend extension with thread-safe
    ; zend_extension_ts = /usr/local/lib/php/extensions/non-debug-zts-xxx/xcache.so
    ;; install as PHP extension (extension_dir must be set to the full path to xcache.so)
    ; extension = xcache.so

    [xcache.admin] [xcache.admin]
    xcache.admin.user = “admin” xcache.admin.user = "admin"
    xcache.admin.pass = md5($your_password) xcache.admin.pass = md5 ($ your_password)

    [xcache] [xcache]
    xcache.shm_scheme = “mmap” xcache.shm_scheme = "mmap"
    xcache.size = 16M xcache.size = 16M
    xcache.count = 1 xcache.count = 1
    xcache.slots = 8K xcache.slots = 8K
    xcache.ttl = 0 xcache.ttl = 0
    xcache.gc_interval = 0 xcache.gc_interval = 0

    xcache.var_size = 0M xcache.var_size = 0M
    xcache.var_count = 1 xcache.var_count = 1
    xcache.var_slots = 8K xcache.var_slots = 8K
    xcache.var_ttl = 0 xcache.var_ttl = 0
    xcache.var_maxttl = 0 xcache.var_maxttl = 0
    xcache.var_gc_interval = 300 xcache.var_gc_interval = 300

    xcache.test = Off xcache.test = Off
    xcache.readonly_protection = Off xcache.readonly_protection = Off
    xcache.mmap_path = “/dev/zero” xcache.mmap_path = "/ dev / zero"
    xcache.coredump_directory = “” xcache.coredump_directory = ""
    xcache.cacher = On xcache.cacher = Aktif
    xcache.stat = On xcache.stat = Aktif
    xcache.optimizer = Off xcache.optimizer = Off

    [xcache.coverager] [xcache.coverager]
    xcache.coverager = Off xcache.coverager = Off
    xcache.coveragedump_directory = “” xcache.coveragedump_directory = ""

  12. You can configure XCache to your preference. Anda dapat mengkonfigurasi XCache untuk pilihan Anda. One setting that must be changed is under the [xcache-common], where you must specify the correct installation path of the XCache extension module. Salah satu pengaturan yang harus diubah adalah di bawah [xcache-umum], di mana Anda harus menentukan jalur yang benar instalasi yang XCache ekstensi modul. You can also opt to run XCache as PHP extension instead of extension for Zend module. Anda juga dapat memilih untuk menjalankan PHP XCache sebagai perpanjangan, bukan untuk perpanjangan Zend modul. In this case, comment and uncomment the line accordingly. Dalam hal ini, komentar dan uncomment baris yang sesuai. Other important options include “xcache.size” which specify amount the memory allocated to XCache, “xcache.count” to take advantage of multi-core processors or multiple processors. Pilihan penting lainnya termasuk "xcache.size" yang menentukan jumlah memori yang dialokasikan untuk XCache, "xcache.count" untuk mengambil keuntungan dari multi-core atau multi prosesor. And if you plan to use XCache web administration interface, input the “xcache.admin.user” and md5 checksum value of “xcache.admin.pass”. Dan jika Anda berencana untuk menggunakan XCache web interface administrasi, input "xcache.admin.user" dan md5 checksum nilai "xcache.admin.pass". Try Mencoba MD5 tools MD5 alat to generate the correct value, or use the following command to generate the MD5 for your password: untuk menghasilkan nilai yang benar, atau menggunakan perintah berikut untuk menghasilkan MD5 untuk password:

    echo -n “password” | md5sum echo-n "password" | md5sum

    Note: Explanation and definition of all XCache INI settings can be found Catatan: Penjelasan dan definisi dari semua XCache INI pengaturan dapat ditemukan here di sini . .

  13. Restart the Apache httpd web server. Restart Apache httpd server web. The following commands should work: Perintah berikut harus bekerja:

    /etc/init.d/apache* restart / etc / init.d / apache restart *

    or atau

    /etc/init.d/httpd* restart / etc / init.d / httpd restart *

  14. Ensure the XCache is running by calling PHP file with phpinfo() (see sample above). Pastikan XCache dijalankan oleh PHP memanggil file dengan phpinfo () (lihat contoh di atas). You should see a new XCache Support block with opcode cache enabled. Anda akan melihat baru XCache Dukungan blok dengan opcode cache diaktifkan.
  15. If you wish to set up XCache administration page, configure an alias in httpd.conf of Apache to point to the admin subdirectory within XCache. Jika Anda ingin mengatur XCache administrasi halaman, mengkonfigurasi sebuah alias di httpd.conf Apache untuk menunjuk ke admin XCache dalam subdirektori. To do so, add the following line to httpd.conf (assuming your xcache source is extracted at /usr/local/src/, and you want to access admin page from /xcache-admin/ URL): Untuk melakukannya, tambahkan baris berikut ke httpd.conf (asumsi Anda xcache sumber yang diambil adalah di / usr / local / src /, dan Anda ingin mengakses halaman dari admin / admin-xcache / URL):

    Alias /xcache-admin/ /usr/local/src/xcache/admin/ Alias / xcache-admin / / usr / src / xcache / admin /

    Then restart Apache web server. Kemudian restart Apache web server. For lighttpd, add the following line instead: Untuk lighttpd, tambahkan baris berikut sebagai gantinya:

    alias.url += (”/xcache-admin/” => “/usr/share/xcache/admin/”) alias.url + = ( "/ xcache-admin /" => "/ usr / share / xcache / admin /")

    Alternatively, you can also copy the whole “admin” directory from the “xcache” source folder to web document-root or sub-directory of your domain which is web accessible. Sebagai alternatif, Anda juga dapat menyalin seluruh "admin" dari direktori "xcache" sumber folder untuk web dokumen-root atau sub-direktori dari domain Anda yang dapat diakses Web. However, this method is not recommended as you may forget to update the admin page when XCache package is updated. Namun, metode ini tidak dianjurkan karena dapat lupa untuk memperbarui halaman admin ketika XCache paket diperbarui.

    Note: Ensure that Catatan: Pastikan bahwa open_basedir protection open_basedir perlindungan , if enabled, is excluded for the directory contains admin-page. , Jika diaktifkan, dikecualikan untuk direktori berisi halaman admin.

IMPORTANT : The page is machine translated and provided "as is" without warranty. PENTING: Halaman yang diterjemahkan mesin dan diberikan "sebagaimana adanya" tanpa jaminan. Machine translation may be difficult to understand. Mesin terjemahan mungkin sulit dimengerti. Please refer to Silakan merujuk ke original English article artikel asli Inggris whenever possible. bila memungkinkan.


Leave a Reply Meninggalkan Balas

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> Anda dapat menggunakan tag ini: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime = ""> <em> <i> <q cite=""> <strike> <strong>

Subscribe to comments feature has been disabled. Berlangganan ke fitur komentar telah dinonaktifkan. To receive notification of latest comments posted, subscribe to Untuk menerima pemberitahuan komentar diposting terbaru, berlangganan My Digital Life Comments RSS feed Saya Digital Life Komentar RSS feed or atau register to receive mendaftar untuk menerima new comments in daily email digest. komentar baru di email harian digest.
Custom Search

New Articles Artikel Baru

Incoming Search Terms for the Article Cari Syarat masuk untuk Artikel

php accelerator linux php accelerator linux - -- this is default plesk page перекласти українською ini adalah halaman default plesk перекласти українською - -- installing a php accelerator menginstal php penderas - -- program decode eaccelerator eaccelerator program membaca sandi - -- como instalar php accelerator como instalar php penderas - -- linux php-accelerator file ini linux php accelerator-file ini - -- php 5 accelerator php 5 penderas - -- optimal linux centos settings for wordpress linux centos optimal untuk wordpress - --