server

server

The developer observes that some information is not delivered at the client end. He
tries using the following code to create a reliable connection between server and
client:
public Server()
{
try
{
serverSocket = new ServerSocket(1001);
System.out.println(serverSocket.toString());
}
catch(IOException e)
{
System.out.println("Error Starting the Server . . .");
}
System.out.println("Server started . . .");
this.start();
}
The developer writes the following code for client:
public client()
{
try
{
Socket clientSocket = new Socket("192.168.0.70", 1002);
}
catch(UnknownHostException e)
{
System.err.println("Unidentified hostname");
System.exit(1);
}
}
However, the developer observes that clients are able to connect to the server only
when the server and clients exist on the same machine. But, when a client executes
on a different machine then an exception is thrown at client end. What is the cause of
this behavior of the preceding code snippet? 
View Answers









Related Tutorials/Questions & Answers:
server
connection between server and client: public Server() { try { serverSocket...(IOException e) { System.out.println("Error Starting the Server . . ."); } System.out.println("Server started . . ."); this.start(); } The developer writes
dns server
dns server   how to make my pc a dns server
Advertisements
dns server
dns server   how to make my pc a dns server
dns server
dns server   how to make my pc a dns server
dns server
dns server   how to make my pc a dns server
dns server
dns server   how to make my pc a dns server
server status
server status   How to check the apache server status in unix machine
ftp server
ftp server  ftp server
ftp server
ftp server  ftp server
ftp server
ftp server  ftp server
snooping the server
snooping the server  Define snooping the server in servlet
snooping the server
snooping the server  Define snooping the server in servlet
SQL Server
SQL Server  Hii, What is SQL Server ?   hello,ADS_TO_REPLACE_1 SQL Server is a DBMS system provided by Microsoft
what is the server
what is the server  what is the server?   Server... of software, such as a WWW server. A single server machine can (and often does) have several different server software packages running on it, thus providing many
server error
server error  during starting of WAS server in eclipse, everytime this warning comes........ WARN [Settings] Settings: Could not parse struts.locale setting, substituting default VM locale plz do help me
Application Server and Web Server - WebSevices
Application Server and Web Server  General difference, Application Server and Web Server  Answer: A Web server handles the HTTP protocol. When the Web server receives an HTTP request, it responds with an HTTP response
Tomcat server/any application server
Tomcat server/any application server  how the server understands request is coming from client and how can it give response within very short span of time
Chat server
Chat server  Please provide me complete information for making a chat server project using JMS
FTP server
FTP server  How to store a series of files in a ftp server using java
Tomcat Server
Tomcat Server  Why my tomcat server installation stop at using:jvm c:\program files\java\jdk 1.6.0\bin\client\jvm.dll. Even though i trying to install several times. please help me....   Installing Tomcat Server
DIFFERENCE BETWEEN APPLICATION SERVER AND WEB SERVER
DIFFERENCE BETWEEN APPLICATION SERVER AND WEB SERVER  What is the difference between application server and web server
chat server
chat server  i want to develop chat server through jsp+struts+spring+hibernate so please guide me
chatting Server
chatting Server  I want to develop a chatting server in jsp using mysql as database.What I need for that. Please tell me
web server
web server  we need to restart tomcat server when we upload java class file but no need to restart when we upload jsp file. why
chat server
chat server  how to write code for Many-Many (Broad cast): Each client opens a socket connection to the chat server and writes to the socket. Whatever is written by one party can be seen by all other parties
FTP Server
FTP Server  i'm working on ftp server if one client has uploaded a file i need to save the details of the user who has uploaded the file like username,filename & ipaddress using java
proxy server in java
proxy server in java  how to developed proxy server in java .. detail of what is proxy server
weblogic server
;WebLogic is a server software application that runs on a middle tier, between back-end... and applications. WebLogic server is based on Java 2 Platform, Enterprise Edition (J2EE... features of WebLogic server include connectors that make it possible for any legacy
Application Server
Application Server       An application server is an application program that accepts connections in order... server, database server, backup server, print server, mail server, web server
(List)Web server n app. server
(List)Web server n app. server  Hi,I have searched list of web server & app server lists,but every time i got shuffled ,Kindly any responsible person tell me the names of web server & app server.   Hi Please
Recommendation for application server and SOA process server
Recommendation for application server and SOA process server  Comparing between apache geranimo and jboss application server, which one is more...? and is there any open source reliable process server alternative to websphere process server
how to print the server time
how to print the server time  how to print the server time in jsp and update time in fix interval
server side scripting in php
server side scripting in php  is it possible to access values on server side in post request PHP
servlet (tomcat server) and jar
servlet (tomcat server) and jar  how to create a jar file and where to place the jar file in tomecat server
Hibernate :dynamically choosing server
Hibernate :dynamically choosing server   Is it possible to dynamically choose server name in hibernate
ModuleNotFoundError: No module named 'server'
ModuleNotFoundError: No module named 'server'  Hi, My Python... 'server' How to remove the ModuleNotFoundError: No module named 'server'... to install padas library. You can install server python with following command
Server Sockets
Server Sockets     ... program and a server program. In java there is a java.net package, which... the client side connection and second is server socket, which implement
server intercommunication - WebSevices
server intercommunication  how to intercommunicate between two servers by using webservices... Example :if our service is in one server(Apache tomcat5.5) and application is in other server(jboss4.0
sql server - SQL
sql server  what is SQL server? & what is oracle? are they same
stop the running hidden server
Server at localhost is already in use. The server may already be running in another process, or a system process may be using the port. To start this server you... server
What is WAMP Server
What is WAMP Server  What is WAMP Server? And what are the configuration of WAMP
Installation of wamp server
Installation of wamp server  how to install wamp server on window 8
upgrade mysql cpanel server
upgrade mysql cpanel server  upgrade mysql cpanel server
Version of geronimo-uddi-server>geronimo-uddi-server dependency
List of Version of geronimo-uddi-server>geronimo-uddi-server dependency
Application server to download
Application server to download  Which Application server can be downloaded for free to use personally at home to practice JSP,EJB etc
server-jsp - JSP-Servlet
server-jsp  how can we implement a simple database(ms access) for storing information about the HTTP requests sent to a web server(database
session variables server side
session variables server side  how to hold session variable for server side..?   request.getSession().setAttribute("wellSelection", uid
Difference between Web server and Application server ? Example of both
Difference between Web server and Application server ? Example of both  Difference between Web server and Application server ? Give example of both
could not start server. - EJB
could not start server.  Dear All I have installed netbeans 5.5.1 and sun java Application server 9.2 to run ejb program. But when I start server by right clicking on sun java app. server in Run Time window an error
what is the difference betwen application server & web server - Java Interview Questions
what is the difference betwen application server & web server  what is the difference betwen application server & web server

Ads