Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Cannot open socket - Listen fails

Posted on 2000-05-17
6
Medium Priority
?
198 Views
Last Modified: 2010-04-01
i installed jdk2 and jsdk2.0 on win95. when i ran SERVLETRUNNER which comes with jsdk2.0 i get the following Exception

java.net.SocketException : Descriptor not a socket Listen failed.
with a stack trace printed out in Standard output

is there a problem with jvm i installed jrun and uninstalled as it too was not able to open a socket to listen.

Thanks
arun.
0
Comment
Question by:marun
  • 4
6 Comments
 
LVL 7

Accepted Solution

by:
Ravindra76 earned 100 total points
ID: 2820101
Replace java.policy file

in c:\jdk2home\jre\lib\security

with



// Standard extensions get all permissions by default

grant {
      permission java.security.AllPermission;
};

Note:- c:\jdk2home is the directory where U actuallu installed JDK software
0
 
LVL 1

Expert Comment

by:tonus
ID: 2821165
Hi,
Generally Servletrunner is trying to connect to 8080 port. If that port is occupied by some other process, servletrunner won't start. Try changing the port of the servletrunner (setup files u will get in c:/jsdk2.0/examples) and run the servletrunner

bye
0
 
LVL 7

Expert Comment

by:Ravindra76
ID: 2821237

Hi ,

It is not port problem.

If it is so, it will give already bind exception

If U still face, some problem

run Your servlets with this command

servletrunner -d c:\Yourdir -v

wher yourdir is the directory where U are wishing to run servlets.

Otherwise U have to put your servlets in c:\jdsk\examples

because servletrunner will run servlerts in c:\jsdk\examples
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 

Author Comment

by:marun
ID: 2822597
when i installed java1.1 it worked but with jdk2 its not working what may be the problem.
    its not the port problem as  said by ravindra. ravindra security is all the same in the file u mentioned i checked it up but directory is too not the problem. please suggest another way to tackle the problem

thanks
0
 
LVL 7

Expert Comment

by:Ravindra76
ID: 2822752

try first

1.ping localhost

      If it succeeds ,

2. Type ipconfig

3. Then try

      ping ipaddress

      where ipaddress is the system ip address given in ipconfig

If both failed means something problem in Your system networking drivers.

Reinstall TCP/IP drivers
0
 
LVL 7

Expert Comment

by:Ravindra76
ID: 2822846

I will feel very happpy if U would have been rejected my answer than giving D grade.

Ok.

Bye
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
Suggested Courses

916 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question