UNABLE TO RETRIEVE THE CLIENT IP ADDRESS AND HOST NAME OF A PORTAL USER

I'm trying to retrive the client IP address and host name of a portal user
trying to access a portal page using APIs:
PortletRenderRequest portletRequest =
(PortletRenderRequest)request.getAttribute(HttpCommonConstants.PORTLET_RENDER_REQUEST);
HttpServletRequest servletRequest =
(HttpServletRequest)portletRequest.getAttribute(HttpCommonConstants.SERVLET_REQUEST);
String l_szClientIPAddress = servletRequest.getRemoteAddr();
String l_szClientHost = servletRequest.getRemoteHost();
but i found that for all portal users on different machines IP addresses, the
returned IP is the same for all which is Portal middle tier IP address.
So how can retrive the IP addess of a portal user trying to access a portal
page ?

Brijesh,
Do you mean how to see hostname/ip address of client requests processed by the server? If yes, depending on what's your front ending component - Web Cache or OHS, you can configure the access log format to have this information recorded in either of these component's access log file.
For Web Cache access log file, refer this:
http://download.oracle.com/docs/cd/B14099_19/caching.1012/b14046/diagnostics.htm#sthref2090
For OHS access log file, refer this:
http://download.oracle.com/docs/cd/B14099_19/web.1012/b14007/servlog.htm#sthref439
By default, both Web Cache and OHS are configured to use Common Log Format (CLF) that does record hostname/ip address so if you haven't made any changes to log format, this info is already there for you. Look for $ORACLE_HOME/webcache/logs/access_log file for Web Cache and $ORACLE_HOME/Apache/Apache/logs/access_log file for OHS.
Thanks
Shail

Similar Messages

  • How to retrieve the client IP address when Apache acts as a proxy for Tomca

    Hello,
    I am trying to retrieve the client IP address accessing the web
    services. Because Apache is our proxy for all requests, when I try to
    retrieve the client IP I always get the localhost IP: 127.0.0.1
    The following code returns the localhost IP:
    MessageContext msgContext = MessageContext.getCurrentContext();
    if(msgContext != null) {
    return msgContext.getProperty(Constants.MC_REMOTE_ADDR).toString();
    return "Unknown";
    From a servlet, obtaining the client IP address can be achieved using
    this code.
    String ipAddress = request.getHeader("x-forwarded-for");
    if (ipAddress == null) {
    ipAddress = request.getHeader("X_FORWARDED_FOR");
    if (ipAddress == null){
    ipAddress = request.getRemoteAddr();
    return IPaddress ;
    Any help is greatly appreciated.
    Thank you very much

    @ejp....
    thanks buddy....
    u made my world a better place to live.....

  • Migrate Active Directory 2008 to 2012 but need to keep the same ip address and server name

    Hi,
    Current setup is 2 DCs in one site running 2008 R2 AD.
    We are planning to migrate from 2008 R2 to 2012 R2 but need to keep the same ip address and server name. I have came up two plans to do this and hope someone can tell me which one would be the best approach. What is the pros
    and cons in Plan A and B or may be plan C if there is a better one?
    First, I was planning to do plan A but just had a second thought of Plan B.  My concern in Plan A is about changing the server name when the new 2012 R2 already running as DC.  Plan B would be changing all the old server
    name and ip before they become member sever and DC. 
    Any information and suggestion would be very appreciated.
    Plan A
    Run adprep /forestprep on 2008 R2 DC
    Build a new 2012 R2 server and promote it as 3rd DCs in current Domain
    Transfer FSMO from 2008 R2 to 2012 R2
    Run Repadmin /syncall to force replication
    Rename the demoted 2008 R2 DC to something else
    Change the demoted 2008 R2 ip address to something else
    Restart the demoted 2008 R2 server to take effect
    Now, run Netdom computername command to change the new 2012 R2 server name to the old 2008 R2 DC server name
    Change the new 2012 R2 DC's ip to old 2008 R2 DC's ip
    Run ipconfig /flushdns
    Run ipconfig /registerdns
    DCDIAG to see any error
    Plan B
    Build 2 new 2012 R2 standalone servers
    In 2008 R2 ServerA transfer FSMO to 2008 R2 ServerB
    Demote 2008 R2 ServerA to become member server
    Rename 2008 R2 ServerA to something else and change the ip address to something else and shut it down
    Now, rename one of the new 2012 R2 standalone server to the old demoted 2008 R2 ServerA name
    Change the new 2012 R2 standalone server ip to the old demoted 2008 R2 ServerA's ip address
    Add the new 2012 R2 standalone server (now with the old 2008 R2 ServerA name and ip) to become member server
    Run adprep /forestprep on the 2008 R2 ServerB
    Promote the new 2012 R2 (now with the old 2008 R2 ServerA name and ip) as DC
    Transfer 2008 R2 ServerB FSMO to the new 2012 R2 DC (now with the old 2008 R2 ServerA name and ip)
    Demote 2008 R2 ServerB as member server
    Rename 2008 R2 ServerB to something else and change the ip address to something else and shut it down
    Now, rename the 2nd new 2012 R2 standalone server to the old demoted 2008 R2 ServerB name
    Change the new 2012 R2 standalone server ip to the old demoted 2008 R2 SeverB 's ip address
    Add the 2nd new 2012 R2 standalone server to become member server
    Promote it as DC
    Run DCDIAG to check error
    Thanks.

    Hi,
    Renaming a Domain Controller is a risky operation which may lead to issues, therefore, I would suggest you go with the Plan B, rename the server before it becomes DC.
    Here is a blog below which could be helpful to you:
    Remove an Old DC and Introduce a New DC with the Same Name and IP Address
    http://blogs.msmvps.com/acefekay/2010/10/09/remove-an-old-dc-and-introduce-a-new-dc-with-the-same-name-and-ip-address/
    Best Regards,
    Amy
    Please remember to mark the replies as answers if they help and un-mark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]

  • Need to change IP address and host name on a ORACLE 10g RAC setup.

    Hi Forum,
    I have a task to change the IP address, host name and host related details for the ORACLE 10g RAC 2 node setup. So Can anyone tell me the procedure to do the same on both the nodes.
    Regards
    Prakash

    change IP Address Public + VIP + Interconnect
    http://surachartopun.com/2007/01/i-want-to-change-ip-address-on-oracle.html
    change VIP name
    http://surachartopun.com/2009/01/change-vip-hostname-on-oracle-rac.html
    If you'd like to change HOSTNAME... Metalink (NOTE:220970.1)
    Can I change the public hostname in my Oracle Database 10g Cluster using Oracle Clusterware?
    Hostname changes are not supported in Oracle Clusterware (CRS), unless you want to perform a deletenode followed by a new addnode operation.
    The hostname is used to store among other things the flag files and Oracle Clusterware stack will not start if hostname is changed.
    Changing the Private Interconnect
    o Change of the IP Address: change the IP address in the hosts file and/or DNS and make sure that ASM and the database also use the same interconnect
    o Change of the private node name used by Oracle Clusterware: requires a reinstall of Oracle Clusterware
    So, Public or Private hostnames can only be changed by removing/adding nodes, or reinstalling Oracle Clusterware. VIP Hostnames can be changed
    But you can read this idea (reinstall CRS)
    http://www.pythian.com/news/482/changing-hostnames-in-oracle-rac
    http://surachartopun.com/2008/12/change-hostnames-oracle-rac.html
    Edited by: Surachart Opun (HunterX) on Oct 25, 2009 10:58 PM

  • Register IP address and host name of SAP Router

    Does anyone think there would be a problem if we register one IP address now and then register another one later, replacing the first?
    Thanks.

    I think that It isn't problem
    Check SAP  Note 126645 - SAP provider remote connection data sheet
    In the message explain your question
    Regards
    William Neira

  • Get the client IP address

    Hello everybody, I'm a student new with java, I'm developing a little server application - running standalone, and I'm trying to get the client Ip address, have a look on my code snippet:
    InetAddress fromcli;
    while(true){
    welcomeSKT.accept()
    fromcli = welcomeSKT.getInetAddress();
    System.out.println("The client Ip Address is: " + fromcli.getHostAddress() + '\n');
    The sysout println returns the 0.0.0.0 that is the server address, mapped to more than one interface eg:(loopback and eth0) - But if with the getInetAddress() method I get the server address where is the difference with the getLocalHost()? - By the way, anyone has a suggestion to print out the client remote address.
    Thank you in advance....
    Jeppojeps
    Edited by: jeppojeps on Mar 24, 2008 3:36 AM

    Oh, sorry of course welcomeSKT is a ServerSocket, actually the snippet that I put is a part of the code, here below I put the complete program, in order to clarify my question, however I would like to know if it's possible to understand from the server side the client IP address, and if yes how...
    Thank you in advance...
    * THIS simple TCP server receives some numbers in input by the client and give back the sum - actually the exceptions are managed in a uncomplete way....but this is my first java program...be patient with me...
    * @jeppojeps
    * @0.1
    import java.io.*;
    import java.net.*;
    public class ServerTCP
    // instance variables - replace the example below with your own
    public static void main(String[] args) throws Exception
    String clientSentence;
    String capitalized;
    InetAddress fromcli;
    String clientIp;
    String portIp;
    int z=0;
    int port=0;
    if (args.length == 0 ){
    System.out.println("Usage: ServerTCP lport" + '\n');
    System.exit(-1);
    else
    port = Integer.parseInt(args[0]);
    if(port <= 1024) {
    System.out.println("Remember dude, only root can use a portnumber < 1024" + '\n');
    else{
    ServerSocket welcomeSKT = new ServerSocket(port);
    System.out.println("Server instance started:" + '\n');
    while(true){
    Socket connectionSocket = welcomeSKT.accept();
    BufferedReader InfromClient = new BufferedReader (new
    InputStreamReader(connectionSocket.getInputStream()));
    DataOutputStream outToClient =
    new DataOutputStream(connectionSocket.getOutputStream());
    outToClient.writeBytes("Hello give me some numbers and I'll give you the sum" + '\n');
    fromcli = welcomeSKT.getInetAddress();
    System.out.println("The client Ip Address is: " + fromcli.getHostAddress() + '\n');
    clientSentence = InfromClient.readLine();
    for(int i = 0 ; i < clientSentence.length() ; i++) {
    try {
    Character c = new Character(clientSentence.charAt(i));
    capitalized = c.toString();
    int x = Integer.parseInt(capitalized);
    System.out.println("Number digited from the client: " + x + '\n');
    z+=x;
    catch(NumberFormatException nfe) {
    System.out.println("Text: " + clientSentence.charAt(i));
    capitalized = Integer.toString(z);
    outToClient.writeBytes("The sum of the given number is: " + capitalized + '\n');
    welcomeSKT.close();
    }

  • How to print the client ip address at the server side( reqd for logging )??

    Hello everybody...
    joined this forum recently.....
    In RMI programming.... is there any way by which the server can know the the Client ip address or machine name.... i want to know this bcoz i need to create a log file as to who all had connected withe the server..
    need a solution soon..... thanks in advance....

    @ejp....
    thanks buddy....
    u made my world a better place to live.....

  • Change IP and Host name of the server

    Hi,
    Db :11.2.0.3
    Os:Aix6
    OS team are going change IP address and host name of the server which has ASM and DB.
    What are the things we need to follow for this?
    Thanks & Regards,
    VN

    OS team are going change IP address and host name of the server which has ASM and DB.
    What are the things we need to follow for this?1. TNSNAMES.ORA files everywhere
    2. LISTENER.ORA on server
    If there are thin JDBC clients, change IP/hostname in their connection URLs.

  • Unable to retrieve the operations and entities during service introspection

    Hi,
                      I created one sample flex mobile project using flash builder 4.5, i would like to invoke the web service (wsdl file), which is developed in java and hosted in remote machine server.i want to call a one getEmployeeList method from the webservice.
                          In flash builder i used the menu Data->connect to web service , i gave the url, changed the service name and package name, after that i clicked next button,
    the service introspection dialog appears and after a few seconds, flash builder 4.5 shows the message "Unable to retrieve the operations and entities from the web service" and "There was an error during service interospection".
                       I try to open the url in the browser window i could able to see the wsdl file.so, please help me to solve this issue!
    Thanks & Regards,
    siva
    Message was edited by: siva csc

    same problem also on my xampp installation , it worked perfect with REST service in the previous flex 3 release , is it my apache conf or something related on Flash builder
    this happens when I call my function that connect to mysql do the query and returns the array object
    Err log from Flash Builder 4:
    There was an error during service introspection.
    <br /><b>Warning</b>:  require_once(Zend/Loader/Autoloader.php) [<a href='function.require-once'>function.require-once</a>]: failed to open stream: No such file or directory in <b>C:\xampp\htdocs\MYAPP\bin-debug\gateway.php</b> on line <b>23</b><br /><br /><b>Fatal error</b>:  require_once() [<a href='function.require'>function.require</a>]: Failed opening required 'Zend/Loader/Autoloader.php' (include_path='.;C:\xampp\php\pear\;C:/xampp/htdocs/ZendFramework/library') in <b>C:\xampp\htdocs\MYAPP\bin-debug\gateway.php</b> on line <b>23</b><br />
    thanks in advance
    P

  • Why does viber keep asking me to set up again? I have   it up about 3 times now and if I don't have my mobile  when overseas will be unable to retrieve the sms code. I am using an ipad mini

    Why does viber keep asking me to set up again when I have already set it up about 3 times and used it successfully. Will be overseas without my mobile and will be unable to retrieve the sms code to set it up if this happens when I am away so should I reinstall it ?

    ISSUE FINALLY RESOLVED!!!!!!
    So, it turns out, I had to restore the iPhone...with a twist! Here are the steps:
    FIRST BACK UP YOUR DEVICE
    1. Go to the library (Hold option, click on "go" in the finder, then go to library)
    2. Go to your iTunes folder in this Library (not application support, the main iTunes folder)
    3. Go to the iX software folder (i.e., iPhone software, iPad software, etc.) and delete the file in this folder
    4. Hook up the phone and then click on restore iPhone.
    At this point, it will redownload the entire OS again. You must then restore the iPhone. As it is downloading the iOS, you can disconnect and use your phone for probably however long you want (I did the restore the same day as the download) and when you are ready you can hook up the phone and restore it.
    THE MOST IMPORTANT STEP FOLLOWS:
    And one many may dislike. Upon restoring the phone, you MUST select "Set-Up as new iPhone"
    You need to make sure you've backed up EVERYTHING elsewhere. 3rd party, non-apple/icloud apps will lose data through this method, and you'll lose all texts, your call history, and super old voicemails. The upside is that, if you've backed up, then you can just restart the process if you forgot something. But seeing as how the popup was interfering with my ability to use iCloud (I couldn't sync anything, such as calendar events, reminders, etc.,  unless I had gone into mail to sign in to iCloud), it was totally worth it....no more popups.
    My only wish is that this thread becomes popular. Many people have this issue and you should only use this method as a super last resort (after trying literally everything I had written previously).

  • I am automating the process of sending appointment reminders to my clients. I started with an alert with an email in calendar using the clients email address as a custom entry in my me card in my contacts. this was resulting in three emails being sent wit

    I am automating the process of sending appointment reminders to my clients. I started with an alert with an email in calendar using the clients email address as a custom entry in my me card in my contacts. this was resulting in three emails being sent with slightly different versions of the same address (see my previous post). Heating someone else's suggestion I created a workflow file to send an email and calling that file from an alert on my calendar. This is working and sends only one email to the client.
    My calendar is on I cloud and I access it from three different computers so I can keep my appointment calendar current. The files that send the email only exist on one computer. My other computers show error messages when those emails get sent. It seems that each computer wants to send the email. It's a small problem but is there a way that I could not get those alerts.
    But appreciate any thoughts about this. It seems like both problems might be related to the iCloud system.
    Thank you in advance,
    Michael

    Good work, catch so far Michael, does seem to be a "feature" of iCloud syncing, not sure what you could do to disable it.

  • Need Help: Web Analysis, Unable to retrieve the data & Security Tab missing

    Hi
    I'm new to Hyperion (our version: 9.2.1) and we're implementing Hyperion Planning. One of the reporting tools is Web Analysis.
    I'm trying to create simple grid reporting. but I'm unable to retrieve the data instead the result is "n/a"
    and
    The File's Properties > Security tab is missing
    Does anyone know my issue?
    Thanks,

    Hi Experts,
    You told its resolved.how?
    I am having the same issue i am unable to retrive the tables.
    "Database:MS SQL Server
    Driver :weblogic.jdbcx.sqlserver.SQLServerDataSource.
    Connection String:jdbc:weblogic:sqlserver://localhost:1433;databaseName=BAM"
    Please help if you have resolved this issue.Any helpful links plz forward [email protected]
    Thanks

  • Unable to retrieve the list of Standard Reports

    Hi,
    User needs an aging report in PW90 paper but gets an error message when clicking on to the report tab once logged into SAP portal.
    Error message:
    Unable to retrieve the list of Standard Reports. Please call the Help Desk to report the problem. Error encountered while connecting to R/3. java.lang.NullPointerException.
    I checked the java support in Internet explorer and deleted the cookies and temporary files but he kept having the same issue.
    Please Help on this !!
    Thanks in advance.

    Hi,
    Try to restart the portal server.
    Regards,

  • CR for Enterprise 4.0: Unable to retrieve the datasource configuration

    Hello Experts, I have the following issue with CR for Enterprise: I can successfully connect to our BI server, but when I select a universe I would like to build a report on, I receive the following error message about the validity of my data source: "Unable to retrieve the datasource configuration: com.crystaldecisions.thirdparty.org.omg.CORBA.UNKNOWN minor code: 0x0 completed: No". The universe I am trying to connect to is based on a relational connection and was built using the IDT 4.0 SP 1.
    Thanks a lot for any guidance on how this could be resolved.
    Sergey

    Hi Surgey,
    Well that is very strange! Is Crystal Reports for Enterprise installed on the server machine or on the local workstation?
    If we are using Crystal Reports for Enterprise which is installed on a sperate workstation, try installing it on the server machine and then try to connect to universe.
    - Kuldeep G

  • Unable to join the client machine into domain in low banswidth 16kbps

    Hi,<o:p></o:p>
    I'm unable to join the client machine into domain which is in low bandwidth 16 kbps.but i can able join other machine into domain which is having
    more bandwidth,please help me on this issue<o:p></o:p>

    Depending on the version of your domain, you could try an offline join.
    http://technet.microsoft.com/en-us/library/offline-domain-join-djoin-step-by-step(v=WS.10).aspx
    Paul Bergson
    MVP - Directory Services
    MCITP: Enterprise Administrator
    MCTS, MCT, MCSE, MCSA, Security, BS CSci
    2012, 2008, Vista, 2003, 2000 (Early Achiever), NT4
    Twitter @pbbergs http://blogs.dirteam.com/blogs/paulbergson
    Please no e-mails, any questions should be posted in the NewsGroup.
    This posting is provided AS IS with no warranties, and confers no rights.
    I would say that it depends on the client OS (Windows 7 or Windows 8) if offline domain join could be used or not, not that much regarding the level of the domain, you can always use the
    /downlevel switch to target a DC running Windows Server 2003 for example.
    Enfo Zipper
    Christoffer Andersson – Principal Advisor
    http://blogs.chrisse.se - Directory Services Blog

Maybe you are looking for

  • Why is an Apple Mail message taking 41kb for a few sentences?

    Well - this isn't actually my own use of Apple Mail - but a friend is using it and they're getting these huge messages with a tiny amount of content. Is there a way to fix their emails so that the HTML isn't so cluttered? THANKS! Here's what the emai

  • Windows 2012 r2 802.1X MAC Address bypass configuration

    I am setting up MAB for my environment and I want to make sure I am setting it up correctly, as I see some articles stating there is a reg edit needed and others that don't mention it at all. I have Dell PowerConnect switch with 802.1X authentication

  • Smaller in size

    Oracle AS: 10.1.2.0.2.0, Linux box I am running reports from the Oracle AS FORM based application. One of my report has plus 42000 pages. I can run this report from thr ulr but can not run from the application. I am getting error as below: Error: Fin

  • St03n : no display Day, Week, Month in Workload tree

    hi all Environment : ECC 6.0 sp13, Oracle10g I can`t see workload data currently and weekly, only see old Data 01/2008 in Month. No display Day, Week in Workload tree and no display week data on TOTAL, Only see today in Day and 01/2008 in Month on TO

  • How can I send a .pdf attachement using maildemo_sql.txt

    Hi I have created a PL/SQL package using the following link. Could you plese tell me how can I send a .pdf as an attachement using the follwing package? http://www.oracle.com/technology/sample_code/tech/pl_sql/htdocs/maildemo_sql.txt regards