1

I have a MacBook Air, Early 2015, running macOS Mojave. Over the last 2 weeks, it has been unexpectedly shutting down and rebooting over varied time periods.

Upon checking the shutdown logs, I found the shutdown code to be -128; checking various sources on the Internet, I found that this was a "catch all hardware issues" code. Many sources showed that this could be caused by the computer overheating, or malfunctioning RAM or battery.

My computer does not overheat when it shuts down/reboots; the battery seems to be working fine, and I've not installed any third-party RAM. System Information seems to show both the RAM cards to be status "OK".

I've tried doing the following

  • Resetting the SMC.
  • Resetting the NVRAM.
  • Booting into Safe Mode.

to no avail.

The issue suddenly started when I was running macOS High Sierra (I was running it for quite some time, and the OS was stable). I've freshly installed macOS Mojave (wiping all previous data), so I'm quite sure this wasn't caused by Malware of some sort. Apple doesn't show any messages like "Your computer shut down because of a problem", and the logs don't show any Kernel Panics.

I've run hardware diagnostics, but it hasn't shown any problems. I've also run First Aid under Disk Utility just to be sure.

Another thing I've noticed, which I'm not sure was there before, is that during boot, with the loading bar around half-way through, the computer screen suddenly goes black for a second or two, and then it comes back to continue from where it left off. I'm not sure whether this is related.

Just to be clear, the time period between reboots and shutdowns are very varied; once, it rebooted thrice during use within a minute-or-two. Usually, it just shuts down in sleep (not caused by autopoweroff; still the same shutdown code), after hours of no usage.

I've noticed that the shutdown log is exactly the time when I boot it. I don't really know what to make of it.

Here are some logs of the second before the computer shutdown with the -128 code (and also the time when I was trying to take it out from sleep):

2018-10-06 09:04:33.861844+0530 0x65       Default     0x0                  0      0    kernel: calling mpo_policy_init for AMFI
2018-10-06 09:04:33.861849+0530 0x65       Default     0x0                  0      0    kernel: Security policy loaded: Apple Mobile File Integrity (AMFI)
2018-10-06 09:04:33.861853+0530 0x65       Default     0x0                  0      0    kernel: calling mpo_policy_init for Sandbox
2018-10-06 09:04:33.861898+0530 0x65       Default     0x0                  0      0    kernel: Security policy loaded: Seatbelt sandbox policy (Sandbox)
2018-10-06 09:04:33.862091+0530 0x65       Default     0x0                  0      0    kernel: calling mpo_policy_init for Quarantine
2018-10-06 09:04:33.862096+0530 0x65       Default     0x0                  0      0    kernel: Security policy loaded: Quarantine policy (Quarantine)
2018-10-06 09:04:33.862371+0530 0x65       Default     0x0                  0      0    kernel: calling mpo_policy_init for TMSafetyNet
2018-10-06 09:04:33.862375+0530 0x65       Default     0x0                  0      0    kernel: Security policy loaded: Safety net for Time Machine (TMSafetyNet)
2018-10-06 09:04:33.968541+0530 0x83       Default     0x0                  0      0    kernel: Started cpu 2 (lapic id 00000002)
2018-10-06 09:04:33.969492+0530 0x84       Default     0x0                  0      0    kernel: Started cpu 1 (lapic id 00000001)
2018-10-06 09:04:33.970435+0530 0x85       Default     0x0                  0      0    kernel: Started cpu 3 (lapic id 00000003)
2018-10-06 09:04:33.971229+0530 0x95       Default     0x0                  0      0    kernel: (AppleAPIC) IOAPIC: Version 0x20 Vectors 64:103
2018-10-06 09:04:33.985599+0530 0x71       Default     0x0                  0      0    kernel: (AppleACPIPlatform) ACPI: sleep states S0 S3 S4 S5
2018-10-06 09:04:34.009380+0530 0xad       Default     0x0                  0      0    kernel: (IOHIDFamily) HID: Legacy shim 2
2018-10-06 09:04:34.009561+0530 0x9a       Default     0x0                  0      0    kernel: (IOPCIFamily) pci (build 20:25:30 Aug 22 2018), flags 0x20e3480
2018-10-06 09:04:34.009565+0530 0xaf       Default     0x0                  0      0    kernel: (IOHIDFamily) HID: Legacy shim 2
2018-10-06 09:04:34.009567+0530 0x9a       Default     0x0                  0      0    kernel: (IOPCIFamily) pci (build 20:25:30 Aug 22 2018), flags 0x20e3480
2018-10-06 09:04:34.010358+0530 0x9a       Default     0x0                  0      0    kernel: (IOPCIFamily) [ PCI configuration begin ]
2018-10-06 09:04:34.010362+0530 0x9a       Default     0x0                  0      0    kernel: kPEDisableScreen -1
2018-10-06 09:04:34.012030+0530 0xb7       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) Provider is IOSMBusController
2018-10-06 09:04:34.012092+0530 0xb7       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) Clearing out battery data
2018-10-06 09:04:34.012109+0530 0xb7       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) Starting poll type 1
2018-10-06 09:04:34.012111+0530 0xb7       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) Restarting poll type 1
2018-10-06 09:04:34.012112+0530 0xb7       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) smcKeysToDictionary without SMC driver
2018-10-06 09:04:34.012114+0530 0xb7       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) Command 0x1100 completed. inCount: 2 data:0x0
2018-10-06 09:04:34.012115+0530 0xb7       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) smcKeysToDictionary without SMC driver
2018-10-06 09:04:34.012117+0530 0xb7       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) Command 0x1200 completed. inCount: 2 data:0x0
2018-10-06 09:04:34.012118+0530 0xb7       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) smcKeysToDictionary without SMC driver
2018-10-06 09:04:34.012119+0530 0xb7       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) Command 0x1300 completed. inCount: 2 data:0x0
2018-10-06 09:04:34.013780+0530 0xb7       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) AppleSmartBatteryManager started
2018-10-06 09:04:34.017775+0530 0x7d       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) Command 0x2 completed. inCount: 2 data:0x6
2018-10-06 09:04:34.019732+0530 0x7d       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) Command 0x1 completed. inCount: 2 data:0x1101
2018-10-06 09:04:34.019758+0530 0x9a       Default     0x0                  0      0    kernel: initialize_screen: b=7F90000000, w=000005A0, h=00000384, r=00001800, d=00000001
2018-10-06 09:04:34.019944+0530 0x9a       Default     0x0                  0      0    kernel: kPEEnableScreen 1
2018-10-06 09:04:34.019958+0530 0x9a       Default     0x0                  0      0    kernel: (IOPCIFamily) console relocated to 0x7f90000000
2018-10-06 09:04:34.019962+0530 0x9a       Default     0x0                  0      0    kernel: (IOPCIFamily) [ PCI configuration end, bridges 12, devices 15 ]
2018-10-06 09:04:34.020376+0530 0xbf       Default     0x0                  0      0    kernel: (IOUSBFamily) 000001.020370 AppleUSBLegacyRoot@(null): AppleUSBLegacyRoot::init: enabling legacy matching
2018-10-06 09:04:34.024195+0530 0x7e       Default     0x0                  0      0    kernel: (AppleSmartBatteryManager) Command 0x16 completed. inCount: 2 data:0xc0
2018-10-06 09:04:34.025277+0530 0xa3       Default     0x0                  0      0    kernel: (AppleSMC) Previous shutdown cause: -128

The logs above end with the shutdown.

The system.log logs before and after boot:

Oct  6 09:35:03 Munishs-MacBook-Air loginwindow[88]: DEPRECATED USE in libdispatch client: dispatch source activated with no event handler set; set a breakpoint on _dispatch_bug_deprecated to debug
Oct  6 09:35:04 Munishs-MacBook-Air com.apple.xpc.launchd[1] (com.apple.xpc.launchd.domain.user.501): Service "com.apple.xpc.launchd.unmanaged.loginwindow.88" tried to register for endpoint "com.apple.tsm.uiserver" already registered by owner: com.apple.SystemUIServer.agent
Oct  6 10:17:11 --- last message repeated 1 time ---
Oct  6 10:17:11 Munishs-MacBook-Air syslogd[39]: ASL Sender Statistics
Oct  6 10:17:13 Munishs-MacBook-Air timed[77]: settimeofday({0x5bb83e51,0x6a1d6}) == 0
Oct  6 10:17:17 Munishs-MacBook-Air xpcproxy[543]: libcoreservices: _dirhelper_userdir: 529: bootstrap_look_up returned (ipc/send) invalid destination port
Oct  6 10:24:18 Munishs-MacBook-Air com.apple.xpc.launchd[1] (com.apple.WebKit.Networking.F3E9FD36-49E7-44C5-A2CE-ED38E105F5FD[555]): Service exited with abnormal code: 1
Oct  6 10:24:19 Munishs-MacBook-Air com.apple.xpc.launchd[1] (com.apple.imfoundation.IMRemoteURLConnectionAgent): Unknown key for integer: _DirtyJetsamMemoryLimit
Oct  6 10:27:12 Munishs-MacBook-Air syslogd[39]: ASL Sender Statistics
Oct  6 10:28:00 localhost bootlog[0]: BOOT_TIME 1538801880 0
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.cdscheduler" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.install" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.family.asl" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.callhistory.asl.conf" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.contacts.ContactsUICore" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.authd" sharing output destination "/var/log/asl" with ASL Module "com.apple.asl".
    Output parameters from ASL Module "com.apple.asl" override any specified in ASL Module "com.apple.authd".
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.authd" sharing output destination "/var/log/system.log" with ASL Module "com.apple.asl".
    Output parameters from ASL Module "com.apple.asl" override any specified in ASL Module "com.apple.authd".
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.authd" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.eventmonitor" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.mail" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.coreaudio" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.performance" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.iokit.power" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.contacts.ContactsAutocomplete" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.mkb" sharing output destination "/private/var/log/keybagd.log" with ASL Module "com.apple.mkb.internal".
    Output parameters from ASL Module "com.apple.mkb.internal" override any specified in ASL Module "com.apple.mkb".
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.mkb" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.AddressBookLegacy" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.MessageTracer" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.networking.boringssl" sharing output destination "/Library/Logs/CrashReporter" with ASL Module "com.apple.networking.networkextension".
    Output parameters from ASL Module "com.apple.networking.networkextension" override any specified in ASL Module "com.apple.networking.boringssl".
Oct  6 10:28:02 localhost syslogd[39]: Configuration Notice:
    ASL Module "com.apple.clouddocs" claims selected messages.
    Those messages may not appear in standard system log files or in the ASL database.
Oct  6 10:28:01 localhost com.apple.xpc.launchd[1]: Early boot complete. Continuing system boot.
Oct  6 10:28:01 localhost com.apple.xpc.launchd[1] (com.apple.cmio.AVCAssistant): ThrottleInterval set to zero. You're not that important. Ignoring.
Oct  6 10:28:01 localhost com.apple.xpc.launchd[1] (com.apple.xpc.launchd.domain.system): com.apple.CoreRAID (lint): The HideUntilCheckIn property is an architectural performance issue. Please transition away from it.
Oct  6 10:28:01 localhost com.apple.xpc.launchd[1] (com.apple.diskmanagementd): ThrottleInterval set to zero. You're not that important. Ignoring.
Oct  6 10:28:01 localhost com.apple.xpc.launchd[1] (com.apple.diskmanagementd): The TimeOut key is no longer respected. It never did anything anyway.
Oct  6 10:28:01 localhost com.apple.xpc.launchd[1] (com.apple.syslogd): The HopefullyExitsLast key is no longer respected. Please remove it.
Oct  6 10:28:01 localhost com.apple.xpc.launchd[1] (com.apple.syslogd): Please switch away from OnDemand to KeepAlive.
Oct  6 10:28:01 localhost com.apple.xpc.launchd[1] (com.apple.opendirectoryd): Unknown key for Boolean: BeginTransactionAtShutdown
Oct  6 10:28:01 localhost com.apple.xpc.launchd[1] (com.apple.xpc.launchd.domain.system): com.apple.opendirectoryd (lint): The HideUntilCheckIn property is an architectural performance issue. Please transition away from it.

Is there anything else I can try before I hand the MacBook over to a professional? I've been using it since around two years, and it isn't covered under warranty.

  • I wanted to note that this is not a duplicate of those questions which ask about what the "-128" code is; I quite very well understand what it is, and my question isn't asking about that. – Ashish Ahuja Oct 6 '18 at 3:17
  • providing code 128 is not sufficient to answer the question. Please copy Console log starting 10 lines before boot time and few lines after. – Ruskes Oct 6 '18 at 3:25
  • @Buscar웃 Console does not show any logs before boot. It doesn't even seems to show the boot logs, weirdly. The first log I can find is by a process named MTLCompilerService. I also just noticed that the shutdown was caused just when I took the computer out of sleep. I'll try searching the logs directory for logs before boot, since they should be there. – Ashish Ahuja Oct 6 '18 at 3:41
  • ok then try the command top in terminal to see who is loading your system – Ruskes Oct 6 '18 at 3:54
  • @Buscar웃 I've added the logs! Please tell me if you need more. Did a grep on all the logs in the terminal. – Ashish Ahuja Oct 6 '18 at 3:54

You must log in to answer this question.

Browse other questions tagged .