Packaging Maya 2022

skypointer
New Contributor II

Hi all, I'm wondering if anyone has had success in packaging Maya 2022 with a non-network server license key, which our institution is able to put on 1200 machines. I tried referencing this post, but havent been able to successfully deploy the program with my modifications. Any help would be appreciated. Thank you.

17 REPLIES 17

Sanchi
Contributor

Also looking for some info on this too

cgeorge
New Contributor III

Have you been successful in getting Maya 2022 to deploy and install? I'm using their documentation to build a silent installer, but it fails every time. I'm putting the Install Maya 2022.app in /tmp, and the script successfully launches it silent, but it errors out at install. I've tried it with users logged in, and no one logged in, and it fails every time.

scrnnmalrdychos
New Contributor

Someone at Autodesk mistyped the command in their silent install kb (https://knowledge.autodesk.com/search-result/caas/CloudHelp/cloudhelp/ENU/Autodesk-Installation-Basi...) and typed --q rather than a single - before the q.   See below for more on that.   My team has already communicated this error to Autodesk.

Please note:  The procedure below has been tested and confirmed to work successfully on supported macOS versions across, for the sake of propriety, enough systems at scale for enterprise level confidence.

  • Place the Install Maya 2022.app in the /tmp directory.  
  • Drag and drop into Composer.
  • Within Composer, navigate to Install Maya 2022.app and modify the Owner and Group to "root" and "wheel" and "Apply Owner and Group to Install Maya 2022.app and Enclosed Items."  (Please don't waste time posting comments regarding this step.  Remember... my deployment works.)
  • Add the following line into a postinstall script for your Source in Composer:

 

#!/bin/sh
## postinstall

sudo /private/tmp/Install\ Maya\ 2022.app/Contents/Helper/Setup.app/Contents/MacOS/Setup -q​

 

  • Save and Build as PKG...and tah-freaking-dah you have a working silent installer for Maya 2022. 

    There are caveats to this method, if you are using a legacy network license, etc., etc.  This, however, is the quickest path from point A to point B given the use case mentioned above.  For those that may want to poke holes, please recall that our deployment works.  Have a magical day!

Hello! I just edited my old Maya 2020 script from here: https://community.jamf.com/t5/jamf-pro/packaging-maya-2020/td-p/229754

 

Below is the updated code for Maya 2022. It has an option to input your server if you do have a network license. This script also requires you to put Install Maya 2022.app in the /tmp/ folder. You will need to package that move. I used composer.

#!/bin/sh

#Instructions for next time
#Import install disk image with munkiimport
#Change installer_type to copy_from_dmg
#Copy installer app to /tmp
#Modify values below as necessary (Usually: year and pKey)

#Set variables

year="2022"
pkgPath1="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/MayaUSD.pkg"
pkgPath2="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/Maya_AdLMconf2022.pkg"
pkgPath3="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Licensing/adlmflexnetserverIPV6.pkg"
pkgPath4="/tmp/Install Maya 2022.app/Contents/Helper/Packages/AdSSO/AdSSO-v2.pkg"
pkgpath4a="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Licensing/adlmframework18.pkg"
pkgPath5="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Licensing/AdskLicensing-11.0.0.4854-mac-installer.pkg"
pkgPath6="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/Maya_core2022.pkg"
pkgPath7="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/bifrost.pkg"
pkgPath8="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/MtoA.pkg"
pkgPath9="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/SubstanceInMaya-2.1.9-2022-Darwin.pkg"
pkgPath10="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/motion-library.maya2022-2.0.0.pkg"
pkgPath11="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/Pymel2022.pkg"

pKey="657N1"
networkServer="[your server]"
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 "${pkgPath4a}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath5}" -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 "${pkgPath10}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath11}" -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}"
    /bin/rm -rf "${tmpfile}"
}

#Run script
runInstaller
createLicenseFiles
licenceHelper
cleanUp

 

Thanks for this, really helpful indeed. I customised it slightly for register rather than change the license and also added my distribution server element to it

/Library/Application\ Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper register --pk "${pKey}" --pv "${year}.0.0.F" --lt "${lic_server_type}" --lt DISTRIBUTED --lm NETWORK --ls "${networkServer}" --sn 572-13572357 --el UK --cf /Applications/Autodesk/maya2022/adlmreg/MayaConfig.pit --nu

Thank you!

ekuehn
New Contributor

Thanks! This was painless!

lakem
New Contributor II

Hi all. I am looking for a script to install Maya & Mudbox 2022 which has a network license. I have tried to modify your script @pclyttle (thanks for supplying), however I am not entirely sure which line to include a serial-key for both Maya and Mudbox.

Any help will be appreciated. Thanks.

ekuehn
New Contributor

Hi Lakem. These instructions are for a network license. Use them if you have a server set up to license your computers instead of a standalone serial #.

lakem
New Contributor II

Hi @ekuehn. Thanks for the reply. This is what I had thought going by the detail in the script, however, after installation and then opening Maya, it still asks for a serial number or to select other license options.

I will check the script and installation again and see what I can figure out.

Thanks

pclyttle
New Contributor II

Double-check that it's pointing to the correct server address and the server is setup properly/up-to-date

lakem
New Contributor II

Hi @pclyttle. Thanks for the reply. Server address is correct and appears to be ok.

One thing I have noticed is adlmframework18.pkg (Install Maya 2022.app/Contents/Helper/Packages/Licensing/adlmframework18.pkg) is missing from my downloaded Install Maya 2022.dmg.

Now when I run the script, I get

connecting to Service failed: reading configuration file /Library/Application Support/Autodesk/AdskLicensingService/AdskLicensingService.data failed: open /Library/Application Support/Autodesk/AdskLicensingService/AdskLicensingService.data: no such file or directory

And this is correct, the file does not exist.

pclyttle
New Contributor II

Okay, take it out. It was in my version.

lakem
New Contributor II

Ok, good news. I now have got a bit further and Maya is now launching (thank you). However, I need to be able to install and license both Maya 2022 and Mudbox 2022 on our Macs, which of course both have different product keys (657N1 and 498N1) and the below line will only cater for one or the other.

/Library/Application\ Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper change --pk "${pKey}" --pv "${year}.0.0.F" --lm NETWORK --ls "${networkServer}"

 I am now looking for a way to be able to have both apps installed and be happy. I will let you know what I find.

lakem
New Contributor II

For those interested, I use the below to install and license both Maya and Mudbox 2022. It may not be the most tidy but it appears to work for me now. Thanks again all, for the help.

#!/bin/sh

#Copy installer app from .dmg to /tmp
#Modify values below as necessary (Usually: year and pKey)

#Set variables

year="2022"
pkgPath1="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/MayaUSD.pkg"
pkgPath2="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/Maya_AdLMconf2022.pkg"
pkgPath3="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Licensing/adlmflexnetserverIPV6.pkg"
pkgPath4="/tmp/Install Maya 2022.app/Contents/Helper/Packages/AdSSO/AdSSO-v2.pkg"
pkgPath5="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Licensing/AdskLicensing-11.0.0.4854-mac-installer.pkg"
pkgPath6="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/Maya_core2022.pkg"
pkgPath7="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/bifrost.pkg"
pkgPath8="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/MtoA.pkg"
pkgPath9="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/SubstanceInMaya-2.1.9-2022-Darwin.pkg"
pkgPath10="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/motion-library.maya2022-2.0.0.pkg"
pkgPath11="/tmp/Install Maya 2022.app/Contents/Helper/Packages/Maya/Pymel2022.pkg"

mayapKey="657N1"
networkServer="licServerFQDN.org"
mayalicPath="/Library/Application Support/Autodesk/AdskLicensingService/${mayapKey}_${year}.0.0.F"
mayalicFile="LICPATH.lic"
mayalgsFile="LGS.data"

#Mudbox

pkgPath12="/tmp/Install Mudbox 2022.app/Contents/Packages/ADLM/AdSSO-v2.pkg"
pkgPath13="/tmp/Install Mudbox 2022.app/Contents/Packages/ADLM/AdskLicensing-11.0.0.4854-mac-installer.pkg"
pkgPath14="/tmp/Install Mudbox 2022.app/Contents/Packages/ADLM/adlmflexnetserverIPV6.pkg"
pkgPath15="/tmp/Install Mudbox 2022.app/Contents/Packages/Mudbox/Mudbox_AdLMconf2022.pkg"
pkgPath16="/tmp/Install Mudbox 2022.app/Contents/Packages/Mudbox/Mudbox_core2022.pkg"

mudboxpKey="498N1"
mudboxlicPath="/Library/Application Support/Autodesk/AdskLicensingService/${mudboxpKey}_${year}.0.0.F"
mudboxlicFile="LICPATH.lic"
mudboxlgsFile="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 /
    /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 "${pkgPath10}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath11}" -target /
    /usr/sbin/installer -verboseR -pkg "${pkgPath12}" -target /		#Mudbox
    /usr/sbin/installer -verboseR -pkg "${pkgPath13}" -target /		#Mudbox
    /usr/sbin/installer -verboseR -pkg "${pkgPath14}" -target /		#Mudbox
    /usr/sbin/installer -verboseR -pkg "${pkgPath15}" -target /		#Mudbox
    /usr/sbin/installer -verboseR -pkg "${pkgPath16}" -target /		#Mudbox
}

createMayaLicenseFiles ()
{
    if [[ ! -e "${mayalicPath}" ]];
    then
        /bin/mkdir "${mayalicPath}"
    fi
    /usr/bin/touch "${mayalicPath}/${mayalgsFile}"
    /bin/chmod 777 "${mayalicPath}/${mayalgsFile}"
    /usr/bin/touch "${mayalicPath}/${mayalicFile}"
    /bin/chmod 777 "${mayalicPath}/${mayalicFile}"
    /bin/echo "SERVER ${networkServer} 000000000000" > "${mayalicPath}/${mayalicFile}"
    /bin/echo "USE_SERVER" >> "${mayalicPath}/${mayalicFile}"
    /bin/echo "_NETWORK" >> "${mayalicPath}/${mayalgsFile}"
}

createMudboxLicenseFiles ()
{
    if [[ ! -e "${mudboxlicPath}" ]];
    then
        /bin/mkdir "${mudboxlicPath}"
    fi
    /usr/bin/touch "${mudboxlicPath}/${mudboxlgsFile}"
    /bin/chmod 777 "${mudboxlicPath}/${mudboxlgsFile}"
    /usr/bin/touch "${mudboxlicPath}/${mudboxlicFile}"
    /bin/chmod 777 "${mudboxlicPath}/${mudboxlicFile}"
    /bin/echo "SERVER ${networkServer} 000000000000" > "${mudboxlicPath}/${mudboxlicFile}"
    /bin/echo "USE_SERVER" >> "${mudboxlicPath}/${mudboxlicFile}"
    /bin/echo "_NETWORK" >> "${mudboxlicPath}/${mudboxlgsFile}"
}

MayalicenceHelper ()
{
    /Library/Application\ Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper change --pk "${mayapKey}" --pv "${year}.0.0.F" --lm NETWORK --ls "${networkServer}"
    
}

MudboxlicenceHelper ()
{
    /Library/Application\ Support/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper change --pk "${mudboxpKey}" --pv "${year}.0.0.F" --lm NETWORK --ls "${networkServer}"
    
}

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

#Run script
runInstaller
createMayaLicenseFiles
createMudboxLicenseFiles
MayalicenceHelper
MudboxlicenceHelper
cleanUp

 

vbang
New Contributor

Hi all,

First time here and I'm new to scripting. I was inspired by the scripts mentioned in this post to do my own script. I took the "Setup" binary approach to carry out a silent install. I found it a tad reliable versus pkg installers.  I also wanted to encompass the idea of installing other Autodesk products within a single script. I have tested Maya 2022, Mudbox 2022 and AutoCAD 2022. Stuck on getting Maya 2018 to activate. Well, here's my script and apologies if it doesn't work for you.

#!/bin/bash

#v1: 05/10/2021 - Vi

# Product keys
# Maya 2022: 657N1
# Maya 2018: 657J1
# Mudbox 2022: 498N1
# AutoCAD 2022: 777N1

# The installation is reliant on the setup binary. The binary command varies across Autodesk products.
# For example, Mudox 2022 and Maya 2022 uses the --noui switch, and Maya 2022 and AutoCAD uses the -q switch
# for triggering silent install. The path of the binary also varies.

# Tested on Maya 2022, Mudbox 2022 and AutoCAD 2022 - all good.

# Next work:
# Replace nested if statements. Can't keep adding new if statements for newer Autodesk versions.
# Helper binary path may change in future releases, use the find command.

########################################################################

# Set variables
pName="${4}"
pYear="${5}"
pKey="${6}"
licServer="{enter your lic server here}"
tmpFolder="/usr/local/tmp" # Installer app goes here. For example: /usr/local/tmp/Maya 2022/Install Maya 2022.app
findSetupFiles=$(find $tmpFolder -iname "setup")
licenseHelper="/Library/Application Support/Autodesk/AdskLicensing/11.0.0.4854/helper/AdskLicensingInstHelper"
currentuser=`python -c 'from SystemConfiguration import SCDynamicStoreCopyConsoleUser; import sys; username = (SCDynamicStoreCopyConsoleUser(None, None, None) or [None])[0]; username = [username,""][username in [u"loginwindow", None, u""]]; sys.stdout.write(username + "\n");'`

########################################################################

clear

# Scan Autodesk setup files in tmp folder.
echo ">> Autodesk setup file(s) found:"
echo "$findSetupFiles"

########################################################################

# Define functions

InstallMaya ()
{

# Locate full path to Maya setup file
MayaSetupFile=$(find $tmpFolder -iname "setup" | grep -w "Maya $pYear")

if [[ -f $MayaSetupFile ]] && [[ $pName = "Maya" ]]; then
echo ">> Maya $pYear setup file found."
echo ">> Running setup file: $MayaSetupFile"

if [[ $pYear = 2022 ]]; then
echo ">> Installing Maya 2022"
sudo "$MayaSetupFile" -q --hide_eula
fi
if [[ $pYear = 2018 ]]; then
echo ">> Installing Maya 2018"
sudo "$MayaSetupFile" --noui
fi
sleep 5

# Run licensing helper
echo ">> Running Maya licensing helper"
sudo "$licenseHelper" change --pk "$pKey" --pv "$pYear.0.0.F" --lm NETWORK --ls "$licServer"

else
if [[ $pName = "Maya" ]]; then
echo ">> Maya $pYear setup file not found. Nothing to do."
fi
fi

}
########################################################################
InstallAutoCAD ()
{
AutoCADSetupFile=$(find $tmpFolder -iname "setup" | grep "AutoCAD 2022")
echo "$AutoCADSetupFile"

if [[ -f $AutoCADSetupFile ]] && [[ $pName = "AutoCAD" ]]; then
echo ">> AutoCAD $pYear setup file found."
echo ">> Installing AutoCAD $pYear."
echo ">> Running setup file: $AutoCADSetupFile"
sudo "$AutoCADSetupFile" -q --hide_eula

# Fix permission for AutoCAD
/bin/chmod 777 /Users/$currentuser/Library/Application\ Support/Autodesk

sleep 5

# Run licensing helper
echo ">> Run AutoCAD licensing helper"
sudo "$licenseHelper" change --pk "$pKey" --pv "$pYear.0.0.F" --lm NETWORK --ls "$licServer"

else
if [[ $pName = "AutoCAD" ]]; then
echo ">> AutoCAD $pYear setup file not found. Nothing to do."
fi
fi

}
########################################################################
InstallMudbox ()
{
MudboxSetupFile=$(find $tmpFolder -iname "setup" | grep -w "Mudbox $pYear")

if [[ -f $MudboxSetupFile ]] && [[ $pName = "Mudbox" ]]; then
echo ">> Mudbox $pYear setup file found."
echo ">> Installing Mudbox 2022."
echo ">> Running setup file: $MudboxSetupFile"
sudo "$MudboxSetupFile" --noui

sleep 5

# Run licensing helper
echo ">> Running Mudbox licensing helper"
sudo "$licenseHelper" change --pk "$pKey" --pv "$pYear.0.0.F" --lm NETWORK --ls "$licServer"

else
if [[ $pName = "Mudbox" ]]; then
echo ">> Mudbox $pYear setup file not found. Nothing to do."
fi
fi

}
########################################################################
# Clean up tmp installer.
cleanUp ()
{
echo ">> Removing installation file in tmp folder."
/bin/rm -rf "$tmpFolder/$pName $pYear"
}
########################################################################

# Troubleshoot licensing issues
TroubleshootLicense ()
{
sudo "$licenseHelper" change --pk "657J1" --pv "2018.0.0.F" --lm NETWORK --ls ""

}
########################################################################

# Run functions
InstallMaya
InstallAutoCAD
InstallMudbox
cleanUp
# TroubleshootLicense

cgalik
Contributor

Has anyone successfully deployed and licensed either Maya 2022 or Mudbox 2022 on an M1 mac?  The installation seems to go through fine, but when either application is launched, Autodesk Licensing Manager crashes.