Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.


Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.

Generic User Avatar

Getting a drive detected in THIS PC


  • Please log in to reply
5 replies to this topic

#1 Bastie

Bastie

  •  Avatar image
  • Members
  • 229 posts
  • OFFLINE
  •  
  • Local time:11:22 AM

Posted 31 July 2023 - 02:27 AM

In my x32Win10ProV22H2, I have SSDs that are connected via SATA ports, but whose power can be switched on (and off) as required. The BIOS has been set to ACHI, so all connected drives should be 'hot swapable'. Yet from time to time, newly connected (i.e. newly powered) drives, do not get detected unless I reboot the PC. I'm looking for a tweak that will force detection without rebooting. I put this question to another forum and one of the responses, provided a batch file to trigger 'rescanning'. The concept is EXACTLY what I am after, but alas the code does not achieve the desired result - it does launch the Command Prompt (probably at elevated level), and Diskpart is employed, I think. I'm wondering if the batch file can be improved or some other work-around created, to avoid the need to reboot so as to get a drive detected.



BC AdBot (Login to Remove)

 


#2 Chris Cosgrove

Chris Cosgrove

  •  Avatar image
  • Global Moderator
  • 25,007 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Scotland
  • Local time:02:22 AM

Posted 31 July 2023 - 04:27 AM

Not my field but I think you need to publish the code of this batch file to get any effective assistance.

 

Chris Cosgrove



#3 cryptodan

cryptodan

    Bleepin Madman


  •  Avatar image
  • Members
  • 32,303 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Catonsville, Md
  • Local time:01:22 AM

Posted 31 July 2023 - 04:43 AM

Some drives may not support hot swap capabilities.

My Linux Systems Specifications: My Desktop - https://dpaste.com/AKGGCBGSW - My Server - https://dpaste.com/8M228Z6ZM - My laptop Arch - https://dpaste.com/FKSMU4MM2

-----------------------------------------------------------------------------

Masters of Science in Computer and Digital Forensics - Stevenson University 
-----------------------------------------------------------------------------
US Navy Veteran - 2002 to 2006 - Blue and Gold and Proud to Serve - Honor, Courage, and Commitment
 

#4 Bastie

Bastie
  • Topic Starter

  •  Avatar image
  • Members
  • 229 posts
  • OFFLINE
  •  
  • Local time:11:22 AM

Posted 31 July 2023 - 06:47 PM

Chris Cosgrove - I will do as you suggest; I was not really expecting an improvement in the code, but instead to intimate the kind of solution I'm hoping for.  

 

@echo off
DISKPART /s C:\script.txt

 

where script.txt says

 

rescan

 

Bleepibn madman - 'Some drives...' This malfunction only occurs sometimes, so the capability is there most of the time.

.



#5 garlin

garlin

  •  Avatar image
  • Members
  • 98 posts
  • OFFLINE
  •  
  • Local time:06:22 PM

Posted 02 August 2023 - 10:06 PM

Have you tried "pnputil /scan-devices"?



#6 Bastie

Bastie
  • Topic Starter

  •  Avatar image
  • Members
  • 229 posts
  • OFFLINE
  •  
  • Local time:11:22 AM

Posted 23 September 2023 - 08:36 AM

Garlin - I have not tried "pnputil /scan-devices" because I did not see your post till today (23/9/23), and I do not know about that option. It looks to me like something one could run from an elevated DOS prompt. I will try that next time a drive that should be detected, is not. Thank you.






1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users