Tuesday, May 6, 2014

Citrix Receiver 13 on Ubuntu 14.04

Long time no post...

I have just come across something awesome that actually works:
http://phpraxis.wordpress.com/2014/05/03/installing-citrix-ica-client-in-64-bit-ubuntulinux-mint-redux/#comment-123

Was able to install the latest Citrix client on a kubuntu 14.04 system without a hiccup.

Enjoy!!!

Wednesday, May 30, 2012

Symantec NetBackup 7 console opening delay fixed

If you are a user of Symantec NetBackup, i am sure you have experienced the long delay before opening the application after upgrading from 6.x to 7.x
To fix the issue just run the following on the master server:
\netbackup\bin\bmrsetupmaster.exe


http://www.symantec.com/business/support/index?page=content&id=TECH142649

Friday, March 12, 2010

Blackberry DB Backup BESMgmt BlackberryDBBackup.exe

Ok, so if anyone is interested in backing up the MSDE database for the Blackberry Enterprise Server, you may have come across a command called blackberrydbbackup.exe. And you most likely would have run into issues with using it. The help when executing the program without switches shows a command -d for specifying the database, -E for using windows credentials, and -f for the backup folder: blackberrydbbackup.exe -d BESMgmt -E -f c:\backup That does not work, no matter what you seem to do. Even though Blackberry support and all forums show it as being the proper command sequence. Well after a half hour of hitting my head against the wall, a solution was born. blackberrydbbackup -dBESMgmt -E -f c:\backup Note the no space after the -d and the .exe taken out. When the script was written, it seems someone made a few mistakes. The .exe extension is taken as a part of the switch it seems. And the help needs to be modified to reflect the -ddbname. Dont even bother using -U and -P for username and password. Nothing i tried worked. -Udomain\besadmin -Udomain\BESAdmin -U domain\besadmin -U domain\BESAdmin -Ubesadmin -UBESAdmin -U BESAdmin -U besadmin -UBESAdmin@domain -U BESAdmin@domain -U: all of the above and the same for -P ofcourse. When scheduling the script for this using Windows Scheduler, -E is enough as the windows credentials will be passed. Just enter the besadmin info when saving the job. Someone posted online about using the AT command to run as a system service along with -U and -P so as to not have to change the password for the job each time the Besadmin pw changed. That makes no difference as even if you got the -U and -P to work properly, when the besadmin pw is changed you would still have to modify the script with the new -P. By the way the tool along with blackberrydbrestore.exe is located in the tools folder on the Blackberry cd. Thank you Alex B

Friday, October 9, 2009

OLKAway Now With Vista support

Long overdue update.

Added Vista support, removed old AutoIT declarations, and set the temp folder to be recreated after deletion to avoid random errors.

#NoTrayIcon
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_outfile=OLKaway.exe
#AutoIt3Wrapper_Compression=4
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#cs
    This script will delete the Outlook temp folder under
    c:\documents and settings\%username%\local settings\temporary internet files\OLKxxx (Windows XP/2000)
    or 
    C:\Users\%username%\AppData\Local\Microsoft\Windows\Temporary Internet Files\Content.Outlook (Windows Vista)
    It will check for the presense of the OutlookSecureTempFolder entry in the registry
    starting with Outlook 2007, all the way to Outlook 2000 working backwards.
    Once found, it will delete the contents.
    /install option will add a shortcut to the startup folder.
    /uninstall option will delete the shortcut.
    no option will just execute the removal without installing.
    created 01/07/2008
    updates 10/09/2009
        Added Vista support
        Removed old AutoIT declarations
        Corrected random Outlook issues due to the temp folder not being recreated, by creating it manually after each delete.
    
    ab@nyitsupport.com
#ce
 
dim $InstallPath
$InstallPath = "C:\Program Files\NYITSupport\OLKaway\"
 
Select
    case @OSVersion = "WIN_VISTA"
        #requireadmin
        Call ("StartSequence")
    case @OSVersion = "WIN_XP"
        Call ("StartSequence")
    case @OSVersion = "WIN_2000"
        $ver = RegRead("HKLM\SYSTEM\CurrentControlSet\Control\ProductOptions", "ProductType")
        If $ver = "ServerNT" then Exit
        Call ("StartSequence")
    case Else
        Exit
EndSelect    
    
Func StartSequence()
    if $CmdLine[$CmdLine[0]] = "" then 
        call ("CleanUp")
    Else
        Select
            case $CmdLine [1] = "/uninstall"
                if not IsAdmin() then Exit
                call ("Uninstall")
                
            case $CmdLine [1] = "/install" 
                if not IsAdmin() then Exit
                if FileExists($InstallPath) then Exit
                Call ("Install")
        
            case Else
                Exit
                
        EndSelect
    EndIf
EndFunc
 
func CleanUp()
    $OSTF = RegRead("HKEY_CURRENT_USER\Software\Microsoft\Office\12.0\Outlook\Security", "OutlookSecureTempFolder") ; Outlook 2007
    if @error then $OSTF = RegRead("HKEY_CURRENT_USER\Software\Microsoft\Office\11.0\Outlook\Security\", "OutlookSecureTempFolder") ; Outlook 2003
    if @error then $OSTF = RegRead("HKEY_CURRENT_USER\Software\Microsoft\Office\10.0\Outlook\Security", "OutlookSecureTempFolder") ; Outlook XP
    if @error then $OSTF = RegRead("HKEY_CURRENT_USER\Software\Microsoft\Office\9.0\Outlook\Security", "OutlookSecureTempFolder") ; Outlook 2000
    DirRemove($OSTF,1)
    DirCreate($OSTF)
EndFunc
 
Func Install()
    FileCopy (@ScriptFullPath, $InstallPath,8)
    ShellExecute("cacls.exe", '"' & StringLeft($InstallPath, StringLen($InstallPath)-1) & '" /e /c /g BUILTIN\Users:F')
    FileCreateShortcut($InstallPath &; "OLKaway.exe", @StartupCommonDir & "\NYITSUPPORT OLKaway.lnk", $InstallPath, "", "NYITSUPPORT OLKaway")
    call ("CleanUp")
EndFunc
 
Func Uninstall()
    FileDelete (@StartupCommonDir &; "\NYITSUPPORT OLKaway.lnk")
    DirRemove($InstallPath,1)
EndFunc

Tuesday, July 14, 2009

WSUS Problems On Cloned Machines

I ran into an interesting issue the other day. A machine registered in WSUS would appear and then dissapear from the WSUS 3 SP1 console.

Found the solution to the problem on the following links:

http://tinyurl.com/mrxrwt – best source

http://tinyurl.com/nz4mu8

http://tinyurl.com/kja3to

Here is a script that will run only once if completed successfully. It will also write a log in either case to a subfolder where it ran from with a computer name in the file name.

#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_outfile=WSUSFix.exe
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#cs
    WSUSFix
        This application will repair WSUS issues that may have been caused by the machine being imaged.
        
        Referrenced from:
            http://www.wsuswiki.com/ClientFAQ
            http://www.experts-exchange.com/OS/Microsoft_Operating_Systems/Server/2003_Server/Q_23550840.html
            http://blog.netnerds.net/2006/12/wsus-force-registration-of-clients-that-are-not-showing-up/
    Alex Belenkiy
    ab@nyitsupport.com
    07/15/2009
#ce
 
If Not IsAdmin() then Exit ; check for admin rights
if @OSVersion <> "WIN_XP" then Exit ; Only install on Windows XP
 
if FileExists("c:\windows\WSUS\WSUSFixComplete.txt") then Exit
 
dim $error, $File, $log, $logText
 
$command = RunWait(@ComSpec & " /c " & "net stop wuauserv")
if @error then 
    call("Logger", "net stop wuauserv FAILED")
    $error = 1
Else
    call("Logger", "net stop wuauserv SUCCESSFUL")
EndIf
 
Call("RegFix", "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate", "AccountDomainSid") 
Call("RegFix", "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate", "PingID") 
Call("RegFix", "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate", "SusClientId") 
Call("RegFix", "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update", "LastWaitTimeout")
Call("RegFix", "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update", "DetectionStartTime")
Call("RegFix", "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update", "NextDetectionTime")
Call("RegFix", "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update", "AUState")
 
$command = RunWait(@ComSpec & " /c " & "net start wuauserv")
if @error then 
    call("Logger", "net start wuauserv FAILED")
    $error = 1
Else
    call("Logger", "net start wuauserv SUCCESSFUL")
EndIf
 
$command = RunWait(@ComSpec & " /c " & "wuauclt /resetauthorization /detectnow")
if @error then 
    call("Logger", "wuauclt /resetauthorization /detectnow FAILED")
    $error = 1
Else
    call("Logger", "wuauclt /resetauthorization /detectnow SUCCESSFUL")
EndIf
 
if $error <> 1 then ; install completed successfully don't run again.
    $File = FileOpen("c:\windows\WSUS\WSUSFixComplete.txt",9)
    call ("Logger", "WSUS Fix completed successfully")
Else ; install did not complete successfully, write a log and allow for another try
    call ("Logger", "WSUS Fix encountered errors. Will try again at next startup.")
EndIf
 
Func Logger($logText) ; write a log
    $log = FileOpen(@ScriptDir & "\Logs\" & @ComputerName & ".log", 9)
    if not @error Then
        FileWriteLine($log, @CRLF & $logText & " - " & @MON & "/" & @MDAY & "/" & @YEAR & " - " & @HOUR & ":" & @MIN)
        FileClose($log)
    EndIf
EndFunc
 
Func RegFix($RegKey, $RegVal)
    $Command = RegRead($RegKey, $RegVal)
    if not @error Then
        call("Logger", "RegRead " & $RegKey & " " & $RegVal & " " & "LOCATED")
        $Command = RegDelete($RegKey, $RegVal)
        if @error then 
            $error = 1
            call("Logger", "RegDelete " & $RegKey & " " & $RegVal & " " & "FAILED")
        Else
            call("Logger", "RegDelete " & $RegKey & " " & $RegVal & " " & "SUCCESSFUL")
        EndIf
    Else
        call("Logger", "REGREAD " & $RegKey & " " & $RegVal & " " & "NOT FOUND")
    EndIf
EndFunc

Wednesday, March 18, 2009

Serial Number Retriever

Yet another serial number generator. Ported from a vbscript found online.
Just feed a machine name to the script to get an output with a serial number into a csv file.
You can also feed a file with all computer names on separate lines. If executed with no options, the current computer info is returned.
If there is no input, the local machine will be used.

#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_outfile=SerialNumber.exe
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#cs
    Just feed a machine name to the script to get an output with a serial number into a csv file.
    You can also feed a file with all computer names on separate lines. If executed with no options, the current computer info is returned.
    If there is no input, the local machine will be used.
    
    Alex Belenkiy
    09/24/08
 
 
#ce
#include <array.au3>
#include <file.au3>
 
dim $strComputer, $ComputersArray
 
$OutputFile = FileOpen("ServiceTag " & @MON & "-" & @MDAY & "-" & @YEAR & ".csv", 10)
FileWriteLine($OutputFile, "Machine Name, Manufacturer, Model Number, Serial Number, Part Number, SMBIOSAssetTag, OtherIdentifyingInfo")
If $CmdLine[0] = 0 Then 
    $objWMIService = ObjGet("winmgmts:" & "{impersonationLevel=impersonate}!\\" & @ComputerName & "\root\cimv2")
    $colSMBIOS = $objWMIService.ExecQuery ("Select * from Win32_SystemEnclosure")    
    For $objSMBIOS in $colSMBIOS
        FileWriteLine($OutputFile, @ComputerName & "," & $objSMBIOS.Manufacturer & "," & $objSMBIOS.Model & "," & $objSMBIOS.SerialNumber & "," & $objSMBIOS.PartNumber & $objSMBIOS.SMBIOSAssetTag & $objSMBIOS.OtherIdentifyingInfo)
    Next
Else
    if not FileExists($CmdLine[1]) Then
        $objWMIService = ObjGet("winmgmts:" & "{impersonationLevel=impersonate}!\\" & $CmdLine[1] & "\root\cimv2")
        if not @error Then
            $colSMBIOS = $objWMIService.ExecQuery ("Select * from Win32_SystemEnclosure")    
            For $objSMBIOS in $colSMBIOS
                FileWriteLine($OutputFile, $CmdLine[1] & "," & $objSMBIOS.Manufacturer & "," & $objSMBIOS.Model & "," & $objSMBIOS.SerialNumber & "," & $objSMBIOS.PartNumber & $objSMBIOS.SMBIOSAssetTag & $objSMBIOS.OtherIdentifyingInfo)
            Next
        EndIf
    Else
        _FileReadToArray($CmdLine[1],$ComputersArray)
        For $a = 1 to $ComputersArray[0]
            $objWMIService = ObjGet("winmgmts:" & "{impersonationLevel=impersonate}!\\" & $ComputersArray[$a] & "\root\cimv2")
            if not @error Then
                $colSMBIOS = $objWMIService.ExecQuery ("Select * from Win32_SystemEnclosure")    
                For $objSMBIOS in $colSMBIOS
                    FileWriteLine($OutputFile, $ComputersArray[$a] & "," & $objSMBIOS.Manufacturer & "," & $objSMBIOS.Model & "," & $objSMBIOS.SerialNumber & "," & $objSMBIOS.PartNumber & $objSMBIOS.SMBIOSAssetTag & $objSMBIOS.OtherIdentifyingInfo)
                Next
            EndIf
        Next
    EndIf
EndIf
    
        
FileClose($OutputFile)