Pelle

//Pelle
Pelle

Forum Replies Created

Viewing 15 posts - 1 through 15 (of 99 total)
  • Author
    Posts
  • Pelle
    Participant
    Post count: 100

    If you’re running it manually you could just create a CMD file as a wrapper, and trigger a restart after the script completes successfully.

    Something like this:

    @echo off
    Deploy-Application.exe
    if errorlevel 3010 (
    shutdown -r -t 0
    )

    Just adjust the If statement or remove it completely. Using a wrapper allows the installation to complete fully and finalize logging and such.

    Hope this helps

  • Pelle
    Participant
    Post count: 100

    Try: PowerShell.exe -Executionpolicy bypass .\Deploy-Application.ps1 -DeploymentType “Install” -DeployMode “Silent” -AllowRebootPassThru:$true

    Alternatively you can change the default value of the parameter AllowRebootPassthru (fram false to true) inside deploy-application.ps1 (I’ve done so in my “template”).

  • Pelle
    Participant
    Post count: 100

    I think the continueonerror is meant to be used if the process you’re trying to execute exits with a bad code.

    You could use test-path in an if statement, and since you seem to have indefinite number of paths it’d be neat to place them in an array and loop through it.

    Something like:

    [array]$Paths = “C:\App1\unins.exe”,”C:\App2\unins.exe”,”C:\app3\unins.exe”

    foreach ( $exe in $paths ) {
    if ( test-path $exe ) {
    execute-process -path “$exe”
    }
    }

  • Pelle
    Participant
    Post count: 100

    If (Test-Path -Path $ProgramPath -ErrorAction SilentlyContinue)

    should do the trick.

  • Pelle
    Participant
    Post count: 100

    I’d suggest you post the log file of the installation. If using default setting, you’ll find it in C:\Windows\Logs\Software.

    It would also be useful to get some info on how the installation is being executed.

  • Pelle
    Participant
    Post count: 100

    I suggest you add any additional office products (such as visio) as their own applications. How would you handle a scenario where a user changes her mind and want to add/remove visio or project?
    Furthermore you would have less need for user interaction, which is good ;)..

  • Pelle
    Participant
    Post count: 100

    Care to share the detection method of one of the failing deployment types?

  • Pelle
    Participant
    Post count: 100

    Not sure why you would want to do that with PowerShell application deployment Toolkit? All that’s required in sccm is a upgrade image and a upgrade task sequence.

    Care to elaborate?

  • Pelle
    Participant
    Post count: 100

    I’d try to add a if statement before the show-installationwelcome. Something like

    If(Test-PowerPoint) {
    exit-script -exitcode 1618
    }

    Unable to try it myself at the moment as I’m traveling. Unsure what Test-PowerPoint returns, so you might have to tweak that part a bit.

    Cheers

  • Pelle
    Participant
    Post count: 100

    Are you able to successfully install the program silently without using the toolkit?

    I know it’s a month later and you haven’t got any replies yet, but I get a 404 error when attempting to open the link to the log file. Care to re-upload it?

    Also, the discussions here tend to be related the toolkit itself, while the issue you’re experiencing (exit code 1403) seems to be generated by the installer of the application. Perhaps the manufacturer of the application have a technical reference for the installer telling you what 1403 means.

    Hope this helps

    Cheers

  • Pelle
    Participant
    Post count: 100

    Bringing life to this thread.

    I’m experiencing this issue on Windows 10.0.10586, and CMTrace version 5.0.8230.1000.

    In the log the Component column and the Date/Time column is blank and when marking a line the date/time in the info pane is set to 01.0.1601 00.00.00.

    Is anyone dealing with this issue?

    Script version: 3.6.8

  • Pelle
    Participant
    Post count: 100

    Eric, have you tried browsing to the share in the context of the system account? You can do so by following the steps below:

    1. Download PSExec.exe (https://technet.microsoft.com/en-us/sysinternals/pxexec.aspx?f=255&MSPPError=-2147217396)
    2. Open Command Prompt (cmd.exe) as administrator
    3. Navigate to the location of your PSExec.exe and type in psexec.exe -s -i powershell
    (3.5. In the powershell console windows, type in $env:username or whoami to ensure that the process is running the process in system context)
    4. In the powershell console window, navigate to the UNC share of you package and verify access

    Following those steps will tell you if the machine (NT Authority\SYSTEM) has access to the share and will clear out any permissions related question.

    Cheers

    • This reply was modified 1 year, 7 months ago by  Pelle.
  • Pelle
    Participant
    Post count: 100

    Agree with Francois. Check your default client settings (In the SCCM Console –> Administration \ Client Settings \ ). Open up the default client settings and the Computer Agent menu. Check the setting “Install permissions”. Sounds like yours might be set to ‘Only administrators’, or perhaps ‘Only administrators and primary users’.

  • Pelle
    Participant
    Post count: 100

    Wasn’t sure if the Show-InstallationRestartPrompt would be able to actually force a reboot on timeout. But if that works, surely that’s a better alternative.

  • Pelle
    Participant
    Post count: 100

    I was going to suggest the $ErrorActionPreference until I read your reply through :)… I guess it only handles the toolkits own cmdlets then. I.e. Copy-File would be handled since it’s defined in AppDeployToolkitMain.ps1 but Test-Path wouldn’t as its source is Microsoft.PowerShell.Management.

    I just try to ensure that my scripts never fail, but of course every situation is different and I guess there’s times you will have various results which need different error handling, but when such situation occurs for me I try and find a different/simpler solution. Sorry for not having a better response.

Viewing 15 posts - 1 through 15 (of 99 total)