<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <br>
    <br>
    On 20/10/11 17:19, Gomes, Rich wrote:
    <blockquote
cite="mid:716C4F59FAB01649B085832B6DC831BA04D3F0B1@anorpexbe01.AUCA.Corp"
      type="cite">
      <meta http-equiv="Context-Type" content="text/html;
        charset=us-ascii">
      <div>
        <p><span>I am still having issues with osa loading the cert. </span></p>
        <p><span>   </span></p>
        <p><span>I went thru every file where I could find the old name
            and replaced it with the new name: </span></p>
        <p><span>/etc/cobbler/settings </span></p>
        <p><span>/etc/pki/spacewalk/jabberd/server.pem </span></p>
        <p><span>/var/www/html/pub/RHN-ORG-TRUSTED-SSL-CERT </span></p>
        <p><span>/etc/jabberd/c2s.xml-swsave </span></p>
        <p><span>/etc/jabberd/sm.xml-swsave </span></p>
        <p><span>/etc/sysconfig/rhn/systemid.save </span></p>
        <p><span>/etc/pki/tls/certs/spacewalk.crt </span></p>
        <p>   </p>
        <p><span>   </span></p>
        <p><span>I am pretty sure that just replacing the name in the
            certs is not enough due to the actual hashes not changing.
            So I ran the following: </span></p>
        <p><span>   </span></p>
        <p>rhn-ssl-tool --gen-ca --force --set-common-name="newhostname"
        </p>
        <p>   </p>
        <p>   </p>
        <p><span>Still receiving the error below: </span></p>
        <p>   </p>
        <p><span>Starting osa-dispatcher: RHN 5802 2011/10/20 16:14:38
            -04:00: ('Traceback caught:',) </span></p>
        <p><span>RHN 5802 2011/10/20 16:14:38 -04:00: ('Traceback (most
            recent call last):\n  File
            "/usr/share/rhn/osad/jabber_lib.py", line 608, in
            connect\n    self.verify_peer(ssl)\n  File
            "/usr/share/rhn/osad/jabber_lib.py", line 688, in
            verify_peer\n    raise SSLVerifyError("Mismatch: peer name:
            %s; common name: %s" %\nSSLVerifyError: Mismatch: peer name:
            newhostname; common name: oldhostname.\n',) </span></p>
        <p><span>                                                          
            [FAILED] </span></p>
        <p>   </p>
        <p>   </p>
        <p>   </p>
        <p><span>What am I missing here? </span></p>
        <p><span>What file is osa pulling the common name from? </span></p>
        <p><span>   </span></p>
        <p><span>   </span></p>
        <p><span>Thanks, </span></p>
        <p><span>Rich </span></p>
        <p>   </p>
        <p><span>   </span></p>
        <p><span>   </span></p>
        <div>
          <div>
            <p><b><span>From:</span></b><span> Gomes, Rich <br>
                <b>Sent:</b> Thursday, October 20, 2011 12:39 PM<br>
                <b>To:</b> <a class="moz-txt-link-abbreviated" href="mailto:spacewalk-list@redhat.com">spacewalk-list@redhat.com</a><br>
                <b>Subject:</b> RE: [Spacewalk-list] issues with host
                rename </span></p>
          </div>
        </div>
        <p>   </p>
        <p><span>Ok, that worked. Thanks!! </span></p>
        <p><span>   </span></p>
        <p><span>Now have an issue when starting osa: </span></p>
        <p><span>   </span></p>
        <p><span>   </span></p>
        <p>Starting osa-dispatcher: RHN 7591 2011/10/20 12:36:08 -04:00:
          ('Traceback (most recent call last):\n  File
          "/usr/share/rhn/osad/jabber_lib.py", line 250, in
          setup_connection\n    c = self._get_jabber_client(js)\n  File
          "/usr/share/rhn/osad/jabber_lib.py", line 307, in
          _get_jabber_client\n    c.connect()\n  File
          "/usr/share/rhn/osad/jabber_lib.py", line 564, in connect\n   
          jabber.Client.connect(self)\n  File
          "/usr/lib/python2.4/site-packages/jabber/xmlstream.py", line
          466, in connect\n    socket.AF_UNSPEC,
          socket.SOCK_STREAM)\ngaierror: (-2, \'Name or service not
          known\')\n',) </p>
        <p>                                                           [ 
          OK  ] </p>
        <p>   </p>
        <p><span>   </span></p>
        <p><span>   </span></p>
        <p><span>Thoughts? </span></p>
        <p><span>   </span></p>
        <div>
          <div>
            <p><b><span>From:</span></b><span> <a
                  moz-do-not-send="true"
                  href="mailto:spacewalk-list-bounces@redhat.com">spacewalk-list-bounces@redhat.com</a>
                <a moz-do-not-send="true"
                  href="mailto:[mailto:spacewalk-list-bounces@redhat.com]">[mailto:spacewalk-list-bounces@redhat.com]</a>
                <b>On Behalf Of </b>Larry Letelier<br>
                <b>Sent:</b> Thursday, October 20, 2011 11:47 AM<br>
                <b>To:</b> <a moz-do-not-send="true"
                  href="mailto:spacewalk-list@redhat.com">spacewalk-list@redhat.com</a><br>
                <b>Subject:</b> Re: [Spacewalk-list] issues with host
                rename </span></p>
          </div>
        </div>
        <p>   </p>
        <p>On 20/10/11 12:37, Gomes, Rich wrote: </p>
        <div>
          <p>I am having issues with a SW server (1.5) that I am
            running. Currently it is running without issue but there is
            a need for a name change. </p>
          <p>Since it is a VM, I am cloning it as the new name and then
            powering off the original. </p>
          <p>Once the new server is up I do the following: </p>
          <p>  </p>
          <p>1 – Change IP to be that of original </p>
          <p>2 – Change hostname in both /etc/hosts and
            /etc/sysconfig/network </p>
          <p>3 – Reboot and verify name change </p>
          <p>4 – Run spacewalk-hostname-rename script </p>
          <p>  </p>
          <p>Each time I receive the following: </p>
          <p>  </p>
          <p>[root@newhostname ~]# spacewalk-hostname-rename xx.xx.xx.xx
             Validating IP ... OK
            ============================================= </p>
          <p>hostname: newhostname </p>
          <p>ip: xx.xx.xx.xx </p>
          <p>============================================= </p>
          <p>Stopping rhn-satellite services ... OK </p>
          <p>Testing DB connection ... ERROR: </p>
          <p>ORA-12505: TNS:listener does not currently know of SID
            given in connect descriptor </p>
          <p>  </p>
          <p>  </p>
          <p>SP2-0306: Invalid option. </p>
          <p>Usage: CONN[ECT] [{logon|/|proxy} [AS
            {SYSDBA|SYSOPER|SYSASM}] [edition=value]] where
            <logon> ::=
            <username>[/<password>][@<connect_identifier>]
          </p>
          <p>      <proxy> ::=
            <proxyuser>[<username>][/<password>][@<connect_identifier>]
          </p>
          <p>SP2-0306: Invalid option. </p>
          <p>Usage: CONN[ECT] [{logon|/|proxy} [AS
            {SYSDBA|SYSOPER|SYSASM}] [edition=value]] where
            <logon> ::=
            <username>[/<password>][@<connect_identifier>]
          </p>
          <p>      <proxy> ::=
            <proxyuser>[<username>][/<password>][@<connect_identifier>]
          </p>
          <p>SP2-0157: unable to CONNECT to ORACLE after 3 attempts,
            exiting SQL*Plus FAILED Your database isn't running. </p>
          <p>Fix the problem and run /usr/bin/spacewalk-hostname-rename
            again </p>
          <p>  </p>
          <p>  </p>
          <p>  </p>
          <p>  </p>
          <p>I would think it would be easier to build a new SW server
            from scratch but that has not worked out. Every time I try,
            with version 1.3, 1.4, and 1.5 everything goes smoothly but
            Taskomatic service will not stay running and I have not
            found a fix for it. </p>
          <p>This server was\is running successfully so I decided to to
            just clone it and rename it. </p>
          <p>  </p>
          <p>Interestingly, if I change host name back to original, it
            does me now good. </p>
          <p>And also, tnsnames and listener.ora both have ‘localhost’
            specified, not new hostname. </p>
          <p>Changing this to the new hostname does not good either. </p>
          <p>  </p>
          <p>  </p>
          <p>Has anyone else run into this? </p>
          <p>How can this be fixed? </p>
          <p>  </p>
          <p>  </p>
          <p>  </p>
          <p>Thanks, </p>
          <p>  </p>
          <p>Rich </p>
          <p>  </p>
          <p>  </p>
          <p>  </p>
          <p><b>  </b> </p>
          <p><b>  </b> </p>
          <p><b>  </b> </p>
          <p><b>Rich Gomes</b> | Senior Systems Administrator,  AUCA
            System Services | ARAMARK Uniform & Career Apparel </p>
          <p>Tel: 781.763.4508 |  Fax: 781.763.2508 </p>
          <p><a moz-do-not-send="true"
              href="mailto:Rich.Gomes@wearguard-crest.com">Rich.Gomes@wearguard-crest.com</a> |
            <a moz-do-not-send="true"
              href="http://www.aramark-uniform.com/"
              title="http://www.aramark-uniform.com/">www.aramark-uniform.com</a>
          </p>
          <p>  </p>
        </div>
        <p><br>
          <br>
        </p>
        <pre>_______________________________________________  </pre>
        <pre>Spacewalk-list mailing list  </pre>
        <pre><a moz-do-not-send="true" href="mailto:Spacewalk-list@redhat.com">Spacewalk-list@redhat.com</a>  </pre>
        <pre><a moz-do-not-send="true" href="https://www.redhat.com/mailman/listinfo/spacewalk-list">https://www.redhat.com/mailman/listinfo/spacewalk-list</a>  </pre>
        <p><br>
          Rich: <br>
          <br>
          Try this, <br>
          <br>
          <br>
          <span><span> </span></span></p>
        <pre><span>-> Stop the osa-dispatcher and jabberd service.</span><span>  </span></pre>
        <pre><span>-></span><span> #rm -f /var/lib/jabberd/db/*  </span></pre>
        <pre><span>   </span></pre>
        <pre><span>-></span><span> Switch to the oracle user and using sqlplus clear out the client and dispatcher tables.  </span></pre>
        <pre><span>   </span></pre>
        <p><span>   sqlplus $(spacewalk-cfg-get default_db)</span> </p>
        <p><span>  </span></p>
        <pre><span>   delete from rhnPushDispatcher;  </span></pre>
        <pre><span>   delete from rhnpushclient;  </span></pre>
        <pre><span>   commit;  </span></pre>
        <pre><span>   </span></pre>
        <pre><span>   quit  </span></pre>
        <pre><span>   </span></pre>
        <pre><span>-> Now restart the jabberd and osa-dispatcher services</span><span>  </span></pre>
        <p><br>
          Good luck-<br>
          <br>
          <br>
          -- Larry Letelier </p>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
Spacewalk-list mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Spacewalk-list@redhat.com">Spacewalk-list@redhat.com</a>
<a class="moz-txt-link-freetext" href="https://www.redhat.com/mailman/listinfo/spacewalk-list">https://www.redhat.com/mailman/listinfo/spacewalk-list</a></pre>
    </blockquote>
    <br>
    <br>
    Are you usign FQDN right ?<br>
    <br>
    what about :<br>
    grep server /etc/rhn/rhn.conf<br>
    <br>
    remember, the files are: <span>/etc/jabberd/*.xml<br>
      <br>
      what about *.ora files. ?<br>
    </span>
  </body>
</html>