The GoTo Community is currently experiencing some technical issues affecting new posts and comments. We are actively working with our service provider and apologize for the frustration.
Forum Discussion
KevinA
16 years agoRetired GoTo Contributor
One2Many Script Repository
Welcome to the LogMeIn Central Script Repository!
What is it? A library of scripts to help you execute automated tasks and manage LogMeIn Pro² computers without having to access them manually.
How does it work? Simply browse the .txt files below, save as a .BAT file and head to your LogMeIn Central console. Then, navigate to the One2Many tab, and select "Run a batch file or executable." From there, simply upload the batch file and you're ready to go.
How can you help? We encourage you to share your own scripts and/or help review the scripts of others-- just "Kudo" your favorites or reply with your comments.
Use of these scripts is at your own risk so please test them on a small number of systems before deploying at scale. The scripts are provided “as is” without any warranty of any kind and LogMeIn disclaims any and all liability regarding any use of the scripts. Please see the following Terms and Conditions for more information.
Remember: The currently running One2Many script ends when either the host service stops or the script includes computer shutdown or reboot tasks.
Script Repository
Microsoft Updates
Windows Update Javascript- The following script will perform comprehensive Windows Updates (Windows and Microsoft updates) on remote computers. This java script must be run as a Custom Task within One2Many with cscript being the entry point, Command to execute to update and install in the Custom Task is:
cscript.exe "%LMI_PACKAGEROOT%\wu.js" /sa /i
/sa will find updates that are flagged to be automatically selected by Windows Update. This is critical to avoid installing all available updates for the computer as this may include over ten 500Mb language support files on Vista and Win7. /i is the command argument that instructs the script to download and install the updates found. Additional arguments are outlined within the source code of the JavaScript.
Both the script and the command to execute can be customized to suite your environment’s needs.
Security
Disable Firewall- disable the Microsoft Windows Firewall for the appropriate version of Windows.
Enable Firewall- enable the Microsoft Windows Firewall for the appropriate version of Windows.
Install AVI Convert- install the LogMeIn Rescue AVI Converter which converts LogMeIn Rescue .rcec
recordings to .avi, for the appropriate version of Windows.
Update AVG Virus Definitions: Updates your AVG (versions 8 and/or 9) virus definition files
Maintenance
Purge DLL Cache- delete and restore the cache folder associated with Microsoft System File Checker for the appropriate version of Windows.
Reboot- reboot the remote device(s) with an end-user notification for the appropriate version of Windows. Remember: When a host is restarted, it disconnects from Central and the currently running One2Many script stops. Since One2Many cannot continue script execution, rebooting a device should be the last step of your One2Many script as it ends the script.
Shut down-shut down the remote device(s) immediately for the appropriate version of Windows. Remember: When a host is shut down, it disconnects from Central and the currently running One2Many script stops. Since One2Many cannot continue script execution, shutting down a device should be the last step of your One2Many script as it ends the script.
Reset System Restore- reset (disable/enable) Microsoft System Restore for the appropriate version of
windows.
Turn Off System Restore- disable Microsoft System Restore for the appropriate version of windows.
Turn On System Restore- enable Microsoft System Restore for the appropriate version of windows.
Defrag- Defragments C volume
Spool Cleaner- Cleans print spooler (submitted by iDevelop)
LogMeIn Update- Updates host software with the latest version of LogMeIn.
Use of these scripts is at your own risk so please test them on a small number of systems before deploying at scale. The scripts are provided “as is” without any warranty of any kind and LogMeIn disclaims any and all liability regarding any use of the scripts. Please see the following Terms and Conditions for more information.
(edited and updated 2/23/23 by GlennD)
https://github.com/knix15/LogMeIn-One2Many-Community-Scripts/
Scripts can be found here as well for better future organization.
136 Replies
- DiamondDave9 years agoRegular Visitor
Is there a way that I can execute a vbs script with the administrator credentials? I am trying to update a folder by deleting the existing files and extracting a zip with the new set of files. this works great if I am logged in with the administrator account. However, when I try to execute the script with the standard user account logged in, I get a message that I need permissions to delete files.
The high level is that I delete existing files in a public\desktoip\links folder structure, then unzip a new folder structure in it's place. I have the administrator credentials applied when I set up the credentials. any advice would be appreciated.
Thanks!
- carlcapone9 years agoActive Contributor
Hey there,
Thanks for the replies. Sorry it's been some time since I've checked back on this. Anyway, @j_helland is this possible on the Rescue LogMeIn centralized script setting? So far, that's the only option I see where I can upload files and/or custom scripts? Not entirely sure if it's the same with the One2Many feature.
As for purpose of the script, I am trying to have the files residing on one server and have our technicians transfer those files to their clients so that we don't have to download each of those files from our file server using the client's computer. More like a drag and drop feature that we have used before from a different platform. Thank you.
- j_helland9 years agoActive Contributor
Hey CarlCapone, if you set up a "custom" One2Many, upload the files, then use the example syntax below, you can transfer multiple files using a simple DOS format:
copy file1.txt "C:\folderpath"&© file2.txt "C:\folderpath&© file3.txt ................
Essentially you'll need to separate each command by the double ampersand, which tells DOS that a new command is coming. I've been using this methodology for complex One2Many pushes for about 6 years and it takes some trial and error, but it usually works!
- Beep-Beep9 years agoActive Contributor
Scripts do not allow the ability to transfer files.
You'd need to issue commands to something in order to do the copy.
Examples of methods:
Initiating a VPN connection then transferring from a fileshare.
Initiating an FTP download (Something like this: FTP through PowerShell )
Using an already available file transfer utility like SCP.
You can use the custom package option (One2Many Task). It will download all files you upload to the task. If you use a PowerShell script, you can refer to the random directory LMI puts the files in through the variable $PSScriptRoot as the script will be in the same directory.
#Rudimentary example #Uninstall old products since they cause new installations to abort (Get-WmiObject -Class Win32_Product | Where-Object { $_.Name -match 'Awesome Program'}).Uninstall() #Start Install Start-Process -Wait msiexec -ArgumentList "/i $PSScriptRoot\AwesomeProgram.msi TRANSFORMS=$PSScriptRoot\AwesomeProgramTransform.mst" #Install dependent program Start-Process -Wait msiexec -ArgumentList "/i $PSScriptRoot\DependentProgram.msi" #Install second dependent program Start-Process -Wait msiexec -ArgumentList "/i $PSScriptRoot\AnotherDependentAwesomeProgram.msi" #License the program Copy-Item -Path $PSScriptRoot\AwesomeLicense.lic -Destination "C:\Program Files (x86)\AwesomeProgram\LicenseFile.lic" -Force
- carlcapone9 years agoActive Contributor
Hi everyone,
I am kinda wondering if someone has successfully transfered files using a script instead of the file transfer/manager in LMI. If anyone is willing to share a working script, that would be awesome. Thank you.
P.S. I've posted on the other thread as well.
- bbrink9 years agoNew Contributor
did the effort to have a "new and easier to use script repository via groups" stall again?
- Beep-Beep10 years agoActive Contributor
For one-liners, I get around set execution policy on PowerShell scripts by using the command:
powershell "put command here"
Watch out for commands that use double quotes though.
Example:
powershell "(Get-WmiObject -Class Win32_Product | Where-Object { $_.Name -eq 'Some Name Here' }).Uninstall()"
What One2Many really needs is the ability to chain tasks sequentially. I know you can just send a script with complex logic but if you already have the individual pieces as tasks, it would be nice to be able to just chain those together.
- tarcis10 years agoActive Contributor
echo off
rem bye lmi by Tarcis
if %PROCESSOR_ARCHITECTURE% equ AMD64 goto amd64
cd "%ProgramFiles%\logmein\x86"
logmein uninstallgoto end
:amd64
cd "%ProgramFiles(x86)%\logmein\x64"
logmein uninstall:end
exit - dreamgear10 years agoActive Contributor
you mean right-clicking on the file before you add it to the One2Many task? Or after ?
- Lisa_K810 years agoRetired GoTo ContributorHi Consultant64 I did not forget this and did enable groups however am having difficulty displaying them in the current structure of the community. I am actively investigating this! Thank you!