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

We are happy to announce the new Windchill Customization board! Learn more.

ANT_HOME is set incorrectly or ant could not be located. Please set ANT_HOME

Invisigoth
14-Alexandrite

ANT_HOME is set incorrectly or ant could not be located. Please set ANT_HOME

Hello,

I am trying to rename a system and running into this problem.  The system is a clone of production that will be a test system. Windchill 10.2 M030 CPS-11.  The SQL Server and PTC Directory server are running, per the rehost documentation.

I have created the rehost.properties with the guidance of this document:

"How to rename Windchill 10.x using Rehosting Utility 3.0 in Windchill PDMLink"

https://support.ptc.com/appserver/cs/view/solution.jsp?n=CS249543

I have also tried the suggestions in this document:

"Rehost Utility throws error "ANT_HOME is set incorrectly", but ANT_HOME is actually set correctly for Windchill PDMLink 10.1"

https://support.ptc.com/appserver/cs/view/solution.jsp?n=CS121851

(which indicates it covers versions 10.1 thru 11)

The Rehost utility documentation says that it is not necessary to escape the characters anyway.  I am using the windchill shell (get the same error when in a windows shell, fwiw).

I have made sure that I have a proper psi_iir file under my windows user profile that points to the installation. Check and doubled checked the values in the rehost.properties file against the site.xconf and db.properties. Tried a ton of different combinations of values. Used the new "test.prop.values.only" and "rehost.log.passwords". I never see any logging under buildlogs or the rehost utility directory.  Set, reset, unset "ANT_HOME". Moved the utility to the same drive as the windchill installation.  Rebooted.  This is all I ever get:

E:\rehostMED-61138-CD-102_M010>rehost.bat conf\rehost.properties

usercase  =  rename

modules   =   InfoEngine,Database,Apache

apache.home       = E:\PTC\Windchill\HTTPServer

wt.home           = E:\PTC\Windchill

wt.usernam        =

rehost.properties = E:\rehostMED-61138-CD-102_M010\conf\rehost.properties

setup env

wt_home   =E:\PTC\Windchill

JAVA_HOME =E:\PTC\Windchill\Java

ANT_HOME is set incorrectly or ant could not be located. Please set ANT_HOME.

E:\rehostMED-61138-CD-102_M010>

BTW, I don't know why "wt.usernam" is not set.  I have populated "target.wc.username". File comments from what I can tell that isn't required for what I am doing here.

I would welcome any suggestions from those who have this working and perhaps know the quirks or any tricks.

Regards,

MLS

1 ACCEPTED SOLUTION

Accepted Solutions
Invisigoth
14-Alexandrite
(To:ChrisSpartz)

Hi Chris,

Thanks for the confirm.  I was able to get the script to work on a different test system.  Based on that, I am creating a map of the rehost.properties values to where can find them in the Windchill configuration.  I was using the "summary.html" file in the .../Windchill/PSI/Installer directory, which uses two different values.  I had the misfortune of selecting the wrong one:

[from the summary.html file]

Base Installation Directory:

E:\ptc\Windchill\

(wrong.  This was the one I was using)

Installing To: E:\ptc\Windchill\Windchill

(correct.)

Once I replaced the following values in the rehost.properties file, the script no longer stopped at the ant error:

target.wt.home=E:\ptc\Windchill\Windchill

source.directory.windchill=E:\ptc\Windchill\Windchill

target.directory.windchill=E:\ptc\Windchill\Windchill

It completed successfully.  This now makes the summary.html file outdated, however it is a record of the original installation.  The new values could be extracted from properties.db, site.xconf and others if that was necessary.

Now I can't get Windchill to start, but that is the next puzzle to work on :  )

Thank you.

Regards,

MLS

View solution in original post

2 REPLIES 2

Based on your values of apache.home and JAVA_HOME, it looks like your wt.home is set incorrectly. It should be E:\PTC\Windchill\Windchill. The ANT_HOME variable is set based on the value of wt.home, so if wt.home is set incorrectly, you'll get this error message.

Invisigoth
14-Alexandrite
(To:ChrisSpartz)

Hi Chris,

Thanks for the confirm.  I was able to get the script to work on a different test system.  Based on that, I am creating a map of the rehost.properties values to where can find them in the Windchill configuration.  I was using the "summary.html" file in the .../Windchill/PSI/Installer directory, which uses two different values.  I had the misfortune of selecting the wrong one:

[from the summary.html file]

Base Installation Directory:

E:\ptc\Windchill\

(wrong.  This was the one I was using)

Installing To: E:\ptc\Windchill\Windchill

(correct.)

Once I replaced the following values in the rehost.properties file, the script no longer stopped at the ant error:

target.wt.home=E:\ptc\Windchill\Windchill

source.directory.windchill=E:\ptc\Windchill\Windchill

target.directory.windchill=E:\ptc\Windchill\Windchill

It completed successfully.  This now makes the summary.html file outdated, however it is a record of the original installation.  The new values could be extracted from properties.db, site.xconf and others if that was necessary.

Now I can't get Windchill to start, but that is the next puzzle to work on :  )

Thank you.

Regards,

MLS

Top Tags