İçeriğe geç
KURUMSAL Kurumsal teknoloji · İşletmenize özel mühendislik Kurumsal Yazılım · Yönetilen Sunucular · Kurumsal E-posta · LiteSpeed + CloudLinux · Imunify360 Güvenlik · cPanel Yönetim · Uygun pakette 3 Gbps'ye kadar ağ profili
AIOR

Mac Enerji Ayarları Nasıl Sıfırlanır

  • Konu başlatıcısı Konu başlatıcısı Aior
  • Başlangıç tarihi Başlangıç tarihi

Aior

Administrator

Yetkili üye
Katıldı
2 Nis 2023
Mesajlar
929
Tepki puanı
2
Puan
18
Yaş
41
Konum
Turkey
Web sitesi
aior.com
Konu sahibi

Mac'iniz geceleri uyumuyor, çantada kapağı kapalıyken ısınıyor, sabaha karşı kendiliğinden uyanıyor ya da uykudayken pili beklenenden hızlı bitiyorsa ilk akla gelen çözüm enerji ayarlarını sıfırlamaktır. Bu bazen işe yarar, ancak çoğu durumda sorun ayarların kendisi değildir. Uykuyu engelleyen bir uygulama, Mac'i uyandıran bir aygıt ya da açık bir ağ servisi varsa sıfırlamadan birkaç gün sonra aynı tablo geri gelir. Bu rehberde önce nedeni bulmayı, sonra gerekiyorsa sıfırlamayı anlatıyoruz. Teşhis komutlarının örnek çıktıları macOS 27 yüklü bir Apple silicon MacBook'tan alındı; menü adları macOS Ventura (13) ve sonrasına göredir.

1. Enerji ayarları güncel macOS'ta nerede?​

macOS Ventura ile Sistem Tercihleri'nin yerini Sistem Ayarları aldı ve enerji seçenekleri birkaç bölüme dağıldı:
Ne arıyorsunuz?Dizüstü (MacBook Air, MacBook Pro)Masaüstü (Mac mini, iMac, Mac Studio, Mac Pro)
Ana bölümSistem Ayarları > PilVentura ve Sonoma'da Enerji Tasarrufu, Sequoia (15) ve sonrasında Enerji
Uyku ve uyanma seçenekleriPil > Seçenekler: "Ağ erişiminde uyan", "Ekran kapalıyken ve güç adaptörü takılıyken otomatik olarak uyku durumuna geçmesini engelle"Aynı bölümde: "Ekran kapalıyken otomatik olarak uyku durumuna geçmesini engelle", "Ağ erişiminde uyan", "Power Nap'i Etkinleştir"
Ekranın kapanma süresiSistem Ayarları > Kilitli EkranSistem Ayarları > Kilitli Ekran
Big Sur (11) ve Monterey (12)Sistem Tercihleri > PilSistem Tercihleri > Enerji Tasarrufu
Catalina (10.15) ve öncesinde dizüstüler dahil tüm Mac'lerde bölümün adı Sistem Tercihleri > Enerji Tasarrufu'dur. Bazı seçenekler modele ve sürüme göre görünmeyebilir. Örneğin Power Nap seçeneği dizüstülerde bazı sürümlerde Pil > Seçenekler altındadır, bazılarında ise arayüzde hiç yer almaz. Arayüzde ne görürseniz görün, Terminal'deki pmset komutu güç yönetimi ayarlarının tamamını gösterir ve Sistem Ayarları'nın kullandığı ayarların aynısını değiştirir.

2. Önce teşhis: pmset ile nedeni bulun​

Terminal'i Uygulamalar > İzlenceler klasöründen ya da Spotlight ile (Command + Boşluk tuşlarına basıp "Terminal" yazarak) açın. Adım 5'teki sudo pmset repeat cancel dışında bu bölümdeki komutlar yalnızca okur; hiçbir ayarı değiştirmez ve yönetici parolası istemez.

Adım 1: Geçerli ayarlar ve uykuyu engelleyenler​

Bash:
pmset -g
Çıktıdaki sleep satırı sistem uykusunun, displaysleep satırı ekran uykusunun süresidir (dakika cinsinden; 0 "hiçbir zaman" demektir). Bir süreç uykuyu engelliyorsa adı satırın sonunda parantez içinde görünür:
Kod:
sleep                1 (sleep prevented by powerd, caffeinate)
displaysleep         10 (display sleep prevented by caffeinate)
Dizüstülerde sleep değerinin 1 görünmesi olağandır: ekran açıkken powerd sistem uykusunu zaten engeller, sistem ekran kapandıktan kısa süre sonra uyur. Asıl ilgilenmeniz gereken, parantez içindeki süreç adlarıdır.

Adım 2: Pil ve adaptör profilleri, değişiklikten önce yedek​

Bash:
pmset -g custom
pmset -g custom > ~/Desktop/pmset-yedek.txt
Dizüstülerde pil (Battery Power) ve adaptör (AC Power) için ayrı değerler tutulur. Sorun yalnızca adaptöre bağlıyken ortaya çıkıyorsa önce AC Power bölümündeki değerlere bakın. Masaüstüne kaydettiğiniz dosya, sonradan neyi değiştirdiğinizi görmenizi ve gerekirse eski değerlere dönmenizi sağlar.

Adım 3: Uyku kilitleri (power assertions)​

Uygulamalar ve sistem servisleri uykuyu geçici olarak engellemek için "assertion" adı verilen kilitler oluşturur:
Bash:
pmset -g assertions
pmset -g assertions | grep -E "pid [0-9]+"
İkinci komut yalnızca kilit sahibi süreçleri listeler. Örnek bir satır:
Kod:
pid 2828(caffeinate): [0x...] 17:10:55 PreventUserIdleSystemSleep named: "caffeinate command-line tool"
  • PreventUserIdleDisplaySleep: Ekranın boşta kalınca kapanmasını engeller. Video oynatıcılar, sunum ve görüntülü görüşme uygulamaları bu kilidi alır.
  • PreventUserIdleSystemSleep: Ekran kapansa bile sistemin boşta uyumasını engeller. İndirme, ses çalma ve yedekleme sırasında görülür.
  • PreventSystemSleep: Sistem uykusunu engeller. Örneğin caffeinate -s bu kilidi alır ve kilit yalnızca Mac adaptöre bağlıyken geçerlidir.
"Powerd - Prevent sleep while display is on" kaydı normaldir. Şüpheli olan, saatlerdir süren bir kayıttır: yukarıdaki örnekte süre sütunu, 17 saattir çalışan ve unutulmuş bir caffeinate'i gösteriyor. Aynı bilgiyi Etkinlik Monitörü'nde Enerji sekmesindeki "Uyuma Engelleme" sütunundan da okuyabilirsiniz; sütun görünmüyorsa Görüntü > Sütunlar menüsünden açın.

Adım 4: Mac'i ne uyandırıyor?​

Bash:
pmset -g log | grep -E "Entering Sleep|Wake from|DarkWake from" | tail -n 30
pmset -g log | grep -E "Wake from|DarkWake from" | grep -oE "due to [^/]*" | sed -E 's/ Using .*//' | sort | uniq -c | sort -rn | head
İlk komut son uyku ve uyanma olaylarını gösterir, ikincisi uyanma nedenlerini sayıp en sık görülenleri üste dizer. "Wake" ekranın açıldığı tam uyanmadır. "DarkWake" ise ekran kapalıyken yapılan kısa bakım uyanmasıdır; Power Nap, ağ bağlantısının canlı tutulması ve zamanlanmış görevler bu şekilde çalışır. Neden metinleri modele ve sürüme göre değişse de iyi ipucu verir: rtc ya da RTC zamanlanmış bir uyanmayı, lid ya da LidOpen kapağın açılmasını, USB ya da XHC bir USB aygıtını, wifibt, ARPT ya da bluetooth kablosuz donanımı, UserActivity ise klavye, fare veya izleme dörtgeni girdisini gösterir.

Adım 5: Zamanlanmış uyanmalar​

Bash:
pmset -g sched
Sahibi com.apple ile başlayan kayıtlar sistemin kendi bakım uyanmalarıdır ve normaldir. Bir yedekleme ya da eşzamanlama uygulamasının kaydını görürseniz zamanlamayı o uygulamanın içinden değiştirin. pmset repeat ile kurulmuş tekrarlayan güç olaylarını sudo pmset repeat cancel kaldırır.

3. Sık görülen nedenler ve çözümleri​

NedenNasıl anlaşılır?Ne yapmalı?
Power NapLog'da düzenli DarkWake satırları; pmset -g çıktısında powernap 1Masaüstünde Enerji'den, dizüstünde seçenek varsa Pil > Seçenekler'den kapatın; yalnızca pil için sudo pmset -b powernap 0
Ağ erişiminde uyan (womp)Ağdaki paylaşım istekleri ve iCloud trafiği Mac'i uyandırır; pmset -g çıktısında womp 1Gerekmiyorsa dizüstünde "Asla" seçin, masaüstünde kapatın ya da sudo pmset -a womp 0 çalıştırın. Bu durumda Mac'imi Bul (Find My Mac) ayarları, Mac uykudayken yerinin belirlenemeyeceği, kilitlenemeyeceği ve silinemeyeceği uyarısını gösterebilir.
Bluetooth ve USB aygıtlarıUyanma nedeninde USB, XHC veya bluetooth; masada itilen bir fare bile Mac'i uyandırabilirAygıtları tek tek çıkarıp yeniden deneyin; arızalı bir hub, dock ya da harici disk uykuyu tamamen engelleyebilir
Uyku kilidi tutan uygulamalarAssertions listesinde tarayıcı, medya oynatıcı, toplantı uygulaması, unutulmuş bir caffeinate ya da Amphetamine gibi uyanık tutma araçlarıSekmeyi veya uygulamayı kapatın; kendi başlattığınız bir caffeinate için pkill -x caffeinate
Bul (Find My) ve iCloud'Maintenance Sleep':TCPKeepAlive=active satırları; destekleyen sistemlerde aynı Apple Hesabı'ndaki cihazlar yaklaşınca uyanma (proximitywake)Büyük ölçüde normaldir. tcpkeepalive'ı kapatmayın: pmset bu durumda "Find My Mac" gibi kritik özelliklerin düzgün çalışmayacağı uyarısını verir
Paylaşma servisleri ve SSHDosya, ekran ya da yazıcı paylaşımı açık; etkin bir SSH oturumu (ttyskeepawake 1)Sistem Ayarları > Genel > Paylaşma'da kullanmadıklarınızı kapatın, uzak oturumları sonlandırın
Spotlight, Time Machine, güncellemelerAssertions listesinde dizinleme, yedekleme ya da güncelleme süreçleriGeçicidir, iş bitince Mac uyur; ilk Spotlight dizinlemesi saatler sürebilir
Kapalı ekran modu (clamshell)Kapak kapalı; harici ekran ve güç adaptörü bağlı, harici klavye, fare ya da izleme dörtgeni kullanılıyorArıza değildir; MacBook bu düzende çalışmaya devam edecek şekilde tasarlanmıştır

4. Ayarları varsayılana döndürme​

Arayüzden: macOS Monterey ve öncesinde Pil ya da Enerji Tasarrufu tercihlerinde "Saptanmışlara Dön" düğmesi bulunur. Apple'ın Ventura ve sonrası için hazırladığı kılavuzlarda bu düğme yer almıyor. Bunun yerine enerji tüketimini artıran bir ayar seçtiğinizde Pil ya da Enerji bölümünde "Mac'iniz bu ayarlarla daha fazla enerji harcayabilir" uyarısı ve yanında "Saptanmışlara Dön" düğmesi görünebilir; macOS 27'de aynı uyarı Kilitli Ekran bölümünde "Sıfırla" düğmesiyle görünebilir. Ne düğme ne de uyarı varsa ayarları elle gözden geçirin:
  1. Kilitli Ekran: pil ya da adaptör için ekranı kapatma süresinde "Asla" seçiliyse makul bir süreye çekin.
  2. Pil > Seçenekler (dizüstü) veya Enerji (masaüstü): "…otomatik olarak uyku durumuna geçmesini engelle" seçeneğini kapatın, "Ağ erişiminde uyan"ı gerçekten ihtiyacınız olan değere getirin.
  3. Düşük Güç Modu ve (modelinizde varsa) Enerji Modu'nu bilerek seçtiğiniz değerde bırakın.
Terminal'den: Tüm güç yönetimi ayarlarını tek komutla varsayılana döndürmek için:
Bash:
pmset -g custom > ~/Desktop/pmset-once.txt
sudo pmset restoredefaults
pmset -g custom
Komut yönetici parolanızı ister; parola yazılırken ekranda karakter görünmez, yazıp Return'e basın. Değişiklik hemen uygulanır. Yeniden başlatmak zorunlu değildir, ancak takılı kalmış uygulama kilitlerini de temizlediği için iyi bir sonraki adımdır. Komut yalnızca güç yönetimi ayarlarını etkiler; dosyalarınıza ve diğer tercihlerinize dokunmaz. Varsayılan değerler modele göre değiştiği için sonucu son komutla kontrol edin. Eski rehberlerin önerdiği PowerManagement plist dosyalarını elle silmek gereksizdir; bu dosyaların yeri sürümden sürüme değişti ve desteklenen yol pmset'tir.

5. Yalnızca Intel Mac'ler: SMC ve NVRAM​

Önce Mac'inizin türünü öğrenin: Apple menüsü > Bu Mac Hakkında penceresinde "Çip" satırı varsa Apple silicon, "İşlemci" satırında Intel yazıyorsa Intel tabanlı bir Mac kullanıyorsunuz. Intel Mac'lerde güç düğmesi davranışını, pil ve şarjı, fanları, kapak açma-kapama davranışını ve uyku göstergesini SMC (Sistem Yönetim Denetleyicisi) yönetir. T2 çipi olup olmadığını görmek için Option tuşuna basılıyken Apple menüsü > Sistem Bilgileri'ni açın ve kenar çubuğundaki Denetleyici (ya da iBridge) bölümünde "Apple T2 çip" ifadesini arayın. T2 çipli modeller şunlardır: 2018-2020 arasında çıkan Intel MacBook Air ve MacBook Pro'lar, Mac mini (2018), iMac Pro, iMac (Retina 5K, 27 inç, 2020) ve Mac Pro (2019).
Model türüApple'ın önerdiği SMC sıfırlama adımları
T2 çipli dizüstüMac'i kapatın, güç (Touch ID) düğmesini 10 saniye basılı tutup bırakın, birkaç saniye sonra açın. Sorun sürerse: kapatın; sol Control, sol Option ve sağ Shift'i 7 saniye basılı tutun, ardından güç düğmesini de ekleyip dördünü 7 saniye daha tutun; bırakın, birkaç saniye bekleyip açın.
T2 çipsiz dizüstüKapatın; sol Shift, sol Control ve sol Option basılıyken güç düğmesine de basın, dördünü 10 saniye tutun, bırakın ve Mac'i açın.
Masaüstü (T2'li ya da T2'siz)Kapatın, güç kablosunu çıkarın, 15 saniye bekleyin, kabloyu takın, 5 saniye bekleyip açın.
NVRAM (yalnızca Intel): Mac'i kapatın, açın ve hemen Option + Command + P + R tuşlarını birlikte basılı tutun; yaklaşık 20 saniye sonra bırakın (bu sırada Mac yeniden başlıyormuş gibi görünebilir). NVRAM ses düzeyi, ekran çözünürlüğü, başlangıç diski ve saat dilimi gibi bilgileri tutar; enerji ayarları ise pmset tarafındadır. Bu yüzden NVRAM sıfırlamayı diğer adımlar sonuç vermezse deneyin. Aygıt yazılımı (firmware) parolası tanımlıysa bazı başlangıç tuş kombinasyonları çalışmaz.

Apple silicon (M serisi): SMC ya da NVRAM için tuş kombinasyonu yoktur. Apple'ın önerisi şudur: Mac güce bağlıyken Apple menüsünden Yeniden Başlat'ı seçin ya da Kapat'ı seçip güç düğmesiyle yeniden açın; SMC işlevleri kendiliğinden sıfırlanır. NVRAM sıfırlama adımları bu Mac'ler için geçerli değildir ve gerekmez.

6. Güvenli mod ve yeni kullanıcı testi​

Bu iki test, sorunun macOS'un kendisinde mi yoksa sonradan yüklediğiniz yazılımlarda mı olduğunu ayırır.
  • Apple silicon'da güvenli mod: Mac'i kapatın, güç düğmesini "Başlangıç seçenekleri yükleniyor" yazısı görünene kadar basılı tutun, başlangıç diskini seçin, Shift basılıyken "Güvenli Modda Sürdür"ü tıklayın.
  • Intel'de güvenli mod: Mac'i açar açmaz Shift'i basılı tutun, giriş penceresi görününce bırakın.
Giriş penceresinin sağ üst köşesinde kırmızı "Güvenli Açılış" yazısı görünür. Güvenli mod, oturum açma öğelerinin ve macOS'un gerektirmediği uzantıların yüklenmesini engeller, başlangıç diskini temel düzeyde denetler ve bazı önbellekleri temizler. Mac'i 20-30 dakika boşta bırakın. Mac güvenli modda uyuyor ama normal açılışta uyumuyorsa sorun büyük olasılıkla bir oturum açma öğesinden ya da uzantıdan kaynaklanıyordur; Sistem Ayarları > Genel > Oturum Açma Öğeleri (yeni sürümlerde Oturum Açma Öğeleri ve Genişletmeler) listesinden öğeleri tek tek kapatarak bulun. Güvenli moddan çıkmak için normal şekilde yeniden başlatmanız yeterli.

Yeni kullanıcı testi: Sistem Ayarları > Kullanıcılar ve Gruplar > Kullanıcı Ekle… ile geçici bir standart hesap açın, kendi oturumunuzu kapatıp bu hesapla giriş yapın ve aynı testi tekrarlayın. Yeni hesapta sorun yoksa sorunun kaynağı kendi hesabınızdaki uygulamalar, menü çubuğu araçları ya da tercihlerdir. Sorun yeni hesapta da sürüyorsa sistem genelindeki bir ayara, bağlı bir aygıta ya da donanıma bakın.

7. İşe yarar pmset ayarları ve geri alma​

Ayar değiştirirken -b pil, -c adaptör (şarj), -a tüm güç kaynakları için kullanılır; her değişiklik sudo gerektirir.
AyarNe yapar?Örnek
displaysleepEkran uykusu süresi (dakika)sudo pmset -b displaysleep 5
sleepSistem uykusu süresi (dakika, 0 = hiçbir zaman)sudo pmset -c sleep 30
wompAğ erişiminde uyan (0/1)sudo pmset -a womp 0
powernapPower Nap (0/1)sudo pmset -b powernap 0
Dikkat edilmesi gerekenler: pmset kılavuzu hibernatemode için açıkça dikkatli olunmasını ister. Bu ayar varsayılan olarak dizüstülerde 3 (bellek beslenmeye devam eder, içeriği ayrıca diske yazılır), masaüstlerinde 0'dır. 25 değeri yalnızca pmset ile ayarlanır; uykuda daha az enerji harcar ama uyuma ve uyanma yavaşlar. Dizüstünde 0'a çekmek, uykudayken pil biterse kaydedilmemiş işlerin kaybolması riskini doğurur. standby ayarını ve modelinizde varsa autopoweroff, standbydelayhigh ve standbydelaylow ayarlarını da nedenini bilmeden değiştirmeyin; Mac'inizin hangi ayarları desteklediğini pmset -g cap gösterir.

Geri alma: Değiştirdiğiniz ayarı yedek dosyanızdaki eski değerle aynı komutla yeniden yazın ya da sudo pmset restoredefaults çalıştırın.

Kalıcı ayar yerine caffeinate: Uzun bir derleme ya da indirme için uyku ayarlarını değiştirmek yerine işi caffeinate ile başlatın; iş bitince kilit kendiliğinden kalkar.
Bash:
caffeinate -i make
caffeinate -d -t 3600
caffeinate -s -w 4242
İlk satır make bitene kadar boşta uykuyu engeller, ikincisi ekranı bir saat açık tutar, üçüncüsü PID'i 4242 olan süreç bitene kadar sistemi uyanık tutar (yalnızca adaptöre bağlıyken).

Mac'i 7/24 açık tutmak: Mac mini'yi derleme makinesi ya da küçük bir sunucu olarak kullanıyorsanız adaptör profilinde sistem uykusunu kapatıp ekranın uyumasına izin verin: sudo pmset -c sleep 0 displaysleep 10. Elektrik kesintisinden sonra kendiliğinden açılması için Enerji bölümündeki "Güç kesintisinden sonra otomatik olarak başlat" seçeneğini açın; bazı model ve sürümlerde bu ayar, "Güç kablosu bağlıyken başlat" menüsündeki "Güç kesintisinden sonra" seçeneğidir. Makineyi yalnızca küçük bir servis için açık tutuyorsanız, servisi bir sanal sunucuya taşıdığınızda uyku ayarları, elektrik ve bağlantı kesintileriyle uğraşmanız gerekmez. Seçenekler için AIOR'un VPS sunucu sayfasına bakabilirsiniz.

Geliştiriciler için: Kendi macOS uygulamanız uzun bir iş sırasında uykuyu engellemek zorundaysa ProcessInfo'nun beginActivity(options:reason:) yöntemini ya da IOPMAssertionCreateWithName'i kullanın ve iş bitince kilidi endActivity ya da IOPMAssertionRelease ile mutlaka bırakın. Bırakılmayan bir kilit, kullanıcılarınızın makinesinde tam olarak bu yazıdaki sorunu yaratır. Konunun geniş çerçevesi için macOS uygulama geliştirme 2026 başlığına göz atabilirsiniz.

8. Pil sağlığı ve İyileştirilmiş Pil Şarjı​

Uyku sorunları ile pil sorunları sık karıştırılır. Kısa bir kontrol listesi:
  • Pil Sağlığı: Sistem Ayarları > Pil'de Pil Sağlığı yanındaki bilgi (i) düğmesi, durumun normal olup olmadığını ya da "Servis Öneriliyor" uyarısını ve Maksimum Kapasite yüzdesini gösterir.
  • Devir sayısı (cycle count): Option basılıyken Apple menüsü > Sistem Bilgileri'ni açın, Donanım > Güç altındaki Pil Bilgileri bölümüne bakın. Terminal'de system_profiler SPPowerDataType komutu aynı bilgileri verir (sistem diliniz İngilizce değilse alan adları farklı görünebilir). Apple'a göre pil, en yüksek devir sayısına ulaştığında ilk kapasitesinin %80'ine kadarını koruyacak şekilde tasarlanmıştır. Apple'ın tablosunda Apple silicon MacBook'lar için bu sınır 1000 devirdir; kendi modelinizi bu tablodan kontrol edin.
  • İyileştirilmiş Pil Şarjı: macOS Big Sur ve sonrasında Mac günlük şarj alışkanlığınızı öğrenir ve uzun süre prize takılı kalacağını öngördüğünde şarjı %80'in üzerine çıkarmayı erteler. Bu sırada pil menüsünde "Şarj Etme Beklemede" görünür; hemen tam şarj gerekiyorsa "Şimdi Tam Şarj Et"i seçin. Ayar, Pil bölümünde Şarj Etme (bazı sürümlerde Pil Sağlığı) yanındaki bilgi (i) düğmesinin altındadır.
  • Şarj Sınırı: macOS Tahoe 26.4 ve sonrası ile Apple silicon gerektirir; sınır %80 ile %100 arasında seçilir. İki özellikte de Mac, şarj tahminini doğru tutmak için ara sıra %100'e kadar şarj olur.
  • Şarj varken ani uyku: Mac pille çalışırken gösterge %20-50 civarındayken aniden uykuya geçiyorsa pmset -g pslog komutunu bir Terminal penceresinde açık bırakın. Sorun tekrarladığında Mac'i güce bağlayıp uyandırın ve çıktıya bakın; pmset kılavuzuna göre %30'dan doğrudan %0'a inmek gibi ani düşüşler yaşlanmış bir pile işaret eder.

Sık sorulan sorular​

sudo pmset restoredefaults dosyalarımı ya da diğer ayarlarımı siler mi?
Hayır. Yalnızca uyku süreleri, ağdan uyanma ve Power Nap gibi güç yönetimi ayarlarını varsayılana döndürür.

Apple silicon Mac'te SMC nasıl sıfırlanır?
Ayrı bir yöntem yoktur. Mac güce bağlıyken yeniden başlatmak ya da kapatıp açmak yeterlidir; Apple'a göre SMC işlevleri kendiliğinden sıfırlanır.

Kapağı kapattığım hâlde MacBook neden uyumuyor?
Harici ekran ve güç adaptörü bağlıysa ve harici bir klavye, fare ya da izleme dörtgeni kullanıyorsanız kapalı ekran modunda çalışmaya devam eder. Bunlar bağlı değilse pmset -g assertions çıktısına ve uyanma log'una bakın.

Mac her gece aynı saatte uyanıyor, neden?
Büyük olasılıkla zamanlanmış bir olaydır. pmset -g sched çıktısını ve log'daki rtc/RTC nedenlerini kontrol edin; kayıt üçüncü taraf bir uygulamaya aitse zamanlamayı o uygulamadan değiştirin.

Uykudayken pilin biraz azalması normal mi?
Evet, bir miktar azalma normaldir; DarkWake, Power Nap ve ağ bağlantısının korunması enerji harcar. Gece boyunca belirgin bir düşüş görüyorsanız log'daki uyanma sayısına bakın ve pil profilinde Power Nap'i kapatmayı deneyin (sudo pmset -b powernap 0).

hibernatemode'u 25 yapmalı mıyım?
Çoğu kullanıcı için hayır. Uykuda tasarruf sağlar ama uyuma ve uyanma yavaşlar; varsayılan değerler çoğu kullanım için dengelidir.

Sonuç ve sonraki adımlar​

Doğru sıra şudur: pmset -g ile ayarları ve engelleyenleri görün, assertions ile süreci bulun, log ile uyanma nedenini doğrulayın, tablodaki nedenleri tek tek eleyin, gerekiyorsa yedek alıp restoredefaults çalıştırın. Intel Mac'te ardından SMC ve NVRAM, en son da güvenli mod ve yeni kullanıcı testi gelir. Bunlar da sonuç vermezse macOS'u güncelleyin ve donanım arızası olasılığına karşı Apple Destek'e başvurun. Mac'inizi geliştirme işleri için ayarlamaya devam etmek isterseniz macOS'ta otomatik düzeltmeyi kapatma rehberimize de göz atın.

If your Mac stays awake all night, gets warm in a bag with the lid closed, wakes itself up before dawn or loses a noticeable share of its battery while asleep, resetting the energy settings is the obvious first idea. Sometimes that works. More often the settings are not the problem: an app is holding the Mac awake, a device or network service keeps waking it, and a reset only buys a few days before the symptom comes back. This guide works the other way around: find the cause first, then reset if you still need to. The sample output below comes from an Apple silicon MacBook running macOS 27, and menu names follow macOS Ventura (13) and later.

1. Where the energy settings live on current macOS​

Ventura replaced System Preferences with System Settings, and the power options are now spread over several panes:
What you are looking forLaptop (MacBook Air, MacBook Pro)Desktop (Mac mini, iMac, Mac Studio, Mac Pro)
Main paneSystem Settings > BatteryEnergy Saver in Ventura and Sonoma, Energy in Sequoia (15) and later
Sleep and wake optionsBattery > Options: "Wake for network access", "Prevent automatic sleeping on power adapter when the display is off"Same pane: "Prevent automatic sleeping when the display is off", "Wake for network access", "Enable Power Nap"
When the display turns offSystem Settings > Lock ScreenSystem Settings > Lock Screen
Big Sur (11) and Monterey (12)System Preferences > BatterySystem Preferences > Energy Saver
On Catalina (10.15) and earlier, every Mac, laptops included, uses System Preferences > Energy Saver. Some options appear only on certain models or versions. The Power Nap switch, for example, sits under Battery > Options on some laptop releases and is missing from the interface on others. Whatever the UI shows, the pmset command in Terminal lists every power management setting and writes to the same settings that System Settings uses.

2. Diagnose first: let pmset tell you what is going on​

Open Terminal from Applications > Utilities or with Spotlight (Command + Space, then type "Terminal"). Apart from sudo pmset repeat cancel in Step 5, everything in this section only reads: nothing is changed and no administrator password is needed.

Step 1: Current settings and who is blocking sleep​

Bash:
pmset -g
The sleep line is the system sleep timer and displaysleep is the display timer, both in minutes (0 means never). When a process is blocking sleep, pmset names it in parentheses at the end of the line:
Kod:
sleep                1 (sleep prevented by powerd, caffeinate)
displaysleep         10 (display sleep prevented by caffeinate)
A sleep value of 1 is normal on laptops: powerd already keeps the system awake while the display is on, and the system sleeps shortly after the display goes dark. The process names in parentheses are what matter.

Step 2: Battery and AC profiles, plus a backup​

Bash:
pmset -g custom
pmset -g custom > ~/Desktop/pmset-backup.txt
Laptops keep separate values for Battery Power and AC Power, so if a problem only shows up on the charger, compare the AC Power values first. The file on your desktop records the values before you touch anything, which makes every later change reversible.

Step 3: Power assertions​

Apps and system services block sleep temporarily by creating power assertions:
Bash:
pmset -g assertions
pmset -g assertions | grep -E "pid [0-9]+"
The second form lists only the owning processes. A typical line:
Kod:
pid 2828(caffeinate): [0x...] 17:10:55 PreventUserIdleSystemSleep named: "caffeinate command-line tool"
  • PreventUserIdleDisplaySleep: keeps the display from idling off. Video players, presentation tools and video-call apps take it.
  • PreventUserIdleSystemSleep: keeps the system from idle sleep even after the display goes dark. Downloads, audio playback and backups take it.
  • PreventSystemSleep: blocks system sleep; caffeinate -s, for example, takes this one, and it only holds while the Mac runs on AC power.
"Powerd - Prevent sleep while display is on" is expected. What deserves attention is an assertion held for hours: the duration column in the example shows a forgotten caffeinate that has been running for 17 hours. Activity Monitor shows the same information in the Preventing Sleep column of its Energy tab; if the column is hidden, turn it on under View > Columns.

Step 4: What is waking the Mac?​

Bash:
pmset -g log | grep -E "Entering Sleep|Wake from|DarkWake from" | tail -n 30
pmset -g log | grep -E "Wake from|DarkWake from" | grep -oE "due to [^/]*" | sed -E 's/ Using .*//' | sort | uniq -c | sort -rn | head
The first command prints the latest sleep and wake events; the second counts wake reasons and lists the most frequent first. "Wake" is a full wake with the display on. "DarkWake" is a short maintenance wake with the display off, which is how Power Nap, network keepalive and scheduled jobs run. The reason strings differ between models and macOS versions, but they are good hints: rtc or RTC points to a scheduled timer, lid or LidOpen to the lid, USB or XHC to a USB device, wifibt, ARPT or bluetooth to the wireless hardware, and UserActivity to keyboard, mouse or trackpad input.

Step 5: Scheduled wakes​

Bash:
pmset -g sched
Entries owned by com.apple services are the system's own maintenance wakes and are nothing to worry about. If a backup or sync app shows up, change its schedule inside that app. Repeating power events created with pmset repeat are removed with sudo pmset repeat cancel.

3. Common culprits​

CulpritHow you spot itWhat to do
Power NapRegular DarkWake entries in the log; powernap 1 in pmset -gTurn it off in Energy (desktop) or Battery > Options (laptop, where offered); for battery only, sudo pmset -b powernap 0
Wake for network access (womp)Sharing requests and iCloud traffic wake the Mac; womp 1 in pmset -gIf you do not need it, choose Never on a laptop, switch it off on a desktop, or run sudo pmset -a womp 0. Find My Mac settings may then warn that you cannot locate, lock or erase this Mac while it is asleep.
Bluetooth and USB devicesUSB, XHC or bluetooth in the wake reason; a mouse nudged on the desk can be enoughDisconnect devices one at a time and retest; a faulty hub, dock or external drive can stop sleep altogether
Apps holding assertionsA browser, media player, meeting app, forgotten caffeinate or keep-awake utility such as Amphetamine in the assertions listClose the tab or quit the app; for a caffeinate you started yourself, pkill -x caffeinate
Find My and iCloud'Maintenance Sleep':TCPKeepAlive=active entries; on supported systems, wakes when a device on the same Apple Account comes near (proximitywake)Mostly expected. Leave tcpkeepalive on: pmset itself warns that turning it off stops critical features such as Find My Mac from working properly
Sharing services and SSHFile, Screen or Printer Sharing enabled; an active SSH session (ttyskeepawake 1)Switch off unused services in System Settings > General > Sharing and close remote sessions
Spotlight, Time Machine, updatesIndexing, backup or update processes in the assertions listTemporary: the Mac sleeps once they finish, though a first Spotlight index can take hours
Closed-display (clamshell) modeLid closed; external display and power adapter connected; external keyboard, mouse or trackpad in useNot a fault: a MacBook is designed to keep running in this setup

4. Restoring the defaults​

From the interface: On Monterey and earlier, the Battery and Energy Saver preferences have a Restore Defaults button. Apple's guides for Ventura and later no longer list it. Instead, when you pick a setting that raises energy use, the Battery or Energy pane may show the warning "Your Mac may use more energy with these settings" next to a Restore Defaults button; on macOS 27, Lock Screen can show the same warning with a Reset button. If you see neither, walk through the settings by hand:
  1. Lock Screen: if a display-off timer for battery or power adapter is set to Never, give it a sensible value.
  2. Battery > Options (laptop) or Energy (desktop): turn off "Prevent automatic sleeping…" and set "Wake for network access" to what you actually need.
  3. Leave Low Power Mode and, where your model has it, Energy Mode at the values you chose on purpose.
From Terminal: one command returns every power management setting to its default:
Bash:
pmset -g custom > ~/Desktop/pmset-before.txt
sudo pmset restoredefaults
pmset -g custom
You will be asked for your administrator password; nothing appears while you type it, so just type it and press Return. The change applies immediately. A restart is not required, but it is a good next step because it also clears assertions left behind by misbehaving apps. The command only touches power management settings, not your files or other preferences. Defaults differ between models, so check the result with the last command. Old guides that tell you to delete the PowerManagement plist files by hand are out of date: those files have moved between macOS versions, and pmset is the supported tool.

5. Intel Macs only: SMC and NVRAM​

First check which Mac you have. In Apple menu > About This Mac, a "Chip" line means Apple silicon, while a "Processor" line naming Intel means an Intel-based Mac. On Intel Macs the SMC (System Management Controller) handles power button behavior, battery and charging, fans, lid open and close behavior and the sleep indicator. To see whether the Mac has a T2 chip, hold Option, choose Apple menu > System Information, select Controller (or iBridge) in the sidebar and look for "Apple T2 chip". T2 models are the Intel MacBook Air and MacBook Pro models from 2018 to 2020, Mac mini (2018), iMac Pro, iMac (Retina 5K, 27-inch, 2020) and Mac Pro (2019).
Mac typeApple's SMC reset steps
Laptop with T2Shut down, hold the power (Touch ID) button for 10 seconds, release, wait a few seconds and turn the Mac on. If the issue remains: shut down; hold left Control, left Option and right Shift for 7 seconds; then hold the power button as well and keep all four held for another 7 seconds; release, wait a few seconds and turn the Mac on.
Laptop without T2Shut down; while holding left Shift, left Control and left Option, press and hold the power button too, keep all four held for 10 seconds, release and turn the Mac on.
Desktop (with or without T2)Shut down, unplug the power cord, wait 15 seconds, plug it back in, wait 5 seconds and turn the Mac on.
NVRAM (Intel only): Shut down, turn the Mac on and immediately hold Option + Command + P + R together; release after about 20 seconds (the Mac may appear to restart in the meantime). NVRAM stores settings such as sound volume, display resolution, startup disk and time zone, while energy settings belong to pmset, so treat an NVRAM reset as a later step. If a firmware password is set, some startup key combinations do not work.

Apple silicon (M-series): There is no SMC or NVRAM key combination. Apple's advice: with the Mac connected to power, choose Restart from the Apple menu, or choose Shut Down and press the power button to turn it on again. The SMC functions reset automatically, and the NVRAM reset steps neither apply to these Macs nor are needed.

6. Safe mode and the new-user test​

These two tests tell you whether the problem sits in macOS itself or in software you added.
  • Safe mode on Apple silicon: Shut down, press and hold the power button until "Loading startup options" appears, select the startup disk, then hold Shift and click "Continue in Safe Mode".
  • Safe mode on Intel: Turn the Mac on and immediately hold Shift; release it when the login window appears.
"Safe Boot" appears in red in the top-right corner of the login window. Safe mode stops login items and extensions that macOS does not require from loading, runs a basic check of the startup disk and clears some caches. Leave the Mac idle for 20 to 30 minutes. If it sleeps in safe mode but not after a normal start, suspect a login item or extension and switch them off one by one in System Settings > General > Login Items (Login Items & Extensions in newer releases). A normal restart takes you out of safe mode.

New-user test: Create a temporary standard account with System Settings > Users & Groups > Add User…, log out of your own account, log in to the new one and repeat the test. If the new account sleeps normally, the cause is in your account: apps, menu bar utilities or preferences. If it does not, look at system-wide settings, connected devices or the hardware.

7. Useful pmset settings, and how to undo them​

In pmset, -b means battery, -c means charger (AC) and -a means all power sources; changing a setting requires sudo.
SettingWhat it doesExample
displaysleepDisplay sleep timer (minutes)sudo pmset -b displaysleep 5
sleepSystem sleep timer (minutes, 0 = never)sudo pmset -c sleep 30
wompWake for network access (0/1)sudo pmset -a womp 0
powernapPower Nap (0/1)sudo pmset -b powernap 0
Handle with care: the pmset manual explicitly asks for caution with hibernatemode. It defaults to 3 on laptops (memory stays powered and a copy is also written to disk) and 0 on desktops. Mode 25 can only be set through pmset; it uses less power during sleep but makes sleeping and waking slower. Setting 0 on a laptop means that a battery running flat during sleep takes your unsaved work with it. Leave standby alone too, along with autopoweroff, standbydelayhigh and standbydelaylow on models that have them, unless you know why you are changing them; pmset -g cap lists the settings your Mac supports.

Undoing changes: Write the old value from your backup file back with the same command, or run sudo pmset restoredefaults.

Use caffeinate instead of permanent changes: For a long build or download, start the job under caffeinate rather than changing your sleep settings. The assertion disappears when the job ends.
Bash:
caffeinate -i make
caffeinate -d -t 3600
caffeinate -s -w 4242
The first line prevents idle sleep until make finishes, the second keeps the display on for an hour, and the third keeps the system awake until process 4242 exits (on AC power only).

Keeping a Mac on around the clock: If a Mac mini serves as a build machine or small server, turn off system sleep on AC and let the display sleep: sudo pmset -c sleep 0 displaysleep 10. Turn on "Start up automatically after a power failure" in the Energy pane so it comes back after an outage; on some models and versions this is a "Start up when power is connected" menu, where you choose "After power failure". If the Mac stays on only to run a small service, moving that service to a virtual server takes sleep settings, power cuts and connection drops out of the picture; AIOR's VPS hosting page lists the options.

For developers: If your own macOS app has to block sleep during a long task, use ProcessInfo's beginActivity(options:reason:) or IOPMAssertionCreateWithName, and always release the assertion with endActivity or IOPMAssertionRelease when the work ends. A leaked assertion causes exactly the problem described here on your users' machines. For the wider picture, see our macOS app development 2026 thread.

8. Battery health and Optimized Battery Charging​

Sleep problems and battery problems are easily confused. A quick checklist:
  • Battery Health: In System Settings > Battery, the Info (i) button next to Battery Health shows whether the condition is normal or "Service Recommended", along with the Maximum Capacity percentage.
  • Cycle count: Hold Option and choose Apple menu > System Information > Hardware > Power, then look under Battery Information. In Terminal, system_profiler SPPowerDataType prints the same data. Apple says a battery is designed to retain up to 80% of its original charge capacity at its maximum cycle count, and its table gives 1000 cycles for Apple silicon MacBooks; check the entry for your model.
  • Optimized Battery Charging: On macOS Big Sur and later the Mac learns your routine and delays charging past 80% when it expects you to stay plugged in for a long time. The battery menu then shows "Charging on Hold"; choose "Charge to Full Now" if you need 100% sooner. The switch sits behind the (i) button next to Charging (Battery Health on some versions) in Battery settings.
  • Charge Limit: Requires macOS Tahoe 26.4 or later and Apple silicon; you choose a limit between 80% and 100%. With either feature, the Mac still charges to 100% now and then to keep its state-of-charge estimate accurate.
  • Sudden sleep with charge left: If the Mac suddenly sleeps on battery while still showing 20-50%, leave pmset -g pslog running in a Terminal window. When it happens again, connect power, wake the Mac and read the output: according to the pmset manual, a sudden jump such as 30% straight to 0% points to an aging battery.

FAQ​

Does sudo pmset restoredefaults delete files or other settings?
No. It only resets power management settings such as sleep timers, wake for network access and Power Nap.

How do I reset the SMC on an Apple silicon Mac?
There is no separate procedure. Restart, or shut down and start up again, while the Mac is connected to power; Apple says the SMC resets automatically.

Why does my MacBook stay awake with the lid closed?
With an external display and power adapter connected and an external keyboard, mouse or trackpad in use, it runs in closed-display mode by design. Without them, check pmset -g assertions and the wake log.

My Mac wakes at the same time every night. Why?
Most likely a scheduled event. Check pmset -g sched and look for rtc or RTC reasons in the log; if a third-party app owns the event, change the schedule in that app.

Is some battery drain during sleep normal?
Yes. DarkWakes, Power Nap and network keepalive all use some energy. If you lose a large share overnight, count the wakes in the log and try turning Power Nap off on battery (sudo pmset -b powernap 0).

Should I set hibernatemode to 25?
For most people, no. It saves energy during sleep but slows sleep and wake, and the defaults are a sensible balance for everyday use.

Conclusion and next steps​

Work in this order: read the settings and blockers with pmset -g, find the process with assertions, confirm the wake reason in the log, rule out the culprits in the table, then take a backup and run restoredefaults if you still need it. On an Intel Mac, SMC and NVRAM come next, followed by safe mode and the new-user test. If none of that helps, update macOS and contact Apple Support, because the fault may be in the hardware. If you are tuning your Mac for development work, our guide to disabling auto-correct on macOS is a good next stop.
 
Son düzenleyen:

Forum istatistikleri

Konular
925
Mesajlar
932
Üyeler
26
En son üye
Jessicawatson

Çevrimiçi üyeler

Şu anda çevrimiçi üye yok.

Öne çıkan içerik

AIOR
AIOR TEKNOLOJİ

Tüm ihtiyaçlarınız için Teklif alın

Hosting · Domain · Sunucu · Tasarım · Yazılım · Mühendislik · Sektörel Çözümler

Teklif al

7/24 Destek · Anında yanıt

Geri
Üst