How do these file operations work?

By greatman05
Dec 24, 2010
Post New Reply
  1. Hello. This might be a weird question, but I was working in Windows 7, and I moved a directory on my hard disk from one location to another on the same disk. The transfer was almost instantaneous. My question is, how is this possible? I'm really trying to ask how the Copy and Move file operations work in Windows. I figure they're similar to the way DOS did it, but I want to be sure.
  2. captaincranky

    captaincranky TechSpot Addict Posts: 11,467   +1,760

    I'm fairly certain that file and folder locations are established by pointer tables and hexadecimal address assignments, rather than actual physical locations, provided that the files exist in the same drive location.

    If this criterion is met, the "move" command simply adjusts the pointers, it doesn't move the file.

    The only operation that would actually move a file in this environment, is the disc defragmenter.

    "Copy" is a different issue than "move". In this case the OS has to recreate the files.
  3. greatman05

    greatman05 TS Maniac Topic Starter Posts: 429

    OK. Thanks for answering that question :D

    So, with that criterion established, how are defragmenters actually able to move files around on the same hard drive?
  4. beauty

    beauty TS Rookie Posts: 64

    My understanding is that a defragmenter actually performs a read/write operation on the disk to change which physical sectors on the hard drive the file contents are written to. Then updates the file system to reflect the new position of the file.
  5. greatman05

    greatman05 TS Maniac Topic Starter Posts: 429

    OK. Thanks guys for all your help! :D

Similar Topics

Add New Comment

You need to be a member to leave a comment. Join thousands of tech enthusiasts and participate.
TechSpot Account You may also...