Cannot log in to Redbox example

Post your questions and bug-reports about the audio/video streaming add-on based on Red5 Media Server.

Moderators: Bax, Lapo, rjgtav

Cannot log in to Redbox example

Postby vision2020 » 14 Jan 2011, 03:03

I have SmartFox Started (checked by going to http://localhost:8080/), and I have Red5 started (checked by going to http://localhost:5080/).

When I start SmartFox, the last line is "[RedBox] Internal event received: serverReady"

I am attempting to run "C:\Program Files\SmartFoxServerPRO_1.6.6\Examples\RedBox\SmartFoxChatAV\bin\SmartFoxChatAV.swf" but when I click the login button (after typing something into the textbox), it doesn't do anything for a while, and then says "Connection was lost"

I have attempted to create a video chat on my own, and SmartFox works fine, until I create a new SmartFoxAVManager. In the output, I get:
[RedBox] NetStatusEvent response received
[RedBox] Level: error | Code:NetConnection.Connect.Failed
[RedBox] NetConnection error, dispatching event...


Does anyone have any idea why this might be happening and/or how I can fix it? I've re-installed Red5 about 6 times, and just can't figure out why SmartFox and Red5 can't talk to one another...
vision2020
 
Posts: 6
Joined: 07 Dec 2010, 19:54

Postby Bax » 14 Jan 2011, 07:33

Why did you install Red5, instead of using the version provided with SFS? It has been configured so that SFS can talk to it. From the log it seems the SFS client can't reach Red5... for example, are you passing the right connection string?
Paolo Bax
The SmartFoxServer Team
User avatar
Bax
Site Admin
 
Posts: 3851
Joined: 29 Mar 2005, 09:50
Location: Italy

Postby vision2020 » 14 Jan 2011, 12:07

I actually didn't discover that SFS came with it until just last night...

I uninstalled Red5 from my machine (so that I wouldn't get confused as to which one SFS was pointing to), and I run /SmartFoxServerPRO_1.6.6/Server/Redbox/red5.bat. At first it gave me something about a QT error, but I removed %CLASSPATH% from the bat file and now it does not give me any errors. The console ends with
[INFO] 2011-01-14 08:32:12,811 main:( org.red5.server.Standalone.main ) Startup done in: 7707 ms

Then I run /SmartFoxServerPRO_1.6.6/start.bat and it does not give me any errors either, ending the console with
08:34:06.464 - [ INFO ] > Server is up and running!
08:34:06.468 - [ INFO ] > [RedBox] Internal event received: serverReady

Then I go to http://127.0.0.1:8080/Examples/RedBox/S ... hatAV/bin/
and try to login under "bob" and it just sits there, spinning its wheels until it finally says "Connection was lost." Both consoles where I started the services are still up, and neither has said that they have shut down.

Same error as before when I try to run my own program...

Any ideas?

Thank you for your speedy reply... This is for a project for school, so I really appreciate it... the deadline is approaching fast!
vision2020
 
Posts: 6
Joined: 07 Dec 2010, 19:54

Postby Bax » 14 Jan 2011, 12:13

What I don't understand is if the example is not working at all (so not connecting to SmartFoxServer), or if it works but then fails once it is time to connect to Red5.
From your brief description it sounds like the first one, so you have to look for problems in a totally different place. I suggest you to read chapter 3.6 of the docs.
Paolo Bax
The SmartFoxServer Team
User avatar
Bax
Site Admin
 
Posts: 3851
Joined: 29 Mar 2005, 09:50
Location: Italy

Postby vision2020 » 14 Jan 2011, 14:36

I really don't know what is happening - smartfox was working enough for two users to connect remotely and send public messages, so I assumed that it was working fully. That's the extent of what I need... remote connection + public messages + video chat.

I'm looking at the chapter now, and it says to type (into cmd):
telnet 10.20.30.40 9339

When I do that, i get:
'telnet' is not recognized as an internal or external command,
operable program or batch file.

I tried the IP they provided, my external IP, and 127.0.0.1, all returned the same thing.

For my firewall, I have both an incoming and outgoing "always allow" rule for port 9339 (TCP), in addition to port 1935 (TCP).

I don't really understand what I'm supposed to do with the Flash Player security settings, but I have already set my Global Security Settings to trust files in "C:\Program Files\SmartFoxServerPRO_1.6.6\". Is there more I have to do with the Flash Player?


The examples I can log into are:
/AS2/01_simpleConnect/
/AS2/02_simpleChat/
/AS2/03_advancedChat/
/AS2/04_avatarChat/
/AS2/07_roomVariables/
/AS2/08_buddyList/
/AS2/21_pro_jsonExample/ (no log-in, but it seems to work...)
/AS3/SmartFoxChat/bin/
/AS3/template_AS3/
/AS3/SFSTemplate(flex)/bin/
/SmartFoxBits/Chat/

Everything else seems to connect, but not log in. :?
vision2020
 
Posts: 6
Joined: 07 Dec 2010, 19:54

Fixed it... Kindof

Postby vision2020 » 16 Jan 2011, 06:51

Ok. So, I had previously thought that it was a problem with Red5, but I guess it was a problem with SmartFox itself.

I reinstalled SmartFox, and now all of the examples work!
The only change was I had to take %CLASS_PATH% out of the red5.bat file and now it seems to run fine. =)

Question though:
When I'm running my own program (which is based off of one of the examples), I start up SmartFox, and had been clicking \SmartFoxServerPRO_1.6.6\Server\RedBox\red5.bat to start up red5. Is this correct? When I'm in my program, and I do this:
avChatMan.sendChatRequest(AVChatManager.REQ_TYPE_SEND_RECEIVE, buddy.getId(), true, true);

it pops up an error in the .swf saying
Error: Red5 connection not available [sendChatRequest method]
at com.smartfoxserver.redbox::AVChatManager/sendChatRequest()
at SmartFoxChatAV/startAVChat()
at testScreen::VideoChatCtrl/keyboardStart()

Is that an error in my code somewhere, or is it the way that I start up red5? (Is there a way to do this through code?)
vision2020
 
Posts: 6
Joined: 07 Dec 2010, 19:54

Postby Bax » 17 Jan 2011, 15:14

I suppose this is an issue in your code. Unless your client is not able to reach Red5.
Paolo Bax
The SmartFoxServer Team
User avatar
Bax
Site Admin
 
Posts: 3851
Joined: 29 Mar 2005, 09:50
Location: Italy

Dumb Problem

Postby vision2020 » 18 Jan 2011, 17:25

So, my first problem was my installation of SmartFox, and my second problem was when I was making the AVChatManager instance, I was passing it a null IP address.

Thank you for all of your help!
vision2020
 
Posts: 6
Joined: 07 Dec 2010, 19:54


Return to RedBox

Who is online

Users browsing this forum: No registered users and 0 guests