Jumat, 30 Januari 2015

Streaming dengan PHPMotion

Membangun Streaming Web Server dengan PHPMotion di centos 6.5

Requirment :
-centos 6.5
– PHP 4.3 and above  Burberry Outlet UK (including support of CLI)
– MySQL database server
– LAME MP3 Encoder
– Libogg + Libvorbis
Mencoder and also Mplayer
– FFMpeg-PHP
– GD Library 2 or higher
– CGI-BIN
– Be able to run background Burberry Sweaters  processes
tahap instalasi :
1. Instalasi Repository
# rpm -Uhv http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
# rpm -Uhv http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.2-2.el6.rf.x86_64.rpm
# rpm –import http://dag.wieers.com/rpm/packages/RPM-GPG-KEY.dag.txt
# rpm -Uhv http://download1.rpmfusion.org/free/el/updates/6/i386/rpmfusion-free-release-6-1.noarch.rpm
# rpm -Uhv http://download1.rpmfusion.org/nonfree/el/updates/6/i386/rpmfusion-nonfree-release-6-1.noarch.rpm
2. Install Package yang dibutuhkan
# yum install mysql mysql-server httpd php php-cli php-common php-cgi perl-CGI mod_fcgid php-mysql php-gd php-imap php-pear php-xml php-xmlrpc lame mencoder ffmpeg flvtool2 libogg libvorbis mplayer freetype-devel SDL-devel freeglut-devel zlib gpac wget unzip -y
3. Instalasi PHPMotion
a. Unduh PHPMotion terlebih dahulu
# wget http://www.phpmotion.com/downloads/V3.5/php5.3.x/phpmotion.zip
b. Ekstrak file phpmotion.zip
# unzip phpmotion.zip
c. Salin semua isi dari folder phpmotion ke folder DocumentRoot (pastikan file .htaccess ikut tersalin)
# cp -Rf phpmotion/* /var/www/html/
d. Ubah folder permission menjadi 777
# chmod -Rf 777 /var/www/html
e. Salin isi folder cgi-bin yang ada pada folder DocumentRoot ke Direktori cgi-bin ( ubah pada file konfigurasi apache untuk merubah direktori cgi-bin)
#cd /var/www/html
# cp -Rf cgi-bin/* /var/www/cgi-bin
f. Ubah folder permission menjadi 755
# chmod -Rf 755 /var/www/cgi-bin
g. Cari direktori PHP Extensions
#php -i |grep extension_dir
extension_dir => /usr/lib64/php/modules => /usr/lib64/php/modules
atau
extension_dir => /usr/lib/php/modules
h. Salin phpshield loader yang ada pada folder DocumentRoot ke direktori PHP Extensions
# cd /var/www/html/phpshield
# cp ixed.5.3.lin /usr/lib64/php/modules/
atau
# cp ixed.5.3.lin /usr/lib/php/modules
i. Tambahkan phpshield extension ke file /etc/php.ini ( taruh di baris paling bawah )
# echo “extension=ixed.5.3.lin” >> /etc/php.ini
4. setting php.ini
vi /etc/php.ini
settingan nya sbb :
– open_basedir = (no value)
– upload_max_filesize = 1024M
– post_max_size = 1024M
– max_execution_time = 1500
– session.gc_maxlifetime = 14400
– safe_mode = off
– thread safety = disabled
– enable_dl = On
– short_open_tag = on
#servie httpd start
5. Buat MySQL database dan user untuk phpmotion
#service mysqld start
misal :
#mysql -u root -p
#create database phpmotion;
#GRANT ALL ON phpmotion.*TO’user’@’localhost’IDENTIFIED BY’user123′;
#FLUSH PRIVILEGES;
#exit
NB : host : localhost , nama DB = phpmotion , user = user , pass DB = user123
6. Start/Restart Service Apache MySQL
# service httpd restart
# service mysqld restart
# chkconfig httpd on
# chkconfig mysqld on
7. Buka http://ip-address-atau-domain-name/setup/ melalui web browser dan ikuti instruksi pada layar
sumber : http://cloudindonesia.com/tutorial-membangun-streaming-web-server-dengan-phpmotion/

Tidak ada komentar:

Posting Komentar