Rescan disks doesn't rescan disks?

Discussion in 'Windows Vista Drivers' started by Norman Diamond, Mar 31, 2008.

  1. In Windows XP SP2, Computer Administration -> Disk Administration, Action ->
    Rescan Disks seems to be inconsistent as to whether it rescans disks or not.

    If I get permission from Windows to detach a USB hard drive, then actually
    detach it and reattach it, then Action -> Rescan Disks rescans the disk.
    But if I don't detach and reattach, i.e. if a disk just remains connected,
    then Rescan Disks doesn't rescan it.

    Does this work differently for anyone else?
    Norman Diamond, Mar 31, 2008
    1. Advertisements

  2. If I get permission from Windows to detach a USB hard drive, then actually
    Detach/reattach reactivates the drive.
    Maxim S. Shatskih, Mar 31, 2008
    1. Advertisements

  3. It sounds like you agree with me. So does anyone know why Disk
    Administrator has a misleading non-working "Rescan Disks" command?
    Norman Diamond, Mar 31, 2008
  4. "Safe removal" for USB disk actually ejects the usbstor device. At that
    time, the LUN and volume are not enumerated anymore; there is nothing to
    rescan for Disk Manager.
    Alexander Grigoriev, Mar 31, 2008
  5. It makes sense to me that an ejected disk isn't rescanned. It makes sense
    to me that a reattached disk is rescanned.

    My question is why disks that were never ejected at all aren't rescanned.
    Consider a disk that is attached once, remains attached, gets repartitioned,
    remains attached, and the user wants its new partitions to be recognized.
    What is the purpose of the Rescan Disks menu entry? If the only way to get
    a disk to be rescanned is to eject it and reattach it, who needs a command
    whose name says rescan but which doesn't rescan?
    Norman Diamond, Apr 1, 2008
  6. Norman Diamond

    David Craig Guest

    There is a specific series of operations that a format program must follow
    to ensure that the media is locked properly and then released to the OS in a
    way that will force a remount operation. Using Disk Manager to 'rescan' is
    NOT the proper procedure. Use IrpTracker and the fastfat source code to see
    what happens. I have a format program that does it properly, but it has
    been years since I looked at it. It contains confidential information since
    it works for SmartMedia. I still haven't thrown away my 1998 1.3 megapixel
    camera that can't use anything larger than a 16MB SmartMedia.

    Look at the storage and disk headers that come with the WDK and SDK, too.
    Also look at CreateFile and exclusive write access to physical drives. The
    sequence of operations including specific IoCtls is very important, but when
    done correctly will work.

    Lately I have not been doing much in the storage arena, but have been
    working on NDIS miniport drivers instead.
    David Craig, Apr 1, 2008
  7. There is a specific series of operations that a format program must follow
    - open the volume
    - write the new empty FS

    Volume will then be mounted on first file open on it.
    Maxim S. Shatskih, Apr 1, 2008
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.