LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-17-2010, 01:10 PM   #1
sudhirmhrj
LQ Newbie
 
Registered: Feb 2010
Location: Earth
Distribution: Centos, Redhat ENT
Posts: 23

Rep: Reputation: 0
problem with mencoder


Hi all,

I have installed vshare in my linux system and also configured the linux server as described in http://labs.buyscripts.in/projects/v...i/Server_Setup

then i uploaded one sample video to the directory /public_html/videos/templates_c/import/

and imported the video from "Video Processing" section

and when i try to convert the imported it shows me the following screen

"""
STARTING VIDEO CONVERSION (process_queue.id = 25)

File: /home/hijohn/public_html/videos/video/031.mp4

####################################################

SELECT * FROM `video` WHERE `VID`=24

####################################################

Video id: 24

Find video duration - START

Duration (ffmpeg-php): 49

DURATION: 00:49

Create Thumbnail - START

Create Thumbnail with ffmpeg-php - END

CONVERT COMMAND: /usr/bin/mencoder '/home/hijohn/public_html/videos/video/031.mp4' -o /home/hijohn/public_html/videos/flvideo/12664288231538911220.flv -of lavf -oac mp3lame -lameopts abr:br=56 -ovc lavc -lavcopts vcodec=flv:vbitrate=500:mbd=2:mv0:trell:v4mv:cbp:last_pred=3 -srate 22050 -ofps 24 -vf harddup

####################################################

####################################################

Return value:
Video Conversion Finished

Back
"""

and when i click back it shows "Convert Error"

i also checked that the file /home/hijohn/public_html/videos/flvideo/12664288231538911220.flv doesnt exist

then i tried the same command in Shell it converts the video successfully without error. And the file 12664288231538911220.flv also exist on the specified folder.

Could you tell me why it is not hapening from the web.

Thank you

Regards
sudhir Maharjan
 
Old 02-18-2010, 01:43 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
The first thing that springs to mind is that the userID as which
apache is running doesn't have the right permissions on that dir.
 
Old 02-18-2010, 08:03 PM   #3
sudhirmhrj
LQ Newbie
 
Registered: Feb 2010
Location: Earth
Distribution: Centos, Redhat ENT
Posts: 23

Original Poster
Rep: Reputation: 0
Thank you for your suggestion

but i didnt understand what actually you are trying to say. Could you explain me in details.
 
Old 02-18-2010, 09:54 PM   #4
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Ummm ...

Check
Code:
$ ps -ef | grep http
root      3204     1  0 16:39 ?        00:00:00 /usr/sbin/httpd -k start
apache    3222  3204  0 16:39 ?        00:00:00 /usr/sbin/httpd -k start
apache    3223  3204  0 16:39 ?        00:00:00 /usr/sbin/httpd -k start
apache    3224  3204  0 16:39 ?        00:00:00 /usr/sbin/httpd -k start
apache    3225  3204  0 16:39 ?        00:00:00 /usr/sbin/httpd -k start
apache    3226  3204  0 16:39 ?        00:00:00 /usr/sbin/httpd -k start
Which user is apache running as?
For me it's apache. Now, assuming you have root access to that machine
you're working with, try:
Code:
sudo -u <apache user> touch /home/hijohn/public_html/videos/flvideo/some_random_filename
What message or result do you get?



Cheers,
Tink
 
Old 02-21-2010, 08:58 AM   #5
sudhirmhrj
LQ Newbie
 
Registered: Feb 2010
Location: Earth
Distribution: Centos, Redhat ENT
Posts: 23

Original Poster
Rep: Reputation: 0
Thanks Tinkster for your suggestion

my result for
ps -ef | grep http

root 3290 2815 0 08:45 pts/0 00:00:00 grep http
root 28976 29879 0 07:13 ? 00:00:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody 28986 29879 0 07:13 ? 00:00:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody 28988 29879 0 07:13 ? 00:00:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody 28989 29879 0 07:13 ? 00:00:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody 28990 29879 0 07:13 ? 00:00:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody 28992 29879 0 07:13 ? 00:00:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody 29548 29879 0 07:22 ? 00:00:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody 29551 29879 0 07:22 ? 00:00:00 /usr/local/apache/bin/httpd -k start -DSSL
root 29879 1 0 Feb13 ? 00:00:05 /usr/local/apache/bin/httpd -k start -DSSL

and i am able to create the file using the code you written
but i am still not able to convert file from vshare.
 
Old 02-21-2010, 11:43 AM   #6
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
The next thing to check will be whether 'nobody' is allowed to
read '/home/hijohn/public_html/videos/video/031.mp4' and allowed
to run mencoder ...
 
Old 02-23-2010, 08:47 AM   #7
sudhirmhrj
LQ Newbie
 
Registered: Feb 2010
Location: Earth
Distribution: Centos, Redhat ENT
Posts: 23

Original Poster
Rep: Reputation: 0
Thanks

user 'nobody' is allowed to read '/home/hijohn/public_html/videos/video/031.mp4'

but how do i check if its allowed to run mencoder or not and if not how do i make it run...

bgrds
 
Old 02-23-2010, 10:29 AM   #8
schneidz
LQ Guru
 
Registered: May 2005
Location: boston, usa
Distribution: fedora-35
Posts: 5,313

Rep: Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918
Code:
ls -l `which mencoder`
will tell us the owner, group, permissions for mencoder.
are you able to ssh in as <nobody> and run:
Code:
/usr/bin/mencoder '/home/hijohn/public_html/videos/video/031.mp4' -o /home/hijohn/public_html/videos/flvideo/12664288231538911220.flv -of lavf -oac mp3lame -lameopts abr:br=56 -ovc lavc -lavcopts vcodec=flv:vbitrate=500:mbd=2:mv0:trell:v4mv:cbp:last_pred=3 -srate 22050 -ofps 24 -vf harddup

Last edited by schneidz; 02-23-2010 at 10:31 AM.
 
Old 02-23-2010, 01:50 PM   #9
sudhirmhrj
LQ Newbie
 
Registered: Feb 2010
Location: Earth
Distribution: Centos, Redhat ENT
Posts: 23

Original Poster
Rep: Reputation: 0
with the command line

/usr/bin/mencoder '/home/hijohn/public_html/videos/video/031_2.mp4' -o /home/hijohn/public_html/videos/flvideo/12664288231538911220.flv -of lavf -oac mp3lame -lameopts abr:br=56 -ovc lavc -lavcopts vcodec=flv:vbitrate=500:mbd=2:mv0:trell:v4mv:cbp:last_pred=3 -srate 22050 -ofps 24 -vf harddup

it creates the file 12664288231538911220.flv

but with the following command the result is

sudo -u nobody /usr/bin/mencoder '/home/hijohn/public_html/videos/video/031_2.mp4' -o /home/hijohn/public_html/videos/flvideo/12664288231538911220.flv -of lavf -oac mp3lame -lameopts abr:br=56 -ovc lavc -lavcopts vcodec=flv:vbitrate=500:mbd=2:mv0:trell:v4mv:cbp:last_pred=3 -srate 22050 -ofps 24 -vf harddup

MEncoder SVN-r30552-4.1.2 (C) 2000-2010 MPlayer Team
success: format: 0 data: 0x0 - 0x3d29ff
libavformat file format detected.
[lavf] Video stream found, -vid 0
[lavf] Audio stream found, -aid 1
VIDEO: [MP4V] 320x240 24bpp 30.010 fps 539.9 kbps (65.9 kbyte/s)
[V] filefmt:44 fourcc:0x5634504D size:320x240 fps:30.010 ftime:=0.0333
==========================================================================
Opening audio decoder: [faad] AAC (MPEG2/4 Advanced Audio Coding)
AUDIO: 44100 Hz, 2 ch, s16le, 106.8 kbit/7.57% (ratio: 13352->176400)
Selected audio codec: [faad] afm: faad (FAAD AAC (MPEG-2/MPEG-4 Audio))
==========================================================================
File not found: '/home/hijohn/public_html/videos/flvideo/12664288231538911220.flv'
Failed to open /home/hijohn/public_html/videos/flvideo/12664288231538911220.flv.
Cannot open output file '/home/hijohn/public_html/videos/flvideo/12664288231538911220.flv'.

Exiting...
 
Old 02-23-2010, 02:20 PM   #10
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Did you REMOVE the output file after the first run?

If the answer is 'YES' I'd suggest running the sudo version
under the strace
Code:
sudo -u nobody strace -o /tmp/mencoder.dbg -vFf /usr/bin/mencoder '/home/hijohn/public_html/videos/video/031_2.mp4' -o /home/hijohn/public_html/videos/flvideo/12664288231538911220.flv -of lavf -oac mp3lame -lameopts abr:br=56 -ovc lavc -lavcopts vcodec=flv:vbitrate=500:mbd=2:mv0:trell:v4mv:cbp:last_pred=3 -srate 22050 -ofps 24 -vf harddup

Cheers,
Tink
 
Old 02-23-2010, 02:53 PM   #11
schneidz
LQ Guru
 
Registered: May 2005
Location: boston, usa
Distribution: fedora-35
Posts: 5,313

Rep: Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918
is <nobody> allowed to read/ write to <hijohn>'s #HOME ?
 
Old 02-23-2010, 05:14 PM   #12
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Quote:
Originally Posted by schneidz View Post
is <nobody> allowed to read/ write to <hijohn>'s #HOME ?
Yup

Post #7 above
 
Old 02-24-2010, 10:58 AM   #13
schneidz
LQ Guru
 
Registered: May 2005
Location: boston, usa
Distribution: fedora-35
Posts: 5,313

Rep: Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918Reputation: 918
Code:
sudo -u nobody touch /home/hijohn/public_html/videos/flvideo/12664288231538911220.flv
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Mencoder with -ss and -endpos switches problem w1k0 Linux - Software 3 12-09-2009 11:56 AM
acidrip/mencoder problem robotjox Linux - Software 3 06-08-2009 02:55 PM
Problem with mencoder me4linux Linux - Software 6 08-29-2007 12:56 PM
mencoder problem masand Linux - Software 1 10-29-2005 02:39 PM
Problem with mencoder/acidrip hari_seldon99 Linux - Software 4 05-21-2004 01:36 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:40 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration