Mounting network drives with a delay in Windows using the "net use" command

MarGib June 13, 2026
🌐 🇵🇱 Polski · 🇬🇧 EN
If you use Windows and frequently access data stored on other computers in your network or other network-shared resources, the standard practice is to map them as network drives so they are available every time you start your computer. By right-clicking in "This PC" (or "My Computer"), you have the option to add a network location. While this is straightforward, it sometimes happens that upon system startup, Windows attempts to connect these drives before the network stack is fully initialized. This can occur for various reasons, such as domain login delays or extended authentication times, resulting in the resources failing to connect and requiring a manual reconnect. A potential solution is to adjust the service startup order (which is not always straightforward in Windows) or simply introduce a delay, for example, of one minute. I decided to delay the mounting process, which works perfectly when the mounting attempt happens faster than the network initialization. 

Step 1 - Launching the cmd console 

Press the Win+r keys and type "cmd" (in some cases, you may need to run the cmd console with administrator privileges). 

Step 2 - Creating the file for mounting remote resources in the appropriate location. 

notepad "%UserProfile%\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup\netlogon.bat

This will open Notepad (in the correct directory) where we will create a file named netlogon.bat. 

Step 3 - Entering the code 

@echo off
timeout /t 60
net use Z: \\some_resource\some_directory


The code above ensures that the network resource is mounted as drive "Z". (Remember that there should be a space after the drive letter and colon).

We can also configure automatic login to the resource if credentials are required. 

@echo off
timeout /t 60
net use Z: "\\some_resource\some_directory" /user:domain\username some_password

You can mount multiple resources at once: 

@echo off
    timeout /t 60
    
    net use Z: \\host123\directory_1 /user:mydomain\user1 password 
    net use X: \\192.156.45.111\disk$ 

To test if everything is working correctly, you can run the "net use..." commands directly in the cmd console or execute the netlogon.bat file. In this example, the delay is set to 60 seconds. 

Facebook X E-mail

Comments

Dodaj komentarz

Explore

Labels

Artificial Intelligence 6 AI 5 coaching 4 technology 4 Business 3 God 3 Windows 3 artificial intelligence 3 internet 3 trivia 3 FIFA 2 LLM 2 Linux 2 Machine Learning 2 Technology 2 automation 2 faith 2 mobile apps 2 money 2 network 2 new technologies 2 news 2 personal competencies 2 personal thoughts 2 religion 2 wealth 2 AI Frameworks 1 AI History 1 AI Safety 1 AI in sports 1 AIMP 1 Alan Watts 1 Alexander Gerst 1 Android 1 Anonymous 1 Anthropic 1 Automation 1 BIG DATA 1 Banking 1 Bill Warner 1 Bono 1 CUDA 1 Claude 1 Claude AI 1 Coaching 1 Constitutional AI 1 Darwin 1 Diagnostics 1 Emigration 1 Fable 1 Football 1 Future of Finance 1 Generation Z 1 Google 1 ISIS 1 ISS 1 Intelligence 1 Islam 1 Islamic State 1 Kylian Mbappé 1 Londoners 1 Maps 1 Medicine 1 Microsoft 1 Mind 1 Mythos 1 NVIDIA 1 Neural Networks 1 Open Source 1 Opera 1 Pac-Man 1 Perceptron 1 Personal Development 1 Personal Finance 1 Personal development 1 Productivity 1 Programming 1 Programs 1 Psychology 1 RedHat 1 Robo-advisors 1 Rust 1 Security 1 Social Media 1 Software 1 Software Engineering 1 Solo Projects 1 Solopreneurship 1 Sport 1 Time Management 1 U2 1 Ubuntu 1 Vivaldi 1 Work 1 World Cup 1 World Cup 2026 1 a drop of motivation 1 addiction 1 aids 1 applications 1 assertiveness 1 audio 1 automateit 1 autonomous cars 1 awareness 1 bash 1 bat files 1 batch 1 better life 1 better living 1 books 1 browsers 1 campaign 1 chemistry 1 coldplay 1 command history 1 communication 1 communities 1 computer intelligence 1 creativity 1 curiosities 1 cyberattacks 1 data 1 date and time 1 deep learning 1 documentary 1 earning 1 economy 1 emotions 1 entertainment 1 evolution 1 facebook 1 file size 1 food 1 future of transport 1 future of work 1 games 1 genius 1 hacker 1 health 1 history 1 how many people live on earth 1 innovation 1 interesting websites 1 investing 1 investments 1 labor market 1 machine learning 1 making money 1 messenger 1 mindfulness 1 mounting 1 mp3 player 1 music 1 music player 1 net use 1 network resources 1 onestep4red 1 people 1 personal development 1 philosophy 1 photography 1 plague 1 player 1 poison 1 questions 1 reading 1 red 1 robotaxi 1 science 1 scientific facts 1 shell 1 social media 1 society 1 space 1 sports 1 statistics 1 terminal 1 terrorism 1 the world in numbers 1 timelapse 1 web applications 1 windows automation 1 wisdom 1 world 1 world cup 2026 1 you are a miracle 1 zeitgeist 1

Blog archive

Table of contents