6 Replies Latest reply on Jul 27, 2012 4:06 PM by pragnyas

    changing node UUID

    pragnyas

      Hi,

       

       

      2 questions here...

       

      Like you can see I have setup my custer using mod_cluster and works fine.. am using Jboss AS 7.1.2 and mod_cluster 1.2.0 final

       

       

      Now how do I change my node UUID, rather than some random number... I woudl like ot have a value of my choice.  which is user friendly and helps others tounderstand which/server or node its binded tooo... rather than doing a nslookup to findout which node/server it is....

       

       

       

      Also.. is there any how to document on how do I create new virtual host on Jboss and bind my apps to that virtual host rather than using default-host ?

       

       

       

       

       

      mod_cluster/1.2.0.Final

      Auto Refresh show DUMP output show INFO output

      Node aa416853-32e3-367c-a56b-03e5aaca504d (ajp://192.168.10.23:8409):

      Enable Contexts Disable Contexts

      Balancer: mycluster,LBGroup: ,Flushpackets: Off,Flushwait: 10000,Ping: 10000000,Smax: 1,Ttl: 60000000,Status: OK,Elected: 0,Read: 0,Transferred: 0,Connected: 0,Load: 100

      Node 8641a665-d4fb-3c29-97ef-7fde82a0c243 (ajp://192.168.10.23:8509):

      Enable Contexts Disable Contexts

      Balancer: mycluster,LBGroup: ,Flushpackets: Off,Flushwait: 10000,Ping: 10000000,Smax: 1,Ttl: 60000000,Status: OK,Elected: 20,Read: 71183,Transferred: 100,Connected: 0,Load: 99

      Virtual Host 1:

      Contexts:

      /application, Status: ENABLED Request: 0 Disable 

      Aliases:

      default-host

      example.com

      localhost

        • 1. Re: changing node UUID
          pferraro

          You can override the node identifier in one of a few ways:

          * By specifying a "jboss.mod_cluster.jvmRoute" system property (recognized by mod_cluster)

            * By specifying a "jboss.jvmRoute" system property (recognized by JBoss Web and Tomcat)

          * By defining a specific instance-id attribute in the web subsystem

           

          As for defining virtual hosts:

          https://community.jboss.org/wiki/VirtualHostsWithJBossAS7

          • 2. Re: changing node UUID
            pragnyas

            Paul,

             

             

             

            I ;am sorry am a newbie for Jboss... can you please give a ow to kind of exlanation on how to do this for UUID.. Thank you in advance,

             

             

            How can I do it in mod_cluster.. so it oudl be easy for me...

             

             

            P

            • 3. Re: changing node UUID
              pferraro

              e.g.

              To override the node ID using a system property:

              $ ./standalone.sh --server-config=standalone-ha.xml -Djboss.mod_cluster.jvmRoute=node1

               

              To override the node ID via the web subsystem:

              <subsystem xmlns="urn:jboss:domain:web:1.2" default-virtual-server="default-host" native="false" instance-id="node1">

              ...

              </subsystem>

               

              Either will work.

              • 4. Re: changing node UUID
                pragnyas

                Paul,

                 

                 

                Thanks fo rthe quick reply.. however am sorry fo rthe trouble.. I used domain mode.. I know we can run the same command for domain.sh

                 

                 

                but my question is.. if I have 2 nodes.. node1 and node2.. and I have 2 server instances per node.. S1 and S2 on node1, also. s1 and S2 on node2..

                 

                What am looking for is.. mod_cluster to display...

                 

                node1_s1 (ajp://........)

                 

                node1_s2 (ajp://.......)

                 

                 

                this kind of message on mod-cluster page..

                 

                P

                • 5. Re: changing node UUID
                  pferraro

                  In that case, just edit the web subsystem as follows:

                  e.g.

                   

                  {code:xml}

                  <subsystem xmlns="urn:jboss:domain:web:1.2" default-virtual-server="default-host" native="false" instance-id="${jboss.node.name}">

                  ...

                  </subsystem>{code}

                   

                  and make sure you've named your servers in host.xml as node1_s1, node1_s2, etc.

                  • 6. Re: changing node UUID
                    pragnyas

                    Hi Paul,

                     

                     

                     

                    Still no good.. I have edited web sub system in all profiles in domain.xml, and have required server names in host-slave.xml file.. (that is what am using..) and still I don't see the changed UUID.. it stil gives me a random number..

                     

                     

                    Note : My Bad.. that worked.. I forgot to chnage web sysbsystem on my master node.... sorry.. it works perfectly fine now..

                     

                     

                    P