LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Is there a way to auto deploy executable update?

I am in a position  where I develope database systems. I control everything with LabVIEW executables, and I am constantly deploying updates. What I do is to load my flash drive with the latest and greatest and run around to 50 or so computers updating the different systems. About half of the computers have the user as an administrator, and the other half I am able to log on as an administrator to install the updates. This is a time consuming and interuptive process. Is there a way to force updates to the variious computers whether the user has an administrator account or not? I don't want the programs to be stored in an accessible location, because the security of the system depends on only certain people having certain programs. There are roughly 25 programs that make up the systems. Thank you for any suggestions that will make the deployment of updates less painful.
0 Kudos
Message 1 of 9
(3,785 Views)

The "proper" way would to be a network install to the user.  But, I do not know how well that will work with standard NI installers.  This thread is a bit out of date, but I am not sure the basic issue of a network install has been addressed.  I have personally had some issues trying to import NI's 8.6 runtime engine MSIs imported into Advanced Installer, so I still don't think they are using standard msi files.  If you go this route, you may need to get a 3rd party install package program, such as Advanced Installer.

 

Another way would be to write an exe (lets call it Launcher.exe) which just checks a network location for a new version of the main program (let's call it Main.exe).  If the new version does NOT exist, it launchesthe local version of Main.exe.  If a new version does exist, it deletes the local Main.exe, then copies the network Main.exe to the local, then launches it.  You can work with your IT department to setup a folder only accessible to users which need the EXE.  Another alternative is to connect to the network location using a hidden username and password (you may have to create a drive mapping to do this, I am not sure), copy the file then destroy the drive map.

0 Kudos
Message 2 of 9
(3,776 Views)

I can't think of anything built into LabVIEW that would allow this to happen seamlessly.  I would probably write in an automatic update feature in the main program that periodically checks a secure location for a new file or something along those lines.  That way, computers and users that are already authorized to use the program will get their updates when they are available and people who do not have it will not get their updates.  It will probably involve a lot of extra coding and be a whole lot of fun...  The process could be something like:

 

1. Main VI checks secure network location for update.

2. If new update exists, Main VI shuts itself down and calls an "updater" VI that replaces the Main VI's executable with the new one.

3. Updater VI closes itself and calls the new Main VI to load

 

You could also add something like an email alert that a particular system was updated successfully (or not).  Since LabVIEW comes with VI's for accessing FTP servers or SMB file shares, I think this would be fairly straight forward.

0 Kudos
Message 3 of 9
(3,771 Views)
Thank you both for the information. I am leaving now for the weekend, but I will dive deeper into this on Monday. Thank you!
0 Kudos
Message 4 of 9
(3,768 Views)

Nickerbocker wrote:

I can't think of anything built into LabVIEW that would allow this to happen seamlessly.  I would probably write in an automatic update feature in the main program that periodically checks a secure location for a new file or something along those lines.  That way, computers and users that are already authorized to use the program will get their updates when they are available and people who do not have it will not get their updates.  It will probably involve a lot of extra coding and be a whole lot of fun...  The process could be something like:

 

1. Main VI checks secure network location for update.

2. If new update exists, Main VI shuts itself down and calls an "updater" VI that replaces the Main VI's executable with the new one.

3. Updater VI closes itself and calls the new Main VI to load

 

You could also add something like an email alert that a particular system was updated successfully (or not).  Since LabVIEW comes with VI's for accessing FTP servers or SMB file shares, I think this would be fairly straight forward.


Our IT guy did something like this for one of the main VB programs we use in engineering.  However, you could do it by eliminating a step.

 

Let the exectuable that the user launches be the updating program.  If it detects a new executable is available, it copies that to the user's hard drive then launches that.  If a new exectuable is not present, then it just launches the executable already present.  I believe he just uses a comparison of the executable file dates.

 

This will essentially eliminate step 2 where the main VI needs to shut itself down and call an updater, because the main VI executable that you want to update hasn't actually launched yet.

Message 5 of 9
(3,748 Views)
I guess I put that step in there because Windows has this habit of locking files that are in use (such as executables).  I have an openned LabVIEW executable now.  If I try and delete or copy a file over my executable I get a nice "Access Denied" message from Windows.  Unless there is a way around this, a seperate update program will most likely be necessary.
0 Kudos
Message 6 of 9
(3,741 Views)
But the main EXE will not be in use.  The launcher program will be its own EXE, so it will be in memory to check for an update, copy down the update if necessary, then launch the main EXE and exit.  If an update is necessary, main will not be open at the time because it has not been started yet.
Message 7 of 9
(3,739 Views)

Thanks Matthew.  That is exactly the scenario.

 

Actually the updater/launcher exectuable is a good place to put a splash screen that can give messages as to what it is doing.

 

Looking for Update.....

Downloading new Version  2.1......  or No new version available

Launching executable.....

 

 Kind of like what LabVIEW's splash screen does.

Message 8 of 9
(3,736 Views)
Another option if your IT department gives you any trouble and you have trouble doing the drive mapping :  Zip up the update with a password, and have your launcher unzip it with the known password.  This way, you can post the zip file into a more public location, but it will be more difficult to access (I won't say imposible).
0 Kudos
Message 9 of 9
(3,733 Views)