I'm having a problem with my macbook where, for some reason, when it's unplugged to the power the computer randomly turns the screen semi-black (not totally black) and starts the fan at max power. The computer itself is still on (the apple is bright) and I have to turn it off by long pressing the power button.
I'm not able to understand what is going on:
The logs from system.log
Apr 19 09:15:03 marco com.apple.xpc.launchd[1] (com.apple.sandboxd[153]): Service exited due to SIGALRM | sent by kernel_task[0]
Apr 19 09:15:03 marco syslogd[96]: ASL Sender Statistics
Apr 19 09:15:05 marco com.apple.xpc.launchd[1] (com.apple.bsd.dirhelper[9925]): Endpoint has been activated through legacy launch(3) APIs. Please switch to XPC or bootstrap_check_in(): com.apple.bsd.dirhelper
Apr 19 09:15:05 marco systemstats[107]: assertion failed: 18D109: systemstats + 676139 [952918BC-3D73-37CE-8C6A-851AAF3C70D1]: 0x7f946c61bfe0
Apr 19 10:13:48 marco syslogd[96]: ASL Sender Statistics
Apr 19 10:13:48 marco com.apple.xpc.launchd[1] (com.apple.newsyslog): Service only ran for 8 seconds. Pushing respawn out by 2 seconds.
Apr 19 10:13:49 marco fud[9987]: objc[9987]: Class MobileAssetUpdater is implemented in both /System/Library/PrivateFrameworks/MobileAccessoryUpdater.framework/Support/fud (0x1029ab908) and /System/Library/AccessoryUpdaterBundles/ApplePowerAccessoryUpdater.bundle/Contents/MacOS/ApplePowerAccessoryUpdater (0x1054b2a68). One of the two will be used. Which one is undefined.
Apr 19 10:14:01 marco timed[133]: settimeofday({0x5cb98349,0xeea4a}) == 0
Apr 19 10:14:03 marco com.apple.xpc.launchd[1] (com.apple.duetknowledged[10064]): Could not find and/or execute program specified by service: 2: No such file or directory: /usr/local/libexec/duetknowledged
Apr 19 10:14:03 marco com.apple.xpc.launchd[1] (com.apple.duetknowledged[10064]): Service setup event to handle failure and will not launch until it fires.
Apr 19 10:14:03 marco com.apple.xpc.launchd[1] (com.apple.duetknowledged[10064]): Service exited with abnormal code: 78
Apr 19 10:20:55 localhost bootlog[0]: BOOT_TIME 1555662055 0
Where 10:15 is the computer still on, but close to the time of "death". I left it running from 10:15 to 10:20 (in this time the fan was running at fullpower) where I turned it off, but nothing appeared in the logs for that time period (weirdly)
Do you have any suggestion on how to debug and fix this issue? I might consider formatting everything as a last resort but I prefer not to because I have a lot of setup of various work projects
OSX Version: 10.14.3