1

I have a networked drive being served over SMB which is regularly accessed from my Macbook Air. The problem is that it spins up even after my Macbook Air has had its lid closed and has been sleeping for 10 hours, with no other networked devices accessing it. My goal is to not have the networked drive spin up unnecessarily.

Running sudo lsof | grep " /media" on the server tells me that the only process using the drive is smbd, i.e. the Samba SMB daemon. As soon as I properly power the Macbook off, there are no longer any open file handles for the drive.

Powernap is disabled both with and without power plugged in, so that didn't solve it.

Is there a straightforward way of making macOS leave networked shares alone when it's sleeping?

  • Based on what do you assume that the (sleeping) MBA somehow triggers the activities on the server? – nohillside Jul 5 at 11:40
  • @nohillside Based on what I explained in the question. The SMB connection originates from the MBA. It triggers the activity when it opens an SMB connection and fails to close it for 10 hours of non-activity. – Andreas Jul 5 at 11:45
  • So you basically are looking for a way to automatically eject network drives before your Mac goes to sleep? – nohillside Jul 5 at 12:05
  • 2
    @nohillside That sounds like a reasonable solution. Or, if it's a known behavior of macOS to keep doing network activities while sleeping, disable that behavior. I wouldn't put it past macOS to do that sort of thing, so I'm open to suggestions. – Andreas Jul 5 at 12:07
  • I should add that I'm not entirely familiar with the inner workings of SMB and if it really does allow for connections to be open indefinitely in this manner. – Andreas Jul 5 at 12:10

You must log in to answer this question.

Browse other questions tagged .