Systellence
Posts: 15
Joined: Thu Feb 09, 2012 11:36 am

Streamlining Automatic Updates

Hi there

We have a system which which will be deployed at various clients. We want to implement Automatic Updates. The updates will be downloaded from a local server and not from the Internet. The system is huge and we want to prevent the usage of unnecessary bandwidth. Obviously the details for each server will be different (paths, IP addresses etc.) We would want to create one installation package to be used for any customer, BUT:

1. For the initial implementation, automatic updates will not relevant and therefore the updates.txt file will also not be created. We would want to create the updater.exe and updater.ini file initially so that the installation package is "Automatic Update Friendly" for the future.
2. The problem is that the INI should reference an updater.txt file and the INI file does not know where this file will be (We want to prevent multiple installs of the same system for various clients). Each server at each client is different.
3. What is the best way of overcoming this problem?
4. Can an installation file (msi) read or copy an external file which is separately kept with the installation file? If possible we could have independent INI files which will be installed, but not form part of the msi package

Looking forward to hear from you

Systellence
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Streamlining Automatic Updates

Hi Jaco,

Copying a file placed next to the setup package is possible at install time, so this could be done by you too.

However, from what I can see the purpose for which you want to use the updater is not really the one it was intended for. Let me see if I get this right. You actually
create the new version MSI for your application and send it to lets say 10 sys admins that are working for your clients, then the sys admins place the MSI in a special location on their servers and the updater from the user's machine will detect and install it.

If this is the case a much better solution is for the sys admins to use Active Directory/GPO or SCCM to install the new version on the end user's machine. This way the users will never have to bother with installing anything, they can just use the application. This is the standard approach used by sys admins all over the world to install an application in a closed environment(network).

Best regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
Systellence
Posts: 15
Joined: Thu Feb 09, 2012 11:36 am

Re: Streamlining Automatic Updates

Hello Bogdan

Thanks for coming back to us. I think you understand what we are trying to do.

Some questions:

1. Is this Active Directory method effective and easy?
2. Some Administrators will be willing to assist and others not. It all depends per company. - We have to have a second option open.
3. "Copying a file placed next to the setup package is possible at install time, so this could be done by you too." - How can this be done with Advanced Installer?

Regards,

Jaco
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Streamlining Automatic Updates

Hi Jaco,
1. Is this Active Directory method effective and easy?
2. Some Administrators will be willing to assist and others not. It all depends per company. - We have to have a second option open.
This method is easy to use, even for a beginner sys admin. All it needs is a server with Win 2003 Server or Win 2008 Server operating system, which most companies have, and the MSI package package you provide. Than, using a simple tutorial, as the one from our web site it can easily deploy the application to all of its client machines.

The limitation for Active Directory/GPO deployment is that it can be used only for MSI, MST and MSP files, not for EXE packages. SCCM can be used to deploy EXE packages too, but this is a much more complex application, which requires some training before you start using it, and also it has a separate license, which I don't know if all of your clients will already have.

In what Active Directory/GPO concerns, I thing that is the best solution for them. As I am sure they must be using one of these deployment methods because it would be totally unpractical, and a waste of resources (time and money), for them to manually configure all their computers.
3. "Copying a file placed next to the setup package is possible at install time, so this could be done by you too." - How can this be done with Advanced Installer?
in the following article we explain how you can copy files found next to the setup package.

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
Systellence
Posts: 15
Joined: Thu Feb 09, 2012 11:36 am

Re: Streamlining Automatic Updates

Hi,
Since we want one setup for different clients(Companies) but with different updater.ini file, we would like to overwrite the updater.ini file during installation using the method of copying a file next to the setup. I'm trying to copy a custom updater.ini file during installation to the AppFolder but nothing is being copied. Here are the steps which im taking to achieve this:

1. Open Install parameters tab , go to properties and add a new property with Name SOURCEDIR and value C:\
2. Open Folders and Files tab, right click Application Folder then property based folder, then i choose SOURCEDIR(C:\), while Application Folder is highlighted, click new file operation then file copy/move.
3. In the dialog box i have these values:Under source file( Name updater.ini , Folder SOURCEDIR) Under destination file(Name update.ini, Folder AppDir) Under propeties(component AI_ExePath, Operation: move)
4. Then build the project
5. Install the project from the desktop and the custom updater.ini file is located on the desktop.

Note the setup extension is msi.

Kind Regards,
Systellence
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Streamlining Automatic Updates

Hi Jaco,

When you are trying to replace a file installed by the package using a copy/move operation you must take into consideration the sequencing of
the standard actions, i.e. the actions that write INI files and move files for your case. By default the move operations are executed first, this would mean that the write INI file operation will overwrite your file, which I suspect is happening.

From Custom Actions page you can move the standard action, under InstallExecuteSequence, that moves the files after the one that writes the INI files and try again.

If this does not work please create a verbose log of the install and attach it on the forums, or send it by e-mail, along with the aip file, to look for other clues.

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
luthfi
Posts: 2
Joined: Wed Jun 13, 2012 11:48 am

Re: Streamlining Automatic Updates

Hi,

I got a similar objective but I'm taking a different approach. Unfortunately I haven't been able to set the update URL value read from a user input dialog into the update.ini file.
Here are the steps I'm using:
  • Create new property UpdateServerURL in the project properties
  • Change the update URL field in the Updater page to use the new property
  • Create a new custom dialog with one edit box that saves the value to UpdateServerURL property
Using the above steps I can see that the property is changed to the value inputted by user in the custom dialog, but the update.ini file is still using the default initial value instead of the new one.

I've attached the aip file along with the log. As you can see in the log file the property is changed but then during install step the value is revert back to the default value.
Attachments
My Awesome App.zip
(161.79 KiB) Downloaded 408 times
luthfi
Posts: 2
Joined: Wed Jun 13, 2012 11:48 am

Re: Streamlining Automatic Updates

Never mind, I found what the problem is. I was using private property instead of public property. I didn't know that name casing will have an impact on the installer behavior.

Return to “Common Problems”