Wowza Community

vods3 setup nullpointerexception

Sorry, I know that this must be a silly setup mistake, but I’ve been banging my head on this for most of a day. We are migrating from wowza2 server to wowza 3. Everything (live/vod) is going fine except for vods3 not working

ERROR server comment 2011-12-29 08:26:35 - - - - - 56327.821play: error opening file (/usr/local/WowzaMediaServer/content/amazons3/testbucketdc/sample.mp4): java.lang.NullPointerException

rtmp://[instance]/vods3/definst/

or

rtmp://[instance]/vods3/

mp4:amazons3/[bucketname]/sample.mp4

Whether we use definst or not, vods3 seems to not be accessing S3. Instead it appears to be accessing vod via the local wowza content folder.

Server.xml has the S3 license key pair. bucket name has simple alphabet characters w/o any uppercase.

Is there debug that I can turn on or something? NullPointerException is rather generic.

Your vods3 app is not configured correctly. You might want to start over with a new instance. Do not use a Startup package, then check the vods3 application that is included.

Richard

The next version of the amazon ami that is due out in a few days is switching to straight medicache. The tuning will be in the startup packages.

Charlie

Make sure you got the right one, it is acting like a regular vod application, appears to be missing the MediaReader property necessary in the Application.xml for vods3.

Or start a new instance without a startup package to get a working copy that you can refer to.

Otherwise, zip up and send conf and logs folders to support@wowza.com. Include a link to this thread for reference. (due to the holidays, it might be a few days to turn-around)

Richard

It is not included in the installer, vods3 is part of pre-built Wowza AMIs. You can use MediaCache instead:

https://www.wowza.com/docs/how-to-scale-video-on-demand-streaming-with-media-cache

Or you could start a Wowza AMI and get jar file(s) needed for this. You will have to review the difference, I don’t remember which one off the top of my head, but I think it is obvious when you compare.

I would just use one of the pre-built lickey AMIs:

https://www.wowza.com/docs/pre-built-amis-amazon-machine-images#lickey

Richard

It’s not a requirement. You can install Wowza on a EC2 instance using the installer.

Be sure to tune:

https://www.wowza.com/docs/how-to-do-performance-tuning

The pre-built AMIs are self-tuning.

Richard

Sorry, I’m lost. What is the current issue?

Richard

I think vods3 is working because “item not in cache” is one of its messages. I don’t understand why you don’t want to use MediaCache. Use vods3 with your pre-built Wowza AMI, use MediaCache otherwise.

Richard

I still suggest you use MediaCache instead of “vods3”, which is just MediaCache that only works with S3 on EC2.

Richard

by “configure”, I assume that you mean conf/vods3/Application.xml. I freshed copied in Application.xml from the default_3.0.zip downloaded, unzipped, and copied it in unmodified only yesterday.

zipped and sent. Okay since I’m stuck I did some more digging.

  1. Why are you guys output errors into wowza_access.log instead of wowza_error.log? I missed some (what appear to be major) clues because of this.

2011-12-29 13:00:24 EST comment server ERROR 500 - RandomAccessReaderFactory: createRandomAccessReader: java.lang.ClassNotFoundException: com.wowza.wms.plugin.amazonaws.ec2.mediacache.MediaCacheRandomAccessReaderAmazonEC2 - - - 31.398 - - - - - - - - - - - - - - - - - - - - - - - - -

2011-12-29 13:00:24 EST comment server ERROR 500 - play: error opening file (/usr/local/WowzaMediaServer/content/amazons3/testbucketdc/sample.mp4): java.lang.NullPointerException -

  1. Looks like I’m missing MediaCachRandomAccessReaderAmazonEC2 class file.

  2. Downloaded fresh Linux install from the store.

  3. Examined every jar file in lib and none of them contain this Class file.

  4. Looked at the fresh new install and there isn’t a vods3 conf folder. So I’m guessing that I did the correct thing in downloading the default_3.0.zip to get vods3 conf/Application.xml

That Application.xml from default_3.0.zip contains a MediaReader (as you note above) which references this class file. Where can I get this class from since it does not seem to come from the installer in the store?

randomAccessReaderClass

com.wowza.wms.plugin.amazonaws.ec2.mediacache.MediaCacheRandomAccessReaderAmazonEC2

bufferSeekIO

true

Boolean

Sorry for the delay, but we lost our instance and had to restore it. After restoring, I pushed the aws-plugin-xxx.jar files over to it that I downloaded from the post link that you put above.

Things look improved, but still no joy. I tried with and without definst w/o difference. We’re now getting a “item not in cache” error.

2011-12-31 14:41:14 EST connect session INFO 200 71.58.43.38 - defaultVHost vods3 definst 0.036 [any] 1935 rtmp://ec2-107-22-140-189.compute-1.amazonaws.com/vods3/definst/ 71.58.43.38 rtmp http://ec2-107-22-140-189.compute-1.amazonaws.com/wowza/examples/SimpleVideoStreaming/client/simplevideostreaming.swf MAC 11,1,102,55 334465385 3622 3073 - - - - - - - rtmp://ec2-107-22-140-189.compute-1.amazonaws.com/vods3/definst/ -

2011-12-31 14:41:14 EST create stream INFO 200 - defaultVHost vods3 definst 0.001 [any] 1935 rtmp://ec2-107-22-140-189.compute-1.amazonaws.com/vods3/definst/ 71.58.43.38 rtmp http://ec2-107-22-140-189.compute-1.amazonaws.com/wowza/examples/SimpleVideoStreaming/client/simplevideostreaming.swf MAC 11,1,102,55 334465385 3694 3413 1 - 0 0 - - - - 0 0.0 rtmp://ec2-107-22-140-189.compute-1.amazonaws.com/vods3/definst/ rtmp://ec2-107-22-140-189.compute-1.amazonaws.com/vods3/definst/ - rtmp://ec2-107-22-140-189.compute-1.amazonaws.com/vods3/definst/ -

2011-12-31 14:41:15 EST comment server INFO 200 - ModuleStreamNameAlias.nameToAlias[play]: streamName:mp4:amazons3/testbucketdc/sample.mp4 alias:{pattern: “*” alias:"${Stream.Name}" wildcardMatches:{[0]: “mp4:amazons3/testbucketdc/sample.mp4”}} result:mp4:amazons3/testbucketdc/sample.mp4 1174.452 - - - - - - - - - -

2011-12-31 14:41:15 EST comment server WARN 404 amazons3/testbucketdc/sample.mp4 MediaReaderH264.open[1]: java.io.IOException: MediaCacheRandomAccessReader.open: Item not in cache: amazons3/testbucketdc/sample.mp4 - - - 1174.457

It’s pretty disappointing that you guys don’t support the installer on EC2 and require us to take one of the images instead.

Okay well if you do support it, can you answer my question from: 12-31-2011, 12:49 PM posted above?

I gave up on you guys responding especially after the sales guy told me that we need to use the AMI to get vods3 working. After giving up, I installed and got running mediacache module, but I’d really prefer to use the standard vods3. Even though mediacache works, I fear that there is something still wrong with my install that I’d like to get to the bottom of.

The last thing that you said on December 29 was:

“Or you could start a Wowza AMI and get jar file(s) needed for this. You will have to review the difference, I don’t remember which one off the top of my head, but I think it is obvious when you compare.”

So I followed your advice and compared my install to a large AMI. There were some jars missing (all of which looked like: aws-plugin-xxx.jar) on my install. I then added those plugin jars to my install and responded on December 31 2011:

Things look improved, but still no joy getting vods3 to work. We’re now getting a “item not in cache” error.

2011-12-31 14:41:14 EST connect session INFO 200 71.58.43.38 - defaultVHost vods3 definst 0.036 [any] 1935 rtmp://ec2-107-22-140-189.compute-1.amazonaws.com/vods3/definst/ 71.58.43.38 rtmp http://ec2-107-22-140-189.compute-1…ostreaming.swf MAC 11,1,102,55 334465385 3622 3073 - - - - - - - rtmp://ec2-107-22-140-189.compute-1.amazonaws.com/vods3/definst/ -

2011-12-31 14:41:14 EST create stream INFO 200 - defaultVHost vods3 definst 0.001 [any] 1935 rtmp://ec2-107-22-140-189.compute-1.amazonaws.com/vods3/definst/ 71.58.43.38 rtmp http://ec2-107-22-140-189.compute-1…ostreaming.swf MAC 11,1,102,55 334465385 3694 3413 1 - 0 0 - - - - 0 0.0 rtmp://ec2-107-22-140-189.compute-1.amazonaws.com/vods3/definst/ rtmp://ec2-107-22-140-189.compute-1.amazonaws.com/vods3/definst/ - rtmp://ec2-107-22-140-189.compute-1.amazonaws.com/vods3/definst/ -

2011-12-31 14:41:15 EST comment server INFO 200 - ModuleStreamNameAlias.nameToAlias[play]: streamName:mp4:amazons3/testbucketdc/sample.mp4 alias:{pattern: “*” alias:"${Stream.Name}" wildcardMatches:{[0]: “mp4:amazons3/testbucketdc/sample.mp4”}} result:mp4:amazons3/testbucketdc/sample.mp4 1174.452 - - - - - - - - - -

2011-12-31 14:41:15 EST comment server WARN 404 amazons3/testbucketdc/sample.mp4 MediaReaderH264.open[1]: java.io.IOException: MediaCacheRandomAccessReader.open: Item not in cache: amazons3/testbucketdc/sample.mp4 - - - 1174.457

So I’m looking for a response to the above error message so that I can get out of the box vods3 application working. I’d rather not (even though I did so) use mediacache because there is manually tuning that would be required (as you noted. The documentation also says that vods3 is a customized medicacache module). I’d rather leverage the Wowza team work on customizing vods3 than try to bumble my way through duplicating that work on my own.

okay so if “item not in cache” is one of it’s messages. How do I get vods3 to initialize its cache? This was all so easy in Wowza 2. Wowza 3 is a nightmare.

The reason that I don’t want to use Mediacache is because I’ve read that “vods3” is a custom built/tuned version of MediaCache. I would assume that you Wowza guys custom tuned vods3. Why do I have to custom tune another mediacache on my own? Why can I not leverage the work that you guys have done? Why do I only have a choice of using a prebuilt AMI or building my own media-cache? This goes back to my original question. Do you or do you not support the installer? Or is it that you support everything under the installer EXCEPT vods3??

If you indeed support the installer, then please support vods3 under the installer and help me figure out why vods3 is not working when I installed Wowza 3 from the wowza 3 installer.

Do you think that I should just wipe my install and re-install? Perhaps the installer that I used 2 months ago had a bug in it and I should try again???

okay guys, thanks for the clarifications. I’ll stick with media-cache then. Sorry to be such a pain, but just wanted to make sure that we took the correct path.