Announcement

Collapse
No announcement yet.

Installing Win7 and shrinking HDD.

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Installing Win7 and shrinking HDD.

    Before Linux i was really into gaming,and i mean hardcore gaming.I havent played anything mainstream for 2 years now.But Mass Effect 3 is coming and im slipping again lol.So my question is:How to i shrink my HDD in order to install Windows on it?I want to install Win7 temporary until i finish the game after that i dont need it.And how do i set up dual boot?And can it all be deleted (i mean Windows 7 and partition where they are located) once i dont need it anymore?I have 2 HDD,my 160 GB is where Kubuntu(no partitions there) is located and 1T one for data.Dont tell me i can use Wine and PlayOnLinux cause i m not going to bother with that id rather install Windows7 and graphic drivers for my HD 5770.

    #2
    The following is for Windows 7 and Ubuntu, but applies to Kubuntu as well: Dual boot Ubuntu and Windows 7
    Windows no longer obstructs my view.
    Using Kubuntu Linux since March 23, 2007.
    "It is a capital mistake to theorize before one has data." - Sherlock Holmes

    Comment


      #3
      Do you want to install Win7 on the first (160GB) HDD, or the 1TB one? I'm guessing the first, and I hope you have plenty of free space on it (for a well-performing Win7 I would allocate 50GB).

      Boot from a Live CD (you can't resize the partition that the current OS is running from). There's a partition editor supplied with Kubuntu but I prefer to use gparted. I can't recall if gparted is on the Kubuntu Live CD but you can download and install it easily.

      It's pretty self-explanatory. gparted will show you /dev/sda - make sure it is the drive you want to shrink (or select the right one from the dropdown). It will show one partition and probably a swap partition. Click on the main partition and then click "resize/move" and enter the new size (or enter the free space after e.g. 50000). Then apply. You now have free space.

      I would at this point create an ntfs partition in the free space, even though windows will reformat the partition. I haven't installed windows onto a system with Linux already on it so I don't know how it will identify the partition you want to install it on, but afaik it too is self-explanatory ... the only hassle might be if it describes the partitions as (hd0,1) etc - you have to be sure whether it's numbering from 0 or 1.

      Caution: windows needs to install on a primary partition (I think this is still true of Win 7) - so the new partition you create must be sda2 or sda3 or sda4 - mostly likely your existing 160GB partition will be sda1, and sda2 will be taken up with an extended partition containing your swap partition as a logical partition.

      Final step: the Windows install will make your Kubuntu install inaccessible (because it has no respect for what it calls "older" operating systems) - you will need to reinstall GRUB2, again from the Live CD.
      Last edited by SecretCode; Mar 03, 2012, 10:20 AM.
      I'd rather be locked out than locked in.

      Comment


        #4
        @Snowhog: that article seems to require installing Win7 first, which wouldn't be the case here - or have I misread it?
        I'd rather be locked out than locked in.

        Comment


          #5
          SecretCode@
          The point being made is that Windows 7 (and for that matter, 'all' Windows variants) *require* that they be installed first. I do agree however, that one *can* install Linux on a system that already has Windows on it, but you have to ensure that Grub IS NOT installed to the Windows HD MBR!. Installing Linux in this way, you then have to modify the Windows boot-loader, or, install a third-party boot-loader to be used by Windows, to control the boot-loading process and provide for the option to boot into other identified OS's. EasyBCD is the "preferred" boot-loader in this case.
          Windows no longer obstructs my view.
          Using Kubuntu Linux since March 23, 2007.
          "It is a capital mistake to theorize before one has data." - Sherlock Holmes

          Comment


            #6
            Originally posted by SecretCode View Post
            Final step: the Windows install will make your Kubuntu install inaccessible (because it has no respect for what it calls "older" operating systems) - you will need to reinstall GRUB2, again from the Live CD.
            Yes that happened to me a long time ago when i tried to install Linux for the first time.I screw my Windows MBR.What about this idea:I shrink 50GB on my 1 TB HDD then i unplug SATA from my 160 GB where my Kubuntu is and then install Windows 7.Would that work?I dont want screw my Kubuntu GRUB because i already have bad sexperience with that and i rather avoid the whole mess and reinstallation if i can.

            Comment


              #7
              Reinstalling GRUB is fairly painless: Grub2 - Community Ubuntu Documentation although I appreciate if you've had pain with it before you might not want to go there.

              Installing Windows on the other hard drive could well be a safer option, though. ... Whichever way you go I hope you have backups of your data since any partition editing can run into problems.

              Originally posted by Snowhog View Post
              SecretCode@
              The point being made is that Windows 7 (and for that matter, 'all' Windows variants) *require* that they be installed first.
              I believe that is not true! How to dual-boot Vista with Linux (with Linux installed first) -- the step-by-step guide with screenshots ... How to Install Windows XP With Ubuntu Installed First | eHow.com ... (there are pages for the same with Win7, but badly written)

              Originally posted by Snowhog View Post
              I do agree however, that one *can* install Linux on a system that already has Windows on it, but you have to ensure that Grub IS NOT installed to the Windows HD MBR!.
              I know this isn't true because I've done it on several computers with XP or Win7 preinstalled. If you install Linux after Windows, GRUB automatically detects windows and creates an entry to chain-load the windows boot loader (which, like stage 2 of GRUB, is in a partition not in the MBR).
              Last edited by SecretCode; Mar 03, 2012, 12:16 PM.
              I'd rather be locked out than locked in.

              Comment


                #8
                Originally posted by SecretCode View Post
                Reinstalling GRUB is fairly painless: Grub2 - Community Ubuntu Documentation although I appreciate if you've had pain with it before you might not want to go there.
                Ok thanks.One last question.Once i m done with gaming will i be able to simply delete partition where the Windows are?I mean can you delete a system partition or do i have to format the whole disk?

                Comment


                  #9
                  Yes you can delete it - if you use GRUB2 as your bootloader, re-run sudo update-grub to remove the windows entry (actually this would not apply if you only boot the windows installation by removing the Kubuntu SATA cable)

                  I assume you'll want to reclaim the space - so delete the partition in gparted and then resize the original data partition to expand to fill all available space.

                  Or simply reformat it as ext4 ... could be handy to have a spare partition in case you want to install windows again, or a new linux distro (I have several bootable partitions on this machine).
                  I'd rather be locked out than locked in.

                  Comment


                    #10
                    Originally posted by SecretCode View Post
                    Yes you can delete it - if you use GRUB2 as your bootloader, re-run sudo update-grub to remove the windows entry (actually this would not apply if you only boot the windows installation by removing the Kubuntu SATA cable)

                    I assume you'll want to reclaim the space - so delete the partition in gparted and then resize the original data partition to expand to fill all available space.

                    Or simply reformat it as ext4 ... could be handy to have a spare partition in case you want to install windows again, or a new linux distro (I have several bootable partitions on this machine).
                    I will be able to delete it?I ask because i couldnt delete Ubuntu system partition in Windows Disk Managment before in the past, it wouldnt let me because it was system partition.

                    Comment


                      #11
                      I am no expert in Windows Disk Management but I believe there are things it can't do - you should have no problems running gparted from a live CD

                      I'm not sure what it means by "system partition" - I don't think that's a specific flag a partition can have in an MBR disk. It might mean 'bootable' or it might just mean that it is mounted.
                      I'd rather be locked out than locked in.

                      Comment


                        #12
                        Originally posted by SecretCode View Post
                        I'm not sure what it means by "system partition" - I don't think that's a specific flag a partition can have in an MBR disk. It might mean 'bootable' or it might just mean that it is mounted.
                        In Windows-land, a system partition is the one containing the files that boot the computer; a boot partition is the one containing the operating system.



                        No, I don't understand why, either.

                        Comment


                          #13
                          Ok now i need help with actually using gparted and how to create a 60 GB partition on my 1 TB drive.

                          Comment


                            #14
                            Aha. That's fair enough - you never know how much information to put into a first reply.

                            Take a look at this page which has some graphical examples: Modify Your Partitions With GParted Without Losing Data | HowtoForge - Linux Howtos and Tutorials

                            What you should see - after you have selected the right drive, probably /dev/sdb - is one big 1TB partition (it may show as 930GB or something, that's nothing to worry about) called sdb1. Click it and then click "Resize/move" and then type 60000 in the "Free space following (MiB)" box. (The tutorial page suggests dragging the black arrow but the result is similar.) The new size of sdb1 should still be large, like 870000 MiB.

                            Click Apply (the tutorial page seems to skip that step).

                            Now you have free, unallocated space, and from what I understand Windows 7 should find it and give you the option to install into it.

                            For a much more extensive tutorial, this page is good: GParted partitioning software - Full tutorial
                            I'd rather be locked out than locked in.

                            Comment


                              #15
                              Originally posted by SecretCode View Post
                              Aha. That's fair enough - you never know how much information to put into a first reply.

                              Take a look at this page which has some graphical examples: Modify Your Partitions With GParted Without Losing Data | HowtoForge - Linux Howtos and Tutorials

                              What you should see - after you have selected the right drive, probably /dev/sdb - is one big 1TB partition (it may show as 930GB or something, that's nothing to worry about) called sdb1. Click it and then click "Resize/move" and then type 60000 in the "Free space following (MiB)" box. (The tutorial page suggests dragging the black arrow but the result is similar.) The new size of sdb1 should still be large, like 870000 MiB.

                              Click Apply (the tutorial page seems to skip that step).

                              Now you have free, unallocated space, and from what I understand Windows 7 should find it and give you the option to install into it.

                              For a much more extensive tutorial, this page is good: GParted partitioning software - Full tutorial
                              Thanks man i know i must be boring.One last question.When i do install widnows how do i set up dual boot?You said you have multiple OS installed and i still want to use Kubuntu as my primary OS.

                              Comment

                              Working...
                              X