Does the server listen in the same port or on a random one....?

Hi all,
As I went through the Java Tutorial in Sun's website I found that though the server is assigned a port to listen, it does the actual communication with the client in another port and keeps the assigned port listening for other clients.
Can't we control this..?

The real number can even go upto 5000.Even 5000 is not alot. Whether you use NIO or blocking IO is going to make more of a differnece.
And we consider this because of some firewall restrictions (from my real client).That depends on how their firewalls are set. Unless they block HTTP and most other internet protocols (which I doubt) Then they only restrict the port the connection is opened on, not the port a open connection sends a packet to.

Similar Messages

  • Why does the same RGB color appear lighter in one ai file and darker in another?

    Why does the same RGB color appear lighter in one ai file and darker in another??  I want to use the more vibrant color, but when I try to reproduce the same RGB color code in another Adobe Illustrator (ai) file, it shows up darker.  I printed the two files out, and you can see the difference in the print too.  I exported the color orginally as an eps file from an ArcGIS map.
    Any insight is greatly appreciated!
    Anne

    You illustrator files may have different color profiles attached.
    Set to show your color profile in the bottom left of each document by using the flyout menu >> show >> document color profile
    Then you can use edit >> assign profile to get them the same
    Yours are quite far off for RGB (which are usually close to each other for many profile due to wide gamut).  I question as Jacob did if one of your documents are in CMYK mode. Look in parenthesis after the document name at top of window.
    Check if view > proof setup is the same (do not use the uncoated profile as in my screenshot, that was only there cause of my testing)
    Make sure view >> proofs colors is checked or unchecked for both.
    To get them to print the same, check these settings are the same
    Sorry for all the screenshots, but hopefully one day we will see Adobe's complex color management united all in one window.

  • Is there an app that does the same as FileMagnet?

    Is there an app that does the same as FileMagnet?

    iBank is one that has similar capabilities. The have a 30 day free trial. http://www.iggsoftware.com/ibank/

  • Is it possible to use both an ILB and an ELB (listening on the same port) in the same Azure cloud service?

    I'm building a test Lync deployment on Azure; yes, I know this is not supported, hence "test".
    Lync Front-End servers expose two set of web services, one for internal users and one for external ones; they listen on different ports (443 and 4443) on the same servers; when external services are published, you need a reverse proxy or a port forwarding
    in order to map port 443 of a public IP address to port 4443 of the Front-End server(s). When you have multiple Front-End servers in a pool, you also need to load-balance them.
    So, a typical Lync deployment looks like this:
           Internal users
                     |
                   443
                      |
              Internal LB
            192.168.0.20
            443         443
              |               |
       Lync FE 1     Lync FE 2
    192.168.0.21 192.168.0.22
              |               |
          4443        4443
              External LB
           Public IP Address
                     |
                  443
                     |
           External Users
    This should be easily replicated in Azure, as it supports both external load balancing and internal load balancing. They are even supported together in the same cloud service, so this configuration should be easy. However, it looks like "should"
    is the keyword here.
    After creating the external load balanced endpoint (which listens on external port 443 and forwards to port 4443 on the servers), I'm trying to create an internal load balancer and add internal endpoints to is; however, while the ILB can be created successfully,
    adding an internal endpoint listening on port 443 and forwarding to port 443 on the servers fails miserably, with an error stating that port 443 is already in use by another endpoint:
    Update-AzureVM : BadRequest : Port 443 is already in use by one of the endpoints in this deployment. Ensure that the port numbers are unique across endpoints within a deployment.
    For reference, my commands are:
    Add-AzureInternalLoadBalancer -InternalLoadBalancerName "LyncILB" -ServiceName "LyncFrontEnd" -SubnetName "LabSubnet" -StaticVNetIPAddress 192.168.0.20
    (This completes successfully)
    Get-AzureVM LYNCFE1 | Add-AzureEndpoint -Name "Https-Int" -Protocol "tcp" -LocalPort 443 -PublicPort 443 -LBSetName "HttpsIntLB" -DefaultProbe -InternalLoadBalancerName "LyncILB"
    (This fails)
    The existing external endpoint is configured as such:
    Get-AzureVM LYNCFE1 | get-azureendpoint
    LBSetName : HttpsExtLB
    LocalPort : 4443
    Name : HTTPS-Ext
    Port : 443
    Protocol : tcp
    Vip :
    ProbePath :
    ProbePort : 4443
    ProbeProtocol : tcp
    ProbeIntervalInSeconds : 15
    ProbeTimeoutInSeconds : 31
    EnableDirectServerReturn : False
    Acl : {}
    InternalLoadBalancerName :
    IdleTimeoutInMinutes :
    LoadBalancerDistribution :
    The error doesn't even make a lot of sense; the external load balancer listens on a public IP address, while the internal load balancer listens on a private IP address in the internal network; there
    shouldn't be any conflict here... however it looks like there is one instead.
    Why doesn't this work? Am I doing something wrong, or is Azure networking just being silly as usual again?

    Hello Massimo Pascucci,
    The issue that you are facing when creating an endpoint with internal loadbalancer is the limitation of not allowing same ports to be listening under a single cloud service. This reason for this is that there is a limitation of only one private IP (Also
    known as the Internal load balanced IP) per cloud service.
    There is also a limitation on the Internal load balancer more than one port to be published per load balancer:
    You can leave your feedback by following the link below:
    https://social.msdn.microsoft.com/Forums/en-US/1805c5a0-3906-4cd6-8561-9802d77e0ae5/is-it-possible-to-use-both-an-ilb-and-an-elb-listening-on-the-same-port-in-the-same-azure-cloud?forum=WAVirtualMachinesVirtualNetwork
    Refer to this article for more information on Internal load balancer:
    http://azure.microsoft.com/blog/2014/05/20/internal-load-balancing/
    Thanks,
    Syed Irfan Hussain

  • Installing 2x Instances of UCM on the same ports on a multihomed server

    We're looking at installing 2x instances of UCM on the same multihomed server, using the same port numbers for each.
    But following the initial installation, we note that the admin port binds to all of the IP's in the server.
    $ netstat -a | grep LISTEN | grep 444
    tcp 0 0 *:4440 *:* LISTEN
    Is there a way to stop the Admin server from doing this, and only to bind to a single IP ?
    We effectively want to get the 1st instance Admin Server to Listen on IP1:4440
    And the 2nd instance Admin Server to Listen on IP2:4440
    Same with port 4444 for both instances.
    Incidentally, the Admin Server should not really listen on all IP's by default, as this is a potential security risk especially if one IP was for example internal traffic, and the other one was for external traffic.
    So there are other reasons for not wanting to listen on all IP's within the server rather than the specific one.
    Any help / guidance much appreciated.
    Regards
    Andrew

    This configuration entry is available:
    IdcServerBindAddress=IPaddress
    It's generally been used in clustered installations but I see no reason why it wouldn't work with a stand alone instance as well.
    Regards,
    Josh

  • Broadcast and point to point server in the same port

    I'm trying to set up a system where I can send point to point messages via sockets to certain ips, send broadcast messages to every pc in the network, and also be able to listen for point to point messages and broadcast messages, all in the same port. I've been able to establish a point to point connection using the Socket class to send the message, and using the ServerSocket class to listen for messages, but I can't seem to get broadcasting to work.
    I read somewhere that for broadcasting one should use the DatagramSocket class. The problem is i'm not sure which ip i'm supposed to specify when I send the message. Also, do I need a special listener to listen for broadcast messages, or will the ServerSocket listener work for that?
    This is what I have for the broadcasting part:
    String msg = myId;
    DatagramSocket sendSocket;
    sendSocket = new DatagramSocket(Constants.COM_PORT); // 4567
    InetAddress group = InetAddress.getByName(Constants.BROADCAST_ADDR); // "192.168.1.1"
    DatagramPacket dp = new DatagramPacket(msg.getBytes(), msg.getBytes().length, group, Constants.COM_PORT);
    sendSocket.send(dp);
    sendSocket.close();
    Thanks in advance
    Diego

    It worth mentioning that UDP/broadcast and robust do go together easily.
    - UDP does not guarantee delivery. i.e. messages can be dropped and you won't be told. Lost packets are not retransmitted either.
    - UDP can fragment packets if larger than 532 bytes long.
    - UDP packets can arrive out of order (though I have never seen this myself)
    If your receiver is under load/busy it can miss many packets if its buffers overflow.

  • HELP!!: Two server application instances could work in the same port?

    Hi everybody!!!
    i have two server application instances over the same JVM and both of them need to get requests from the same port, how can i get this??
    I`m not interested on using RMI, and i wouldn`t like to use sockets, because i have already using XML-RPC, so if you can tell me how can i get this without using sockets nor RMI, please help me...
    I don�t if there any way using threads??
    thanks a lot,
    JCPARRAM

    Two sockets can't be bound to the same port on the same machine at the same time. This means that one application can't have two sockets listening on the same port and that two applications can't each have a socket listening on the same port (no matter what language they are written in, and, if they are in Java, no matter whether they are on the same JVM or not).
    Your only solution is to make one of the server applications listen on a different port.

  • Can you have multiple RMI Servers listen at the same port?

    Hi,
    I am wondering if is possible to assign many RMI servers to the same port. I have a working RMI system that is assigning a single server to a specified port when the server is created. I need to scale my project to incorporate Activation and the ability to go through a firewall. I have the power to punch holes in the firewall, so I am thinking that I would like to set up a port for all my activated servers to listen on. Is this possible to put them all on one port?

    Yes you are correct. However, I am wanting the actual servers listening on the same port. I have noticed that when I do not assign a port number when binding my RMI servers to the registry, then the rmi system sets them all up listening on the same port. This port is random and changes each time I restart my server system, which rebinds all the servers to the rmiregistry again. I am look for a way to use custom socket factories and then tell the servers the exact port to listen at. I keep getting port already in use issues though when I try to assign more than one server to a particular port. I don't know if this is even possible. Has anyone ever gotten this to work?

  • Several process listening to the same port number

    I hope I am in the right form (it's the third one I am trying).
    I have server/client application, one server that handles a lot of clients. In general when ever a client approach the server, the server create new process (fork()) that handle the client request.
    I would like to know if there is a problem that several processes (parent and several child processes) are listening to the same port number, is it better to create thread that would handle the client request, instead of creating a child process?
    To better understand the problem I create very simple client and server application.
    This is a part of the server application:
    The server creates a socket, bind to this socket and then listen to this socket.
    After that in a while (1) loop he waits for accept:
    int sockclient = accept(sockId,(struct sockaddr*)(&client_addr), &addrLen);
    When the server get a sockclient (client ask for service) he create new process (fork()) that handle the client request.
    struct sockaddr_in addr, client_addr;
    bzero(&addr,sizeof(struct sockaddr_in));
    addr.sin_family = PF_INET;
    addr.sin_port = 8865;
    bcopy(ent->h_addr_list[0],&(addr.sin_addr), ent->h_length);
    // bind
    bind(sockId,(struct sockaddr*)(&addr), sizeof( struct sockaddr_in));
    If it would help I can add the all code.
    If you knows about articles that talked about this subject It might help too (I am talking about advantages and disadvantages of thread against process but regardless of sockets).

    You might look at this article
    http://httpd.apache.org/docs-2.1/misc/perf-tuning.html
    under the section "accept Serialization - multiple sockets".

  • Can I listens to the same port in differernt threads on the same computer

    Q1:can I listens to the same port in differernt threads on the same computer?
    Q2:if I use two thread to listen to two different port, you know, as the method for listening is a block method, will them block each other?
    Thank you very much!

    Q1:can I listens to the same port in differernt
    threads on the same computer?If you mean ServerSocket.accept(), the answer is yes.
    Q2:if I use two thread to listen to two different
    port, you know, as the method for listening is a
    block method, will them block each other?No.

  • My ipod touch 8gb keeps freezing everytime i press something and it never lets me listen to music , i tried to restore it millions of times but it does the same thing

    my ipod touch 8gb keeps freezing everytime i press something and it never lets me listen to music , i tried to restore it millions of times but it does the same thing

    How much free storage space is available on your iPod Touch?
    When restoring your iPod Touch with iTunes, did you restore from the backup for the iPod Touch or as a new iPod Touch?
    If the former and the problem lies with the data included with the backup, restoring from the backup will also restore the problem putting you right back where you started.

  • Two applications wants to read on the same port using Socket

    I have an application running on one machine using TCP/IP socket. The data transfer with the other application on other machine is in ASCII.
    Now I want a new application that can have a copy of data received and sent on the given port, where the previous application is running.
    Is it possible in Java using socket and TCP/IP to have two application reading data from the same port and both can read all the data.

    Even when you don't state the type of app which need to read the data stream (is it a server or a client app???), it's impossible to share a single TCP/IP socket among multiple apps.
    Perhaps the best thing to do is to develop something like a proxy server who listens on the nominated port and provides to contact (if your apps are server ones) or to be contacted (if your apps are client ones) by the desired apps.
    This way, the only job for the proxy is to duplicate the contents of the data stream and make them available to all the apps engaged.
    Hope this helps.

  • Creating a serverSocket while sonnecting to a socket on the same port

    I want to make a file transfer application for multiple clients, there will not be a server that users will connect to, the application serves as client AND server, every client will have a serversocket object listen for new connections (it will recieve a connection when someone wants to send a file to them) and I will also have a socket object that will connect to a client when I want to send a file to them.
    Is it possible to run all these connections on a single port? Or will there be a conflict?

    836981 wrote:
    I want to make a file transfer application for multiple clients, there will not be a server that users will connect to, the application serves as client AND server, every client will have a serversocket object listen for new connections (it will receive a connection when someone wants to send a file to them)Read up on peer-to-peer.
    and I will also have a socket object that will connect to a client when I want to send a file to them.A new socket for each outbound connection.
    Is it possible to run all these connections on a single port?Yes. A serversocket listens for connections to a specific port number, it can accept many connections.
    Or will there be a conflict?No. Your outbound connections will not use the same port number locally.
    You are more likely to encounter problems with clients (peers) behind NAT routers.

  • Help with 2 separate domains with the same ports in a single machine

    Hi,
    Where I can get info on having 2 separate domains on the same machine that works on the same ports, and one works with http://admin-server, and the other for http://production-server.
    I want to have webapps that are installed only in the admin domain, and the others in the production domain. The problem is that if I put the same ports for both domains says:
    Domain production-domain failed to startup. There is a conflict on port 80. Please check the server log for more details.
    CLI156 Could not start the domain production-domain.
    Thanks,
    Regards,
    Lorenzo Jim�nez

    Hi, we don't have two iPhones in the family as yet but as I understand it each device can have separate settings for syncing calendars and contacts. For example my iPhone syncs these over the air with the Exchange server at work so if/when my wife gets an iPhone it would be easy to have hers sync to Outlook on our computer
    To make sure apps purchased on one device don't inadvertently merge with others turn off Automatically sync new apps from the apps tab when you connect your device.
    The Apple support document How to use multiple iPods with one computer suggests a number of ways for managing the media content. I use method two (Sync with selected playlists) with a slight twist. Rather than regular playlists I set the grouping field to indicate which users should receive which tracks and create smart playlists based on the content of this field.
    e.g.
    "Alice's Tracks" is "Grouping contains Alice" + "Kind contains audio"
    "Bob's Videos" is "Grouping contains Bob" + "Kind does not contain audio"
    Tracks that both Alice & Bob want on their iPods have the grouping set to "Alice/Bob"
    etc.
    I currently manage our family's five iDevices using this system, each getting a different selection to suit their tastes and the capacity of their device. An advantage of using the grouping field is that it is stored in file tags (for non-wav audio files anyway) so that it is relatively easy to recreate the playlists should the iTunes library get trashed and need rebuilding. Also useful if you move files about manually as playlist membership is preserved when you delete & re-import the tracks.
    So far we have managed everything with a single Apple ID, but that will probably change as the kids leave home. Managing app updates from multiple IDs is a pain as you have to manually sign in to each account in turn, however there are other benefits to each user having their own account.
    tt2

  • Reading the same port on the same machine

    Hello,
    i'm working on DatagramSocket to broadcast DatagramPacket (IP 192.168.xxx.255) and a fixed num port. The problem is that I can't have 2 threads that read (datagramSocket.read) on the same port, on the same machine.
    How can I perform my tests ?
    java.net.BindException: Address already in use
    at java.net.PlainDatagramSocketImpl.bind(Native Method)
    at java.net.DatagramSocket.bind(DatagramSocket.java:368)
    at java.net.DatagramSocket.<init>(DatagramSocket.java:210)
    at java.net.DatagramSocket.<init>(DatagramSocket.java:261)
    at java.net.DatagramSocket.<init>(DatagramSocket.java:234)

    Well, the short answer is that you can't.... at least I've never heard of a way how. Basically, when an application requests a port number, it basically owns that port number until it gives it up. You do this when you create the DatagramSocket. Each DatagramSocket is its own request, and therefore must have an unique identifying port. Otherwise, how would your operating system know who to give the data to when it receives a packet on your machine for port XXXX? Also, it would be a secuirity problem if other applications could listen on the same port as you use for other things like surfing the web, making online purchases, email.
    However, what you could do is have one owner of the DatagramSocket... and share it among the other threads. When that owner receives a packet, it can notify the other threads it received a packet and pass the data to each one. Set it up something like how listeners work. Also, if you want it to span processes, you could use RMI or pass the data through other deined network connections between the processes.
    Does that make sense? :)

Maybe you are looking for

  • Mac book pro Users & Groups deleting problems

    I have a Macbook Pro, i believe its a 2008 15 inch, thats just come back from the repair shop. I added another user (through Users and Groups) changed the settings so that person was the admin and deleted the original user. Now after roughly an hour

  • Minidisplay port issue

    Hi all, I just got a new Macpro last week. It's been a major pain reinstalling all music programs etc (made the mistake of trying the Migration assistant) Now my final issue is a wierd one which I'm sure has a simple solution. I'm using dual VGA Dell

  • Word of the Day screensaver font

    I have deactivated fonts that I did not need, including the one used for the Word of the Day screensaver. Anyone know what the font is?

  • AC1600 Slow Wired And Wireless Speed

    Hello, I just purchase a smart WiFi router model AC1600. The speed off my router is 3 times as slow as what is coming from my MTA from the cable company. I reinstall my firmware and rebooted it several times, but the best I can get is 6 Mbps downstre

  • [svn:fx-3.x] 8580: Minor ASDoc edits

    Revision: 8580 Author:   [email protected] Date:     2009-07-15 08:40:13 -0700 (Wed, 15 Jul 2009) Log Message: Minor ASDoc edits QE Notes: None Doc Notes: None Bugs: - Checkintests: Passed Modified Paths:     flex/sdk/branches/3.x/frameworks/projects