Q:

ffmpeg Video not converting from .mp4 to .ts format

We are using RecordRTC to record video.  We have used "video/mp4" mimeType and recording the video and uploading to the upload directory using the PHP file upload function. 
Here is the function that I have used to record using RecordRTC
recorder = RecordRTC(stream, {type: 'video',mimeType: 'video/mp4'});

We have checked the uploaded file and played on multiple browsers and multiple devices and it's playing video properly. 
But when we try to convert video from .mp4 to .ts format generating 0B .ts file.  We have searched but not found any proper solution.  We have converted video using FFmpeg and executing with exec() PHP function. 
We are using the below command to convert from .mp4 to .ts format

exec('ffmpeg -i abc.mp4 -c copy -framerate 30 -bsf:v h264_mp4toannexb
  -f mpegts -crf 32 pqr.ts');

So can anyone please check and let us know is there any solution. 
Thanks in advance. 

A:

Finally found the solution after many tries. 
exec('ffmpeg -i abc.mp4 -c:v libx264 -c:a aac -b:a 160k -bsf:v h264_mp4toannexb -f mpegts -crf 32 pqr.ts');

