FLV streaming using Apache + WHM/cPanel

Streaming FLV files with Apache + mod_flvx has never been easier. Setup your web server to stream FLV files using Apache in just 3 minutes.

cd /usr/local/src
wget http://people.apache.org/~pquerna/modules/mod_flvx.c
apxs -cia mod_flvx.c

If your system can’t find apxs locate it using

which apxs

You’ll get something like /usr/bin/apxs as result – that’s the path to it – you need it for next step

And then use full path to apxs to compile (for example):

/usr/bin/apxs -cia mod_flvx.c

Non WHM/cPanel users
Should now add those two lines into httpd.conf:

LoadModule flvx_module modules/mod_flvx.so
AddHandler flv-stream .flv

and simply restart Apache using:

service httpd restart

WHM/cPanel users
Should use Include Editor since any changes made to httpd.conf will be lost in case of rebuilding apache.
So login to WHM and go to Apache Configuration -> Include Editor -> Pre Main Include -> All Versions and in the box that appears copy/paste following two lines and after saving that confirm Apache restart.

LoadModule flvx_module modules/mod_flvx.so
AddHandler flv-stream .flv

Here are a few pictures for newbies so they can find their way trough more easily:

1. Apache Configuration
2. Include Editor
apache include editor whm cpanel

3. Locate PreMain Include – select All Versions
4. Copy/paste those two lines and press Update (then confirm Apache reload)
apache include editor whm cpanel

Setting up the player
If you use JW Player (that I strongly recommend) you need to set provider to value http.
jwplayer provider http
Visit JW Player setup wizard to easily install JW Player on your site.

MP4 Streaming using Apache
To learn how to setup MP4 streaming using Apache click here

Tags: apache flv streaming

Solution for the custom fileds problem with WordPress 3.4.2

No you are not nuts there really is a problem with custom fields in WordPress 3.4.2. If you have just updated to current latest version of WordPress 3.4.2 and have found out that the custom fields are not updating and are broken – you are not alone. Its happening for everybody. Its a known bug for WordPress 3.4.2. Here we have a quick fix before WordPress 3.4.3 (or 3.5) arrives. WordPress developers are aware of the bug (http://core.trac.wordpress.org/ticket/21829). The next milestone version will be WordPress 3.5 but since this is a critical bug its already fixed in rev.21780 so it could be released early on 3.4.3 but we just don’t know when is that going to happen.

Until then you can use WordPress hotfix plugin that will take care of this bug:
http://wordpress.org/extend/plugins/hotfix/

All you need to do is install it in your WordPress. Login to wp-admin and go to Plugins -> Add New in search box enter hotfix and install the first plugin from the results list (plugin Version 0.9, plugin author: Mark Jaquith). That’s it!

Solution for yum problems on new CentOS 6 + WHM installations

Recently I discovered problems trying to install anything using yum on new servers based on CentOS 6 (64-bit) + WHM/cPanel. I was trying to install subversion using yum:

yum install subversion

And I was getting following output:

Error: Package: subversion-1.6.11-7.el6.x86_64 (base)
           Requires: perl(URI) >= 1.17
 You could try using --skip-broken to work around the problem
** Found 5 pre-existing rpmdb problem(s), 'yum check' output follows:
bandmin-1.6.1-5.noarch has missing requires of perl(bandmin.conf)
bandmin-1.6.1-5.noarch has missing requires of perl(bmversion.pl)
bandmin-1.6.1-5.noarch has missing requires of perl(services.conf)
exim-4.77-1.x86_64 has missing requires of perl(SafeFile)
frontpage-2002-SR1.2.i386 has missing requires of libexpat.so.0

And I would get that trying to install just about anything with yum or by calling yum check.

To solve this problem you will have to open /etc/yum.conf for editing and to locate perl* in exclude= line and remove it (just perl* part). Now install anything by running the yum install package_name it will solve all those problems that you had! Once the installation is done and problems are solved, don’t forget to put perl* back to /etc/yum.conf in exclude= list!

Tags: frontpage-2002-sr1 2 i386 has missing requires of libexpat so 0, bandmin-1 6 1-5 noarch has missing requires of perl(bandmin conf), ** found 29 pre-existing rpmdb problem(s) \yum check\ output follows: