/build/static/layout/Breadcrumb_cap_w.png

ERROR 1606 - With Autodesk Products & SMS

When installing Autodesk products via SMS as the system account we run into sporadic errors where the package runs fine as a user, but when run from sms fails with an error 1606 - can't access network location.

All the 1606 errors I have run into relate to the Windows installer trying to read / use a variable that is not populated. Different Autodesk products want to place files in different places. For example, Architectural Desktop wants to place some files in the My Documents folder, while the DWG viewer does not. The installer reads the variables from the system's registry. If running as a user it reads the variable from HKCU if running as the system account (such as via a GPO or SMS) it should read from the system registry HKEY-USERS\S-1-5-18\Software\Microsoft\Windows\Currentversion\Explorer\Shell Folders... but it appears that it is instead reading from HKEY-USERS\.DEFAULT.

I tried the fix suggest in Autodesk support article TS100633 but found the system registry was correctly populated and I was still getting the error. You can turn on verbose logging and compare a failed log to a successful log and see where it incorrectly sets a variable when the registry setting is not configured, then when it tries to read/write to that path it fails with the 1606 error that it cannot access the location because it does not exist.

The script below will populate all the default user values in the registry with the "default" values, except for the personal (my docs), app data, and local settings folder which are populated with the paths to the system account's profile. After making the changes on my test machines I did logon as a user without a profile to ensure new profile creation is not effected and indeed a new user's registry is normal (points to its own my docs folder, not the system's). I'm sending this script as a silent mandatory to all the systems to prevent further 1606 errors due to this cause. My guess is there is an error with the Windows installer technology, Autodesk's use of the installer is reading from the wrong key, or possibly the system account is being regenerated each time it runs for some reason and each time pulls its values from the default user registry... in any case, this script has been resolving the 1606 errors.'

The "default" default user settings I used came from this post which lead me to the fix - with outside help of course... hopeful this solves the same problems for others.

'==========================================================================
'
' VBScript Source File -- Created with SAPIEN Technologies PrimalScript 3.1
'
' NAME: SetDefaultUserReg.vbs
'
' AUTHOR: Andy King , CDM
' DATE : 7/19/2006
'
' COMMENT: populates the default user registry key with the required values
' to allow Autodesk software to be installed via SMS. "Should" work for
' Wndows Xp and Windows 2000...possibly Vista. Will quit if detects NT4.
' Uncomment the Wscript.Echo statements to see what keys/folders are Set
' and or created.
'===============================================================
On Error Resume Next

const HKEY_USERS = &H80000003

strComputer = "."

'get Os... quit if less than Win2000 (<v5)
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")

Set colOSes = objWMIService.ExecQuery("Select * from Win32_OperatingSystem")
For Each objOS in colOSes
iVersion = Left(objOS.Version,1) 'Version & build
If iVersion <5 Then
WScript.Quit
End IF
Next

Set oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\" &_
strComputer & "\root\default:StdRegProv")

Set objFSO = CreateObject("Scripting.FileSystemObject")

'Determine Windows Directory
Const WINDOWS = &H24&

Set objShell = CreateObject("Shell.Application")
Set objFolder = objShell.Namespace(WINDOWS)
Set objFolderItem = objFolder.Self
sWinDir = objFolderItem.Path 'grabs the path to windows or winnt

'Create Dictonary Object with all registry names/values to populate
Set oDicRegValues = CreateObject("Scripting.Dictionary")
oDicRegValues.CompareMode = TextMode

oDicRegValues.Add "AppData","c:\Documents and Settings\Default User\Application Data"
oDicRegValues.Add "Cookies","c:\Documents and Settings\Default User\Cookies"
oDicRegValues.Add "Desktop","c:\Documents and Settings\Default User\Desktop"
oDicRegValues.Add "Favorites","c:\Documents and Settings\Default User\Favorites"
oDicRegValues.Add "NetHood","c:\Documents and Settings\Default User\NetHood"
oDicRegValues.Add "Personal",sWinDir & "\system32\config\systemprofile\My Documents"
oDicRegValues.Add "My Pictures","c:\Documents and Settings\Default User\My Documents\My Pictures"
oDicRegValues.Add "PrintHood","c:\Documents and Settings\Default User\PrintHood"
oDicRegValues.Add "Recent","c:\Documents and Settings\Default User\Recent"
oDicRegValues.Add "SendTo","c:\Documents and Settings\Default User\SendTo"
oDicRegValues.Add "Start Menu","c:\Documents and Settings\Default User\Start Menu"
oDicRegValues.Add "Templates","c:\Documents and Settings\Default User\Templates"
oDicRegValues.Add "Programs","c:\Documents and Settings\Default User\Start Menu\Programs"
oDicRegValues.Add "Startup","c:\Documents and Settings\Default User\Start Menu\Programs\Startup"
oDicRegValues.Add "Local Settings",sWinDir & "\system32\config\systemprofile\Local Settings"
oDicRegValues.Add "Local AppData",sWinDir & "\system32\config\systemprofile\Local Settings\Application Data"
oDicRegValues.Add "Cache","c:\Documents and Settings\Default User\Local Settings\Temporary Internet Files"
oDicRegValues.Add "History","c:\Documents and Settings\Default User\Local Settings\History"
oDicRegValues.Add "Fonts",sWinDir & "\Fonts"

colKeys = oDicRegValues.Keys
For Each strKey In colKeys
strValueName = strKey
strValue = oDicRegValues.Item(strKey)
'WScript.Echo "Populating: " & strValueName & " [with] " & strValue
SetRegStringValue strValueName,strValue
CheckFolderExists(strValue)
Next

Sub SetRegStringValue(strValueName, strValue)
'Configure the Default User Local Settings Values
strKeyPath = ".DEFAULT\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders"
oReg.SetStringValue HKEY_USERS,strKeyPath,strValueName,strValue
End Sub

Sub CheckFolderExists(strValue)
'Create the corresponding paths if they do not exist
If NOT objFSO.FolderExists(strValue) Then
'WScript.Echo strValue & " does not exist, creating..."
Set objFolder = objFSO.CreateFolder(strValue)
Else
'WScript.Echo strValue & " exists."
End If
End Sub

0 Comments   [ + ] Show comments

Answers (14)

Posted by: Witto 6 years ago
Senior Yellow Belt
0

For the silent or quiet (unattended) installation of Autodesk Design Review or DWG TrueView, create a batch file next to Setup.exe, name it Install.cmd, Setup.cmd, Install.bat or Setup.bat or so. Write in the file:


@Echo Off

start /w "" "%~dp0Setup.exe" /S /Q /W /I"%~dp0Setup.ini"


The /W makes Setup.exe wait intill the end of the installation. The return code or errorlevel or exit code should now be 0.

Posted by: Witto 6 years ago
Senior Yellow Belt
0

For the silent or quiet (unattended) installation of Autodesk Design Review or DWG TrueView, create a batch file next to Setup.exe, name it Install.cmd, Setup.cmd, Install.bat or Setup.bat or so. Write in the file:


@Echo Off

start /w "" "%~dp0Setup.exe" /S /Q /W /I"%~dp0Setup.ini"


The /W makes Setup.exe wait intill the end of the installation. The return code or errorlevel or exit code should now be 0.

Posted by: cduplessis 16 years ago
Orange Senior Belt
0
Would this same vb file work for any application?
Posted by: AndyKingCDM 16 years ago
Yellow Belt
0
Currently I am using it for all the Autodesk 2008 "verticals" AutoCAD 2008, Civil 3D 2008, ADT2008, MEP 2008, TrueView 2008 / also for previous version. I have modified it so it checks/fills in more default registry settings. The example below is likely missing a couple const values stored in the lager install script. But the subroutine I use is below.

I have SMS run a vbscript that runs the Autodesk network install/setup.exe that is created from the Autodesk DVD. The vbscript makes the reg change, pauses the antivirus service, runs the network install / monitors it for completion, makes some post install customizations, then resumes the antivirus service. I've used it to deploy Autodesk products to around 2000 workstations.

Sub FixAutoDeskRegIssue()
strComputer = "."

Set oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\" &_
strComputer & "\root\default:StdRegProv")
'===================================================
'Set Default User Reg Values
'===================================================
Set oRegDic = CreateObject("Scripting.Dictionary")
oRegDic.CompareMode = TextMode

oRegDic.Add "AppData","C:\WINDOWS\system32\config\systemprofile\Application Data"
oRegDic.Add "Cookies","C:\WINDOWS\system32\config\systemprofile\Cookies"
oRegDic.Add "Desktop","C:\WINDOWS\system32\config\systemprofile\Desktop"
oRegDic.Add "Favorites","C:\WINDOWS\system32\config\systemprofile\Favorites"
oRegDic.Add "NetHood","C:\WINDOWS\system32\config\systemprofile\NetHood"
oRegDic.Add "Personal","C:\WINDOWS\system32\config\systemprofile\My Documents"
oRegDic.Add "PrintHood","C:\WINDOWS\system32\config\systemprofile\PrintHood"
oRegDic.Add "Recent","C:\WINDOWS\system32\config\systemprofile\Recent"
oRegDic.Add "SendTo","C:\WINDOWS\system32\config\systemprofile\SendTo"
oRegDic.Add "Start Menu","C:\WINDOWS\system32\config\systemprofile\Start Menu"
oRegDic.Add "Templates","C:\WINDOWS\system32\config\systemprofile\Templates"
oRegDic.Add "Programs","C:\WINDOWS\system32\config\systemprofile\Start Menu\Programs"
oRegDic.Add "Startup","C:\WINDOWS\system32\config\systemprofile\Start Menu\Programs\Startup"
oRegDic.Add "Local Settings","C:\WINDOWS\system32\config\systemprofile\Local Settings"
oRegDic.Add "Local AppData","C:\WINDOWS\system32\config\systemprofile\Local Settings\Application Data"
oRegDic.Add "Cache","C:\WINDOWS\system32\config\systemprofile\Local Settings\Temporary Internet Files"
oRegDic.Add "History","C:\WINDOWS\system32\config\systemprofile\Local Settings\History"
oRegDic.Add "My Pictures","C:\WINDOWS\system32\config\systemprofile\My Documents\My Pictures"
oRegDic.Add "Fonts","C:\WINDOWS\Fonts"
oRegDic.Add "My Music","C:\WINDOWS\system32\config\systemprofile\My Documents\My Music"
oRegDic.Add "CD Burning","C:\WINDOWS\system32\config\systemprofile\Local Settings\Application Data\Microsoft\CD Burning"
oRegDic.Add "My Video","C:\WINDOWS\system32\config\systemprofile\My Documents\My Videos"
oRegDic.Add "Administrative Tools","C:\WINDOWS\system32\config\systemprofile\Start Menu\Programs\Administrative Tools"

strKeyPath = ".DEFAULT\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders"
colKeys = oRegDic.Keys
For Each sKey in colKeys
sValName = sKey
sVal = oRegDic.Item(sKey)
SetHkuRegValue strKeyPath,sValName,sVal
Next

'===================================================
'Set System Reg Values
'===================================================
Set oSysRegDic = CreateObject("Scripting.Dictionary")
oSysRegDic.CompareMode = TextMode

oSysRegDic.Add "AppData","C:\WINDOWS\system32\config\systemprofile\Application Data"
oSysRegDic.Add "Cookies","C:\WINDOWS\system32\config\systemprofile\Cookies"
oSysRegDic.Add "Desktop","C:\WINDOWS\system32\config\systemprofile\Desktop"
oSysRegDic.Add "Favorites","C:\WINDOWS\system32\config\systemprofile\Favorites"
oSysRegDic.Add "NetHood","C:\WINDOWS\system32\config\systemprofile\NetHood"
oSysRegDic.Add "Personal","C:\WINDOWS\system32\config\systemprofile\My Documents"
oSysRegDic.Add "PrintHood","C:\WINDOWS\system32\config\systemprofile\PrintHood"
oSysRegDic.Add "Recent","C:\WINDOWS\system32\config\systemprofile\Recent"
oSysRegDic.Add "SendTo","C:\WINDOWS\system32\config\systemprofile\SendTo"
oSysRegDic.Add "Start Menu","C:\WINDOWS\system32\config\systemprofile\Start Menu"
oSysRegDic.Add "Templates","C:\WINDOWS\system32\config\systemprofile\Templates"
oSysRegDic.Add "Programs","C:\WINDOWS\system32\config\systemprofile\Start Menu\Programs"
oSysRegDic.Add "Startup","C:\WINDOWS\system32\config\systemprofile\Start Menu\Programs\Startup"
oSysRegDic.Add "Local Settings","C:\WINDOWS\system32\config\systemprofile\Local Settings"
oSysRegDic.Add "Local AppData","C:\WINDOWS\system32\config\systemprofile\Local Settings\Application Data"
oSysRegDic.Add "Cache","C:\WINDOWS\system32\config\systemprofile\Local Settings\Temporary Internet Files"
oSysRegDic.Add "History","C:\WINDOWS\system32\config\systemprofile\Local Settings\History"
oSysRegDic.Add "My Pictures","C:\WINDOWS\system32\config\systemprofile\My Documents\My Pictures"
oSysRegDic.Add "Fonts","C:\WINDOWS\Fonts"
oSysRegDic.Add "My Music","C:\WINDOWS\system32\config\systemprofile\My Documents\My Music"
oSysRegDic.Add "CD Burning","C:\WINDOWS\system32\config\systemprofile\Local Settings\Application Data\Microsoft\CD Burning"
oSysRegDic.Add "My Video","C:\WINDOWS\system32\config\systemprofile\My Documents\My Videos"
oSysRegDic.Add "Administrative Tools","C:\WINDOWS\system32\config\systemprofile\Start Menu\Programs\Administrative Tools"

strKeyPath = "S-1-5-18\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders"
colKeys = oRegDic.Keys
For Each sKey in colKeys
sValName = sKey
sVal = oRegDic.Item(sKey)
SetHkuRegValue strKeyPath,sValName,sVal
Next

'===================================================
'Set LocalService Reg Values
'===================================================
Set oLSRegDic = CreateObject("Scripting.Dictionary")
oLSRegDic.CompareMode = TextMode

oLSRegDic.Add "AppData","C:\Documents and Settings\LocalService\Application Data"
oLSRegDic.Add "Cookies","C:\Documents and Settings\LocalService\Cookies"
oLSRegDic.Add "Desktop","C:\Documents and Settings\LocalService\Desktop"
oLSRegDic.Add "Favorites","C:\Documents and Settings\LocalService\Favorites"
oLSRegDic.Add "NetHood","C:\Documents and Settings\LocalService\NetHood"
oLSRegDic.Add "Personal","C:\Documents and Settings\LocalService\My Documents"
oLSRegDic.Add "PrintHood","C:\Documents and Settings\LocalService\PrintHood"
oLSRegDic.Add "Recent","C:\Documents and Settings\LocalService\Recent"
oLSRegDic.Add "SendTo","C:\Documents and Settings\LocalService\SendTo"
oLSRegDic.Add "Start Menu","C:\Documents and Settings\LocalService\Start Menu"
oLSRegDic.Add "Templates","C:\Documents and Settings\LocalService\Templates"
oLSRegDic.Add "Programs","C:\Documents and Settings\LocalService\Start Menu\Programs"
oLSRegDic.Add "Startup","C:\Documents and Settings\LocalService\Start Menu\Programs\Startup"
oLSRegDic.Add "Local Settings","C:\Documents and Settings\LocalService\Local Settings"
oLSRegDic.Add "Local AppData","C:\Documents and Settings\LocalService\Local Settings\Application Data"
oLSRegDic.Add "Cache","C:\Documents and Settings\LocalService\Local Settings\Temporary Internet Files"
oLSRegDic.Add "History","C:\Documents and Settings\LocalService\Local Settings\History"
oLSRegDic.Add "My Pictures","C:\Documents and Settings\LocalService\My Documents\My Pictures"
oLSRegDic.Add "Fonts","C:\WINDOWS\Fonts"
oLSRegDic.Add "My Music","C:\Documents and Settings\LocalService\My Documents\My Music"
oLSRegDic.Add "CD Burning","C:\Documents and Settings\LocalService\Local Settings\Application Data\Microsoft\CD Burning"
oLSRegDic.Add "My Video","C:\Documents and Settings\LocalService\My Documents\My Videos"
oLSRegDic.Add "Administrative Tools","C:\Documents and Settings\LocalService\Start Menu\Programs\Administrative Tools"
strKeyPath = "S-1-5-19\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders"

colKeys = oLSRegDic.Keys
For Each sKey in colKeys
sValName = sKey
sVal = oLSRegDic.Item(sKey)
SetHkuRegValue strKeyPath,sValName,sVal
Next

'===================================================
'Set NetworkService Reg Values
'===================================================
Set oNSRegDic = CreateObject("Scripting.Dictionary")
oNSRegDic.CompareMode = TextMode

oNSRegDic.Add "AppData","C:\Documents and Settings\NetworkService\Application Data"
oNSRegDic.Add "Cookies","C:\Documents and Settings\NetworkService\Cookies"
oNSRegDic.Add "Desktop","C:\Documents and Settings\NetworkService\Desktop"
oNSRegDic.Add "Favorites","C:\Documents and Settings\NetworkService\Favorites"
oNSRegDic.Add "NetHood","C:\Documents and Settings\NetworkService\NetHood"
oNSRegDic.Add "Personal","C:\Documents and Settings\NetworkService\My Documents"
oNSRegDic.Add "PrintHood","C:\Documents and Settings\NetworkService\PrintHood"
oNSRegDic.Add "Recent","C:\Documents and Settings\NetworkService\Recent"
oNSRegDic.Add "SendTo","C:\Documents and Settings\NetworkService\SendTo"
oNSRegDic.Add "Start Menu","C:\Documents and Settings\NetworkService\Start Menu"
oNSRegDic.Add "Templates","C:\Documents and Settings\NetworkService\Templates"
oNSRegDic.Add "Programs","C:\Documents and Settings\NetworkService\Start Menu\Programs"
oNSRegDic.Add "Startup","C:\Documents and Settings\NetworkService\Start Menu\Programs\Startup"
oNSRegDic.Add "Local Settings","C:\Documents and Settings\NetworkService\Local Settings"
oNSRegDic.Add "Local AppData","C:\Documents and Settings\NetworkService\Local Settings\Application Data"
oNSRegDic.Add "Cache","C:\Documents and Settings\NetworkService\Local Settings\Temporary Internet Files"
oNSRegDic.Add "History","C:\Documents and Settings\NetworkService\Local Settings\History"
oNSRegDic.Add "My Pictures","C:\Documents and Settings\NetworkService\My Documents\My Pictures"
oNSRegDic.Add "Fonts","C:\WINDOWS\Fonts"
oNSRegDic.Add "My Music","C:\Documents and Settings\NetworkService\My Documents\My Music"
oNSRegDic.Add "CD Burning","C:\Documents and Settings\NetworkService\Local Settings\Application Data\Microsoft\CD Burning"
oNSRegDic.Add "My Video","C:\Documents and Settings\NetworkService\My Documents\My Videos"
oNSRegDic.Add "Administrative Tools","C:\Documents and Settings\NetworkService\Start Menu\Programs\Administrative Tools"
strKeyPath = "S-1-5-20\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders"

colKeys = oNSRegDic.Keys

For Each sKey in colKeys
sValName = sKey
sVal = oNSRegDic.Item(sKey)
SetHkuRegValue strKeyPath,sValName,sVal
Next
WriteToLog("Done Correcting Registry Values")
End Sub

Sub SetHkuRegValue(strKeyPath,strValueName,strValue)
oReg.SetStringValue HKEY_USERS,strKeyPath,strValueName,strValue
WriteToLog("HKEY_USERS,"&strKeyPath)
WriteToLog(strValueName & " | " & strValue)
End Sub
Posted by: anonymous_9363 16 years ago
Red Belt
0
Nice....

One point-ette, though: purists might like to alter the code so that the engine only needs to make one reference to the object being used. That is:

oLSRegDic.Add "AppData","C:\Documents and Settings\LocalService\Application Data"
oLSRegDic.Add "Cookies","C:\Documents and Settings\LocalService\Cookies"
etc, etc


becomes



With oLSRegDic
.Add "AppData","C:\Documents and Settings\LocalService\Application Data"
.Add "Cookies","C:\Documents and Settings\LocalService\Cookies"
etc, etc
End With
Posted by: tommy_a_d 16 years ago
Yellow Belt
0
I am trying to deploy the above mentioned product with SCCM 2007, can you post more specificlly how you are doing it? I have tried using the Civil 3d.lnk file in the Program, and also the setup.exe but to avail!
Posted by: oilernut 16 years ago
Senior Yellow Belt
0
Been trying to package Map 3D 2008 and push it out via Altiris to Vista SP1 machine.

I used the steps above to get around the 1606 error code, but now I am getting a 259 error message saying "no more data is avaliable."

Also has anyone been able to slipstream the service packs into the main msi? It seems the only way to do it is through their deployment method.
Posted by: msi_support 15 years ago
Orange Belt
0
I have to install Civil 3D 2009 from SMS and I have a similar issue on Vista. In XP, everything works fine.
In Vista, when I install the app logged in as an admin, it installs fine. If i am logged in as a normal user and try to install ('Run As' an admin) the installation fails.
Log file for the MSI shows [Product: AutoCAD Civil 3D 2009 -- Error 1606. Could not access network location Autodesk\LandXML Reporting]
I did use the above script but I guess I got a few paths wrong in my script for Vista. I shall try it again.
Meanwhile could someone give me some more ideas on what else can be tried.
Posted by: msi_support 15 years ago
Orange Belt
0
I have changed the script to this and it did put all the entries in registry but no luck with the install [8|]
Please let me know if I am doing something wrong here..
Posted by: anonymous_9363 15 years ago
Red Belt
0
I don't know how I missed this when the thread was more current but you do know, of course, that in spite of its name, HKEY_USERS\.Default is NOT the default user profile hive? It's the local System user's profile hive. It's not generally a good idea to mess with stuff there.

Find out which path isn't being resolved correctly and fix that. A verbose log will show you all you need to know. Remember that any "odd" path is regarded as a network location by the WI engine, keeping up Microsoft's tradition of displaying error messages along the lines of "Something happened, I can't actually work out what it was but I have to tell you something so I'm going with this [error text follows]". Anyone who played with Word for Windows v1 with network-stored user templates will remember the classic message "Word cannot print" when, in reality, the problem was that the user had no drive mapped (or no write access) to the template location.

Oh, BTW, the CODE tag still exists in this forum. Please use it! :)
Posted by: msi_support 14 years ago
Orange Belt
0
What worked for me

On a clean build here, all the registries in the path HKCU\Software\Microsoft\Windows\Current Version\Explorer\Shell Folders had %USERPROFILE% in the string values.
Apparently that was causing my MSI to not resolve paths. So modifying these entries made all the difference.
Example: AppData=%USERPROFILE%\AppData\Roaming changed to AppData=C:\Users\testuser\AppData\Roaming

I did not modify anything in the HKEY_USERS\.Default. Instead, I wrote a small wisescript to resolve the paths in the HKCU\Software\Microsoft\Windows\Current Version\Explorer\Shell Folders entries and the Civil 3d 2009 install went fine.
Thanks once again to everyone here!!
Posted by: anonymous_9363 14 years ago
Red Belt
0
I suspect the paths weren't resolved because your property usage was incorrect. If you want to use properties based on environment variables, the format should be [%USERPROFILE]AppData\Roaming
Posted by: AngelD 14 years ago
Red Belt
0
ORIGINAL: VBScab
the format should be [%USERPROFILE]AppData\Roaming

Don't forget the back-slash [;)]
[%USERPROFILE]\AppData\Roaming
Posted by: anonymous_9363 14 years ago
Red Belt
0
Good catch, Kim. I was forgetting env. vars don't get resolved with trailing backslahses.
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ