hjuutilainen / munkiadmin

macOS app for managing Munki repositories
MIT License
370 stars 34 forks source link

MunkiAdmin crashes when starting. #189

Closed ReneRochefort closed 5 years ago

ReneRochefort commented 5 years ago

I can't start MunkiAdmin, it crashes immediately when starting up. The crash report says: *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Couldn't posix_spawn: error 13'

It worked for a while but this started all of a sudden.

I've uninstalled MunkiAdmin, removed every trace of Munki I could find, re-set up everything again, but the crash keeps happening.

ReneRochefort commented 5 years ago
MunkiAdmin[17330:90642] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Couldn't posix_spawn: error 13'
*** First throw call stack:
(
    0   CoreFoundation                      0x00007fff3cdab783 __exceptionPreprocess + 250
    1   libobjc.A.dylib                     0x00007fff72d578f3 objc_exception_throw + 48
    2   Foundation                          0x00007fff3f4015a5 -[NSConcreteTask launchWithDictionary:error:] + 5014
    3   MunkiAdmin                          0x000000010733e913 MunkiAdmin + 743699
    4   libdispatch.dylib                   0x00007fff74059553 _dispatch_call_block_and_release + 12
    5   libdispatch.dylib                   0x00007fff7405a4de _dispatch_client_callout + 8
    6   libdispatch.dylib                   0x00007fff7405c328 _dispatch_queue_override_invoke + 763
    7   libdispatch.dylib                   0x00007fff740687e5 _dispatch_root_queue_drain + 326
    8   libdispatch.dylib                   0x00007fff74068f25 _dispatch_worker_thread2 + 92
    9   libsystem_pthread.dylib             0x00007fff742b771d _pthread_wqthread + 220
    10  libsystem_pthread.dylib             0x00007fff742b75c3 start_wqthread + 15
)
libc++abi.dylib: terminating with uncaught exception of type NSException
libc++abi.dylib: terminating with uncaught exception of type NSException
Abort trap: 6
logout
Saving session...
...copying shared history...
...saving history...truncating history files...
...completed.

[Process completed]
hjuutilainen commented 5 years ago

Thanks for reporting, investigating...

hjuutilainen commented 5 years ago

Can't replicate this immediately but this is already a second report of this within a couple of hours. What macOS version and what MunkiAdmin version are you running? Do you get any messages from MunkiAdmin in the latest log file at ~/Library/Logs/MunkiAdmin? There should be at least a line saying "Starting MunkiAdmin version 1.7.0".

ReneRochefort commented 5 years ago

Currently running 10.15, was on 10.14 tried updating to see if it would fix the issue.

No MunkiAdmin folder in Logs

These are the details from the report.

Starting MunkiAdmin version 1.7.0
2019-10-24 13:40:55.848 MunkiAdmin[17330:90592] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Couldn't posix_spawn: error 13'
*** First throw call stack:
(
    0   CoreFoundation                      0x00007fff3cdab783 __exceptionPreprocess + 250
    1   libobjc.A.dylib                     0x00007fff72d578f3 objc_exception_throw + 48
    2   Foundation                          0x00007fff3f4015a5 -[NSConcreteTask launchWithDictionary:error:] + 5014
    3   MunkiAdmin                          0x000000010733e913 MunkiAdmin + 743699
    4   libdispatch.dylib                   0x00007fff74059553 _dispatch_call_block_and_release + 12
    5   libdispatch.dylib                   0x00007fff7405a4de _dispatch_client_callout + 8
    6   libdispatch.dylib                   0x00007fff7405c328 _dispatch_queue_override_invoke + 763
    7   libdispatch.dylib                   0x00007fff740687e5 _dispatch_root_queue_drain + 326
    8   libdispatch.dylib                   0x00007fff74068f25 _dispatch_worker_thread2 + 92
    9   libsystem_pthread.dylib             0x00007fff742b771d _pthread_wqthread + 220
    10  libsystem_pthread.dylib             0x00007fff742b75c3 start_wqthread + 15
)
2019-10-24 13:40:55.848 MunkiAdmin[17330:90642] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Couldn't posix_spawn: error 13'
*** First throw call stack:
(
    0   CoreFoundation                      0x00007fff3cdab783 __exceptionPreprocess + 250
    1   libobjc.A.dylib                     0x00007fff72d578f3 objc_exception_throw + 48
    2   Foundation                          0x00007fff3f4015a5 -[NSConcreteTask launchWithDictionary:error:] + 5014
    3   MunkiAdmin                          0x000000010733e913 MunkiAdmin + 743699
    4   libdispatch.dylib                   0x00007fff74059553 _dispatch_call_block_and_release + 12
    5   libdispatch.dylib                   0x00007fff7405a4de _dispatch_client_callout + 8
    6   libdispatch.dylib                   0x00007fff7405c328 _dispatch_queue_override_invoke + 763
    7   libdispatch.dylib                   0x00007fff740687e5 _dispatch_root_queue_drain + 326
    8   libdispatch.dylib                   0x00007fff74068f25 _dispatch_worker_thread2 + 92
    9   libsystem_pthread.dylib             0x00007fff742b771d _pthread_wqthread + 220
    10  libsystem_pthread.dylib             0x00007fff742b75c3 start_wqthread + 15
)
libc++abi.dylib: terminating with uncaught exception of type NSException
libc++abi.dylib: terminating with uncaught exception of type NSException
Abort trap: 6
logout
Saving session...
...copying shared history...
...saving history...truncating history files...
...completed.

[Process completed]
hjuutilainen commented 5 years ago

Do you get anything more in the log if you manually increase the logging level: defaults write com.hjuutilainen.MunkiAdmin logLevel -int 5?

ReneRochefort commented 5 years ago

Good morning,

Apparently, I was looking in the wrong folder…

Attached is the most recent log file, including an attempt after increasing the log level.

hjuutilainen commented 5 years ago

Troubleshooted this with another affected user in MacAdmins Slack and the culprit seems to be a broken munkitools install. Try reinstalling the full munkitools package (3.6.4 or 3.7 beta) and make sure they are working.

ReneRochefort commented 5 years ago

How do I make sure munkitools is working properly? I haven’t gotten anything completely set up yet, I did the demo set up and it worked.

I was running munkitools-3.6.4.3786, downloaded a new copy of the installer, reinstalled, same issue.

Downloaded munkitools-3.7.0.3875, installed, same issue.

Installed MunkiAdmin-1.7.0 again (replaced files), same issue.

-- René Rochefort Information Technology Services Grand Erie District School Board 519-756-6301, ext. 287012

From: Hannes Juutilainen notifications@github.com Reply-To: hjuutilainen/munkiadmin reply@reply.github.com Date: Friday, October 25, 2019 at 11:39 AM To: hjuutilainen/munkiadmin munkiadmin@noreply.github.com Cc: "Rochefort, Rene" rene.rochefort@granderie.ca, Author author@noreply.github.com Subject: Re: [hjuutilainen/munkiadmin] MunkiAdmin crashes when starting. (#189)

CAUTION: This email originated from outside of the organization. Do not follow guidance, click links, or open attachments unless you recognize the sender and know the content is safe.

Troubleshooted this with another affected user in MacAdmins Slack and the culprit seems to be a broken munkitools install. Try reinstalling the full munkitools package (3.6.4 or 3.7 beta) and make sure they are working.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/hjuutilainen/munkiadmin/issues/189?email_source=notifications&email_token=ANHYVZ3VLLLDEKKYK2RVA5LQQMHLXA5CNFSM4JEXSVR2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECIXRGY#issuecomment-546404507, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ANHYVZ2FILIPNFXK6PXVZETQQMHLXANCNFSM4JEXSVRQ.

hjuutilainen commented 5 years ago

Could you run the following commands in Terminal.app and copy/paste the output here:

which makepkginfo
makepkginfo --version
makecatalogs --version

On a working munkitools install, those should result something like this:

% which makepkginfo                     
/usr/local/munki/makepkginfo

% makepkginfo --version
3.7.0.3875

% makecatalogs --version
3.7.0.3875
ReneRochefort commented 5 years ago

This is what I get

apple-imgserv:~ admin$ which makepkginfo
/usr/local/munki/makepkginfo
apple-imgserv:~ admin$ makepkginfo --version
3.7.0.3875
apple-imgserv:~ admin$ makecatalogs --version
3.7.0.3875
ReneRochefort commented 5 years ago

Is there a way to reset the path settings? Uninstalling doesn't get rid of everything. Maybe I have a path wrong or another settings that is saved somewhere else.

hjuutilainen commented 5 years ago

You can reset all MunkiAdmin settings by running defaults delete com.hjuutilainen.MunkiAdmin but could you first run defaults read com.hjuutilainen.MunkiAdmin and post the output here so I could check if there’s anything weird?

ReneRochefort commented 5 years ago
[apple-imgserv:~ admin$ defaults read com.hjuutilainen.MunkiAdmin
{
    NSNavLastRootDirectory = "/Users/Shared/munki_repo/manifests";
    NSNavLastUserSetHideExtensionButtonState = 0;
    NSNavPanelExpandedSizeForOpenMode = "{712, 448}";
    NSNavPanelExpandedSizeForSaveMode = "{712, 448}";
    "NSTableView Columns v2 installsItemsTableView" = {length = 1389, bytes = 0x62706c69 73743030 d4010203 0405069f ... 00000000 00000407 };
    "NSTableView Columns v2 manifestsTableView" = {length = 1760, bytes = 0x62706c69 73743030 d4010203 040506cc ... 00000000 00000520 };
    "NSTableView Columns v2 packagesTableViewWithIcons" = {length = 1518, bytes = 0x62706c69 73743030 d4010203 040506b7 ... 00000000 00000458 };
    "NSTableView Columns v2 receiptsTableView" = {length = 1030, bytes = 0x62706c69 73743030 d4010203 04050677 ... 00000000 000002f0 };
    "NSTableView Sort Ordering v2 installsItemsTableView" = {length = 404, bytes = 0x62706c69 73743030 d4010203 04050625 ... 00000000 00000122 };
    "NSTableView Sort Ordering v2 manifestsTableView" = {length = 412, bytes = 0x62706c69 73743030 d4010203 04050625 ... 00000000 0000012a };
    "NSTableView Sort Ordering v2 packagesTableViewWithIcons" = {length = 562, bytes = 0x62706c69 73743030 d4010203 04050639 ... 00000000 00000198 };
    "NSTableView Sort Ordering v2 receiptsTableView" = {length = 483, bytes = 0x62706c69 73743030 d4010203 0405062f ... 00000000 0000015d };
    "NSTableView Supports v2 installsItemsTableView" = 1;
    "NSTableView Supports v2 manifestsTableView" = 1;
    "NSTableView Supports v2 packagesTableViewWithIcons" = 1;
    "NSTableView Supports v2 receiptsTableView" = 1;
    "NSToolbar Configuration mainWindowToolbar" =     {
        "TB Display Mode" = 1;
        "TB Icon Size Mode" = 1;
        "TB Is Shown" = 1;
        "TB Size Mode" = 1;
    };
    "NSWindow Frame mainwindow" = "90 238 1100 722 0 0 1280 1001 ";
    logLevel = 5;
    makecatalogsPath = "/Users/Shared/munki_repo/catalogs";
    manifestsSortDescriptors = {length = 146, bytes = 0x040b7374 7265616d 74797065 6481e803 ... 70617265 3a868686 };
    openRepositoryLastDir = "/Users/Shared/munki_repo";
    selectedRepositoryPath = "/Users/Shared/munki_repo";

I'll wait before deleting the settings.

hjuutilainen commented 5 years ago

Ah, the problem is here makecatalogsPath = "/Users/Shared/munki_repo/catalogs";. That should be the path to the makecatalogs command line tool. Check if running defaults delete com.hjuutilainen.MunkiAdmin makecatalogsPath to only reset that particular setting resolves this issue?

ReneRochefort commented 5 years ago

That did it!

Thank you for your help!

ReneRochefort commented 5 years ago

Thank you for your assistance!