Chocolatey Not Installing
-
- Posts: 34
- Joined: Mon Jan 11, 2016 8:50 pm
- 8
Chocolatey Not Installing
Hello - I have a client that will not install the chocolatey agent. I can't figure out why. Originally, I found errors about some shell issues. I could install the client manually from the computer, but because LT didn't do the install all the automation stuff breaks down. I can't figure out how to manually install the chocolatey agent from the LT console, since the automation isn't taking care of it.
Thanks!
Toby
Thanks!
Toby
Re: Chocolatey Not Installing
Toby,
Chocolatey is all about Powershell so it may be a disconnect between LT and executing PoSh. Can you post the script logs to the thread here during a forced install?
To force another attempt at install do the following.
Go here and click your installed agents number to open the management console for Choco installs Next find the systems that have a missing Path. If it has a QwA6xxxxxxxxxxx in Path that is valid but a Null path is a sign of a failing system. Select system in list then right click for menu to force a reinstall. Then monitor your script logs and the Command tab of computer console to see the results. Post the results.
Chocolatey is all about Powershell so it may be a disconnect between LT and executing PoSh. Can you post the script logs to the thread here during a forced install?
To force another attempt at install do the following.
Go here and click your installed agents number to open the management console for Choco installs Next find the systems that have a missing Path. If it has a QwA6xxxxxxxxxxx in Path that is valid but a Null path is a sign of a failing system. Select system in list then right click for menu to force a reinstall. Then monitor your script logs and the Command tab of computer console to see the results. Post the results.
-
- Posts: 34
- Joined: Mon Jan 11, 2016 8:50 pm
- 8
Re: Chocolatey Not Installing
Thank you for the reply. I did as instructed and I'm not sure what log information you want. I have the output of the failed command from within computer's console within LT. It's below:
Parameters: cmd.exe!!! /c "@powershell -NoProfile -ExecutionPolicy Bypass -Command
Output: The shell cannot be started. A failure occurred during initialization:
Object reference not set to an instance of an object.
Do you want any other information? This is a new computer with a fresh load of the OS. I looked up the last line of the error, but it's not clear how that relates to Chocolatey and Powershell. Thanks for the help.
Parameters: cmd.exe!!! /c "@powershell -NoProfile -ExecutionPolicy Bypass -Command
Output: The shell cannot be started. A failure occurred during initialization:
Object reference not set to an instance of an object.
Do you want any other information? This is a new computer with a fresh load of the OS. I looked up the last line of the error, but it's not clear how that relates to Chocolatey and Powershell. Thanks for the help.
Re: Chocolatey Not Installing
Toby,
These 2 tabs should provide the information needed to why it has failed. Can you post screen shots of these 2 tabs and select the lines that error so that the bottom half of screen shows the whole error
These 2 tabs should provide the information needed to why it has failed. Can you post screen shots of these 2 tabs and select the lines that error so that the bottom half of screen shows the whole error
-
- Posts: 34
- Joined: Mon Jan 11, 2016 8:50 pm
- 8
Re: Chocolatey Not Installing
OK, the screenshots are attached.
- Attachments
-
- Command.jpg (213.11 KiB) Viewed 18656 times
-
- Scripts1.jpg (224.89 KiB) Viewed 18656 times
Re: Chocolatey Not Installing
Where is Choco.exe on that system located?
You said you did manually install Chocolatey or no?
If No and it is not installed then from the Command prompt tab run the following and post it's output.
This is the command that installs Chocolatey, if it installs ok then check to see if a Choco.exe exists anywhere on system. Post path
You said you did manually install Chocolatey or no?
If No and it is not installed then from the Command prompt tab run the following and post it's output.
Code: Select all
@powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1'))" && SET PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin
-
- Posts: 34
- Joined: Mon Jan 11, 2016 8:50 pm
- 8
Re: Chocolatey Not Installing
I installed it manually, but Labtech kept trying to find files pertaining to chocolatey within the C:\Windows\LTSvc. When LT installs things, related software is installed in this folder, so I assumed the errors were due to me installing it manually. With that in mind, I uninstalled chocolatey. In the end, is the error when LT tries to install it. Do you know what that error is about?
I'll try to re-install using the syntax you provided. Once it's installed, how do I force a chocolatey scan of that computer in regards to software to install or update? If I can't do that, then I have to wait until the next scheduled run.
I'll try to re-install using the syntax you provided. Once it's installed, how do I force a chocolatey scan of that computer in regards to software to install or update? If I can't do that, then I have to wait until the next scheduled run.
-
- Posts: 34
- Joined: Mon Jan 11, 2016 8:50 pm
- 8
Re: Chocolatey Not Installing
I ran the command and chocolatey is installed. I assume we now need LT to run the maintenance scripts. Can I induce that manually?
-
- Posts: 34
- Joined: Mon Jan 11, 2016 8:50 pm
- 8
Re: Chocolatey Not Installing
OK, so I forced another install of chocolatey after I had installed it manually on the computer using the command you provided. I still get the error as before, "A failure occurred during initialization: Object reference not set to an instance of an object.", but initializing the install from LT caused the maintenance script(s) to run. I'm not back to the error before where it's looking for components of chocolatey is missing within the Windows\LTSvc folder, so the maintenance scripts fail. I have provided the screenshots again.
- Attachments
-
- Scripts2.jpg (105.91 KiB) Viewed 18653 times
-
- Scripts1.jpg (112.39 KiB) Viewed 18653 times
-
- Command1.jpg (131.82 KiB) Viewed 18653 times
Re: Chocolatey Not Installing
Looking at your logs the script is running against your system and a response is received. I see the text file being read and it shows AdobeAir and Chocolatey versions as it should, Then we execute a Powershell function to convert text file to a SQL file. Very simple code if PoSh is working and is in global path. We then read in the sql file and save it to the database.tobycarver wrote:I ran the command and chocolatey is installed. I assume we now need LT to run the maintenance scripts. Can I induce that manually?
You are not getting the SQL file and thus no data in DB that Chocolatey is installed.
If you go into the script Chocolatey Maintenance in the Maintenance script folder you will find on line 12 of the Else section of script is a Powershell Script. Copy that script to a file and the open that file with PowerShell ISE as admin and execute. You may need to set the full path to both files in the first few lines (if poSh can not determine location based on the profile your using) .
Does it take the chocoscan.txt file and make a chocoscan.sql file out of it?