3 Replies Latest reply: Jun 24, 2009 4:37 AM by ahmed elgenedy - oracle RSS

    Programaticaly remove(disable/enable) origin server from WebCache Cluster

    74527
      Hi.

      Can I programaticaly disable/enable origin server (OAS) from WebCache Cluster for safe node Up/Down ?

      Thanks.
        • 1. Re: Programaticaly remove(disable/enable) origin server from WebCache Cluster
          74527
          I found only one way - simulate HTTP request from web console by wget.

          wc_balance.bat (windows script):
          ------------------
          @rem Using a script: parameter ON - enable node, OFF - disable node

          @rem server env
          set HOST=class4.tst.lan:4000
          set AUTH=ias_admin:system

          @rem req env
          set u_host=class4.tst.lan
          set u_port=7888
          set u_capacity=100
          set u_numRetry=5
          set u_url=/
          set u_interval=10
          @rem !!! line number server in the Origin Server !!!
          set u_id=h2


          set U1="hostname=%u_host%&port=%u_port%&routing=%1&capacity=%u_capacity%&numRetry=%u_numRetry%&URL=%u_url%&interval=%u_interval%&SSL_TYPE=NONE&ACTION=Submit&id=%u_id%&SCREEN_ID=CGA.Site.OriginServers_Edit"
          set U2="webcacheadmin?SCREEN_ID=CGA.ConfigTree&ACTION=Apply+Changes"

          @rem set new status
          wget http://%AUTH%@%HOST%/webcacheadmin?%U1%
          @rem commit changes
          wget http://%AUTH%@%HOST%/webcacheadmin?%U2%
          ---------------

          Message was edited by:
          sisaev
          • 2. Re: Programaticaly remove(disable/enable) origin server from WebCache Cluster
            434281
            Hi Sisaev,

            I'm also looking for a solution on this.
            I tryed to send the URL via wget to the WebCacheAdmin but an error is returned because wget doesn't support frames nor JavaScript.

            With a "normal" browser it works.

            Did you find any other possibility for this?

            Thanks a lot, Christian
            • 3. Re: Programaticaly remove(disable/enable) origin server from WebCache Clust
              ahmed elgenedy - oracle
              Hi all,

              The following line in the above script:

              set U2="webcacheadmin?SCREEN_ID=CGA.ConfigTree&ACTION=Apply+Changes"

              should be changed to:

              set U2="SCREEN_ID=CGA.ConfigTree&ACTION=Apply+Changes"

              to get this script working.

              Regards,
              Ahmed