Re: [WiX-users] Environment Variable Changes by MSI are not reflected
If you want to do patching, do a minor upgrade (but only when patching). If you don't, don't (ever). That's my take. It's served me and my clients well for several years now. > From: keith.doug...@statcan.gc.ca > To: wix-users@lists.sourceforge.net > Date: Mon, 4 Nov 2013 08:58:02 -0500 > Subject: Re: [WiX-users] Environment Variable Changes by MSI are not > reflected > > By the way, the last sentence of Nicolás' remarks seems to be our single > biggest problem "with WiX" here - so much stuff does unoptimal practice with > installations, file locations, environment set up, OS settings, etc. it is > difficult for a few people like myself to show that a more optimal practice > is desirable ... I get "but XYZ does it that way!" a lot. We all learn from > examples, and unfortunately it when it comes to installation especially > examples are hard to find that illustrate various principles. For example, I > am still (like many here) trying to figure out when one *would* do a Minor > Upgrade vs. a Major Upgrade. I understand now what the difference in effect > is, I think, but that still leaves why. > > > > > Keith Douglas > Statistics Canada | 170 Tunney's Pasture Driveway, Ottawa ON K1A 0T6 > Statistique Canada | 170, promenade Tunney's Pasture, Ottawa ON K1A 0T6 > keith.doug...@statcan.gc.ca > Telephone | Téléphone 613-951-4405 > Facsimile | Télécopieur 613-951-1966 > Government of Canada | Gouvernement du Canada > > > -Original Message- > From: Nicolás Alvarez [mailto:nicolas.alva...@gmail.com] > Sent: November-03-13 3:22 PM > To: General discussion about the WiX toolset. > Subject: Re: [WiX-users] Environment Variable Changes by MSI are not reflected > > 2013/11/1 Phil Wilson : > > If there's a way to avoid using PATH, try to find it and use it. > > There are always issues with that, not only install and uninstall but > > corruption, files and Dlls being picked up from the wrong directory and so > > on. > > I concur. > > I had problems during development with an application failing to start, > saying a DLL of a wrong architecture was being loaded. It turns out an Intel > Wi-Fi driver (or whatever OEM crapware it was, but it was definitely from > Intel) adds its program folder to the PATH, and there's a 64-bit zlib1.dll in > there. > > That's just one of half a dozen directories the Intel crapware added to my > PATH. Just because the big guys are doing it doesn't make it right. > > -- > Nicolás > > -- > Android is increasing in popularity, but the open development platform that > developers love is also attractive to malware creators. Download this white > paper to learn more about secure code signing practices that can help keep > Android apps secure. > http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk > ___ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users > -- > Android is increasing in popularity, but the open development platform that > developers love is also attractive to malware creators. Download this white > paper to learn more about secure code signing practices that can help keep > Android apps secure. > http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk > ___ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users -- November Webinars for C, C++, Fortran Developers Accelerate application performance with scalable programming models. Explore techniques for threading, error checking, porting, and tuning. Get the most from the latest Intel processors and coprocessors. See abstracts and register http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk ___ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users
Re: [WiX-users] Environment Variable Changes by MSI are not reflected
By the way, the last sentence of Nicolás' remarks seems to be our single biggest problem "with WiX" here - so much stuff does unoptimal practice with installations, file locations, environment set up, OS settings, etc. it is difficult for a few people like myself to show that a more optimal practice is desirable ... I get "but XYZ does it that way!" a lot. We all learn from examples, and unfortunately it when it comes to installation especially examples are hard to find that illustrate various principles. For example, I am still (like many here) trying to figure out when one *would* do a Minor Upgrade vs. a Major Upgrade. I understand now what the difference in effect is, I think, but that still leaves why. Keith Douglas Statistics Canada | 170 Tunney's Pasture Driveway, Ottawa ON K1A 0T6 Statistique Canada | 170, promenade Tunney's Pasture, Ottawa ON K1A 0T6 keith.doug...@statcan.gc.ca Telephone | Téléphone 613-951-4405 Facsimile | Télécopieur 613-951-1966 Government of Canada | Gouvernement du Canada -Original Message- From: Nicolás Alvarez [mailto:nicolas.alva...@gmail.com] Sent: November-03-13 3:22 PM To: General discussion about the WiX toolset. Subject: Re: [WiX-users] Environment Variable Changes by MSI are not reflected 2013/11/1 Phil Wilson : > If there's a way to avoid using PATH, try to find it and use it. > There are always issues with that, not only install and uninstall but > corruption, files and Dlls being picked up from the wrong directory and so on. I concur. I had problems during development with an application failing to start, saying a DLL of a wrong architecture was being loaded. It turns out an Intel Wi-Fi driver (or whatever OEM crapware it was, but it was definitely from Intel) adds its program folder to the PATH, and there's a 64-bit zlib1.dll in there. That's just one of half a dozen directories the Intel crapware added to my PATH. Just because the big guys are doing it doesn't make it right. -- Nicolás -- Android is increasing in popularity, but the open development platform that developers love is also attractive to malware creators. Download this white paper to learn more about secure code signing practices that can help keep Android apps secure. http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk ___ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users -- Android is increasing in popularity, but the open development platform that developers love is also attractive to malware creators. Download this white paper to learn more about secure code signing practices that can help keep Android apps secure. http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk ___ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users
Re: [WiX-users] Environment Variable Changes by MSI are not reflected
2013/11/1 Phil Wilson : > If there's a way to avoid using PATH, try to find it and use it. There are > always issues with that, not only install and uninstall but corruption, > files and Dlls being picked up from the wrong directory and so on. I concur. I had problems during development with an application failing to start, saying a DLL of a wrong architecture was being loaded. It turns out an Intel Wi-Fi driver (or whatever OEM crapware it was, but it was definitely from Intel) adds its program folder to the PATH, and there's a 64-bit zlib1.dll in there. That's just one of half a dozen directories the Intel crapware added to my PATH. Just because the big guys are doing it doesn't make it right. -- Nicolás -- Android is increasing in popularity, but the open development platform that developers love is also attractive to malware creators. Download this white paper to learn more about secure code signing practices that can help keep Android apps secure. http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk ___ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users
Re: [WiX-users] Environment Variable Changes by MSI are not reflected
I agree. I feel dirty whenever someone asks me to modify the path. It's usually the Java guy s but then the MS PowerShell guys come by and they only give you two options (that I know of) to register a module. 1) Update the PSModulePath and 2) Install in the root PowerShell Modules path under SystemFolder32/64. That just seems wrong. I don't like option #1 either but I guess it made perfect sense to them since they were trying to make a great "shell" experience. From: "Phil Wilson" Sent: Friday, November 01, 2013 12:38 PM To: "General discussion about the WiX toolset." Subject: Re: [WiX-users] Environment Variable Changes by MSI are not reflected The general rule is that if the process is already running it won't pick up the new environment strings, which is why things like services and command prompts won't pick up the new values. Sometimes the definition of "new process" isn't that obvious. If you have a running command prompt from which you do the install and then run the PowerShell then I'm pretty sure anything you fire off from that prompt after the install will not get the new values because they are propagated from the command prompt that has been continually running, just as an example. So I don't know how exactly that PowerShell context works in that environment (pun intended). If there's a way to avoid using PATH, try to find it and use it. There are always issues with that, not only install and uninstall but corruption, files and Dlls being picked up from the wrong directory and so on. For example, if your install stored in the registry the location of the files you want to run it's likely that the PowerShell script could find them without resorting to PATH. Phil Wilson On Thu, Oct 31, 2013 at 3:25 PM, Christopher Painter wrote: > I've done this recently and two things can bite you: > > 1) Windows Installer WriteEnvironmentStrings doesn't send the broadcast > message if there is a pending reboot already. > 2) If you want to use it in a windows service ( such as IIS worker pool ) > you'll have to take the reboot for it to take effect. > > > From: "Suryadeep Biswal" > Sent: Thursday, October 31, 2013 4:23 PM > To: "General discussion about the WiX toolset." < > wix-users@lists.sourceforge.net> > Subject: Re: [WiX-users] Environment Variable Changes by MSI are not > reflected > > After installing the MSI, we require the users run a PowerShell cmdlet for > configuring the machine. This cmdlet depends on binaries that are present > in the directory that we add to "PATH" in the MSI. Since the value of > "PATH" does not change (even in a new process), the users have issues > running the PowerShell cmdlet. I would expect it to take effect immediately > after MSI installation so that any new process have the updated value for > "PATH" variable. > Regards,Surya > > > Date: Thu, 31 Oct 2013 13:11:59 -0700 > > From: phildgwil...@gmail.com > > To: wix-users@lists.sourceforge.net > > Subject: Re: [WiX-users] Environment Variable Changes by MSI are not > reflected > > > > The short answer is yes. The longer answer depends on exactly where you > > expect it take effect. What's the exact problem? It doesn't get picked > by a > > program? By a command prompt? It doesn't get used when you run something? > > > > > http://superuser.com/questions/351279/adding-a-directory-to-user-path-doesnt -work > > > > > > Phil Wilson > > > > > > On Thu, Oct 31, 2013 at 11:53 AM, Suryadeep Biswal < > surya6...@hotmail.com>wrote: > > > > > Hi, > > > > > > > > > > > > Our MSI uses the inbuilt Environment > > > WIX element to add a directory to PATH > > > variable. We are seeing an issue on Windows Blue/8.1 where this does > not > > > get > > > reflected until the user logs off and logs on. Is this a known issue? > Are > > > there > > > any alternatives to set the environment variable other than writing a > > > Custom > > > Action? Please advise. > > > > > > > > > > > > This is from our WXS file - > > > > > > > > Name="PATH" Action="set" Part="last" System="yes" > > > Value="" Permanent="no"/> > > > > > > > > > > > > Regards, > > > > > > Surya > > > > > > > > > > > > >
Re: [WiX-users] Environment Variable Changes by MSI are not reflected
The general rule is that if the process is already running it won't pick up the new environment strings, which is why things like services and command prompts won't pick up the new values. Sometimes the definition of "new process" isn't that obvious. If you have a running command prompt from which you do the install and then run the PowerShell then I'm pretty sure anything you fire off from that prompt after the install will not get the new values because they are propagated from the command prompt that has been continually running, just as an example. So I don't know how exactly that PowerShell context works in that environment (pun intended). If there's a way to avoid using PATH, try to find it and use it. There are always issues with that, not only install and uninstall but corruption, files and Dlls being picked up from the wrong directory and so on. For example, if your install stored in the registry the location of the files you want to run it's likely that the PowerShell script could find them without resorting to PATH. Phil Wilson On Thu, Oct 31, 2013 at 3:25 PM, Christopher Painter wrote: > I've done this recently and two things can bite you: > > 1) Windows Installer WriteEnvironmentStrings doesn't send the broadcast > message if there is a pending reboot already. > 2) If you want to use it in a windows service ( such as IIS worker pool ) > you'll have to take the reboot for it to take effect. > > > From: "Suryadeep Biswal" > Sent: Thursday, October 31, 2013 4:23 PM > To: "General discussion about the WiX toolset." < > wix-users@lists.sourceforge.net> > Subject: Re: [WiX-users] Environment Variable Changes by MSI are not > reflected > > After installing the MSI, we require the users run a PowerShell cmdlet for > configuring the machine. This cmdlet depends on binaries that are present > in the directory that we add to "PATH" in the MSI. Since the value of > "PATH" does not change (even in a new process), the users have issues > running the PowerShell cmdlet. I would expect it to take effect immediately > after MSI installation so that any new process have the updated value for > "PATH" variable. > Regards,Surya > > > Date: Thu, 31 Oct 2013 13:11:59 -0700 > > From: phildgwil...@gmail.com > > To: wix-users@lists.sourceforge.net > > Subject: Re: [WiX-users] Environment Variable Changes by MSI are not > reflected > > > > The short answer is yes. The longer answer depends on exactly where you > > expect it take effect. What's the exact problem? It doesn't get picked > by a > > program? By a command prompt? It doesn't get used when you run something? > > > > > http://superuser.com/questions/351279/adding-a-directory-to-user-path-doesnt-work > > > > > > Phil Wilson > > > > > > On Thu, Oct 31, 2013 at 11:53 AM, Suryadeep Biswal < > surya6...@hotmail.com>wrote: > > > > > Hi, > > > > > > > > > > > > Our MSI uses the inbuilt Environment > > > WIX element to add a directory to PATH > > > variable. We are seeing an issue on Windows Blue/8.1 where this does > not > > > get > > > reflected until the user logs off and logs on. Is this a known issue? > Are > > > there > > > any alternatives to set the environment variable other than writing a > > > Custom > > > Action? Please advise. > > > > > > > > > > > > This is from our WXS file - > > > > > > > > Name="PATH" Action="set" Part="last" System="yes" > > > Value="" Permanent="no"/> > > > > > > > > > > > > Regards, > > > > > > Surya > > > > > > > > > > > > > -- > > > Android is increasing in popularity, but the open development platform > that > > > developers love is also attractive to malware creators. Download this > white > > > paper to learn more about secure code signing practices that can help > keep > > > Android apps secure. > > > > http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk > > > ___ > > > WiX-users mailing list > > > WiX-users@lists.sourceforge.net > > > https://lists.sourceforge.net/lists/listinfo/wix-users > > > > > > ---
Re: [WiX-users] Environment Variable Changes by MSI are not reflected
I've done this recently and two things can bite you: 1) Windows Installer WriteEnvironmentStrings doesn't send the broadcast message if there is a pending reboot already. 2) If you want to use it in a windows service ( such as IIS worker pool ) you'll have to take the reboot for it to take effect. From: "Suryadeep Biswal" Sent: Thursday, October 31, 2013 4:23 PM To: "General discussion about the WiX toolset." Subject: Re: [WiX-users] Environment Variable Changes by MSI are not reflected After installing the MSI, we require the users run a PowerShell cmdlet for configuring the machine. This cmdlet depends on binaries that are present in the directory that we add to "PATH" in the MSI. Since the value of "PATH" does not change (even in a new process), the users have issues running the PowerShell cmdlet. I would expect it to take effect immediately after MSI installation so that any new process have the updated value for "PATH" variable. Regards,Surya > Date: Thu, 31 Oct 2013 13:11:59 -0700 > From: phildgwil...@gmail.com > To: wix-users@lists.sourceforge.net > Subject: Re: [WiX-users] Environment Variable Changes by MSI are not > reflected > > The short answer is yes. The longer answer depends on exactly where you > expect it take effect. What's the exact problem? It doesn't get picked by a > program? By a command prompt? It doesn't get used when you run something? > > http://superuser.com/questions/351279/adding-a-directory-to-user-path-doesnt-work > > > Phil Wilson > > > On Thu, Oct 31, 2013 at 11:53 AM, Suryadeep Biswal > wrote: > > > Hi, > > > > > > > > Our MSI uses the inbuilt Environment > > WIX element to add a directory to PATH > > variable. We are seeing an issue on Windows Blue/8.1 where this does not > > get > > reflected until the user logs off and logs on. Is this a known issue? Are > > there > > any alternatives to set the environment variable other than writing a > > Custom > > Action? Please advise. > > > > > > > > This is from our WXS file - > > > > > Name="PATH" Action="set" Part="last" System="yes" > > Value="" Permanent="no"/> > > > > > > > > Regards, > > > > Surya > > > > > > > > -- > > Android is increasing in popularity, but the open development platform that > > developers love is also attractive to malware creators. Download this white > > paper to learn more about secure code signing practices that can help keep > > Android apps secure. > > http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk > > ___ > > WiX-users mailing list > > WiX-users@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/wix-users > > > -- > Android is increasing in popularity, but the open development platform that > developers love is also attractive to malware creators. Download this white > paper to learn more about secure code signing practices that can help keep > Android apps secure. > http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk > ___ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users -- Android is increasing in popularity, but the open development platform that developers love is also attractive to malware creators. Download this white paper to learn more about secure code signing practices that can help keep Android apps secure. http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk ___ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users -- Android is increasing in popularity, but the open development platform that developers love is also attractive to malware creators. Download this white paper to learn more about secure code signing practices that can help keep Android apps secure. http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk ___ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users
Re: [WiX-users] Environment Variable Changes by MSI are not reflected
After installing the MSI, we require the users run a PowerShell cmdlet for configuring the machine. This cmdlet depends on binaries that are present in the directory that we add to "PATH" in the MSI. Since the value of "PATH" does not change (even in a new process), the users have issues running the PowerShell cmdlet. I would expect it to take effect immediately after MSI installation so that any new process have the updated value for "PATH" variable. Regards,Surya > Date: Thu, 31 Oct 2013 13:11:59 -0700 > From: phildgwil...@gmail.com > To: wix-users@lists.sourceforge.net > Subject: Re: [WiX-users] Environment Variable Changes by MSI are not > reflected > > The short answer is yes. The longer answer depends on exactly where you > expect it take effect. What's the exact problem? It doesn't get picked by a > program? By a command prompt? It doesn't get used when you run something? > > http://superuser.com/questions/351279/adding-a-directory-to-user-path-doesnt-work > > > Phil Wilson > > > On Thu, Oct 31, 2013 at 11:53 AM, Suryadeep Biswal > wrote: > > > Hi, > > > > > > > > Our MSI uses the inbuilt Environment > > WIX element to add a directory to PATH > > variable. We are seeing an issue on Windows Blue/8.1 where this does not > > get > > reflected until the user logs off and logs on. Is this a known issue? Are > > there > > any alternatives to set the environment variable other than writing a > > Custom > > Action? Please advise. > > > > > > > > This is from our WXS file – > > > > > Name="PATH" Action="set" Part="last" System="yes" > > Value="" Permanent="no"/> > > > > > > > > Regards, > > > > Surya > > > > > > > > -- > > Android is increasing in popularity, but the open development platform that > > developers love is also attractive to malware creators. Download this white > > paper to learn more about secure code signing practices that can help keep > > Android apps secure. > > http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk > > ___ > > WiX-users mailing list > > WiX-users@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/wix-users > > > -- > Android is increasing in popularity, but the open development platform that > developers love is also attractive to malware creators. Download this white > paper to learn more about secure code signing practices that can help keep > Android apps secure. > http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk > ___ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users -- Android is increasing in popularity, but the open development platform that developers love is also attractive to malware creators. Download this white paper to learn more about secure code signing practices that can help keep Android apps secure. http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk ___ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users
Re: [WiX-users] Environment Variable Changes by MSI are not reflected
The short answer is yes. The longer answer depends on exactly where you expect it take effect. What's the exact problem? It doesn't get picked by a program? By a command prompt? It doesn't get used when you run something? http://superuser.com/questions/351279/adding-a-directory-to-user-path-doesnt-work Phil Wilson On Thu, Oct 31, 2013 at 11:53 AM, Suryadeep Biswal wrote: > Hi, > > > > Our MSI uses the inbuilt Environment > WIX element to add a directory to PATH > variable. We are seeing an issue on Windows Blue/8.1 where this does not > get > reflected until the user logs off and logs on. Is this a known issue? Are > there > any alternatives to set the environment variable other than writing a > Custom > Action? Please advise. > > > > This is from our WXS file – > > Name="PATH" Action="set" Part="last" System="yes" > Value="" Permanent="no"/> > > > > Regards, > > Surya > > > > -- > Android is increasing in popularity, but the open development platform that > developers love is also attractive to malware creators. Download this white > paper to learn more about secure code signing practices that can help keep > Android apps secure. > http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk > ___ > WiX-users mailing list > WiX-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wix-users > -- Android is increasing in popularity, but the open development platform that developers love is also attractive to malware creators. Download this white paper to learn more about secure code signing practices that can help keep Android apps secure. http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk ___ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users