7940 Posts in 1543 Topics by 946 members
|Go to End||Next >|
21 May 2009 at 4:27am
Some people have reported this problem, that PHP is having a hard time running shell scripts. To confirm that it's not, try:
echo exec('ffmpeg'); in your config.php, and see that it returns nothing.
I'm currently implementing a more robust way of executing shell scripts to the FLV class. Sit tight, should have something soon. I'll post it on my bug reports thread.
21 May 2009 at 9:53am
My local server is an Intel Xserve running Leopard Server with entropy php.
I compiled ffmpeg with --enable-shared and then compiled ffmpeg-php and everything went well I now have a ffmpeg.so file linked to as an extension in my php.ini.
Apache gives me an error about it though and won't load the ffmpeg.so so I can't get it to work after working on it for about 5 hours.
I guess I will have to make a way to upload my own thumbnail for use with the popup since I cannot get the ffmpeg to work and I probably won't get it to work on the production box either.
I think that many people will run into a problem with being able to get this to work with ffmpeg so while those who it does work for have really nice functionality most of us will have to hack it to work.
Any ideas on another way to do this?
21 May 2009 at 10:48am
Yes, I very much anticipated these sorts of issues. We've introduced a whole slew of variables by relying on a third party product to work properly in a uniquely configured server environment.
Sorry you've sunken so much time into it. Two things I can say right now.
1) As seen in the bug reports thread, I am changing the exec() function to something more robust and compatible that may resolve the issue.
2) I'm also going to add a way to echo out the shell commands that are run, so you can go to your command line and try them yourself to see if it's just a bad command or if it's a good, working command that is being executed improperly, or not at all, by PHP.
I can tell you, though. I have it set up on two different servers for two different clients right now, and it's working awesome. Clients are nuts about it, too. If we can iron out these kinks, I really think we have a game-changer on our hands.
21 May 2009 at 10:53am
Even though there might be some issues with how you are running the scripts. It seems that the problem I am having is outside SilverStripe alltogether and that it is just so difficult to install ffmpeg on my server and get php to load the ffmpeg.so. So even if your code was perfect I still wouldn't be able to get it to work.
How do you go about installing ffmpeg? Or is it usually already there when you want it on the servers you use?
21 May 2009 at 2:52pm Last edited: 21 May 2009 2:52pm
At Bluehouse Group, we had our sys admin guy do it. I can ask him what he did. Took him all of 30 seconds as I remember. My other server is on Site5, where it is pre-installed for all shared hosting accounts.
I'm very much learning as I go here, though, as you can probably tell.
22 May 2009 at 8:01am Last edited: 22 May 2009 8:01am
Just got this from my sys admin. Maybe it helps.
What OS are you running on your server? If it's CentOS/RHEL-like, there
is a repository called RPMforge that has all the packages you need.
Basically, you go to their site, download and install the
rpmforge-release package to install the repository, then just run 'yum
install ffmpeg', which will pull in any other dependencies it needs.
23 May 2009 at 6:51am
Great work once again UncleCheese. I have been using a custom video page for many clients. I used Flowplayer for my player. It accepts a few more formats than just flv. But the initial integration can be a bit tougher than Long Tail. Just a thought though.
I Will be using this in the near future.
23 May 2009 at 8:18am
Thanks for the info. My staging server is running OSX Leopard Server so it doesn't have yum. Macports does have a version of ffmpeg but it isn't complies with --enable-shared so it cannot be used as a shared library.
My live server is CentOs and I used Yum to install ffmpeg but the standard release is also not compiled as a shared library. I will try the rpm you mentioned in your post and hopefully that will do the trick.
Also are you calling a shell script directly or using ffmpeg-php as an extension to php?
|Go to Top||Next >|