cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

Changing Windchill URL

DavidBourcier
1-Visitor

Changing Windchill URL

Hello gurus,

Our customer wish to change the URL of their Windchill environement, is there any way to avoid the "Reinstallation + Rehosting" cycle ? Are you aware of any procedure that could allow me to perform this operation ?

Thanks in advance

Cheers

8 REPLIES 8

Rehost has three scenary , and one match yours.

David,

This is all theory, and I have been wondering the same thing myself for sometime. Going to think outloud here for a moment.

  • Windchill is a web based application running on Apache / Tomcat
  • Apache can host more than one website if configured properly
  • One site is apache can be setup to accept more than one host header / virtual host per site (IIS / apache)
    • In order for this work the URL needs to be setup correctly in DNS

    • With the host header setup properly apache doesn't care what URL is being passed. It just wants to feed up the web content / application

I have two test Windchill environments. I am going to test this out, and let you know my findings.

Stay tuned!

Patrick

I did the following:

Created a new A record in DNS that pointed to the IP address of my Windchill test server.

Updated the DNS records on the DNS server.

Flushed the DNS on my local machine.

Waiting until I got a pint response with the new host name (A record that was created in the first step).

Launched IE / Firefox, and entered http://newhostname/Windchill.

Windchill launched, but after it loaded it reverted back to the original hostname because Windchill's configurations

Would this be an acceptable work around for your client?

- Patrick

Patrick,

Your correct, you can use Apache to change the hostname of the Windchill application without executing a rehost. The issue you ran into was Windchill giving you a redirect back to the installed URL. You need to change the URL in both Apache and Windchill. We've found the easiest way to do this is by using the Apache Reverse Proxy feature and changing a few settings in Windchill. A second instance of Apache is required to run the Reverse Proxy, which can be installed on same system as Windchill or a separate server.

The communication will be as follows:
Client <-> Reverse Proxy Apache <-> Windchill Apache <-> Windchill Tomcat

Example: Apache installed on different servers both listening on port 80:
Installed URL: windchill.olddomain.com
New URL: wc.newdomain.com

1) Install a second Apache server (ie the Reverse Proxy Apache) - If you install the reverse proxy Apache on the same server as Windchill be sure to change the Listen line on the Windchill Apache service in the httpd.conf file and specify a different IP or port to bind too (eg 8880). If you define a different port you'll also need to change all urls below referencing http://windchill.olddomain.com to include the port (eg. http://windchill.olddomain.com:8880).

2) Configure the Reverse Proxy Apache server
a)Uncomment or add the following modules to the httpd.conf file:
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_connect_module modules/mod_proxy_connect.so
LoadModule proxy_http_module modules/mod_proxy_http.so

b) Added the Proxy settings for the Windchill application and Windchill Help to httpd.conf
ProxyPass /Windchill/ http://windchill.olddomain.com/Windchill/
ProxyPassReverse /Windchill/ http://windchill.olddomain.com/Windchill/
ProxyPass /Windchill-WHC http://windchill.olddomain.com/Windchill-WHC
ProxyPassReverse /Windchill-WHC http://windchill.olddomain.com/Windchill-WHC

3) Update Windchill to use Reverse Proxy:
xconfmanager -s wt.rmi.clientSocketFactory=wt.boot.WTRMIMasterSocketFactory -t codebase/wt.properties
xconfmanager -s wt.rmi.serverSocketFactory=wt.util.WrappedRMISocketFactory -t codebase/wt.properties
xconfmanager -s wt.rmi.javarmicgi=servlet/JavaRMIServlet -t codebase/wt.properties
xconfmanager -s wt.server.codebase=http://wc.newdomain.com/Windchill -t codebase/wt.properties
xconfmanager -s com.ptc.core.ca.co.client.doer.task.default.repository=windchill.olddomain.com -t codebase/wt.properties
xconfmanager -s wt.httpgw.mapCodebase=http://windchill.olddomain.com/Windchill -t codebase/wt.properties
xconfmanager -s wt.federation.rpc.endpoint=http://windchill.olddomain.com:18080/Windchill/servlet/RPC -t codebase/wt.properties
xconfmanager -p

4) Add the following to %WT_HOME%/codebase/urlmap.properties files
wtcore/=http://wc.newdomain.com/Windchill/wtcore/
servlet/=http://wc.newdomain.com/Windchill/servlet/
wt/=http://wc.newdomain.com/Windchill/wt/
com/=http://wc.newdomain.com/Windchill/com/
netmarkets/=http://wc.newdomain.com/Windchill/netmarkets/
wtx/=http://wc.newdomain.com/Windchill/wtx/
tx/=http://wc.newdomain.com/Windchill/tx/
infoengine/=http://wc.newdomain.com/Windchill/infoengine/

5) Restart all services and enjoy your new URL!

The Advanced Deployment Guide has additional information on Reverse Proxies.

http://www.ptc.com/WCMS/files/78982/en/WCAdvDeployGuide.pdf

We've wrapped the commands above into a script that allows us to change the name of Windchill to anything in a few seconds. This comes in very handy when you need to clone a Windchill system and don't want to deal with a full rehost.

I presented on a related topic at latest week's PlanetPTC conference titled "Clone Windchill in Minutes With Virtualization". As a follow up to the presenation I've posted a set of steps, with example automation scripts, to change the URL of a Windchill system at http://www.boston-engineering.com/plm-blog/clone-windchill.

Shawn Lothrop can you please revise with me the following procedure:

Duplicate the

  • \Apache\conf\http.conf

to

  • \Apache\conf\windchill_proxy.conf

Edit

  • \Apache\conf\http.conf

Change the listening port to another, eg:

  • Listen 0.0.0.0:8880

And

  • ServerName olddomain.com:8880

Edit

  • \Apache\conf\windchill_proxy.conf

Uncomment the 3 lines:

  • LoadModule proxy_module modules/mod_proxy.so
  • LoadModule proxy_connect_module modules/mod_proxy_connect.so
  • LoadModule proxy_http_module modules/mod_proxy_http.so

And set new domain, eg:

  • ServerName newdomain.com:80

And add, eg:

Make a new Apache service:

  • httpd -k install -n "ApacheReverseProxy" -f D:\Winchill\Apache\conf\windchill_proxy.conf

Edit host, eg:

  • 127.0.0.0 localhost newdomain.com

Run the following at windhill terminal:

  • xconfmanager -s wt.rmi.clientSocketFactory=wt.boot.WTRMIMasterSocketFactory -t codebase/wt.properties
  • xconfmanager -s wt.rmi.serverSocketFactory=wt.util.WrappedRMISocketFactory -t codebase/wt.properties
  • xconfmanager -s wt.rmi.javarmicgi=servlet/JavaRMIServlet -t codebase/wt.properties
  • xconfmanager -s wt.server.codebase=http://newdomain.com -t codebase/wt.properties
  • xconfmanager -s wt.httpgw.mapCodebase=http://olddomain.com/Windchill -t codebase/wt.properties
  • xconfmanager -s com.ptc.core.ca.co.client.doer.task.default.repository=olddomain.com -t codebase/wt.properties
  • xconfmanager -s wt.federation.rpc.endpoint=http://olddomain.com:$WT_TASK_DISPATCHER_MINPORT/Windchill/servlet/RPC -t codebase/wt.properties
  • xconfmanager -p

Add at urlmap.properties to:

Restart all

Hi Shawn,

When I'm trying to click the link that you were provided here i.e http://www.boston-engineering.com/plm-blog/clone-windchill., getting that "Page Not Available".

Please provide me corresponding article as I need to perform this technique.

My email id is : krishna.chaithanya@adroitecinfo.com

Thanks in advance

Reverse proxy is not working as per the post, can I know what script that can make our system handy

Announcements


Top Tags