Start up hangs when a disconnected mapped network drive is present on Windows #85689
Labels
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
12 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: blender/blender#85689
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
System Information
Operating system: Windows 10
Graphics card: Nvidia GTX 1080Ti
Blender Version
Broken: 2.91.2 and previous
Blender start up hangs (~60 seconds) after initial window creation when a disconnected mapped network drive is present. Also File browser hangs regularly and clicking on the disconnected volume also causes further hanging (all around 30-60 seconds each). Can any of this behavior be made non blocking please? It can get very frustrating when a networked machine is turned off. I appreciate windows itself hangs before issuing a 'Restoring Network Connections' prompt but I fail to see why blenders startup seems to be affected. I've gone through and disabled all addons and made sure nothing that blender needs is coming from the disconnected network drive - just a guess but maybe the act of populating the 'Volumes' area of the file browser is all blender needs to cause a hang? Just my guess.
Exact steps for others to reproduce the error
Create a network mapped volume on Windows (i.e. I mapped \cedefs\NAS\ to Z:). Turn the network machine off so it disconnects in windows (red X). Run blender.
Added subscriber: @cedeon
#96151 was marked as duplicate of this issue
blender/blender-addons#82424 was marked as duplicate of this issue
#90239 was marked as duplicate of this issue
#86453 was marked as duplicate of this issue
Added subscriber: @erminos
This seems related to #63748.
Same problem was on Windows 7. Eventually I removed those net-drives on Feb 1 and haven't tested after.
Added subscribers: @Khachatur, @lichtwerk
Changed status from 'Needs Triage' to: 'Needs Developer To Reproduce'
Added subscriber: @mont29
@mont29: since you have done 6dceafbde3: does this ring a bell?
Bookmarked paths should not be an issue anymore, but indeed
fsmenu_read_system
could produce similar effects I guess.This would be better handled by someone with access to that platform, that can reproduce the issue and test the fix.
From within the file browser there is just nothing we can do, this is Windows issue really.
Added subscribers: @G7, @iss, @derekbarker
Added subscriber: @DanielGrauer
Added subscribers: @BenoitAlexis, @OmarEmaraDev, @mano-wii, @dr.sybren
Added subscriber: @ROBYER1
Added subscriber: @Harley
@Harley Do you think this is something that can be fixed?
Removed subscriber: @Khachatur
Yes, but the difficulty is only in recreating the issue locally, as I don't currently have a network running at home.
When the Volumes list is created we call
fsmenu_entry_refresh_valid
on each item which does a stat of the location, which would pause on disconnected drive. A quick and dirty way to deal with this is basically "the OS said these are the available drives, so trust it".NetworkDrives.diff
You would not get a slow down on startup if a drive is broken. The mapped disconnected item would be in the Volumes list. But if you tried clicking on it you'd then get the pause, which seems fair as it has to happen some time.
That sounds ideal to me if that startup slowdown can be skipped on launch. Then the pause would only happen if the user explicitly chose to open an unconnected mapped network drive as you say. As the drive is disconnected anyway, they wouldn't be using it in Blender surely as they aren't connected to the network for the drive?
This would require someone who can recreate this issue to compile and test the above patch to confirm that it works as advertised. I doubt we could get this kind of change in without it though.
I can give that a shot unless anyone else on here who already knows how to compile Blender can. If there's a guide I need to follow, I will
@ROBYER1 - Wait, stop!
We have just confirmed that my patch above does not help in this situation. But the person who confirmed that my idea sucks, also wrote a solution that works. So I'll post a patch for this very quickly
This issue was referenced by
ae3c8bc9f0
Changed status from 'Needs Developer To Reproduce' to: 'Resolved'
Thanks, will this land in a daily build that I can start using on my work laptop? Thanks so much for the fast response also, this was my first Blender bug report (and probably my last judging from my past 7 or so years of using it with no issues)
Yes it should be in the daily builds tonight or tomorrow - shown as "3.2.0 Alpha" with a build date of March 12 or later.
@Harley I tested this today with a network drive disconnected (not used to open any files from the network drive of course) using March 14, 02:24:38 -
b959f603da
- the issue with slow startup times is still there. Connecting to the network drive immediately fixes the slow startup times, and disconnecting from it brings back the long hangs on launch.Is the patch not in that release? I hope it is that, I can't reopen this issue
That depends on which one you tried. If you start here…
https://builder.blender.org/download/daily/
Then go to the “Windows” tab. My change is only in one of the six builds shown: the “3.2.0 Alpha”.
@Harley That is the exact version I am testing with where I can recreate this issue still - blender-3.2.0-alpha+master.b959f603da45-windows.amd64-release
Is there anything I can do to help with testing of this? The behaviour is identical to before, with network drives disconnected, a launch of that alpha Blender version can cause a long hang, then for the next 4-5 times I reopen Blender it is fast then after those few attempts at opening and closing it, Blender slows to a crawl on launch again. I have recorded this here in the video below to show what I am seeing. I reopen and close Blender a lot to show the behaviour while on a VPN is consistent and when the VPN is disconnected Blender likes to hang for ages on launch then subsequent launches work until it does it again periodically after.
2022-03-14 14-22-18.mp4
@ROBYER1 - This is difficult to diagnose without me being able recreate this myself.
We tested this by mapping some network drives over VPN then dropping that connection. This recent change solved any pauses we were getting when launching Blender.
Something you could still try is to compile blender yourself, after applying the patch I added earlier in this thread. That turns off the validation of items as they are added to the "Volumes" list.
I will give this a shot with compiling myself hopefully first thing tomorrow I will take a look. I haven't compiled Blender myself before but I assume it is using this
https://wiki.blender.org/wiki/Building_Blender
I also have some other laptops I can see if there is a reproducible scenario I can set up that is using a non-workplace VPN if I can create a foolproof way to reproduce this to help you guys
@Harley I can confirm building with your diff file from this post fixes the slow hang on launch of Blender issue on my problematic work laptop while VPN/Network drives are disconnected. Building without the diff file from the latest master branch as of today produces the error again.
I took another laptop (a personal one) and tried to reproduce the issue by mapping a network drive of a local PC (without VPN) and disconnecting from that didn't produce the hang. Although you guys tested this with a VPN network drive, I can only assume through trial and error now that perhaps certain types of network drives accessed only through VPN can produce the long hang on launch of blender when not using your diff file
Is there a possibility of merging that diff patch file into the master branch at some point? I would be keen to test it in a proper commit with the previous mentioned fixes added, there must be some middle ground between the fixes or can they both work together?
Awesome, so it is the stat call in the validation code.
Maybe; I'll see what I can do.
It's a more difficult change to propose because we have had validation on the File Browser locations for a long time. At one time we ran a background thread that periodically refreshed those lists and constantly rechecked the items. We no longer do that but I would anticipate pushback to the idea of just removing the validation on load altogether.
It might seem less risky to only do so for the Volumes items, but then we'd have the same problem if one of those items was added to your "Recent" list or if any of your bookmarks contained items on that drive.
I'll try to talk to some other other developers with interest in the File Browser and see how wedded we are to the link validation. Then I can see if I can come up with a proposal that makes us all happy.
Changed status from 'Resolved' to: 'Confirmed'
Thanks, I did see in fsmenu.c that the bookmarks get validated in an async job due to the network drive delay issue already, I wonder if it's just the thread blocking validation on startup of blender that can be skipped at least. Then the onus is on anyone who chose to bookmark a network drive to deal with the possible delay of many minutes when they go to the File Browser in Blender, which I assume is one time only and also could be avoided if the async job might finish before they even use the File Browser.
Otherwise I guess a nice fallback is to have some kind of Blender settings option to allow or disallow the validation of drives to give users the option themselves of skipping drive validation overall?
Looking forward to hearing what you and the team come up with also 👍
AFAIK that job is no longer being started. It was used to check all the links all the time, so in theory you could watch a volumes link become disabled and enabled automatically. But in practice it was causing us issues so now we only discover and validate them on startup and you can refresh/revalidate by clicking the "refresh" button.
I have been using that diff patched version of Blender for a good few days now and noticing no issues with it, if I open the File > Open menu all is working well navigating local drives and of course if I click on the disconnected network drives there I will suffer that windows hang but that is my own fault if I was to make a bookmark on a networked drive that is now disconnected tbh since that is Windows behaviour.
Added subscriber: @Maker7
Hello@all,
i´ve the exactly same problem like @ROBYER1
Can anybody please share with me a compiled test version using the diff from @Harley, or can explain me how i can use the diff in the blender script panel? I´m not a coder and can´t do it for myself in an efficient timeframe. So it would like to give this complied version a try if it really runs faster.
Right now loading files or just clicking on the menu makes blender close to unasable on my company workstation notebook. network drives connected etc.
( graphics card is a nvidia quadro "#2000", driver 511.79)
Blender takes minutes to start with standard version.
thanks to blender.chat community my current workaround was to use the copy+paste the opgengl.dll method. It makes blender faster start, but slows down the whole fps of the tool.
System Information
Operating system: Windows 10
Graphics card: Nvidia quadro "#2000"
Blender Version 3.1 and previous, also tried out Blender 3.2.0 - Alpha
March 29,
27424b758a
- slow start up, no response for minutes clicking on menuBlender works fine and without lag with Blender 2.79 !
I have written these very simple instructions for you to use the git diff file yourself as it is good to know how some of this works!
Here is also my build zipped up you can try, I am hoping this fix can be incorporated soon as we are moving my team from other software to using Blender but it is affecting a lot of the team's remote working laptops due to them not always being connected to network drives that they don't use regularly in work either.
Blender3_2_NetworkDrivesFix.zip
This issue was referenced by
84fde382e4
Changed status from 'Confirmed' to: 'Resolved'
@ROBYER1 Thanks for your help on this!
I tried your provides files and also tried the to compile it by myself.
Blender3_2 Networkdrivefix does not work on this machine here. Blender shows the same behavoiur as mentioned before: slow startup, takes minutes to launch on splash screen. Then click on menu dialogs cause lagging again.
Compile blender by myself: fail :) I have to ask some of our IT guys to support here.
Anyway, thank you all for your help and your effort making blender better and better!
@Maker7 If you go to Blender builds here you can download the current 3.2.0 alpha which has the fix in too, did my build work?
https://builder.blender.org/download/daily/
Thanks for the fix merge Harley, its saving me time waiting for Blender to open today already!
@ROBYER1 yes, i´ve tried as well the daily version and created a real-time video. you can see it below.
Time till splash screen: 02:46 min
Time to open preference dialog: 01:13 min
(not in video other stuff like, all takes nearly 1min.. e.g. Time for changing render mode eevee to cycles: 01:12 min)
So in short, issue still exist. seems to be something different as network drives, because fix doesn´t have any effect.
Maybe company OS image related, or its really the graphics card (opengl)..
Next step will be to make a test on a virtual machine. Maybe this is solving the issue to enable usability of blender.
20220331_slowblender_short.mp4
No worries!
Note that drives are only enumerated during startup and when you click the "refresh" button in File Browser. So the delay shown in your video opening Preferences is unrelated to this report.
First thing I would check is if this is a delay opening all windows. So select "New Window" from the "Window" menu and see if they delay is the same as with Preferences.
Next though you'd have to create a separate bug report, otherwise your issue will get lost being attached to this one. Within Blender just select "Help / Report a bug" and then describe it like "Long delay opening any window", etc. You should also be able to drag the video you made into it as well, which is quite helpful.
Thanks @Harley i will create a bug report.