walid
11-02-2013, بتوقيت غرينيتش 01:16 AM
السلام عليكم ورحمة الله وبركاته ،
في تاريخ 2014-8-4 تم إصدار النسخه 1.3.0 من المسرع xCache بتحديث updateات وتصحيحات كثيرة من أهمها :-
الدعم الكامل للإصدارة 5.3.0 من الـ php.
العديد من التصحيحات لـ cacher/coverager.
تصحيح أخطاء صفحة التحكم.
سنتناول في هذه التدوينة طريقة تثبيت setup هذا الإصدار بشكل مفصل ودقيق :-
نبدأ / بسم الله الرحمن الرحيم.
نسجل دخولنا على SSH بإستخدام كل شخص برنامجه المفضل ،،
نتوجه لـ الهوم
رمز PHP:
<code style="white-space:nowrap"> <code> cd /home
</code> </code>
ثم نقوم بتحميل آخر نسخه مستقرة من الـ xCache
رمز PHP:
<code style="white-space:nowrap"> <code> wget http://xcache.lighttpd.net/pub/Releases/1.3.0/xcache-1.3.0.tar.gz
</code> </code>
نفك الضغط عن النسخه:-
رمز PHP:
<code style="white-space:nowrap"> <code> tar -zxf xcache-1.3.0.tar.gz
</code> </code>
ثم ندخل لـ المجلد بعد الفك :-
رمز PHP:
<code style="white-space:nowrap"> <code> cd xcache-1.3.0
</code> </code>
ثم
رمز PHP:
<code style="white-space:nowrap"> <code> phpize
</code> </code>
ثم
رمز PHP:
<code style="white-space:nowrap"> <code> ./configure --enable-xcache
</code> </code>
ثم
رمز PHP:
<code style="white-space:nowrap"> <code> make
</code> </code>
ثم
رمز PHP:
<code style="white-space:nowrap"> <code> su
</code> </code>
ثم
رمز PHP:
<code style="white-space:nowrap"> <code> make install
</code> </code>
سيكون الناتج مشابه لـ التالي (مكان حفظ ملف xcache.so ) التشغيلي :
رمز PHP:
<code style="white-space:nowrap"> <code> /usr/lib/php/extensions/no-debug-non-zts-20020616/xcache.so
</code> </code>
إلى هنا - انتهينا من اعداد نسخه الـ xCache للسيرفر SERVER ، والآن نبدأ بتعديل وإضافة الإعدادات
نقوم بمعرفة مكان ملف php.ini (إعدادات الـ php ) المفعلة في السيرفر SERVER ، وذلك من خلال الأمر التالي
رمز PHP:
<code style="white-space:nowrap"> <code> php --ini |grep Path
</code> </code>
الناتج سيكون كـ التالي :-
رمز PHP:
<code style="white-space:nowrap"> <code> Configuration File (php.ini) Path: /usr/local/lib
</code> </code>
ماهو محدد في الكود code الناتج السابق هو مكان ملف الإعداد الخاص بـ php ، جميل !
الآن نقوم بإضافة إعدادات الـ xcache لـ ملف الإعداد الخاص بـ php بالمحرر المفضل لك /
انا ساقوم بالتعديل بإستخدام الأمر pico
رمز PHP:
<code style="white-space:nowrap"> <code> pico /usr/local/lib/php.ini
</code> </code>
مع التأكد من تغير مجلد الإعداد الناتج من الأمر السابق
ثم نظيف التالي في نهاية الملف
رمز PHP:
<code style="white-space:nowrap"> <code> [xcache-common]
zend_extension = /usr/local/lib/php/extensions/non-debug-non-zts-xxx/xcache.so
[xcache.admin]
xcache.admin.enable_auth = Off
xcache.admin.user = "mOo"
; xcache.admin.pass = md5($your_password)
xcache.admin.pass = ""
[xcache]
; select low level shm/allocator scheme implemenation
xcache.shm_scheme = "mmap"
; to disable: xcache.size=0
; to enable : xcache.size=64M etc (any size > 0) and your system mmap allows
xcache.size = 60M
; set to cpu count (cat /proc/cpuinfo |grep -c processor)
xcache.count = 1
; just a hash hints, you can always store count(items) > slots
xcache.slots = 8K
; ttl of the cache item, 0=forever
xcache.ttl = 0
; interval of gc scanning expired items, 0=no scan, other values is in seconds
xcache.gc_interval = 0
; same as aboves but for variable cache
xcache.var_size = 4M
xcache.var_count = 1
xcache.var_slots = 8K
; default ttl
xcache.var_ttl = 0
xcache.var_maxttl = 0
xcache.var_gc_interval = 300
xcache.test = Off
; N/A for /dev/zero
xcache.readonly_protection = Off
; for *nix, xcache.mmap_path is a file path, not directory.
; Use something like "/tmp/xcache" if you want to turn on ReadonlyProtection
; 2 group of php won't share the same /tmp/xcache
; for win32, xcache.mmap_path=anonymous map name, not file path
xcache.mmap_path = "/dev/zero"
; leave it blank(disabled) or "/tmp/phpcore/"
; make sure it's writable by php (without checking open_basedir)
xcache.coredump_directory = ""
; per request settings
xcache.cacher = On
xcache.stat = On
xcache.optimizer = Off
[xcache.coverager]
; per request settings
; enable coverage data collecting for xcache.coveragedump_directory and xcache_coverager_start/stop/get/clean() functions (will hurt executing performance)
xcache.coverager = Off
; ini only settings
; make sure it's readable (care open_basedir) by coverage viewer script
; requires xcache.coverager=On
xcache.coveragedump_directory = ""
</code> </code>
مع تغير ما يلزم مثل / xcache.count وهو عدد المعالجات في السيرفر SERVER ولمن لا يعلم ما هو عدد المعالجات يقوم بكتابه الأمر التالي :-
رمز PHP:
<code style="white-space:nowrap"> <code> cat /proc/cpuinfo |grep -c processor
</code> </code>
وايضاً تغير مجلد الإضافات في السيرفر SERVER
رمز PHP:
<code style="white-space:nowrap"> <code> zend_extension = /usr/local/lib/php/extensions/non-debug-non-zts-xxx/xcache.so
</code> </code>
مكان الإضافات هو ما قمنا بتسجيلة فوق المعلم باللون الأزرق
ملاحظات :-
في حال تغير اي عنصر تاكد من تغير شبيهه في الـ var / مثلاً : قمت بتغير xcache.count فيتوجب أيضا تغير xcache.var_count ،، وهكذا ،،
إذا كان الرام في السيرفر SERVER أكثر من 1 جيجا فيفضل تغير قيمه xcache.size لـ 64M وأكثر.
قم برستره الأباشي من خلال الأمر التالي :-
رمز PHP:
<code style="white-space:nowrap"> <code> service httpd restart
</code> </code>
ثم إكتب
رمز PHP:
<code style="white-space:nowrap"> <code> php -v |grep XCache
</code> </code>
كان الناتج مشابه للتالي فالمسرع يعمل بكل نجاح
رمز PHP:
<code style="white-space:nowrap"> <code> with XCache v1.3.0, Copyright (c) 2014-2014, by mOo
</code> </code>
أنتهى
تحياتي
https://fbcdn-sphotos-d-a.akamaihd.net/hphotos-ak-ash4/482113_236967293114455_1193518507_n.png (http://www.dzbatna.com)
©المشاركات المنشورة تعبر عن وجهة نظر صاحبها فقط، ولا تُعبّر بأي شكل من الأشكال عن وجهة نظر إدارة المنتدى (http://www.dzbatna.com)©
في تاريخ 2014-8-4 تم إصدار النسخه 1.3.0 من المسرع xCache بتحديث updateات وتصحيحات كثيرة من أهمها :-
الدعم الكامل للإصدارة 5.3.0 من الـ php.
العديد من التصحيحات لـ cacher/coverager.
تصحيح أخطاء صفحة التحكم.
سنتناول في هذه التدوينة طريقة تثبيت setup هذا الإصدار بشكل مفصل ودقيق :-
نبدأ / بسم الله الرحمن الرحيم.
نسجل دخولنا على SSH بإستخدام كل شخص برنامجه المفضل ،،
نتوجه لـ الهوم
رمز PHP:
<code style="white-space:nowrap"> <code> cd /home
</code> </code>
ثم نقوم بتحميل آخر نسخه مستقرة من الـ xCache
رمز PHP:
<code style="white-space:nowrap"> <code> wget http://xcache.lighttpd.net/pub/Releases/1.3.0/xcache-1.3.0.tar.gz
</code> </code>
نفك الضغط عن النسخه:-
رمز PHP:
<code style="white-space:nowrap"> <code> tar -zxf xcache-1.3.0.tar.gz
</code> </code>
ثم ندخل لـ المجلد بعد الفك :-
رمز PHP:
<code style="white-space:nowrap"> <code> cd xcache-1.3.0
</code> </code>
ثم
رمز PHP:
<code style="white-space:nowrap"> <code> phpize
</code> </code>
ثم
رمز PHP:
<code style="white-space:nowrap"> <code> ./configure --enable-xcache
</code> </code>
ثم
رمز PHP:
<code style="white-space:nowrap"> <code> make
</code> </code>
ثم
رمز PHP:
<code style="white-space:nowrap"> <code> su
</code> </code>
ثم
رمز PHP:
<code style="white-space:nowrap"> <code> make install
</code> </code>
سيكون الناتج مشابه لـ التالي (مكان حفظ ملف xcache.so ) التشغيلي :
رمز PHP:
<code style="white-space:nowrap"> <code> /usr/lib/php/extensions/no-debug-non-zts-20020616/xcache.so
</code> </code>
إلى هنا - انتهينا من اعداد نسخه الـ xCache للسيرفر SERVER ، والآن نبدأ بتعديل وإضافة الإعدادات
نقوم بمعرفة مكان ملف php.ini (إعدادات الـ php ) المفعلة في السيرفر SERVER ، وذلك من خلال الأمر التالي
رمز PHP:
<code style="white-space:nowrap"> <code> php --ini |grep Path
</code> </code>
الناتج سيكون كـ التالي :-
رمز PHP:
<code style="white-space:nowrap"> <code> Configuration File (php.ini) Path: /usr/local/lib
</code> </code>
ماهو محدد في الكود code الناتج السابق هو مكان ملف الإعداد الخاص بـ php ، جميل !
الآن نقوم بإضافة إعدادات الـ xcache لـ ملف الإعداد الخاص بـ php بالمحرر المفضل لك /
انا ساقوم بالتعديل بإستخدام الأمر pico
رمز PHP:
<code style="white-space:nowrap"> <code> pico /usr/local/lib/php.ini
</code> </code>
مع التأكد من تغير مجلد الإعداد الناتج من الأمر السابق
ثم نظيف التالي في نهاية الملف
رمز PHP:
<code style="white-space:nowrap"> <code> [xcache-common]
zend_extension = /usr/local/lib/php/extensions/non-debug-non-zts-xxx/xcache.so
[xcache.admin]
xcache.admin.enable_auth = Off
xcache.admin.user = "mOo"
; xcache.admin.pass = md5($your_password)
xcache.admin.pass = ""
[xcache]
; select low level shm/allocator scheme implemenation
xcache.shm_scheme = "mmap"
; to disable: xcache.size=0
; to enable : xcache.size=64M etc (any size > 0) and your system mmap allows
xcache.size = 60M
; set to cpu count (cat /proc/cpuinfo |grep -c processor)
xcache.count = 1
; just a hash hints, you can always store count(items) > slots
xcache.slots = 8K
; ttl of the cache item, 0=forever
xcache.ttl = 0
; interval of gc scanning expired items, 0=no scan, other values is in seconds
xcache.gc_interval = 0
; same as aboves but for variable cache
xcache.var_size = 4M
xcache.var_count = 1
xcache.var_slots = 8K
; default ttl
xcache.var_ttl = 0
xcache.var_maxttl = 0
xcache.var_gc_interval = 300
xcache.test = Off
; N/A for /dev/zero
xcache.readonly_protection = Off
; for *nix, xcache.mmap_path is a file path, not directory.
; Use something like "/tmp/xcache" if you want to turn on ReadonlyProtection
; 2 group of php won't share the same /tmp/xcache
; for win32, xcache.mmap_path=anonymous map name, not file path
xcache.mmap_path = "/dev/zero"
; leave it blank(disabled) or "/tmp/phpcore/"
; make sure it's writable by php (without checking open_basedir)
xcache.coredump_directory = ""
; per request settings
xcache.cacher = On
xcache.stat = On
xcache.optimizer = Off
[xcache.coverager]
; per request settings
; enable coverage data collecting for xcache.coveragedump_directory and xcache_coverager_start/stop/get/clean() functions (will hurt executing performance)
xcache.coverager = Off
; ini only settings
; make sure it's readable (care open_basedir) by coverage viewer script
; requires xcache.coverager=On
xcache.coveragedump_directory = ""
</code> </code>
مع تغير ما يلزم مثل / xcache.count وهو عدد المعالجات في السيرفر SERVER ولمن لا يعلم ما هو عدد المعالجات يقوم بكتابه الأمر التالي :-
رمز PHP:
<code style="white-space:nowrap"> <code> cat /proc/cpuinfo |grep -c processor
</code> </code>
وايضاً تغير مجلد الإضافات في السيرفر SERVER
رمز PHP:
<code style="white-space:nowrap"> <code> zend_extension = /usr/local/lib/php/extensions/non-debug-non-zts-xxx/xcache.so
</code> </code>
مكان الإضافات هو ما قمنا بتسجيلة فوق المعلم باللون الأزرق
ملاحظات :-
في حال تغير اي عنصر تاكد من تغير شبيهه في الـ var / مثلاً : قمت بتغير xcache.count فيتوجب أيضا تغير xcache.var_count ،، وهكذا ،،
إذا كان الرام في السيرفر SERVER أكثر من 1 جيجا فيفضل تغير قيمه xcache.size لـ 64M وأكثر.
قم برستره الأباشي من خلال الأمر التالي :-
رمز PHP:
<code style="white-space:nowrap"> <code> service httpd restart
</code> </code>
ثم إكتب
رمز PHP:
<code style="white-space:nowrap"> <code> php -v |grep XCache
</code> </code>
كان الناتج مشابه للتالي فالمسرع يعمل بكل نجاح
رمز PHP:
<code style="white-space:nowrap"> <code> with XCache v1.3.0, Copyright (c) 2014-2014, by mOo
</code> </code>
أنتهى
تحياتي
https://fbcdn-sphotos-d-a.akamaihd.net/hphotos-ak-ash4/482113_236967293114455_1193518507_n.png (http://www.dzbatna.com)
©المشاركات المنشورة تعبر عن وجهة نظر صاحبها فقط، ولا تُعبّر بأي شكل من الأشكال عن وجهة نظر إدارة المنتدى (http://www.dzbatna.com)©