Linux on iMac reboots instead of shutdown

ayushhroyy

New Member
Joined
May 7, 2022
Messages
7
Reaction score
1
Credits
57
I am running Linux on iMac late 2015, 21.5 inch (the 1tb hdd version) and it’s running effortlessly with just one issue,

It reboots on a shutdown.

(Suspend doesn’t work too, it just hangs the system or reboot sometimes but it happens to most Apple devices on linux so i let that slide)
I have tried Linux kernel 5.17 to 5.12 and lts 5.4, Fedora, Ubuntu, Elementary, Arch, Manjaro, pop OS all of these had the same issue.

Evidently, I thought it was an ACPI issue so I turned it off with quiet splash acpi=off in the grub file but it didn’t make any difference. I have tried running XHCI > /proc/wakeup/acpi that to led too no difference

I need some guidance to how to fix this issue, Much gratitude
 


Does
Code:
sudo shutdown -P now
work?
If this shuts down your machine properly, then it may be an issue with compatibility with your physical power button (if that is what you are using to shut down your computer when you have the issue).
In that case, try:
Code:
sudo apt update && sudo apt install laptop-mode-tools
providing you are running an Ubuntu or Debian based OS.

Also check to see if turning off the WiFi adapter first allows it to shut down
 
sudo shutdown -P now
This along with turning off wifi adaptor led to the same behaviour although there was a 30second pause before the reboot this time


sudo apt update && sudo apt install laptop-
I am on fedora and i used the GitHub install instructions, the app doesn't launch for me

Could you lead to the possible issues/kernel flags/properties that can create this behaviour? I wanna look into it myself too but can't get where to start.

Thank you
 
Side question: To anyone who would know, is this a typical problem for iMacs? I have a 2013 iMac desktop coming available to me sometime in the near future, and this would be good to know.
 
Side question: To anyone who would know, is this a typical problem for iMacs? I have a 2013 iMac desktop coming available to me sometime in the near future, and this would be good to know.
I guess it depends, I have another Mac mini from 2015 with same hardware specs and it runs linux perfectly, you might wanna look into forums online for your model.
 
In the BIOS do you have wake on LAN enabled? If so disable it , save the settings and try shut down again
 
In the BIOS do you have wake on LAN enabled? If so disable it , save the settings and try shut down again
Mac do not have a bios, though i disabled all the options that seem to be WOL and even disabled WOL from linux with ethtool, it didn't make a difference.

Could Linux kernel be a problem?
 
Huh... TIL: https://macpaw.com/how-to/mac-bios-mode

I mean, you pretty much have to have BIOS or UEFI - which it seems you definitely do, but you can't access it. That's kinda crazy, but I guess if it's just meant to run one OS and only that OS, you really don't need to access BIOS/CMOS/UEFI.
Well actually, I was wrong to say it doesn't have a bios, it pretty much provides the functionalities in recovery mode

The article you linked, I tried it before posting the reply above and it was a read-only command line whcih only allowed a few Unix commands so there wasn't much to do there

Thank you
 
Last edited:
Sorry for the late reply, but yes, it IS a typical problem with Intel based iMac computers. Mine is a late 2016 machine and yes, I too have to push the power button for 5 seconds to be able to power down. I first give the shutdown -h now command in linux, wait until all shutdown text stops scrolling by and then hold the power button. Never had any side effects from doing so...
Cheers, Eddy
 
Sorry for the late reply, but yes, it IS a typical problem with Intel based iMac computers. Mine is a late 2016 machine and yes, I too have to push the power button for 5 seconds to be able to power down. I first give the shutdown -h now command in linux, wait until all shutdown text stops scrolling by and then hold the power button. Never had any side effects from doing so...
Cheers, Eddy
Which Mac are you talking about? We might have the same ones, this Apple site does not list any Mac's from 2016 https://support.apple.com/en-us/HT201634
 
I seem to have the year of manufacturing wrong, sorry, it is an iMac (Retina 4K, 21.5-inch, Late 2015). Amazing how fast the years are passing, doesn't it ?
Cheers, Eddy
 
I seem to have the year of manufacturing wrong, sorry, it is an iMac (Retina 4K, 21.5-inch, Late 2015). Amazing how fast the years are passing, doesn't it ?
Cheers, Eddy
True that,
Btw is your sound okay or do you have a workaround with pipe wire and easyeffects? Mine has wrong mapping and i fixed it through alsa.

Thank you
 
I have no issue with my sound, having it configured with pulseaudio...
Cheers, Eddy
 
Sorry for the late reply, but yes, it IS a typical problem with Intel based iMac computers.
That's good to know. I plan to use mine as a server, so it will be on most of the time.

I wonder if shutdown -H (uppercase) would work to put it in a halted state, proper to turn off?
 
I also wonder if the Magic SysRq REISUB combo might save the day. It's typically reserved for frozen systems, but would it work to shut down? I'm not sure what the combo would be on a Mac.
 
I wonder if shutdown -H (uppercase) would work to put it in a halted state, proper to turn off?

Using shutdown -h or -H does not make any difference, I'm affraid... :-(
I never tried de Magic SysRq REISUB, I just use the power button if Debian hangs itself ;-)
Cheers, Eddy
 
I also wonder if the Magic SysRq REISUB combo might save the day. It's typically reserved for frozen systems, but would it work to shut down? I'm not sure what the combo would be on a Mac.

It's to be used as a server, so I'm assuming it'll be accessed remotely. REISUB doesn't work over SSH, VNC, etc... At least I've never figured out a way to forward it. It always reboots the local device.
 
Resurrecting this thread -
I have an iMac 16,1 with Debian 12 installed (not dual booted, Debian only). The problem described by the OP still exists, current kernel is 6.1.0-12-amd64. Anyone ever solve this?
 

Members online


Top