nchounlapane
Posts: 28
Joined: Tue Mar 31, 2020 10:01 pm

Changing TEMP directory folder

Fri Apr 14, 2023 8:06 pm

Is there a way to change where the installer uses the TEMP directory? It seems that the installer is geared towards using the TEMP environmental variable path. I am wondering if we are able to direct the installer to use a different path without changing the TEMP environmental variable?

Catalin
Posts: 6542
Joined: Wed Jun 13, 2018 7:49 am

Re: Changing TEMP directory folder

Wed Apr 19, 2023 1:12 pm

Hello,

Indeed, if you add a file as a "Temporary File", it will be added in the "Temporary" folder which at install time resolves to the %temp% environment variable.

What you can do is create a new folder and move your "Temporary Files" there. However, please make sure that this is not a location that requires elevated permissions unless you are running your setup as administrator from the start.
Screenshot_27.png
Screenshot_27.png (10.8KiB)Viewed 7616 times

In the above example, the folder C:\test will be created on the disk and test2.txt will be extracted there at the very start of the installation.

Hope this helps!

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

nchounlapane
Posts: 28
Joined: Tue Mar 31, 2020 10:01 pm

Re: Changing TEMP directory folder

Wed Apr 19, 2023 5:43 pm

Catalin,

My follow up question would be that since the install log and PowerShell scripts uses %TEMP% by default, we would have to manually change each of them to use a designated TEMP folder as you mentioned? Also, how do you also change the output of where the SQL log file (AI_SQLScripts.log) will be generated?

Nick

Catalin
Posts: 6542
Joined: Wed Jun 13, 2018 7:49 am

Re: Changing TEMP directory folder

Thu Apr 20, 2023 12:44 pm

Hello Nick,

No, please ignore my previous reply as I thought you meant the temporary files, you didn't mention anything about PowerShell.

If you'd like to change the location for your PowerShell inline script, simply click on the "PowerShell Script Options" hyperlink.
Screenshot_113.png
Screenshot_113.png (25.91KiB)Viewed 7031 times

Hope this helps!

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

nchounlapane
Posts: 28
Joined: Tue Mar 31, 2020 10:01 pm

Re: Changing TEMP directory folder

Thu Apr 20, 2023 6:02 pm

I apologize if I wasn't clear. Our goal is for the installer to navigate away using the %TEMP% directory. I'm aware that you can change where PowerShell scripts can be launched and where the verbose log gets generated by updating the MSI command line. Is there a way where we can assure that the installer not use the %TEMP% directory, and use a different directory for any operations?

Nick

Catalin
Posts: 6542
Joined: Wed Jun 13, 2018 7:49 am

Re: Changing TEMP directory folder

Tue Apr 25, 2023 3:04 pm

Hello Nick,

Thank you for your followup on this!

I understand what you are trying to achieve now, but I'm afraid that would not be possible.

If you have any other questions, please let me know and I will gladly assist.

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”