Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conemu Chocolatey Package 16.7.7.0 hangs in a background. #766

Closed
marcinbojko opened this issue Jul 8, 2016 · 24 comments
Closed

Conemu Chocolatey Package 16.7.7.0 hangs in a background. #766

marcinbojko opened this issue Jul 8, 2016 · 24 comments

Comments

@marcinbojko
Copy link

@marcinbojko marcinbojko commented Jul 8, 2016

Versions

ConEmu build: 16.7.7.0 x64
OS version: Windows 2012R2 x64, WIndows 8/8.1 x64 Windows 10 x64
Used shell version (Far Manager, git-bash, cmd, powershell, cygwin, whatever): ???
cmd, puppet

Problem description

when upgrading from previous chocolatey version (16.6.19) conemusetup just hangs. After timeout package is auto-removed from installed packages (by chocolatey).
Tested with other conemu window open/closed - doesn't matter

Steps to reproduce

  1. chocolatey install conemu --version 16.6.19.0
  2. chocolatey upgrade conemu

Actual results

Installing ConEmu... Chocolatey timed out waiting for the command to finish. The timeout specified (or the default value) was '2700' seconds. Perhaps try a higher --execution-timeout? See choco -h for details. The install of conemu was NOT successful. Error while running 'C:\ProgramData\chocolatey\lib\ConEmu\tools\chocolateyInstall.ps1'. See log for details.

Expected results

Silent upgrade

Additional files

Settings,
screenshots,
logs,
etc.

@Maximus5
Copy link
Owner

@Maximus5 Maximus5 commented Jul 8, 2016

Please try to download manually current and previous release installers (from releases section).
Try both in manual upgrade mode (standard MSI wizard).

That is strange, may be changes in chocolatey, because ConEmu installation scripts (MSI and nuget) weren't changed.

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Jul 8, 2016

I am cuurently in a test phase.Manual installation seems to be ok (after killing hanged process conemusetup_, and ruby_)
However using psexec on remote machine hangs as mentioned. Foreman+Chocolatey+Puppet hangs as mentioned.
It currently affected us on almost 200 machines.

@Maximus5
Copy link
Owner

@Maximus5 Maximus5 commented Jul 8, 2016

Craziness...

Can you run ProcessMonitor to track what happens when hang occurs?
Have you checked CPU utilization by processes? That may be a problem of antivirus software (updated recently). ProcessExplorer.

@Maximus5
Copy link
Owner

@Maximus5 Maximus5 commented Jul 8, 2016

BTW, ConEmuSetup doesn't run Ruby...

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Jul 8, 2016

The process run like this: Foreman=>puppet=>Chocolatey=>conemusetup.
2 hours ago all our machines reported 'out of sync'. Looking at logs, there was hanged conemusetup, which blocked another puppet agent (ruby) run.
So to unblock:

  1. kill conemusetup
  2. kill puppet agent (ruby)
  3. run manually puppet agent or manually choco install conemu.
    Allowing to run again by puppet end in point 1 (hanged conemusetup).
    Process affects ALL our OSes (Server and Desktop alike).

@Maximus5
Copy link
Owner

@Maximus5 Maximus5 commented Jul 8, 2016

Do you mean this foreman?
https://github.com/ddollar/foreman
Have not tried it.
I can only say, that installer was not changed since last build. Try to psexec previous ConEmuSetup to be sure...

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Jul 8, 2016

CPU stays at 0%, mem used for ConEmu installer stays at 0,7 MB.
ConEmu Installer is 32bit app. Looking at puppet logs it just hangs on 'Installing Conemu'

Foreman: https://theforeman.org/

Running chocolatey with previous version (16.6.19.0) with -force hungs as well.
Looks like there is a problem when previous version exists.

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Jul 8, 2016

Tested, removed all version of conemu. Installing from puppet/chocolatey hangs.
Maybe something with system account? I am unable to diagnose, it just ends with 'Installing Conemu'.
Is there any way to know what installer is doing?

@Maximus5
Copy link
Owner

@Maximus5 Maximus5 commented Jul 8, 2016

Installer is a bootstrap for MSI.

  1. It unpacks msi and cab to the temp folder (is ConEmu.160707 created in user local temp dir?)
  2. It runs msiexec.exe with arguments, passing temp msi package.
  3. Waits for msiexec termination.

In theory, ConEmuSetup may show error message box if some problem occurs, but I'm almost sure it must not do that in automatic mode used by choco.

Look at process tree in ProcessExplorer, use ProcessMonitor to check process activity as I've suggest before.

Also, you may unpack msi+cab manually (run ConEmuSetup /? for switches) and try to emulate (psexec) the problem by starting msiexec.exe directly, without ConEmuSetup.

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Jul 8, 2016

  1. No, it uses system temp path - c:\windows\temp\chocolatey\ConEmu
  2. OK
  3. OK

I've included 2 printscreens:
https://dl.dropboxusercontent.com/u/6066664/PAC%20%28v4.5.5.7%29_347.png
https://dl.dropboxusercontent.com/u/6066664/PAC%20%28v4.5.5.7%29_348.png

About the last point (test with msi/cab) I will be able to get back to this issue in a couple of days, but as for now I have to clean all servers.

@Maximus5
Copy link
Owner

@Maximus5 Maximus5 commented Jul 8, 2016

No, ConEmuSetup.exe is saved by choco in system temp. But msi+cab are extracted to another temp dir, returned by GetTempPath API function and creates there new unique subfolder ConEmu.XXXXXX, where extract files.

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Jul 8, 2016

Apologies, misunderstood.
I am unable to find extracted files, nothing under c:\windows\temp
However, I am able to find those extracted files from previous installs (160515)

@Maximus5
Copy link
Owner

@Maximus5 Maximus5 commented Jul 8, 2016

In my case, files are located in c:\users\name\appdata\local\temp...
You may easily check that by running ConEmuSetup manually.
Also, files are expected to be removed after ConEmuSetup exits.

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Jul 8, 2016

Yes, if I am running choco manually from my account, your path is true. But when I left it to run under system account, there are no files/directories with those names in c:\windows\temp, which should be default tempdir for local system account.
I've checked this with psexec run with and without -s flag.
With -s
TEMP=C:\Windows\TEMP
TMP=C:\Windows\TEMP�

without s
TEMP=C:\Users\MARCIN1.BOJ\AppData\Local\Temp
TMP=C:\Users\MARCIN
1.BOJ\AppData\Local\Temp�

@Maximus5
Copy link
Owner

@Maximus5 Maximus5 commented Jul 8, 2016

Has it ever been working before?
I suppose, GetTempPath returns bad inaccessible dir when running under system account.

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Jul 8, 2016

Yes, it worked perfectly, and because your ConEmu is such great tool, i just replaced cmd with conemu on all our machines.
Ran the last test: run installer via psexec with and without system account. Without system account looks like it works perfectly. With system account it hangs.
I think that you may be right about Temp, in last version chocolatey changed something with Temp folders.
In my own installers I started to use tests: if temp path exists

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Jul 8, 2016

Maybe something like this: chocolatey/choco#826

Maximus5 pushed a commit that referenced this issue Jul 11, 2016
  * Don't show MessageBox in auto mode (chocolatey, autoupdate);
  * Log error messages to log-file in the exe's folder;
  * In case TEMP directory is inaccessible, just use exe's folder.
@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Jul 11, 2016

Hi Maximus5
I am afraid with new version we again have problem with all servers puppet agent fails, and ConEmu setup just cumulates with tme (after few hours we have 5-6 running instances).
Is it possible to make packages with MSI instead of exec, which currently seems to have serious problems?

@Maximus5
Copy link
Owner

@Maximus5 Maximus5 commented Jul 11, 2016

New version behaves different way. What is the process tree at "hang" state?
Also, new version creates log file on problems, check tge dir where ConEmuSetup.exe is located. Want to see it.

No sense to create msi packages, I have already three different packages, two more?

When I've checked on my PC, there were no problem while installing from System account.

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Jul 12, 2016

Will check.Currently I pinned down all version from latest to 16.07.07

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Jul 12, 2016

Hi Maximus5.
Again, thank you for your help, I appreciate this.

From logs:

ConEmu 160710 installer
Can't create temp folder
C:\WINDOWS\system32\config\systemprofile\AppData\Local\Temp\ConEmu160710_103743
ErrorCode=3
ReportError code=10

Which looks exactly like chocolatey/choco#826, but on your installer level.

Packed logs: https://dl.dropboxusercontent.com/u/6066664/16.7.10.0.zip
Process Tree: https://dl.dropboxusercontent.com/u/6066664/Screenshot%20from%202016-07-12%2010%3A38%3A38.png

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Jul 25, 2016

Hi Maximus5
No change with 160724 version.

ConEmu 160724 installer Installer failed C:\Windows\system32\config\systemprofile\AppData\Local\Temp\ConEmu160724\ConEmu.160724.x64.msi ExitCode=1619 ReportError code=1719

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Aug 31, 2016

Thanks!

@marcinbojko
Copy link
Author

@marcinbojko marcinbojko commented Aug 31, 2016

Looks like this issue is gone now.
Thank you for your time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants