Can start method invoke twice at one instance

I am using JBoss and writing a class which extends Thead. I would like to ask can I invoke start() method twice to an instance of that class. I've tried it but it seems that the object did nothing when start() method is invoked at the second time.

Any Thread can only be start()ed once.
Also, prefer implementing Runnable to extending Thread. Think of Threads as the workers and Runnables as the job itself. You implement Runnable because your "unit of work" or whatever you want to call it IS-A Runnable -- that is, something that will do its job start-to-finish when you call run. You would only extend Thread if your class IS-A Thread -- that is, it has a reason to do everything Thread does, and you need to slightly add to or modify Thread's behavior.

Similar Messages

  • Can a method return more than one value?

    I was studying for my biology exam and I got bored and I started thinking and then I wandered if a method can return more than one value...?
    For example, if I want a method to return a row a column, I make a method that returns an int. But what if I want to return two ints? Or what If I want to return an integer and a string? Is it possible or do I have make two methods, each returning one thing?
    What I always did until now is is I want for example to return a few integers, I would store them in a String and then when I return the string, I parse the numbers out using stringtokenizer... but it doesn't look like the best way... and it's pretty annoying...

    I'm weak on terminology, hence I don't even know what
    AFAIK means...As Far As I Know
    This doesn't really make sense for me. It's more
    efficient to make a whole class just for two
    integers, than having two methods? Efficiency is not the point. The flow is.
    If you have two methods, the caller must be aware of both of them. The other way it's up to the callee.
    Just because the
    two integers are related to each other? Doesn't
    making a class require more memory usage than just
    making two one-line methods?The memory usage is not wholly irrelevant, but there are ways to handle that (caching, inlining, etc.).
    It's a bit hard to counter your point for me, but if you had done a lot of GUI painting stuff, you'd see all those Points, Dimensions, Rectangles, you name it, are quite invaluable.

  • Can you run iTunes twice on one computer?  Run two libraries on one compute

    My roommate and I both have iPods and share a computer but we have vastly different tastes in music. How can we both have our own iTunes libraries on one computer?

    There are a couple of ways you can do this, have a look at this guide: "How to use multiple iPods with one computer" http://docs.info.apple.com/article.html?artnum=300432

  • Can you not use more than one instance of Safari at a time

    I can't use my IE browser because of problems in my other post.
    I also need to have multiple windows or browser sessions open at once and Safari will only seem to open one session at a time.
    Is this the case?
    How do I get around it?
    If I open Safari, and click the Safari icon again it just sits there and won't open another session.
    Thanks,
    Tom

    Between "New window" and "New Tab," the tab is the way to go for the needs I believe you are expressing. However, tabbed browsing may not be enabled by default.
    To make the tab bar always visible--and therefore easily make new tabs by control-clicking the tab bar--open Safari Preferences. Select "Tabs" and, in that pref pane, select "Enable Tabbed Browsing" and "Always show tab bar." There are also some keyboard shortcuts shown there.

  • Process.Start(url) sometimes one instance fails

    I need some help!!!
    ASPX.NET/C#- Call Process.Start(url) several times, sometimes one instance fails without error!!
    I have a program that calls a http aspx.net with arguments(URL) to execute some stuff. That program are invoking 10 times that aspx.net (all in the same time) with diferents urls.
    But sometimes, one of the calls (url) do not launch in browser.
    Code is very simple:
    public partial class _Default : System.Web.UI.Page
    private Object thisLock = new Object();
    protected void Page_Load(object sender, EventArgs e)
    try
    string URL = Request.Params["URL"];
    Logger.Log("CURRENT URL TO LAUNCH->", URL);
    lock (thisLock)
    ProcessStartInfo startInfo = new ProcessStartInfo("IExplore.exe");
    startInfo.WindowStyle = ProcessWindowStyle.Maximized;
    startInfo.Arguments = URL;
    Process.Start(startInfo);
    catch (Exception ex)
    Logger.Log("Exception", ex);
    }The URL launch are a client side technology!And that´s because i need to open the IE in WebServer!It´s silverlight web application to generate reports!The silverlight application closes the IE instances after finish. Everything goes right, except sometimes in 10 requests one fail 
    Thanks

    What's the url do?
    Is it possibly that the url isn't ready or there?
    I can't recall ever doing process start from a web page.
    Maybe there's an alternative way of approaching whatever you're trying to do.
    BTW
    I think you should probably ask this question in the asp.net forum since there's actually no Silverlight in the mix there
    Hope that helps.
    Recent Technet articles: Property List Editing;
    Dynamic XAML

  • Can a method return multiple items

    Can a method return more than one thing?
    I want to have a method return a boolean and a String. My method is saying if something is right or wrong, then its saying the reason why.
    help, please.
    Thanx

    Afternoon_Delight wrote:
    My question is:
    Is there a way so that it can be more like this:
    public boolean, String checkValidity (){
    To expand on the previous posts, one way (not saying it's the best one!) is to create an object that combines the information that you want returned:
    public class MyValid
      private boolean valid;
      private String text;
      public MyValid(boolean valid, String text)
        this.valid = valid;
        this.text = text;
      public boolean isValid()
        return valid;
      public String getText()
        return text;
    class DoFoo
      public MyValid checkValidity()
        return new MyValid(false, "Because I said so!");
    }

  • One machine = One Instance

    Hi there,
    How can i prevent that more than one instance of my application from being created in the same machine. How can i rename the process associated to the application (instead of the usual javaw.exe)?
    Thanks for any help you can give me,
    Carlos Ferreira

    When I was writing for Windows, we did this via global
    Mutex objects. Your app (on startup) would attempt to
    create and get ownership of a global named Mutex
    (usually the App name). If you got ownership, you were
    the only one running.
    The problem here with Java is that you MIGHT be
    running multiple JVMs. Without access to a machine
    level Mutex, it is difficult to ensure One instance
    per machine (that behaves well following a crashor
    error).Um - you do realize that the suggested socket approach guarantees exactly this? I come up, and either I get the socket or I don't. If I fail - someone else is already running, exit. When I leave, or if I crash, the socket is automatically freed up for me.
    (And, having had to debug poorly-written Windows Mutex code, I know that mutexes can be left in odd states if the holder falls over while holding them. It's easy to code to notice and deal with this - but if you fail to do so, then your app fails to run again, unless/until you reboot the machine.)
    However, one could make use of JMS to simulate this.
    Lots of overhead to set up the client and server ends
    of this simply to ensure 1 application per machine,
    but it should work. We do have to assume that the
    application plays by the rules and attempts to
    validate its one-ness prior to startup.Ow. JMS is a hugely-overcomplicated tool to use for this straightforward application.
    And, regarding everyone "playing fair" - well, yeah, that's a given. But since what we're talking about here is two instances of the same program, then it pretty much by definition either plays the game, or it doesn't.
    Grant

  • Can I launch more than one instance?

    Can I launch more than one instance of the same AIR
    application?

    Check out page 309 of the AIR Dev Guide "Only one instance of
    an AIR application is started. When an already running application
    is invoked again, AIR dispatches a new invoke event to the running
    instance. It is the responsibility of an AIR application to respond
    to an invoke event and take the appropriate action (such as opening
    a new document window)."
    It looks like we have to handle this InvokeEvent.INVOKE event
    and programatically create a new instance of the application.
    If anyone's done this already an example would be a big help
    as this will be a VERY common use case.

  • Can I create more than one instance of a native library?

    Hello all,
    I am using Java to access a Win32 DLL with JNI. Everything is working fine, but I have several threads using the same instance of the native library because it is loaded "statically" in the Java class which uses it, and I suspect I am getting a bottle-neck at the native library.
    Does anyone know if there is any way to load more than one "instance" of a native library?
    The use of System.loadLibrary() would indicate not, and my (limited) knowledge of the Windows environment would tell me that a "shared" library only has on instance. (confirm anyone?)
    I need to find a way around this bottle-neck issue... (and "no", before anyone suggests it, I can't ditch Windows!)
    Thanks.

    I am not sure about the behaviour of the dll as it's not mine. It's a COM DLL which I have "wrapped" in a standard windows DLL so I can expose the JNI methods. I assume because it's COM that it IS reentrant, but I am a bit of a novice when it comes to Windows and COM. I didn't install the COMponent either, it was installed as part of another application. (It's an antivirus COM dll that is part of an AV application)
    Thanks for your help though, I think I will just have to live with it.

  • Getting Error :- Only one instance of COBRAS Export can be running at a time

    Hi All,
    I was checking the Briefcase Mode help file and it mentions for Unity Conection
    that COBRAS will run multiple instances of itself – if you schedule multiple backups to fire up at the same time they will all run at the same time.
    However if I schedule multiple backups to fire at the same time then I get the error :- "Only one instance of COBRAS Export can be running at a time".
    This also happens if the COBRAS windows is left open and the scheduled backup starts in the background.
    http://www.ciscounitytools.com/Applications/General/COBRAS/Help/COBRAS_Briefcase/COBRAS_Briefcase.htm#_Toc276653845
    I am not sure if I am making a mistake in understanding the statement :- "COBRAS will run multiple instances of itself – if you schedule multiple backups to fire up at the same time" or do we need to add any switch like lot of other application need like /m etc in the field of the scheduled backups as I see as /silent switch for process to run in background automatically but none for multiple instances.
    I am attaching the screen shots of the errors I got when
    A.) I scheduled 2 backups to run at the same time and the COBRAS application window was open "COBRASExportCUC7.exe" was running  and no backup took place and got errors for both the scheduled backups.
    And
    B.) I scheduled 2 backups to run at the same time and the COBRAS application window was closed off and "COBRASExportCUC7.exe" was not running and one of the scheduled backups started to work and the other one gave error and didn't work
    Unity Connection in use :- Version 8.0.3.20000-18
    Cobras Export :- Version 1.0 Build 76
    Please Suggest.
    Regards,
    Prad
    (E-Mail :- [email protected])

    Yeah, I’m of two minds on that – on the one hand it’s bad style to have a scheduled application popping dialog boxes (especially if you’re running as an account you don’t log in as regularly) – one the other hand I did have some sites go a while not noticing backups were failing (due to a UNC not flying any longer after a server reconfig) – folks can be bad about checking log files or the event log for issues.  A pop up would pretty much guarantee they’d notice on next login at any rate.
    I think I may stitch in email notifications in COBRAS Export in the same way they’re in the User Data Dump so failures of scheduled backups would be noticed right away (big, bright email in your box saying “failed!” would do it). 
    Either way, I’ll update the help and make sure it fails quietly for now when I update some other items on the site middle of next week.
    Thanks for the report.

  • Can a Method listen to more than one event in ABAP OO ?

    Hi,
    is it possible to prepare/register a handler method for e.g two events of two different classes ?
    Or can a method generally listen to only one event ?
    It seems that the syntax allows only one event ?
    methods event_handler for event my_event of my_class.
    Thanks for help in advance
    Olaf

    An event can refer to more than one object but you have to instantiate the objects
    for example   I have 2 grids and want to handle events depending on which grid
    the user is selecting / requesting actions on. (I've just posted the relevant bits coded here as data extraction etc you can code normally).
    FORM instantiate_grid
    * Create Grid container
    * Instantiate Grid class
    * Instantiate Event Handler class
    * Display the Grid
       USING  grid_container  TYPE REF TO cl_gui_custom_container
              class_object  TYPE REF TO cl_gui_alv_grid
              container_name TYPE scrfname.
    * create the container
      CREATE OBJECT grid_container
      EXPORTING container_name = container_name.
    * Create the ALV grid object using
    * container just created
      CREATE OBJECT  class_object
      EXPORTING
         i_parent = grid_container.
    *  Exclude the SUM function from the GRID toolbar
      ls_exclude = cl_gui_alv_grid=>mc_fc_sum.
      APPEND ls_exclude TO lt_exclude.
    * Instantiate our handler class
    * lcl_event_handler
      CALL METHOD class_object->register_edit_event
        EXPORTING
          i_event_id = cl_gui_alv_grid=>mc_evt_enter.
      CREATE OBJECT g_handler.
      SET HANDLER g_handler->handle_double_click FOR class_object.
      SET HANDLER g_handler->handle_hotspot_click FOR class_object.
      SET HANDLER g_handler->handle_toolbar FOR class_object.
      SET HANDLER g_handler->handle_user_command FOR class_object.
      SET HANDLER g_handler->handle_data_changed FOR class_object.
      SET HANDLER g_handler->handle_data_changed_finished FOR class_object.
    ENDFORM.                    "instantiate_grid
    MODULE status_0100 OUTPUT.
      IF grid_container IS INITIAL.
        PERFORM instantiate_grid
           USING grid_container
                 grid1
                 'CCONTAINER1'.
    * Grid title Primary Grid
        struct_grid_lset-grid_title = 'Delimit Old org Units - Selection'.
        struct_grid_lset-edit =  'X'.
        struct_grid_lset-sel_mode = 'D'.
        PERFORM display_grid
         USING
            grid1
             <dyn_table>
             it_fldcat.
      ENDIF.
      SET PF-STATUS '001'.
      SET TITLEBAR '000' WITH 'Delimit Old Org Units'.
    ENDMODULE.                    "status_0100 OUTPUT
    * PAI module
    MODULE user_command_0100 INPUT.
      CASE sy-ucomm.
        WHEN 'BACK'.
          LEAVE PROGRAM.
        WHEN 'EXIT'.
          LEAVE PROGRAM.
        WHEN 'CANC'.
          LEAVE PROGRAM.
        WHEN 'RETURN'.
          LEAVE PROGRAM.
      ENDCASE.
    ENDMODULE.                    "user_command_0100 INPUT
    MODULE status_0200 OUTPUT.
      IF grid_container1 IS INITIAL.
        PERFORM instantiate_grid
           USING grid_container1
                 grid2
                 'CCONTAINER2'.
    * Grid title  secondary grid
        struct_grid_lset-grid_title = 'Delimited Objects'.
        struct_grid_lset-edit =  ' '.
        PERFORM display_grid
         USING
            grid2
             <dyn_table1>
             it_fldcat1.
      SET PF-STATUS '001'.
      SET TITLEBAR '000' WITH 'Org Units Delimited'.
    endif.
    ENDMODULE.                    "status_0200 OUTPUT
    In your local event handling class use the variable SENDER to  determine which grid / object triggered the event
    for example
    CLASS lcl_event_handler DEFINITION .
      PUBLIC SECTION .
        METHODS:
    **Hot spot Handler
        handle_hotspot_click FOR EVENT hotspot_click OF cl_gui_alv_grid
                          IMPORTING e_row_id e_column_id es_row_no,
    **Double Click Handler
        handle_double_click FOR EVENT double_click OF cl_gui_alv_grid
                                        IMPORTING e_row e_column es_row_no
                                        sender,
    ** Toolbar handler.
    handle_toolbar
            FOR EVENT toolbar OF cl_gui_alv_grid
                IMPORTING e_object e_interactive
                sender,
    * button press
        handle_user_command
            FOR EVENT user_command OF cl_gui_alv_grid
                IMPORTING e_ucomm
                 sender,
    * data changed
    handle_data_changed
        FOR EVENT data_changed OF cl_gui_alv_grid
          IMPORTING er_data_changed,
    *data changed finished
    handle_data_changed_finished
         FOR EVENT data_changed OF cl_gui_alv_grid,
    download_to_excel.
    ENDCLASS.                    "lcl_event_handler DEFINITION
    * Implementation methods for lcl_event_handler
    CLASS lcl_event_handler IMPLEMENTATION.
    *Handle Hotspot Click
    * When a "hotspotted"cell is double clicked
    * Hotspot indicatore needs to be set in
    * the field catalog.
    * Not required for this application.
      METHOD handle_hotspot_click .
        PERFORM mouse_click
          USING e_row_id
                e_column_id.
        CALL METHOD grid1->get_current_cell
          IMPORTING
            e_row     = ls_row
            e_value   = ls_value
            e_col     = ls_col
            es_row_id = ls_row_id
            es_col_id = ls_col_id
            es_row_no = es_row_no.
        CALL METHOD grid1->refresh_table_display.
        CALL METHOD grid1->set_current_cell_via_id
          EXPORTING
            is_column_id = e_column_id
            is_row_no    = es_row_no.
      ENDMETHOD.                    "lcl_event_handler
    *Handle Double Click
      METHOD  handle_double_click.
        CASE sender.
          WHEN grid1.
    * returns cell double clicked  FROM GRID 1
    * Ignore any event from GRID 2
            PERFORM double_click
               USING e_row
               e_column.
        ENDCASE.
      ENDMETHOD.                    "handle_double_click
    * Add our buttons to standard toolbar
      METHOD handle_toolbar.
        CASE sender.
    * Only add functionality to PRIMARY GRID (GRID 1)
          WHEN grid1.
    * append a separator to normal toolbar
            CLEAR ls_toolbar.
            MOVE 3 TO ls_toolbar-butn_type.
            APPEND ls_toolbar TO e_object->mt_toolbar.
    * Delimit Org
            CLEAR ls_toolbar.
            MOVE 'PROC' TO ls_toolbar-function.
            MOVE icon_railway TO ls_toolbar-icon.
            MOVE 'DELIMIT' TO ls_toolbar-quickinfo.
            MOVE 'DELIMIT ORG UNIT' TO ls_toolbar-text.
            MOVE ' ' TO ls_toolbar-disabled.
            APPEND ls_toolbar TO e_object->mt_toolbar.
    * Select All Rows
            MOVE 'SELE' TO ls_toolbar-function.
            MOVE icon_select_all TO ls_toolbar-icon.
            MOVE 'ALL CELLS' TO ls_toolbar-quickinfo.
            MOVE 'ALL CELLS' TO ls_toolbar-text.
            MOVE ' ' TO ls_toolbar-disabled.
            APPEND ls_toolbar TO e_object->mt_toolbar.
    * Deselect all Rows.
            MOVE 'DSEL' TO ls_toolbar-function.
            MOVE icon_deselect_all TO ls_toolbar-icon.
            MOVE 'DESELECT ALL' TO ls_toolbar-quickinfo.
            MOVE 'DESELECT ALL' TO ls_toolbar-text.
            MOVE ' ' TO ls_toolbar-disabled.
            APPEND ls_toolbar TO e_object->mt_toolbar.
            ENDCASE.
         move  0 to ls_toolbar-butn_type.
         move 'EXCEL' to ls_toolbar-function.
         move  space to ls_toolbar-disabled.
         move  icon_xxl to ls_toolbar-icon.
         move 'Excel' to ls_toolbar-quickinfo.
         move  'EXCEL' to ls_toolbar-text.
         append ls_toolbar to e_object->mt_toolbar.
      ENDMETHOD.                    "handle_toolbar
      METHOD handle_user_command.
    * Entered when a user presses a Grid toolbar
    * standard toolbar functions processed
    * normally
       g_sender = sender.
        CASE e_ucomm.
          WHEN 'PROC'.    "Process selected data
            PERFORM get_selected_rows.
          WHEN 'SELE'.
            PERFORM select_all_rows.
          WHEN 'DSEL'.
            PERFORM deselect_all_rows.
          WHEN 'EXCEL'.
              call method me->download_to_excel.
            WHEN OTHERS.
        ENDCASE.
      ENDMETHOD.                    "handle_user_command
      METHOD handle_data_changed.
    * only entered on data change  Not req for ths app.
        PERFORM data_changed USING er_data_changed.
      ENDMETHOD.                    "data_changed
      METHOD handle_data_changed_finished.
    * only entered on data change finished  Not req for ths app.
        PERFORM data_changed_finished.
      ENDMETHOD.                    "data_changed_finished
    * Interactive download to excel
      method download_to_excel.
      field-symbols:
       <qs0>   type standard table,
       <qs1>   type standard table.
      data: G_OUTTAB1 type ref to data,
            g_fldcat1 type ref to data,
            LS_LAYOUT type KKBLO_LAYOUT,
            LT_FIELDCAT type KKBLO_T_FIELDCAT,
            LT_FIELDCAT_WA type KKBLO_FIELDCAT,
            L_TABNAME type SLIS_TABNAME.
    case g_sender.
      when grid1.
         get reference of <dyn_table> into g_outtab1.
         get reference of it_fldcat into g_fldcat1.
       when grid2.
       get reference of <dyn_table1> into g_outtab1.
         get reference of it_fldcat1 into g_fldcat1.
    endcase.
       assign g_outtab1->* to <qs0>.
        assign g_fldcat1->* to <qs1>.
           call function  'LVC_TRANSFER_TO_KKBLO'
          exporting
            it_fieldcat_lvc   = <qs1>
    *     is_layout_lvc     = m_cl_variant->ms_layout
             is_tech_complete  = ' '
          importing
            es_layout_kkblo   = ls_layout
            et_fieldcat_kkblo = lt_fieldcat.
        loop at lt_fieldcat into lt_fieldcat_wa.
          clear lt_fieldcat_wa-tech_complete.
          if lt_fieldcat_wa-tabname is initial.
            lt_fieldcat_wa-tabname = '1'.
            modify lt_fieldcat from lt_fieldcat_wa.
          endif.
          l_tabname = lt_fieldcat_wa-tabname.
        endloop.
        call function 'ALV_XXL_CALL'
             exporting
                  i_tabname           = l_tabname
                  is_layout           = ls_layout
                  it_fieldcat         = lt_fieldcat
                  i_title             = sy-title
             tables
                  it_outtab           = <qs0>
             exceptions
                  fatal_error         = 1
                  no_display_possible = 2
                  others              = 3.
        if  sy-subrc <> 0.
          message id sy-msgid type 'S' number sy-msgno
                 with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
        endif.
    endmethod.
    ENDCLASS.                    "lcl_event_handler IMPLEMENTATION
    The sender instance is a variable such as  g_sender type ref to cl_gui_alv_grid.       "Sender instance.
    The above example is for OO ALV grids but should work for other interactive cases where a User presses a key or does a mouse action.
    Cheers
    jimbo

  • Can a thread's start() method be called more than once?

    Is it legal/well-defined to call a Thread object's start() method after a previous call to start() has completed?
    eg.
    Thread t = new Thread(public void run() {...});
    t.start();
    t.join();
    t.start(); // will this call fail?

    Ok, since no one's going to answer you I will.
    Yes. It won't work if you call start() multiple times and it will throw an exception on all subsequent times.
    The way I work around it is to put the method in an inner-class and then create a new instance of that iner-class everytime I want to start a new thread.

  • Listener ( lsnrctl ) - stop and start just one instance

    Hey all. I hava a Oracle 9.2 installed over a Linux Red Hat 4.0 64 bits server.
    Some Virtual Machines will connect in some databases installed in my Oracle server. My listener has one instance for each database like this:
    SID_LIST_LISTENER =
    (SID_LIST =
    (SID_DESC =
    (GLOBAL_DBNAME = VM01)
    (ORACLE_HOME = /opt/oracle/product/9.2.0)
    (SID_NAME = VM01)
    (SID_DESC =
    (GLOBAL_DBNAME = VM02)
    (ORACLE_HOME = /opt/oracle/product/9.2.0)
    (SID_NAME = VM02)
    (SID_DESC =
    (GLOBAL_DBNAME = VM03)
    (ORACLE_HOME = /opt/oracle/product/9.2.0)
    (SID_NAME = VM03)
    LISTENER =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = IPC)(KEY = VM01))
    (ADDRESS = (PROTOCOL = IPC)(KEY = VM02))
    (ADDRESS = (PROTOCOL = IPC)(KEY = VM03))
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = lab2)(PORT = 1521))
    And my tnsnames:
    VM03 =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = lab2)(PORT = 1521))
    (CONNECT_DATA =
    (SERVICE_NAME = VM03)
    VM02 =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = lab2)(PORT = 1521))
    (CONNECT_DATA =
    (SID = VM02)
    VM01 =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = lab2)(PORT = 1521))
    (CONNECT_DATA =
    (SERVICE_NAME = VM01)
    I need to start and stop just one instance (VM01 or VM02 or VM03). I really can't stop all instances when I need to stop just one. And more if i have to create another instance i will have to stop the listener... and i can't because other people are using your instance...
    Do you know how to help me?
    Thanksssssss

    You still use listener.ora, just create 3 listeners, one for each instance:
    listener.ora:
    LISTENER_VM01 =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = IPC)(HOST = lab2)(KEY = VM01))
    (ADDRESS = (PROTOCOL = TCP)(HOST = lab2)(PORT = 1521))
    SID_LIST_LISTENER_VM01 =
    (SID_LIST =
    (SID_DESC =
    (GLOBAL_DBNAME = VM01)
    (ORACLE_HOME = /opt/oracle/product/9.2.0)
    (SID_NAME = VM01)
    LISTENER_VM02 =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = IPC)(HOST = lab2)(KEY = VM02))
    (ADDRESS = (PROTOCOL = TCP)(HOST = lab2)(PORT = 1522))
    SID_LIST_LISTENER_VM02 =
    (SID_LIST =
    (SID_DESC =
    (GLOBAL_DBNAME = VM02)
    (ORACLE_HOME = /opt/oracle/product/9.2.0)
    (SID_NAME = VM02)
    LISTENER_VM03 =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = IPC)(HOST = lab2)(KEY = VM03))
    (ADDRESS = (PROTOCOL = TCP)(HOST = lab2)(PORT = 1523))
    SID_LIST_LISTENER_VM03 =
    (SID_LIST =
    (SID_DESC =
    (GLOBAL_DBNAME = VM03)
    (ORACLE_HOME = /opt/oracle/product/9.2.0)
    (SID_NAME = VM03)
    Then, when you need to stop the connections to only one instance, you stop the corresponding listener:
    lsnrctl stop listener_vm02
    lsnrctl start listener_vm02
    For each instance you need to configure the parameter local_listener:
    sys@VM01> alter system set local_listener=listener_vm01;
    sys@VM02> alter system set local_listener=listener_vm02;
    sys@VM03> alter system set local_listener=listener_vm03;
    And register in tnsnames.ora:
    listener_vm01=
    (DESCRIPTION=
    (ADDRESS=(PROTOCOL=tcp)(HOST=lab2)(PORT=1521)))
    listener_vm02=
    (DESCRIPTION=
    (ADDRESS=(PROTOCOL=tcp)(HOST=lab2)(PORT=1522)))
    listener_vm03=
    (DESCRIPTION=
    (ADDRESS=(PROTOCOL=tcp)(HOST=lab2)(PORT=1523)))
    It's a recommended configuration for the flexibility it provides,it requires a different port for each listener, but you don't need to edit the listener.ora file each time you need to stop the connectivity to only one instance.

  • Have one instance on linux running one database.can i create more databases to sam

    i have one instance on linux running one database.can i create more databases to same instance and they all remain up .

    you can create more than one database (Instance) on the same machine, start up all of them, in the connect string write the Instance name you want to work with.
    null

  • I have multiple devices in my family. Each of us has an iPhone and an iPad. Is there a way for each of us to have our own Apple ID but one account so we can all get the same music, movies, books, etc. I can't see paying twice for something in the same fam

    I have multiple devices in my family. Each of us has an iPhone and an iPad. Is there a way for each of us to have our own Apple ID but one account so we can all get the same music, movies, books, etc. I can't see paying twice for something in the same family.

    Welcome to the world of digital media. Your can't really transfer it. I don't know what the rules are about transferring to your spouse but I do know that in some cases when you die, your heirs cannot inherit your digital media. This is why there is still an advantage to buying the CD since the usage rights belong to whomever holds the physical media.
    A possible workaround is to burn the songs to a music CD with yout account (tracks only without song titles) and then having your wife upload it as a regular music CD onto her account. It's been a while since i've done this so I'm not sure if it would work now.
    Please note that I'm not advocating copyright and/or TOS violations. I'm only suggesting ways to copy music for your own personal use which has traditonally been permitted. I only did this because I wanted to convert iTunes songs to mp3 files so I could burn them onto a data CD for use in my car. It would make sense that since married couples are a joint entity, this would be personal use.
    Also, I'm not a lawyer so don't take this as legal advice.

Maybe you are looking for

  • Sap business one studio 9.0 for microsoft visual studio 2010

    Hi Experts, After added a new project, Sap business one 9.0 Add-on Project, that project can't be loaded in Visual Studio 2010. When try to re-load the project in the Solution Explorer, the project stays as (unavailable), and the next line says, The

  • Why can't I download a purchased iTunes movie on to one of my authorized computers

    Why can't I download a purchased movie from iTunes onto one of my authorized computers? I keep getting a request to purchase the movie. Message was edited by: OrionFemale

  • Exporting a video for email

    What is the best way to export a video from fce to attach to a email. The video is about 10 min long. I have it in a meg-4 format and it is about 26 mb and I need to get it down to 10mb. Thanks!

  • Problem with order conformation

    I have created process order for finished goods, and issued materials against that order using transaction:migo and movement type is 261, the order status is at this stages is as fallows rel, prec, basc, bcrq, gmps, macm, pign, setc. but wen i do the

  • Flash Builder 4: "Flex 2 is not supported; use Flex 3.0.0 or higher "

    In our project we have to maintain an application developed in Flex 2, but we have licensed Flash Builder 4, which is now available for Adobe only. When we tried to configure Flash Builder 4 with Flex 2 SDK we get the following error: "Flex 2 is not