So OS X doesn't need to be defragmented eh?

Posted:
in macOS edited January 2014
Pffft. I tried to install Windows at the weekend via Bootcamp and I thought first of all that it would be an easy 3 step process:



1. burn drivers CD

2. partition drive

3. install Windows



Step 1 went great but then came step 2. I only wanted a 32GB partition from a 250GB drive that had 70GB free. It started a bit and then gave an error about not being able to move files around.



I freed up to 90GB and tried all sizes down to 5GB and every one failed. They also failed randomly. Sometimes choosing 19GB almost went through and other times it wouldn't even get going. I freed 150GB and still the same thing.



Fortunately the drive had already been cloned to an external drive so all I had to do was format it (no zeroing btw) and clone it back. Cloning back 190GB took about 3 hours. Then Bootcamp partitioned successfully first time at 32GB.



Now, I'm not saying necessarily that OS X should have a defragment tool because I've read about defrag processes taking upwards of 8 hours and it can damage your data but is there a filesystem that is not susceptible to fragmentation at all? I'm guessing that OS X can just deal with a fragmented filesystem without slowing down but surely one that is impervious to it would be even better.



I can't think of how it could be achieved though. Maybe it would be easier to figure out a way to allow partitions to use a non-contiguous portion of the drive.

Comments

  • Reply 1 of 11
    As I understand it, it defragments smallish file sunder 20MB on the fly. Any intensive work likely requires outside intervention. I used to do some light video editing and defragging made a big difference.
  • Reply 2 of 11
    kickahakickaha Posts: 8,760member
    Reboot the machine. Usually, the files that can't be moved are being used by the OS and Finder. Reboot, and immediately start the partitioning.
  • Reply 3 of 11
    MarvinMarvin Posts: 15,322moderator
    Quote:
    Originally Posted by Kickaha


    Reboot the machine. Usually, the files that can't be moved are being used by the OS and Finder. Reboot, and immediately start the partitioning.



    I tried that 3 or 4 times and I made sure absolutely nothing was running including Dashboard widgets. I actually wasted the whole afternoon because I was sure it could be done but nothing worked. Bootcamp actually recommended the formatting of the drive when it couldn't move the files.
  • Reply 4 of 11
    irelandireland Posts: 17,798member
    It is still technically a Beta.
  • Reply 5 of 11
    What computer are you using? Do you have any mods to your machine at all?
  • Reply 6 of 11
    e1618978e1618978 Posts: 6,075member
    Quote:
    Originally Posted by ricksbrain


    What computer are you using? Do you have any mods to your machine at all?



    Lots of people had this problem - I have an unmodified core2duo macbook pro, and I had to use SuperDuper to back my hard drive up to an external drive and then back again before bootcamp would work.
  • Reply 7 of 11
    MarvinMarvin Posts: 15,322moderator
    Quote:
    Originally Posted by ricksbrain


    What computer are you using? Do you have any mods to your machine at all?



    It has done it on an iMac with 150GB free out of 250GB and that machine was bought about 2 months ago. It did the same thing for me today on a Mac Mini with 15GB out of 60GB free which was bought at the same time. Today my brother installed Windows on someone else's iMac and they had just bought it and still had most of the 250GB left and Bootcamp had no problem partitioning it.



    These machines have no mods whatsoever and even if they did, the fact that Bootcamp tells you to backup your drive, format it and restore it suggests fragmentation is the cause of the problem. I'm still not sure how it failed to partition 32GB from 150GB though.



    I also tried installing on an external drive over both USB and firewire and Windows says it can't install onto the device - even though it recognized the 80GB Fat32 drive as a suitable destination. Supposedly Windows doesn't like to be run from an external device and you even have to modify the installer CD to get it to work. It didn't even let me boot the installer CD from my external firewire DVD drive. XP sucks.



    This did go to prove however that you can run Windows without OS X at all. Windows CDs just boot like OS X CDs/DVDs when you hold the alt key. If you have two drives in say a Mac Pro, you only need Bootcamp for the drivers CD.
  • Reply 8 of 11
    Quote:
    Originally Posted by Marvin


    I also tried installing on an external drive over both USB and firewire and Windows says it can't install onto the device - even though it recognized the 80GB Fat32 drive as a suitable destination. Supposedly Windows doesn't like to be run from an external device and you even have to modify the installer CD to get it to work. It didn't even let me boot the installer CD from my external firewire DVD drive. XP sucks.



    Even Vista does not allow installation onto external media. So you can safely say that Vista also sucks!
  • Reply 9 of 11
    Quote:
    Originally Posted by Marvin


    I also tried installing on an external drive over both USB and firewire and Windows says it can't install onto the device - even though it recognized the 80GB Fat32 drive as a suitable destination. Supposedly Windows doesn't like to be run from an external device and you even have to modify the installer CD to get it to work. It didn't even let me boot the installer CD from my external firewire DVD drive. XP sucks.



    Guys, do you ever actually read the Read-Me files Apple provides with its software? On page 5 of their "Boot Camp Beta Installation & Setup Guide", it says:

    "Creating a partition for Windows XP - Boot Camp Assistant creates a partition for Windows XP on your computer’s startup or other internal disk."



    That means that it only works with internal disks, and as multiple internal disks can only be installed into the MacPro, that again means that external disks are not supported. Even when using a regular PC, Windows can't be installed externally - unless the mainboard supports it AND you have the correct drivers on floppy to "feed" to the installer.



    Oh, and by the way, page 20 of the same document states: "I can’t partition my disk. (...) Boot Camp Assistant only works with internal disks. You cannot use Boot Camp Assistant to partition and install Windows XP on an external disk."



    Regarding the defragmentation process: OS X itself does not need any manual defragmentation, as ricksbrain said correctly, because it does that on the fly. BUT re-partitioning is a complete different story. Of course you need contiguous free space to do that, otherwise the data will be overwritten. I'm not sure, though, whether Apple can solve that problem easily. Cloning the drive and writing back all the stuff is quite an easy process, although a time-consuming one, but it works perfectly.



    If you have a brand new computer and want to use BootCamp on it, there should be no problem at all. But after a few weeks, every harddrive gets a bit fragmented, although it is technically not fragmented, but rather the big files get written in one single data stream towards the end of the free drive space. That is, again, not fragmentation, but rather making efficient use of all the space a drive has. The data can be read faster when the file is stored in one data stream - even when this big file is stored towards the inner sectors of a hard drive - towards the spindle, where the "slower" sectors are compared to the sectors at the outer end of the drive's platters.
  • Reply 10 of 11
    MarvinMarvin Posts: 15,322moderator
    Quote:
    Originally Posted by gwoodpecker


    Guys, do you ever actually read the Read-Me files Apple provides with its software? On page 5 of their "Boot Camp Beta Installation & Setup Guide", it says:

    "Creating a partition for Windows XP - Boot Camp Assistant creates a partition for Windows XP on your computer?s startup or other internal disk."



    That means that it only works with internal disks, and as multiple internal disks can only be installed into the MacPro, that again means that external disks are not supported.



    Sure but unsupported doesn't always mean impossible - people have done it already and are booting their Macs from external drives. It just requires a bit of hacking around. I wasn't criticizing Apple in this respect btw, it's clearly Microsoft's fault.



    Quote:
    Originally Posted by gwoodpecker


    Oh, and by the way, page 20 of the same document states: "I can?t partition my disk. (...) Boot Camp Assistant only works with internal disks. You cannot use Boot Camp Assistant to partition and install Windows XP on an external disk."



    I didn't try to partition the external drive using Bootcamp, it was completely fat32 and Windows saw it at the initial installation stage.



    Quote:
    Originally Posted by gwoodpecker


    Regarding the defragmentation process: OS X itself does not need any manual defragmentation, as ricksbrain said correctly, because it does that on the fly. BUT re-partitioning is a complete different story. Of course you need contiguous free space to do that, otherwise the data will be overwritten. I'm not sure, though, whether Apple can solve that problem easily. Cloning the drive and writing back all the stuff is quite an easy process, although a time-consuming one, but it works perfectly.



    I agree that cloning is the best solution. You may be right that from a performance perspective OS X doesn't need to be defragged but for dynamic partitioning it obviously does. That's all I was saying but extending that to if anyone ever wanted to defrag their system, cloning would be the easiest way to do it.
  • Reply 11 of 11
    Quote:
    Originally Posted by Marvin


    Sure but unsupported doesn't always mean impossible - people have done it already and are booting their Macs from external drives. It just requires a bit of hacking around. I wasn't criticizing Apple in this respect btw, it's clearly Microsoft's fault.



    Booting a Mac from an external FIREWIRE drive is no problem. OS X supports this. Windows hates to boot from anything other than the master HDD. Actually, IIRC, it won't do it at all without some serious user intervention. Linux takes some serious messing around to do this too (well, Ubuntu at least). On your Mac - simply go to system prefs / startup disk / external OS X installation. I think there's also some keys you can press when you restart, but I haven't booted from an external partition in a long time, so I can't remember what they are.
Sign In or Register to comment.