dforest
Posts: 2
Joined: Tue Jul 07, 2020 12:09 am

advanced installer Error 1924. Could not update environment variable 'Path'. Verify that you have sufficient privileges

Hi

We have updated to 17.4.1 and now get the following error when using the uninstaller after a successful installation: Error 1924. Could not update environment variable 'Path'. Verify that you have sufficient privileges to modify environment variables.

The aip file is the same that we used in 17.3 and 17.4 and we haven't had this issue before (in 17.3 for sure). Running the installer as adminstrator works.

The installer is an Enterprise installer and we are installing onto Windows 10 Pro.

Thanks

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

Re: advanced installer Error 1924. Could not update environment variable 'Path'. Verify that you have sufficient privile

Hello Darren and welcome to our forums,

If I am not mistaken, modifying system variables requires administrator rights:

systemVars.png
systemVars.png (85.63 KiB) Viewed 3112 times


When installing the setup, are you guys modifying the "Path" environment variable through our "Environment" page (e.g. adding your executable to it)?

If so, then I'd say the behavior is normal.

Now, another thing that we need to take into consideration here is the installation type and the way you guys are performing the uninstall.

If the installation type is of "Per-machine only", then when uninstalling the setup from Control Panel a UAC should be spawned, asking for administrative rights, thus this should not be a problem, since the user will always be asked to provide administrative privileges.

Hope this helps!

Best regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
dforest
Posts: 2
Joined: Tue Jul 07, 2020 12:09 am

Re: advanced installer Error 1924. Could not update environment variable 'Path'. Verify that you have sufficient privile

Hi Catalin

Thanks very much for the response. I have taken over building our installers. The reason I added this case was that the previous installer was created in 17.3. We didn't have this issue with that version on the same hardware. The issue happened when we moved the installer to 17.4.1. I have added comments inline.
When installing the setup, are you guys modifying the "Path" environment variable through our "Environment" page (e.g. adding your executable to it)?
I am using the "Environment" to modify and set the system variables.
Now, another thing that we need to take into consideration here is the installation type and the way you guys are performing the uninstall.

If the installation type is of "Per-machine only", then when uninstalling the setup from Control Panel a UAC should be spawned, asking for administrative rights, thus this should not be a problem, since the user will always be asked to provide administrative privileges.
The installation type is Per-user only. I wonder if I should be setting it to Per-user only (with administrator rights required)? Or should this be done as a per machine install? Is there any benefit?

Thanks

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

Re: advanced installer Error 1924. Could not update environment variable 'Path'. Verify that you have sufficient privile

Hello Darren,

Perhaps the old developer of the packages had the installtion type set to "per-machine"?

I am thinking about this because you have mentioned your installation type is "per-user" and you are trying to modify system variables.

Normaly, a per-user installation should not be able (unless provided with administrator privileges) modify the system variables.

The error should be encountered on the first time install as well, unless you install the setup as administrator.

When you open "System properties" --> "Advanced" tab --> "Environment Variables", you can see that there are two types of environment variables:

- per-user variables (variables availalbe for the current user)

- per-machine variables (or system) (variables available system-wide; by all users)

This is quite the difference between a "per-user" setup and a "per-machine" one.

A per-machine installation will install its' files in a per-machine location and all users should be able to access them. Such location can be the %programfiles% location (e.g. C:\Program Files). Writing to this location requires administrator privileges.

A per-user installation will install its' files in a per-user location and only the user who performed the installation will be able to access the them. Such location can be the %appdata% location. As opposed to the above, writing to this location does not require administrator privileges.

With this in mind, I would say the behavior is normal.

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

Return to “Common Problems”