Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mount only after the display turns on #60

Open
polochamps opened this issue May 26, 2023 · 10 comments
Open

Mount only after the display turns on #60

polochamps opened this issue May 26, 2023 · 10 comments
Labels
enhancement New feature or request

Comments

@polochamps
Copy link

polochamps commented May 26, 2023

Hello Niels,

I'm still experiencing issues with the "disk not ejected properly" notifications. I would like to provide specific details about the components I'm using and can provide more information if necessary. Here are the details:

  • I have a Mac mini M2. (Ventura 13.4)
  • I'm using an HP Z27n monitor, which has a built-in USB 3.0 hub powered by the Mac mini. It is connected to the Mac mini using a USB 3.0 Type B cable to USB Type A.
  • I have an ORICO 20Gbps USB C to M.2 NVMe SSD Enclosure Adapter. The cable provided with the enclosure has a USB C to USB A adapter, which is connected to the USB hub on the monitor.
  • The SSD I'm using with the ORICO enclosure is an Intel 670p 1TB.

I have already tried using the "Unmount when display turned off" and "Unmount when system starts sleeping" options, but I'm still receiving the notifications. I came across a post on MacRumors suggesting that the Mac mini might be waking up periodically due to the "Wake for Network Access" setting in Energy Saver preferences. This causes the monitor's USB hub to receive power, resulting in the reconnection of the external drive (Intel 670p). Shortly afterward, the Mac goes back to sleep, and the cycle repeats, triggering the numerous notifications.

Based on my limited knowledge, do you think it would be possible to have an option that only mounts the drive when the screen is awake? The idea behind this is that when the system wakes up due to network access, Ejectify could automatically mount the drive but not automatically unmount it when the system goes back to sleep.

Thank you for your assistance and any insights you can provide.

*added text (Ventura 13.4)

@polochamps
Copy link
Author

My guess is that when the Mac wakes up for network access, it may grant exclusive access only to the programs that requested it. As a result, Ejectify is unable to unmount the drive during this wake-sleep cycle.

@polochamps
Copy link
Author

polochamps commented May 26, 2023

If my understanding is correct, I would like to suggest adding an option to mount the volumes exclusively when the display is on. It appears that the current option is configured to automatically mount volumes when the system or screens wake up, but it does not specifically cater to mounting them only when the display is on.

@nielsmouthaan
Copy link
Owner

Right now, Ejectify unmounts only when the display turns on (again) when you select the Display turned off option is selected.

I suggest taking a look at this FAQ to diagnose what causes the volume not to be unmounted. It could also be that your volume is encrypted; some have reported issues related with this.

@polochamps
Copy link
Author

To clarify, my suggestion is to add an option in Ejectify that allows mounting the drive only when the display is turned on. This would prevent the drive from being mounted during the wake-sleep cycle caused by the "Wake for Network Access" feature.

The issue seems to be that Ejectify currently unmounts the drive only when the display turns on again. As a result, the drive remains mounted, during the wake-sleep cycle caused by the "Wake for Network Access" feature. This means that when the system goes back to sleep (from the wake-sleep cycle), the drive is still mounted.

Volume is unencrypted.

@polochamps
Copy link
Author

What I'm suggesting is to keep the volume unmounted during sleep and have it automatically mount only when the monitor is awake or turned on.

@nielsmouthaan
Copy link
Owner

This is what Ejectify suppose to do. It unmounts when your display turns off, and only unmounts it when your display turns on again. This is assuming you have set Unmoun when to Display turned off.

@polochamps
Copy link
Author

polochamps commented May 26, 2023

I apologize, if I don't make myself clear. Yes, Ejectify unmounts when display is turned off but what I'm saying that it should remain unmounted during system sleep. Or if in case the system wakes because of "network access", the volume should remain unmounted.

It will only mount volumes again when two conditions are met. Both system and display are awake.

@nielsmouthaan
Copy link
Owner

nielsmouthaan commented May 26, 2023

Ejectify won't remount the drive as long as your display is turned off, but perhaps macOS does. You can check the Console app to check whether that's really the case. If so, this might be a valid feature request, although Ejectify needs to deal with a lower-level component to avoid macOS mounting the volume (if possible).

@nielsmouthaan nielsmouthaan added the enhancement New feature or request label May 26, 2023
@polochamps
Copy link
Author

Buy Ejectify is advertised as "Automatically mounts volumes again when your Mac or screens wake up, optionally after a delay." I'm confused.

@nielsmouthaan
Copy link
Owner

I updated the comment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants