Reboot and resume setup error

Got a problem you cannot solve? Try here.
gonpla
Posts: 40
Joined: Tue Sep 06, 2011 8:47 am

Re: Reboot and resume setup error

Post by gonpla »

Hello,
I understand that when I launched Update, get the old installer SUPPORTDIR variable. If we change the variable SUPPORTDIR in the setup of our new version of the software will not work because it takes the old version to launch the update.
Anyway I did a test changing this variable in the old installer does indeed who puts temporary files in the directory that I say although I still have the problem that when I click on restart the computer automatically not restarts in Windows XP (it works in 7). Does continue to manually restart the installation in this case.
Is there any way to catch the new installer SUPPORTDIR variable when calling Upgrading from an old one?
Thank you
FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: Reboot and resume setup error

Post by FrancescoT »

Dear User,

probably I missed something, but you do not have to catch your SUPPORTDIR at all otherwise you will have the same problem. Why do you not save it in any other folder es: c:\documents\myupgrade? The you will launch your upgrade from it.

What Im tryng to say is:
if you execute just for test your project "Test1_1_0_1" locally on your target system (copy everywhere but not in SUPPORTDIR .... without downloading it) after you have installed "Test1_1_0_0." it will works, because your setup file for "Test1_1_0_1" it is still available after reboot.

Regarding the missed reboot on XP, honestly I have checked on Win7. I can try to repeat my test even on XP .... but I will do it as soon as I can.

Regards
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE
gonpla
Posts: 40
Joined: Tue Sep 06, 2011 8:47 am

Re: Reboot and resume setup error

Post by gonpla »

We understand that change the path to download temporary files must be done in version Test1_1_0_0, and this we can not do because this version is already installed in our customers. so we need an other way to modify the download path but on the setup Test1_1_0_1.
FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: Reboot and resume setup error

Post by FrancescoT »

Dear User,

I may suggest to you what I think it is the only way to solve your issue.

Because you have already distributed your first version, you may sobstitute your actual upgrade to version 1.1.0.1, that you have already on your online server, with a replacement update that implements the correction for the destination path for your future upgrades. So substantially, this should be just a fix for your issue and you probably could execute this as are you actually doing. Once your first version it is installed, probably in this way you could force, just replacing your upgrade file on your server with a fixed version, to execute a fixing on your existing installations.

Then once the fix has installed, this will contains all the corrections that you may need and could point to a new really upgraded version of your software.

It is the only thik possible .... I think.

Anyway before to distribute a software release I suggest to you to perform some tests, otherwise if there is an error and often could happen, you are not able to fix it easly.

Hope this helps you
Regards.
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE
gonpla
Posts: 40
Joined: Tue Sep 06, 2011 8:47 am

Re: Reboot and resume setup error

Post by gonpla »

Hello,
We see this possibility feasible, because it is more complex for our customers.
We have in the installer B (the discharge) that run the script framework 4, and click on restart, copy the file.exe to another location, keep in Run to run again on reboot. The problem is that after we reboot and there are times it restart and sometimes not. We do not know what is happening and we are now desperate with this problem.
You know what the problem might be that not restart?
I copy the code:

Set Variable DOTNET40CLIENT_RESULT_x86 to REBOOTT
Variable Equals REBOOT if DOTNET40CLIENT_RESULT_x86
MessageBox: $TITLE$ Setup, Your Computer Needs to be restarted $TITLE$ Setup Before continue.Please can save your work in all running programs and click OK to restart your computer. Setup will resume your computer restarts eleven. If you click CANCEL, setup will exit. You will Have to run setup again at a later time to install $TITLE$.
Variable Equals OK if REBOOTNOW
Call DLL Function kernel32.dll-> CopyFileA
Set variable PATH to $TEMPDIR$$SFXFILE$ REBOOTCOMPUTER=FALSE RUNAPP=FALSE REBOOTNOW=CANCEL /m=$TEMPDIR$$SFXFILE$ /k=""
Write Persist Registry Key SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce\Test1, $PATH$
reboot Computer
else
Terminate Installation
end
end
FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: Reboot and resume setup error

Post by FrancescoT »

Dear User,

What is the exact path where you are saving your file to be executed after restart?
Why you are directly writing to RunOnce reg key? Are you shure that it is not overwritten by something else?
When you say, "it restart and sometimes not", different OS? Same PC sometime works and sometime not?

Regards
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE
gonpla
Posts: 40
Joined: Tue Sep 06, 2011 8:47 am

Re: Reboot and resume setup error

Post by gonpla »

The path where I keep it at $TEMPDIR$$SFXFILE$, I have also tried a different folder. In both works well, this is not the problem.
I write in the RunOnce registry key to tell where is located the file to launch after a reboot. If you know a better way let me know. Anyway, the temporary file and the RunOnce key is not the problem, because if I manually restart perfectly continuous. The only problem is that when I "Reboot Computer" does nothing. I accept the reboot and do not restart.
In Windows XP never resets in Windows 7 itself.
FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: Reboot and resume setup error

Post by FrancescoT »

Dear User,

Please send me again your project (if you have produced changes with the old one) so I will look at it again.

Send to me both projects ... compressed .... as simple as possible.

Bacause I think that there is something missing ... in some way.

I am doing all my best.

Regards.
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE
gonpla
Posts: 40
Joined: Tue Sep 06, 2011 8:47 am

Re: Reboot and resume setup error

Post by gonpla »

Hello,
I am attaching the project as before.
Remember that the file I modified is "setupnet4aip_client_x86" and obviously I test it on an x86 computer.
To reproduce the error, you must have a computer without the Framework 4 Client installed and launch "Test1_1_0_0.exe". Then click on Start/Test1/Update
It download Framework 4 Client, install it and reach the point where it asked to restart the computer. By accepting you'll not restart.
Thank you very much for your interest.

Regards,
Rubén.
Attachments
TestReboot.zip
(5.14 MiB) Downloaded 495 times
FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: Reboot and resume setup error

Post by FrancescoT »

Ok!

I will tell you as soon as possible.

Regards
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE
gonpla
Posts: 40
Joined: Tue Sep 06, 2011 8:47 am

Re: Reboot and resume setup error

Post by gonpla »

Dear Francesco,

First of all, thanks for your interest and support.
I have raised the issue to our Technical Director as our version is stalled because of this problem. He is also helping me with the English description of the issue.

ISSUE 1
The deployed version of our application (v1.0.0) will not be able to upgrade successfully to next version because we need to make a restart after the .NET Framework 4 is installed. The fact that the SUPPORTDIR is erased after a reboot is the cause of the issue.

OVERCOMING ISSUE 1
Following your advice, we changed in the upgrade (v1.0.1) the SUPPORTDIR variable to a location which is not erased by the reboot. This will be tested at the end of the process when we will update from v1.0.1 to v1.0.2.

ISSUE 2
The approach of modifying the SUPPORTDIR will work only for the updates mades on v1.0.1. Our initial scenario is already deployed and we cannot change the SUPPORTDIR.

OVERCOMING ISSUE 2
To overcome this issue, we modified v1.0.1 to manually copy the setup file from SUPPORTDIR to a TEMPDIR, a location which would survive the reboot. This also required us to change from the "Reboot and resume" mode to "Reboot" and manually adding a registry key to simulate the desired "Reboot and login" behaviour. The value of the key in HKCU RunOnce reflects the new path (TEMPDIR).

TEST SCENARIO
We have created the following test scenario to illustrate the problem.
- Test1_1_0_0.exe (Simulates the already deployed version v1.0.0)
- Test1_1_0_1.exe (Upgrade)
Manually copies setup file in TEMPDIR and modifies registry accordingly to simulate the "Reboot and login" mode. It includes .NET Framework 4 Client as requirement to force a reboot.

TEST RESULTS
The process works well in Windows 7 (with UAC).
We have problems in Windows XP because the system does not reboot after installing the .NET Framework 4 Client. If we manually reboot, the setup finishes with no problem.
This is very strange because this only happens in an upgrade process. We have tested installing Test1_1_0_1.exe in a clean Windows XP (no prior version) and it reboots successfully.

Let me include the last version of our test scenarios and, please, do not hesitate to ask for further clarifications.

Best regards.
FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: Reboot and resume setup error

Post by FrancescoT »

Dear User,

your issue is very clear!

Please let me test it.

Just one more question, have you attached any new test project with your last reply?
I have not found any ... will I use the last files you posted on Tue Mar 13, 2012 8:00 pm?

Let me know.
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE
gonpla
Posts: 40
Joined: Tue Sep 06, 2011 8:47 am

Re: Reboot and resume setup error

Post by gonpla »

Yes, correct. These are the files
Thank you.
FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: Reboot and resume setup error

Post by FrancescoT »

Please Wait for my reply ... I am quite busy ... but I will look at it ASAP.

Regards
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE
FrancescoT
Site Admin
Posts: 5361
Joined: Sun Aug 22, 2010 4:28 am

Re: Reboot and resume setup error

Post by FrancescoT »

Dear User,

Here I am although with some delays but unfortunately I have many tests to do and each one takes time to complete properly.

I repeated the test exactly as you wrote and probably I found the reason of your case. Although I have to admit that with my testing has always completed the reboot (test on Win XP Pro 32 Sp3) .

I need an extra information:
if you run on your XP test machine that already have the "Test1_1_0_0.exe " installed and run the "Test1_1_0_1.exe " without downloading it from your web service, but launching it from a local path on your test machine, will it restart as expected after NET Framework 4 is installed?

To be more clear, install on your test machine "Test1_1_0_0.exe " once the setup is completed do not use your installed shortcut but launch "Test1_1_0_1.exe" from a folder.

If not restarts correctly, could you debug your code to verify what it is the returned value by NET Framework 4 installation. You could also just place a dialog to test the returned value. Unfortunately, the project "Test1_1_0_1" lacks for a plugin that you used and I can not open it, so I can't do it.

Let me know
Francesco Toscano
InstallAware Software

White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Publications - http://www.installaware.com/publications-review.htm
InstallAware Help -F1 anywhere in the InstallAware IDE
Post Reply