Re: Server machine and listening port

Is there a way to retrieve the machine a server is running on (and its listening
port) inside a Servlet or JSP?
Currently whenever I change the machine or listening port for a server (via the
console or the config.xml), I also need to find all Servlets and JSPs and alter
them accordingly to reflect the change. This becomes very tedious and cumbersome.
Thanks!

Hi Jamieson,
You can get to parameters like the server name and listen port using methods
of weblogic.management.configuration.ServerMBean
(http://edocs.bea.com/wls/docs60/javadocs/index.html). For example, to get
the listen port, use something like this:
// Create an instance of ServerMBean
weblogic.management.configuration.ServerMBean servermbean =
weblogic.management.Admin.getServer();
// Get the listen port
int port = servermbean.getListenPort();
System.out.println("port = " + port);
// Get the server listenaddress
String listenAddress = servermbean.getListenAddress();
System.out.println("listenAddress = " + listenAddress);
// To get the SSL listenport, create an instance of SSLMBean from the
ServerMBean instance
weblogic.management.configuration.SSLMBean sslmbean = servermbean.getSSL();
// Now, get the SSL listenport
int sslport = sslmbean.getListenPort();
System.out.println("sslport = " + sslport);
Robert's suggestion of using relative URLs is even better, however!
- Ginny
"Jamieson Rivers" <[email protected]> wrote in message
news:3bb92179$[email protected]..
>
Is there a way to retrieve the machine a server is running on (and itslistening
port) inside a Servlet or JSP?
Currently whenever I change the machine or listening port for a server(via the
console or the config.xml), I also need to find all Servlets and JSPs andalter
them accordingly to reflect the change. This becomes very tedious andcumbersome.
>
>
Thanks!

Similar Messages

  • Finding the databse server IP  and the port number

    hi
    is it possible to find the database server IP and the port number through forms using any packages?

    Hello,
    Probably more chances to get an answer in the Database forum ;o)
    Francois

  • BAM Connection in 12C -  Failed to establish a connection to localhost at port 7004.Please verify the Bam server host and JNDI port.

    Hi,
    BAM server is running on 7004 in our local system.
    We need o connect to BAM server from OSB service.
    We tried to use the BAM adapter in the pipeline in 12c, We received Failed to establish a connection to localhost at port 7004.Please verify the Bam server host and JNDI port.
    Please let us know the resolution to this issue.
    Also please provide some links/steps to connect from OSB service to BAM server in 12c.
    Thanks,

    In BAM 12c, you can send data via JMS by configuring an EMS in BAM using the "self-described" payload. Make sure the date formats match correctly. You can configure an error queue which will show you any data parsing problems.
    For example,
    <msgRoot dataObjectName="Student" operationType="insert" keys="RequestId">
       <RequestId>R1000</RequestId>
       <StudentId>S12345</StudentId>
       <RequestType>Admission</RequestType>
       <RequestStatus>Open</RequestStatus>
       <RequestMessage>Please Admin</RequestMessage>
       <RequestCode>3</RequestCode>
       <SubmitTime>2015-03-17 18:23:07</SubmitTime>
       <ApprovalTime>2015-02-18 18:23:07</ApprovalTime>
    </msgRoot>

  • How to get SMTP server name and SMTP port

    hi
    i need to send a report to the use to his mail id
    while configuring the ibot in mail tab it is asking for SMTP server ,and SMTP port
    how we can get these two,.... ?:(
    do i have to purchase from vendors, can any one please tell me the process
    really i don;t knw, please help me out
    Thanks in advance

    Hi,
    To configure the Mail Server u need to have SMTP server details, which your using as the mail server,either from vendor side or u can use your's domain.For your info iam pasting the Gmail Smtp server details here,
    Incoming Mail (POP3) Server - requires SSL:      pop.gmail.com
    Use SSL: Yes
    Port: 995
    Outgoing Mail (SMTP) Server - requires TLS or SSL:      smtp.gmail.com (use authentication)
    Use Authentication: Yes
    Port for TLS/STARTTLS: 587
    Port for SSL: 465
    Account Name:      your full email address (including @gmail.com or @your_domain.com)
    Email Address:      your email address ([email protected] or username@your_domain.com)
    Password:      your Gmail password
    Thanks,
    Kumar.

  • List all printers configured from server and local machine when hosted in server machine and working from Client machine

    Hello Team
    I am developing web application in asp.net. When application run from IIS(hosted in server machine running from client machine using web browser) application should list all the configured printers in local and network.
    can any one please let me know the process, in this i was able to load printers from server, so need to load printers from local machine.
    Thanks in Advance
    Bindu

    Hi Bindu,
    I am developing web application in asp.net. When application run from IIS(hosted in server machine running from client machine using web browser) application should list all the configured printers in local and network.
    From this message, this is a web application in asp.net, and it also related to IIS.
    You should post in the dedicated ASP.Net Forum
    http://forums.asp.net
    For IIS issue, http://forums.iis.net/ IIS forum should post.
    Thanks
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • How do I use pots on my client machine to change values, from the field, on my server machine and all other client machines?

    I am using Lookout 4.5, build 12, and I am having a problem concerning pots. I have data tables created for the different size sewer stations my system monitors. For each station, there are setpoints for starting and stopping of the pumps. I want to be able to change the setpoints for a station on the client file using a pot and have it change on all other machines running Lookout. I did this in 3.8 using DDE, but I don't want to use DDE anymore.
    I created a pot on the client file and URL'ed it to a pot on the server. On the server I created a table with a generic member "A" named "Lead Setp" and then created a member "A1" named
    "C5_1LeadSetp" then a member "A2" named "C3_1LeadSetp" and so on....
    In this table I connected the generic member "A" to the Pot I created on the server, and I connected A1 to its corresponding setpoint signal coming in from the field.
    On the client file I connected (in the table similar to the one on the server but with all signals for the station) the "A1" member to the setpoint signal coming in from the field, and I connected the "A" member to the Pot I created on the client file which is URL'ed to the pot on the server file.
    But, when I change the value of the pot on the client file, only the pot on the server and the "A" member in the table on the server change to the value of the pot on the client. The "A1" member whose screen I am changing the values from on the client does not change! This is the last thing I have to do and my file will be completely converted to 4.0. Does anyone have any ideas?
    Thanks for any responses..
    GBWY
    Jason
    Jason Phillips

    Hi Jason,
    If I understood your task correctly, you want to change the Setpoints on the Server DataTable using Pots from different clients. And also reflect these changes on the clients locally.
    You correctly remoted the Pots on the Clients to the corresponding Pots on the Server. However, you do not need tables on your clients. All you need is Expressions on each client to the particular cell of the Clients.
    So, to summarize: On the Server, the Pots write to the DataTable. And since the Pots on the Clients are remoted to these Pots on the Server, you can affect any change using these Pots. Because of the common remote source (Server Pots, i.e.) all of these Pots will always be in sync. Finally, to get the Setpoints on the Clients, just insert Expressio
    ns to the Server's DataTable.
    I am attaching a simple example (exmpl.zip) which does this. There are three processes -- My_Server, My_Client1, and My_Client2. I had them setup on the same machine so the paths are all process relative, but you can always change those to computer relative or absolute and move the client processes to diff machines.
    Hope this helps.
    Rgds,
    Khalid
    Attachments:
    exmpl.zip ‏12 KB

  • Time Machine and 4 Port USB Hub

    I am trying to use a 1Tb external drive with Time Machine. I have connected the external drive via a 4 port, externally powered USB hub. The hub is then connected to my Airport Extreme.
    The problem is the drive will not mount using the hub. Yet, when I plug the drive directly into my MacBook Pro, it shows up just fine in Disk Utilities, and Time Machine wants to know if I would like to use it as a backup disk.
    I'd really like to use this drive wirelessly to back up multiple Macs via my Airport Extreme. The odd thing is that I have a printer connected to the same hub and I share it using the Airport Extreme and it works just fine. I just don't understand why the hub is making a difference.
    - Do I need a different hub?
    - Are hubs a problem with this kind of set up?
    And I'd like to sneak in a follow-up question if I may:
    - Can I use the same hard drive with Time Machine to back up 2 or 3 Macs?
    Thanks in advance!

    My thanks to you and Tesserax for the quick and helpful responses! You were right about the 1Tb drive not being supported wirelessly through my Airport Extreme. The drive showed up under "disk" in Time Machines preferences, but the drive would not mount. The minute I put the printer directly into the Extreme and connected the drive to the MacBook Pro via the hub, it showed up in Disk Utilities and was ready to format. And, now Time Machine is asking me if I want to use it as my Backup Disk. Cool! Now the only question is if I can share the disk so that my other Macs can also take advantage of this new Backup Disk. We'll see..
    Thanks again so much!!

  • Oracle Applicatio Server 10g and JDeveloper Port

    Hi,
    I deployed a war file into my Oracle 10g application server, but I have no idea about the URL to run this application. The admin page shows my J2EE applications, and I can see my Discoverer Web Application deployed and ACTIVE.
    It shows my Web Module with my war file, but on URL mapping it doesn't show the correct URL to open this web page...
    Is there any easy way to figure out all my application servers URLs or paths?
    Thanks!

    Hi,
    Take a look in the Application Server Deployment guide, which answers you question very well
    http://download-uk.oracle.com/docs/cd/B25221_04/web.1013/b14431/toc.htm
    You should also create an index.jsp containing a redirect directive to you applications start page and configure the index.jsp in the application web.xml file. This ensures your star page is always found, even when a user does not type the full URI to your start page.

  • Is there a transaction to get ORACLE_SID, SERVICE_NAME and Listener PORT?

    I know this information can be gotten from the Oracle DBAu2019s who set up the database, but in my big company, I even do not know who the DBAu2019s are.
    My Oracle database for SAP BI 7.0 is 10.2. Is it possible to get this information using a SAP BW/BI transaction?
    Thanks.

    > I know this information can be gotten from the Oracle DBAu2019s who set up the database, but in my big company, I even do not know who the DBAu2019s are.
    In that case you really shouldn't bother where the databases are because direct SQL access should be out of discussion.
    > My Oracle database for SAP BI 7.0 is 10.2. Is it possible to get this information using a SAP BW/BI transaction?
    No, there isn't such transaction. Of course not.
    What would it be good for?
    If you need to have this information - better get in touch with the DBAs.
    If the database servers are set up in a sensible way, you cannot access them anyhow.
    They would be located in separate network segments, the listener would block all connection trials that don't come from the application servers .
    There shouldn't be any option for you to even reach those servers without having the permission and the information from those people that are in charge of them.
    regards,
    Lars

  • Difference between HTTP Server port and HTTP Server listen port

    Hi,
    What's the difference between the following?
    Oracle HTTP Server port = 7780
    Oracle HTTP Server listen port = 7781
    They are the ports used in my 9ias 9.0.3 instance.
    Please advise.
    Thank you.

    Hi,
    The server port, 7780, is port where HTTP server response and listen ports are other ports tha HTTP Server can listen. In IAS, the default configuration, the server port is response for Web Cache and Web Cache connect with HTTP Server in listen port.
    Marcio Mesti

  • How to know the port number to which the server process is listening

    I have created oracle 10g Release 1 database(orcl) in Windows Xp Professional edition through DBCA . I also created one more database(sample) manually .
    The ORCL server process listens to port no 1521 and
    SAMPLE server process listens to port no 1522
    Once I start the OracleServiceORCL (Service for orcl) from services.msc and check the listener status it displays
    Service "orcl" has 1 instance(s).
    Instance "orcl", status READY, has 1 handler(s) for this service...
    But when I start OracleServiceSAMPLE (Service for sample) from services.exe and check the listener status there is no change . Only when i start the instance the dynamic registration takes place with port no 1521 .
    There is no entry for listener parameter in init.ora file . My question is how is the service ORCL able to get itself registered with the listener even before the instance is up ?
    And how can i know which port no is linked with which server process?
    Also if we provide a different port number(other than 1521 say 1522) in tnsnames.ora for a service and consider the listener is listening to both 1521 and 1522 . Now consider that port number 1521 is free . In this case to which port number will the service be listening to ?
    The listener file looks like this
    SID_LIST_LISTENER =
    (SID_LIST =
    (SID_DESC =
    (SID_NAME = PLSExtProc)
    (ORACLE_HOME = D:\oracle\product\10.1.0\Db_2)
    (PROGRAM = extproc)
    LISTENER =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = irobo)(PORT = 1521))
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = irobo)(PORT = 1522))
    The tnsnames file has the following entry
    ORCL =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = irobo)(PORT = 1522))
    (CONNECT_DATA =
    (SERVICE_NAME = ORCL)
    SAMPLE =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = irobo)(PORT = 1521))
    (CONNECT_DATA =
    (SERVICE_NAME = ORCL)
    EXTPROC_CONNECTION_DATA =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC))
    (CONNECT_DATA =
    (SID = PLSExtProc)
    (PRESENTATION = RO)
    )

    Service "orcl" has 1 instance(s).
    Instance "orcl", status READY, has 1 handler(s) for this service...[coe]
    The status tells you the instance is up. Starting the service often means the instance gets started also, but whatever "often" means, "READY" means "The instance is up, running and taking callers".
    Your statement that "ORCL [is] able to get itself registered with the listener even before the instance is up" is therefore factually incorrect: you started the service, that started the instance. The instance is up and running. Instances that aren't running don't exist. Things which don't exist don't register themselves. Things which HAVE registered themselves therefore do exist.. and if they say they are "ready", it means they are completely, 100% up and running and behaving quite normally.
    I have not set LOCAL_LISTENER initialization parameter.How is this happening ?
    You only need to set LOCAL_LISTENER if (a) you're not using TCP/IP, (b) you're not using port 1521. Otherwise, PMON is hard-coded to register itself with listeners running on port 1521 and using TCP/IP and you don't need to set LOCAL_LISTENER to achieve that.
    Server Processes do not listen. Listeners do (there's a clue in their name). Listeners receive a call to connect to an instance, they spawn a server process to handle your call, and then they connect you to that server process (or send a message back to you telling you how to contact the server process). Each server process of course receives communications from its dedicated client on a specific port (usually in the 50000+ range), and that port is chosen randomly by the listener when it's spawning it. It's a bit blurry and vague to call that server process port a port on which server processes "listen", however.
    If you're talking dedicated server, each client causes one new server process to be spawned, and there is a one-to-one correspondence between server processes and the port that server process happens to accept client communications on.
    If you're going to ask a listener to do listening duty on multiple ports, I'd first question your need to do that and I'd then point out that unless your client tnsnames.ora knows to talk on the second or subsequent port numbers, the listener is never actually going to make use of that second port.
    In either case, the port the listener listens on has nothing whatsoever to do with the port your client-to-server-process communication ends up taking place on.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Unable to initialize the Microsoft Exchange Information Store service because the clocks on the client and on the server machine are skewed

    Each time I restart this exchange server, the Information Store and System Attendant don't start. If It try to manually start the services, I get the follow errors:
    Event ID 5003:
    Unable to initialize the Microsoft Exchange Information Store service because the clocks on the client and on the server machine are skewed. This may be caused by a time change either in the client or the server machine, and may require a reboot of that machine. Other than that, verify that your domain is properly configured and is currently online.
    Event ID 1005:
    Unexpected error The clocks on the client and server machines are skewed. ID no: 80090324 Microsoft Exchange System Attendant  occurred.
    The clocks on the domain controllers and the exchange server are set to the same time zones. As well, all three clocks are in sync down to the second. Any ideas on what's causing this and how to fix it?

    Run this Command from the Exchange Server
    Net time \\ADServerName /Set
    and confirm the action,
    and then you need to restart the service
    Microsoft Exchange Active Directory Topology Service
    and confirm you are not getting the Error 4001 in the event Viewer.
    Thank you, it resolved my issue after being sweating looking for solution.
    How can I prevent this from happening? I cannot restart services on each server reboot nor lose 5 years of my life!!!
    Sokratis Laskaridis MCP, MCTS, MCITP, Small Business Specialist Netapp ASAP, Symantec STS

  • How to deploy Forms, Reports and Menu from Client to Server machine

    Dear Experts,
    I have one requirement to deploy the Forms, Reports and Menu from client machine to server machine.
    Deployment involves the following steps :
    1. Firstly we have to search the selected file in a folder where the .fmx is present ( in Server machine) and take the back up of the the existing file in the server (Source and destination paths will be available).
         Ex. If the existing FMB name is TEST.fmx then the backup file should be TEST_sysdate.fmx.
    2. Secondly we have to transfer the file from the client folder (or from another folder of the same server) to the server folder where the back up exists.
    Please help me to search/rename/copy/replace the _.fmx/.rdf/.rep/.mmx_ files from client to server.
    We are using
    9i Database.
    10g Forms and reports.
    SQL Developer tool.
    OS is Windows (Client and Server).
    Help me out to attach a file of front end screen which we are planning to develop. It will give a clear picture on this requirement.
    Thanks :)
    Edited by: 941175 on Jun 17, 2012 9:09 AM
    Edited by: 941175 on Jun 17, 2012 9:12 AM
    Edited by: 941175 on Jun 17, 2012 9:14 AM

    941175
    Welcome to the forum. Please take a while to go through the FAQ to be found to the top right of the page.
    Your issue is more to do with batch files rather than Forms. The only relation with Forms, as I see it, is that you will be using HOST/CLIENT_HOST to start a batch file with the file name to be deployed as a parameter passed to it.
    You need to rewrite either a CMD batch file or a Powershell script to achieve what have set out to do.
    For CMD batch files look up http://www.robvanderwoude.com/battech.php , or any of the other excellent resources available on the internet.
    Regards,

  • LOAD BALANCE (CSS) and Portal Port Number based on Instance Number

    Hi,
    My doubt is about LOAD BALANCE (CSS) and Portal Port Number based on Instance Number.
    I have to install 3 servers machines and 2 servers databases cluster. There will be a HIGH AVAILABILITY environment. There will be a MIGRATION and UPGRADE.
    Today there are 2 servers machines in Windows NLB. Today my production Portal is 6 6.20.
    Once, I did something for LABORATORY TEST. Migration (6 6.40) and Upgrade (7.0)in two other machines. But they were with Windows NLB. When I did the installation, for each server machine and during the instalation I had to give one Instance Number for each and in result there was a different Port Number for each.
    But I accessed both machines throught a virtual url(dns) with a specific port number. And it works!
    NOW, with a HARDWARE LOAD BALANCE _ CSS I don't know how to do.
    A guy who works with it  tell us that couldn't redirect one Port Number for different port numbers. He couldn't configure the CSS like this.
    My question is: Is he write? And if he is, there is a  way to give the same instance number for my 3 new Portal servers machines? Example: 5(02)00.
    Could you understand?
    I need help.
    Regards,
    cheers,
    Nivia

    Nivia,
    I have used F5 for load balancing, I am sure you can do the same with CSS. Yes, you can configure a virtual IP on the load balancer with standard ports (80 or 443) and load balancing the traffic to multiple servers with different ports. You can have different ports for each instance.
    -Regards
    RK

  • ORA-12535 error but TNSPing Works and listener logs connection

    We recently migrated our firewall and then started seeing this problem for users outside of our own subnet. However, although the user gets this error when launching the application, the workstation is able to TNSPing the server successfully and listener.log does log the connection.
    I was hoping someone might have some ideas or suggestions as to what might be causing the error despite the apparent connectivity to the database.
    Thanks in advance.

    Thanks so much for the suggestions.
    1. telnet <host> 1521 connects
    2. sqlplus <username>/<pwd>@<instance> returns the ORA-12535 error
    Finally, the sqlnet.log on the client side doesn't log anything when launching the application so I have no information as to what exactly is occurring at that point. However, the sqlplus command above logged the following:
    VERSION INFORMATION:
    TNS for 32-bit Windows: Version 9.2.0.1.0 - Production
    Windows NT TCP/IP NT Protocol Adapter for 32-bit Windows: Version 9.2.0.1.0 - Production
    Time: 26-JAN-2007 08:43:41
    Tracing not turned on.
    Tns error struct:
    nr err code: 0
    ns main err code: 12535
    TNS-12535: TNS:operation timed out
    ns secondary err code: 12560
    nt main err code: 505
    TNS-00505: Operation timed out
    nt secondary err code: 60
    nt OS err code: 0
    I've been doing more research on this -- please note that I'm not an Oracle dba so I am just getting familiar with lots of things -- and have learned that user connect requests come in through 1521 but are then randomly redirected to other ports. Given the new firewall, I'm wondering if it's an issue that the random ports being selected aren't open for the users outside of our subnet. Does this sound like a plausible explanation? If so, how do administrators generally handle this -- by opening the necessary ports on the firewall? Is there some other standard approach?
    Again, thanks so much for any assistance you can provide.

Maybe you are looking for