AutoCAD 2021 Deployment with Network Server

Onkston
New Contributor III

Hey All,

This year Autodesk decided to change the installer for AutoCAD, Maya and Mudbox. Here's how I got AutoCAD to install silently since the new silent installer option is broken. You will want a policy to copy the app from the dmg to a temp directory. I used /tmp

EDIT: You only want to change the license server address in the script below. Nothing else.

#!/bin/sh

year="2021"
pkgpath="/tmp/Install Autodesk AutoCAD ${year} for Mac.app"
pkgPath1="/tmp/Install Autodesk AutoCAD ${year} for Mac.app/Contents/Helper/ObjToInstall/lib.pkg"
pkgPath2="/tmp/Install Autodesk AutoCAD ${year} for Mac.app/Contents/Helper/Packages/AdSSO/AdSSO-v2.pkg"
pkgPath3="/tmp/Install Autodesk AutoCAD ${year} for Mac.app/Contents/Helper/Packages/Licensing/AdskLicensing-10.1.0.3194-mac-installer.pkg"
pkgPath4="/tmp/Install Autodesk AutoCAD ${year} for Mac.app/Contents/Helper/ObjToInstall/licreg.pkg"
pkgPath5="/tmp/Install Autodesk AutoCAD ${year} for Mac.app/Contents/Helper/ObjToInstall/autocad2021.pkg"
pKey="777M1"
networkServer="LICENSE SERVER ADDRESS"
licPath="/Library/Application Support/Autodesk/AdskLicensingService/${pKey}_${year}.0.0.F"
licFile="LICPATH.lic"
lgsFile="LGS.data"

#Declare functions

runInstaller ()
{
    /usr/sbin/installer -verboseR -pkg "${pkgPath1}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath2}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath3}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath4}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath5}" -target /

}

createLicenseFiles ()
{
    if [[ ! -e "${licPath}" ]];
    then
        /bin/mkdir "${licPath}"
    fi
    /usr/bin/touch "${licPath}/${lgsFile}"
    /bin/chmod 777 "${licPath}/${lgsFile}"
    /usr/bin/touch "${licPath}/${licFile}"
    /bin/chmod 777 "${licPath}/${licFile}"
    /bin/echo "SERVER ${networkServer} 000000000000" > "${licPath}/${licFile}"
    /bin/echo "USE_SERVER" >> "${licPath}/${licFile}"
    /bin/echo "_NETWORK" >> "${licPath}/${lgsFile}"
}
licenceHelper ()
{
    /Library/Application Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper change --pk "${pKey}" --pv "${year}.0.0.F" --lm NETWORK --ls "${networkServer}"
}
cleanUp ()
{
    /bin/rm -rf "${pkgPath}"
}

#Run script

runInstaller
createLicenseFiles
licenceHelper
cleanUp
2 ACCEPTED SOLUTIONS

Qwheel
Contributor II

Just weighing in for others. As we have a bunch of Macbooks within our institution, I had to package up the 2022 standalone versions for CAD and Maya.
I used the script proposed above by others but found the license section wasn't flawless. I suspect it's because spaces weren't escaped (I'm looking at you "Application\ Support").

When problem solving why licensing wasn't working, I tinkered a fair bit (adding "", sudo, \ etc) . Actually wasn't sure if /.config was even there but it was hidden (as .folders are...) .

But yeah, as I used the above scripts, I thought I'd show my CAD and Maya standalone 2022 corrections and share my experience getting it working.

#!/bin/sh
year="2022"
pkgpath="/private/tmp/Install Autodesk AutoCAD ${year} for Mac.app"
pkgPath1="/private/tmp/Install Autodesk AutoCAD ${year} for Mac.app/Contents/Helper/ObjToInstall/lib.pkg"
pkgPath2="/private/tmp/Install Autodesk AutoCAD ${year} for Mac.app/Contents/Helper/Packages/AdSSO/AdSSO-v2.pkg"
pkgPath3="/private/tmp/Install Autodesk AutoCAD ${year} for Mac.app/Contents/Helper/Packages/Licensing/AdskLicensing-11.0.0.4854-mac-installer.pkg"
pkgPath4="/private/tmp/Install Autodesk AutoCAD ${year} for Mac.app/Contents/Helper/ObjToInstall/LicregTool/licreg.pkg"
pkgPath5="/private/tmp/Install Autodesk AutoCAD ${year} for Mac.app/Contents/Helper/ObjToInstall/autocad2022.pkg"
pKey="XXXXX"
sn="XXX-XXXXXXXX"
licPath="/Library/Application Support/Autodesk/AdskLicensingService/${pKey}_${year}.0.0.F"
licFile="LICPATH.lic"
lgsFile="LGS.data"

#Declare functions

runInstaller ()
{
    /usr/sbin/installer -verboseR -pkg "${pkgPath1}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath2}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath3}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath4}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath5}" -target /

}

licenceHelper ()
{
	#/Library/Application\ Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper register --pk "${pKey}" --pv "${year}.0.0.F" --lm STANDALONE --sn "${sn}" --cf /Library/Application Support/Autodesk/Adlm/.config/ProductInformation.Pit -el US
	sudo /Library/Application\ Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper register --pk "XXXXX" --pv "2022.0.0.F" --lm STANDALONE --sn "XXX-XXXXXXX" --cf /Library/Application\ Support/Autodesk/Adlm/.config/ProductInformation.Pit -el US
}

cleanUp ()
{
    /bin/rm -rf "${pkgPath}"
}

#Run script

runInstaller
licenceHelper
cleanUp


And for Maya, I found that the Autodesk build couldn't install MtoA (Arnold renderer). Don't know why it was failing but MacOS version was 11.5.X.
Excluded that line from the installer and went to their website. Using Composer, I dumped the PKG next to the Maya installer in /tmp and ran it from there in the order previously described.
Apologies for not having done the housekeeping to tidy it up, but I consider it useful to see what has been removed.

#!/bin/sh

year="2022"
pkgpath="/tmp/Install Maya ${year}.app"
helperpath="${pkgpath}/Contents/Helper"
pkgPath1="${helperpath}/Packages/Licensing/AdskLicensing-11.0.0.4854-mac-installer.pkg"
pkgPath2="${helperpath}/Packages/AdSSO/AdSSO-v2.pkg"
pkgPath3="${helperpath}/Packages/Maya/Maya_AdLMconf2022.pkg"
pkgPath4="${helperpath}/Packages/Maya/Maya_core2022.pkg"
#pkgPath5="${helperpath}/Packages/Maya/MtoA.pkg"
pkgPath6="${helperpath}/Packages/Maya/bifrost.pkg"
pkgPath7="${helperpath}/Packages/Maya/MayaUSD.pkg"
pkgPath8="${helperpath}/Packages/Maya/SubstanceInMaya-2.1.9-2022-Darwin.pkg"
pkgPath9="${helperpath}/Packages/Maya/motion-library.maya2022-2.0.0.pkg"
PkgPathA="${helperpath}/Packages/Maya/Pymel2022.pkg"
pKey="XXXXX"
networkServer="YOUR LICENSE SERVER NAME HERE"
licPath="/Library/Application Support/Autodesk/AdskLicensingService/${pKey}_${year}.0.0.F"
licFile="LICPATH.lic"
lgsFile="LGS.data"

#Declare functions

runInstaller ()
{
    /usr/sbin/installer -verboseR -pkg "${pkgPath1}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath2}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath3}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath4}" -target /
    /usr/sbin/installer -verboseR -pkg "/private/tmp/MtoA-4.2.4-darwin-2022.pkg" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath6}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath7}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath8}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath9}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPathA}" -target /

}

#createLicenseFiles ()
#{
 #   if [[ ! -e "${licPath}" ]];
#    then
    #    /bin/mkdir "${licPath}"
   # fi
  #  /usr/bin/touch "${licPath}/${lgsFile}"
 #   /bin/chmod 777 "${licPath}/${lgsFile}"
#    /usr/bin/touch "${licPath}/${licFile}"
    #/bin/chmod 777 "${licPath}/${licFile}"
   # /bin/echo "SERVER ${networkServer} 000000000000" > "${licPath}/${licFile}"
  #  /bin/echo "USE_SERVER" >> "${licPath}/${licFile}"
 #   /bin/echo "_NETWORK" >> "${licPath}/${lgsFile}"
#}
licenceHelper ()
{
    sudo /Library/Application\ Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper register --pk "XXXXX" --pv "2022.0.0.F" --lm STANDALONE  --sn "XXX-XXXXXX" --cf /Library/Application\ Support/Autodesk/ADLM/PIT/2022/MayaConfig.pit -el US
}
cleanUp ()
{
    /bin/rm -rf "${pkgPath}"
}

#Run script

runInstaller
#createLicenseFiles
licenceHelper
cleanUp



 

View solution in original post

GabeShack
Valued Contributor III

Ok all looks like I got this all working again, but slightly different.  2 things....just remember to enter your own SN and product ID for the x's and also make a pkg with composer that puts the 2023 installer in /Users/Shared but this is working great now.

 

 

 

 

#!/bin/sh
# Adapted By GabeShack
# Remove 2021 version
/Applications/Autodesk/AutoCAD\ 2021/Remove\ AutoCAD\ 2021.app/Contents/MacOS/Remove\ AutoCAD\ 2021 -silent
# Remove 2022 version
/Applications/Autodesk/AutoCAD\ 2022/Remove\ AutoCAD\ 2022.app/Contents/MacOS/Remove\ AutoCAD\ 2022 -silent
# Remove 2023 version
/Applications/Autodesk/AutoCAD\ 2023/Remove\ AutoCAD\ 2023.app/Contents/MacOS/Remove\ AutoCAD\ 2023 -silent
# Install Silently (Requires Autodesk 2023 Installer to be in /Users/Shared)
/Users/Shared/Install\ Autodesk\ AutoCAD\ 2023\ for\ Mac.app/Contents/Helper/Setup.app/Contents/MacOS/Setup --silent
# License 2023 Version  add your sn and version for the X's
/Library/Application\ Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper register --pk "XXXXX" --pv "2023.0.0.F" --lm STANDALONE --sn "xxx-xxxxxxx" --cf /Library/Application\ Support/Autodesk/Adlm/.config/ProductInformation.Pit -el US
# Remove 2021, 2022 and 2023 installer files
rm -rf "/Users/Shared/Install Autodesk AutoCAD 2021 for Mac.app"
rm -rf "/Users/Shared/Install Autodesk AutoCAD 2022 for Mac.app"
rm -rf "/Users/Shared/Install Autodesk AutoCAD 2023 for Mac.app"

 

 

 

 

 

Gabe Shackney
Princeton Public Schools

View solution in original post

87 REPLIES 87

Qwheel
Contributor II

As much as I wish I could set up a teams meet to share my experience and help get some more information for you, when I return from leave I’m going to be a little snowed under with works that have seen great delays already.

I might be able to test it again and grab some logs for you but it won’t be prioritised unfortunately. Maybe someone else here can help in the mean time to move things along?

Perhaps you could discuss this directly with:

Support Email: support@jamf.com
Support Line: (844) 411-5263

I would expect their engineers will have some sort of closed test environment that could be explored?

That way it’ll be B2B instead of working directly with customers. The more I think about it, this does strike me as a vendor to vendor issue. JAMFsupport are really responsive.

Feel to reference this thread in your support request.

As JAMF aren’t the only vendor out there, I wouldn’t be surprised if we are the only ones affected.

GabeShack
Valued Contributor III

@wei503 Wei, Im going to be honest with you.  Your software is not made to be installed easily by a Mac Administrator.  If you want to create a normal Apple recommended .pkg installer, the entire JAMF community would rejoice.  We should not have to put any special command scripts together, or call a "silent" installer.  We should be able to control the install by dumping a regular .pkg file into whatever MDM we use and then apply a script after the install to program any license info that is required.

Your app is its own island vs anything made by any other company for the Mac.  Your installer works in a different and confusing/complex method and the amount of trial and error associated with it makes its almost useless.  Hence the reason we have about 5 discussions on here about how to process the installer without issue.   

If AutoDesk really wants to cater to schools and businesses that are wanting to install their software (I have about 3000 devices where they want the ability to install) they should start over and build an installer that actually uses the Apple Installer program and not this custom installer that works like no other.  Please do better.

 

Gabe Shackney
Princeton Public Schools

kacey3
Contributor II

Does this same process work for all of the Autodesk Mac apps?

  • AutoCAD
  • Maya
  • Smoke
  • Flame
  • Arnold
  • Mudbox

wei503
New Contributor

Hi @kacey3 ,

The license registration/activation script should work for all products.

The silent Install scripts should work on most of these products, if not all..

The update script is AutoCAD only. Other products may have their own scripts.

 

wei503
New Contributor

Some of the issues known or fixed:
1. Install does not work if client machine does no sign in - fixed in AutoCAD 2023, it is also said that the issue does not exist on macOS Monterey.
2. postinstall error, adsklicensingservice not running... This issue is top#1 install problem as we see. It may occur due to different reasons, but mostly are because the license files permission not correct. We have fixed some issues that may cause license problems, and still some remains. One case that may cause license file permission wrong is the "umask" value is customized. This can be worked around by correct the permission for license files/folders in folder below with chmod. 

/Library/Application\ Support/Autodesk/AdskLicensing/
/Library/Application\ Support/Autodesk/AdskLicensingService/

 

robertojok
Contributor

Hi guys just to add here in case there are technicians in education who are trying to install Autodesk Apps... last year, I too had problems with AutoCAD 2022 as it required a user to be logged in before it could install. However, this year I used the script from @jonw  and it has been a life saver, thanks to him. The steps in the script will even install AutoCAD 2023 on Start up trigger so I will just repost it here for you thanks again to @jonw 

Just remember that my configuration uses two servers (DISTRIBUTED)

---------------------------------------------------------------

#!/bin/zsh
 
### Install AutoDesk Combo 2023 (AutoCAD, Maya & MudBox)
### silently @ login window with network licenses (aka multi-user lab/classroom deploy)
 
### 2022.07.27 by JonW
 
### Simply update variables/products below the function section as desired
### Read the additional details at the end of the script for more clarity on licensing.
 
### Ensure:
### 1) installer app(s) re-packed from .dmg by Composer & deployed to /private/tmp (root:wheel 755)
### 2) the network license server is functional
### 3) optionally, that previous Autodesk installations have been removed.
### and if so, you've also unloaded com.autodesk.AdskLicensingService.plist
 
#################################################
 
 
installFunction ()
{
### Before install, clear quarantine that may step on Setup.app when run at the login window.
### Also as of 2023, Mudbox still uses a different setup app path with --noui flag NOT --silent
### Finally, remove the installer app when complete
 
/usr/bin/xattr -rc /private/tmp/"${installerApp}"
 
if echo "$installerApp" | grep -iq "Mudbox"; then
/private/tmp/"${installerApp}"/Contents/MacOS/setup --noui
else
/private/tmp/"${installerApp}"/Contents/Helper/Setup.app/Contents/MacOS/Setup --silent
fi
 
/bin/rm -rf /private/tmp/"${installerApp}"
}
 
 
 
licenseFunction ()
{
### based off Onkstons's terrific work (I think they we're the first?) but simplified for 2023.
### see also, addl details at the end of script for alternative 'legit' licensing method.
licensePath="/Library/Application Support/Autodesk/AdskLicensingService/${productKey}_${year}.0.0.F"
/bin/mkdir -p "${licensePath}"
/usr/bin/touch "${licensePath}/licpath.lic"
/bin/echo "SERVER ${networkServer} 000000000000" > "${licensePath}/licpath.lic"
/bin/echo "USE_SERVER" >> "${licensePath}/licpath.lic"
 
/Library/Application\ Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper change --pk "${productKey}" --pv "${year}.0.0.F" --lm NETWORK --ls "${networkServer}" --lt DISTRIBUTED
}
 
 
#################################################
 
#Enter networkserver/s
networkServer="2080@MY-SERVER-1.MYCOMPANY.COM0@MY-SERVER-2.MYCOMPANY.COM"
 
### AutoCAD
productKey="777O1"
year="2023"
installerApp="Install Autodesk AutoCAD 2023 for Mac.app"
installFunction
licenseFunction
 
 
### Maya
productKey="657O1"
year="2023"
installerApp="Install Maya 2023.app"
installFunction
licenseFunction
 
 
### Mudbox
productKey="498O1"
year="2023"
installerApp="Install Mudbox 2023.app"
installFunction
licenseFunction
 
 
 
#################################################
 
### Verify license details - not required, but kind of nice to see.
/Library/Application\ Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper list
echo "Autodesk network licensing complete"
 
 
##################################################
 
 
### Additional network license details:
### For those who are curious, or if the above ever ceases to function:
 
### The 'legit' method for initial silent license registration (using autoCAD as an example) uses the 'register' command instead of 'change'.
### It also requires use of the --cf flag to denote a path to the app's config (.pit) file.
 
### e.g.
### configFile="/Library/Application Support/Autodesk/ADLM/.config/ProductInformation.pit"
### /Library/Application\ Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper register --pk "${productKey}" --pv "${year}.0.0.F" --cf "${configFile}" --lm NETWORK --ls "${networkServer}"
 
### The end result is the same as the 'change' method used above (at least after the initial app launch).
### Essentially the 'change' method works backwards to manually create the licpath.lic directory & file,
### then uses the 'change' command to register it.
 
### Anecdotally, the 'change' method appears to produce a slightly faster initial app launch,
### but it's hard to say which is better.
### Either way, it's good to know both & having handle on the AdskLicensingInstHelper utility helps a lot!
 
### Check these out >>>
### /Library/Application\ Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper register --help
### /Library/Application\ Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper change --help
 
### Also, either method seems to deploy fine while at the login window, so no worries there.
 
### Some good tips & reference:
 
 
### Hope this helps some folks out!  

Qwheel
Contributor II

Maybe someone knows how:

I have someone who had standalone Maya 2022 installed. They've run our standalone Maya 2023 /Setup --silent installation policy. Its installed happily according to reporting but their device is hanging on the first launch 'Activate' step.

The policy was tested on a fresh student lab device and was working just fine. It's not really an option to wipe staff devices annually.

There must be something I'm missing here. Any idea's?
Thanks!

GabeShack
Valued Contributor III

  Here is my facetious answer: You're just missing a working installer from AutoDesk.  Perhaps one day they will create one.

Here's my constructive one: My only guess is there is still an older version of the licensing program "AdskLicensingService" running and would possibly need to be removed before reinstalling.  Otherwise try a restart which seemed to fix a few issues in the past.  I tend to run the uninstallers for the older versions before trying the new versions, however even their uninstaller doesn't quite work to get rid of everything it puts in.  Perhaps one day.....

Gabe Shackney
Princeton Public Schools