How to migrate XP, Vista, Linux, BSD and Solaris to a bigger hard disk - Page 3


Page 3 of 12 FirstFirst 1234567 ... LastLast
Results 31 to 45 of 180

Thread: How to migrate XP, Vista, Linux, BSD and Solaris to a bigger hard disk

  1. #31
    Join Date
    Jun 2004
    Location
    Newcastle upon Tyne
    Posts
    2,978
    irlandes,

    Thanks for the kind words.

    I am passing the knowledge that mods and members have taught me. That is what JustLinux is all about. Wait until you see what our village elders (super mods) can do for you.

    I am just one of their pupils.
    Linux user started Jun 2004 - No. 361921
    Using a Linux live CD to clone XP
    To install Linux and keep Windows MBR untouched
    Adding extra Linux & Doing it in a lazy way
    A Grub menu booting 100+ systems & A "Howto" to install and boot 145 systems
    Just cloning tips Just booting tips A collection of booting tips

    Judge asked Linux "You are being charged murdering Windoze by stabbing its heart with a weapon, what was it?" Replied Linux "A Live CD"

  2. #32
    Join Date
    Dec 1999
    Location
    tx
    Posts
    1,190
    Your comment about being one of their pupils brought back some history. Sorry to digress.

    In 1974, I started on the first microprocessor unit in our company. It was based on a Rockwell PPS-4, a 4 bit cash register microprocessor, which we used to make a fine area navigation computer for business jets. And, of course, the Israeli Air Force bought them for their fighters instead of paying $100,000 each as the USAF did.

    I was a true pioneer in those days. I was good, and that is no brag. The last time I was especially good in that company.

    Sometime later, I transferred to another department, and some of the guys there asked me for an introduction to micro-p's.

    Within a few days, those guys were moving on past me. Incredible.

    So, being a pupil does not always mean being lesser. Trust me on this.

  3. #33
    Join Date
    Sep 2007
    Posts
    4
    saikee,

    I'm a Linux noob, I started looking at distributions about 4 weeks ago. I've read with great interest your tutorials on booting, cloning, and migrating. I appreciate the time and effort that you put forth in doing this. Following the instructions in your migrating XP to a larger hard disk tutorial I have successfully migrated XP from an 80 GB SATA to a 160 GB SATA. I am currently dual booting that PC (I need to find the LInux equivilant of one Windows program and then I can dump Windows totally).

    My second attempt at migrating has been unsuccessful and I'm hoping that you can help. I tried to migrate XP from a 60 GB PATA to a 400 GB PATA. After a few minutes the process stops and I get the below message:

    dd reading /dev/hda input/output error
    310061+1 records in
    310061+1 records out

    (10.0 GB copied)

    The 60 GB PATA disk has 40 GB in files so more than 10 GB should have been copied. I tried to boot from the new 400 GB PATA but of course it will not. I have done this twice and the error messages are exactly the same both times. The old 60 GB PATA successfully boots XP and has never given an indication of having a problem. Do you have any suggestions or ideas that I could try ?

    Thank you.

  4. #34
    Join Date
    Jun 2004
    Location
    Newcastle upon Tyne
    Posts
    2,978
    jsnadml,

    Welcome to Juxtlinux.

    I believe dd does not distinguish empty space from files because everything are bits of "1" and "0".

    The number of records times the block size should equal exactly the disk size in a successful pass. In your case it looks the disk has some kind of corruption or enough of bad sectors serious enough to prevent the disk from being read continuously.

    I do not have a solution for it. You may need to slow down the read access by changing the DMA mode or use a different version of dd like dd_rescue. I haven't had a need to go into such a bad disk myself. There have been a few posts here saying a dead disk could be brough back from life with various tricks.
    Last edited by saikee; 10-16-2007 at 04:47 PM.
    Linux user started Jun 2004 - No. 361921
    Using a Linux live CD to clone XP
    To install Linux and keep Windows MBR untouched
    Adding extra Linux & Doing it in a lazy way
    A Grub menu booting 100+ systems & A "Howto" to install and boot 145 systems
    Just cloning tips Just booting tips A collection of booting tips

    Judge asked Linux "You are being charged murdering Windoze by stabbing its heart with a weapon, what was it?" Replied Linux "A Live CD"

  5. #35
    Join Date
    Sep 2007
    Posts
    4
    saikee,

    Thank you for the quick reply. I'll try the suggestions that you mentioned.

  6. #36
    Join Date
    Jun 2004
    Location
    Newcastle upon Tyne
    Posts
    2,978

    An example of cloning

    Here is an Ubuntu 7.10 Live CD screen message of cloning from a 500Gb eSata disk sda (Seagate), which is physically outside the PC to an internal raw 500Gb Pata disk sdb (Western Digital)
    Code:
    ubuntu@ubuntu:~$ sudo su
    root@ubuntu:/home/ubuntu# fdisk -l
    
    Disk /dev/sda: 500.1 GB, 500107862016 bytes
    255 heads, 63 sectors/track, 60801 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sda1               1       12158    97659103+  17  Hidden HPFS/NTFS
    /dev/sda2   *       12159       24316    97659135    7  HPFS/NTFS
    /dev/sda3           24317       36598    98655165    5  Extended
    /dev/sda4           36599       60801   194410597+  83  Linux
    /dev/sda5           24317       24438      979933+  82  Linux swap / Solaris
    /dev/sda6           24439       25654     9767488+  83  Linux
    /dev/sda7           25655       26870     9767488+  83  Linux
    /dev/sda8           26871       28086     9767488+  83  Linux
    /dev/sda9           28087       29302     9767488+  83  Linux
    /dev/sda10          29303       30518     9767488+  83  Linux
    /dev/sda11          30519       31734     9767488+  83  Linux
    /dev/sda12          31735       32950     9767488+  83  Linux
    /dev/sda13          32951       34166     9767488+  83  Linux
    /dev/sda14          34167       35382     9767488+  83  Linux
    /dev/sda15          35383       36598     9767488+  83  Linux
    
    Disk /dev/sdb: 500.1 GB, 500107862016 bytes
    255 heads, 63 sectors/track, 60801 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    
    Disk /dev/sdb doesn't contain a valid partition table
    root@ubuntu:/home/ubuntu# dd if=/dev/sda of=/dev/sdb bs=32768
    15262080+1 records in
    15262080+1 records out
    500107862016 bytes (500 GB) copied, 8047.02 seconds, 62.1 MB/s
    root@ubuntu:/home/ubuntu#
    The above show the raw disk sdb has no partition to start with and took 8047.02 seconds, at a rate of 62.1 MB/s transfer rate, to copy 500Gb. The first command "sudo su" is to become a super user, having the root privilege, in a Live CD. The command "fdisk -l" is for checking the disks' partitions. The whole cloning process is done by one line command of " dd if=/dev/sda of=/dev/sdb bs=32768".

    Both disks have an identical size of 500107862016 bytes. Since I specified each block size of 32768 bytes in each transfer (by the bs=32768) I therefore should have 15262080.75 records to be shifted. This matches exactly the number of records read and written by dd, which reported 15262080+1 records as the last one was not a complete record.


    The partition table after the cloning is
    Code:
    root@ubuntu:/home/ubuntu# fdisk -l
    
    Disk /dev/sda: 500.1 GB, 500107862016 bytes
    255 heads, 63 sectors/track, 60801 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sda1               1       12158    97659103+  17  Hidden HPFS/NTFS
    /dev/sda2   *       12159       24316    97659135    7  HPFS/NTFS
    /dev/sda3           24317       36598    98655165    5  Extended
    /dev/sda4           36599       60801   194410597+  83  Linux
    /dev/sda5           24317       24438      979933+  82  Linux swap / Solaris
    /dev/sda6           24439       25654     9767488+  83  Linux
    /dev/sda7           25655       26870     9767488+  83  Linux
    /dev/sda8           26871       28086     9767488+  83  Linux
    /dev/sda9           28087       29302     9767488+  83  Linux
    /dev/sda10          29303       30518     9767488+  83  Linux
    /dev/sda11          30519       31734     9767488+  83  Linux
    /dev/sda12          31735       32950     9767488+  83  Linux
    /dev/sda13          32951       34166     9767488+  83  Linux
    /dev/sda14          34167       35382     9767488+  83  Linux
    /dev/sda15          35383       36598     9767488+  83  Linux
    
    Disk /dev/sdb: 500.1 GB, 500107862016 bytes
    255 heads, 63 sectors/track, 60801 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sdb1               1       12158    97659103+  17  Hidden HPFS/NTFS
    /dev/sdb2   *       12159       24316    97659135    7  HPFS/NTFS
    /dev/sdb3           24317       36598    98655165    5  Extended
    /dev/sdb4           36599       60801   194410597+  83  Linux
    /dev/sdb5           24317       24438      979933+  82  Linux swap / Solaris
    /dev/sdb6           24439       25654     9767488+  83  Linux
    /dev/sdb7           25655       26870     9767488+  83  Linux
    /dev/sdb8           26871       28086     9767488+  83  Linux
    /dev/sdb9           28087       29302     9767488+  83  Linux
    /dev/sdb10          29303       30518     9767488+  83  Linux
    /dev/sdb11          30519       31734     9767488+  83  Linux
    /dev/sdb12          31735       32950     9767488+  83  Linux
    /dev/sdb13          32951       34166     9767488+  83  Linux
    /dev/sdb14          34167       35382     9767488+  83  Linux
    /dev/sdb15          35383       36598     9767488+  83  Linux
    root@ubuntu:/home/ubuntu#
    I have a XP at sda1, Vista in sda2, sda5 a swap and sda6 to sda15 each has a Linux inside.

    The terminal commands are marked in red. The last partition table of disk sdb shows a mirror image of the former disk sda.

    For some reason all 500Gb disk of Seagate, Western Digital and Samsung all have the same number of sectors, making cloning a trouble free operation.

    I also enclose the buffered read speed of sda (a Sata II) and sdb (a Pata ATA133)
    Code:
    root@ubuntu:/home/ubuntu# hdparm -tT /dev/sda
    
    /dev/sda:
     Timing cached reads:   8712 MB in  2.00 seconds = 4360.12 MB/sec
     Timing buffered disk reads:  198 MB in  3.02 seconds =  65.60 MB/sec
    root@ubuntu:/home/ubuntu# hdparm -tT /dev/sdb
    
    /dev/sdb:
     Timing cached reads:   8658 MB in  2.00 seconds = 4333.50 MB/sec
     Timing buffered disk reads:  214 MB in  3.00 seconds =  71.22 MB/sec
    root@ubuntu:/home/ubuntu#
    My motherboard see the eSata as a SCSI disk and has it detected first and the Pata disk second.
    -------------------------------------------
    Edited 20/10/07

    I am editing this thread with the Vista in the Pata disk. This Vista is the third clone. I originally installed it, same as XP and 10 Linux in an internal 500Gb (Western Digital) Sata II disk.

    I first clone the internal 500 Gb Sata to an external eSata disk (a Seagate Sata II disk physically outside the PC and connected to the eSata port of the mobo). That operation took 9134 seconds at 54.8MB/s. I use Slax a Linux inside the internal disk for cloning.

    I then powered down, remove the internal Sata and boot up the eSata as the only disk in the system. The Bios had to select the eSata to boot as it is the only hard disk in the system. All the OSes work as expected.

    I then powered downed, add a raw Pata disk (as described at the beginning of this thread) as an internal disk, boot up a Ubuntu Live CD and to clone all the OSes from the eSata back into the internal Pata disk.

    I always use mobile racks for my hard disks so pulling one out and insert another in take only a few second.

    As I reported in the thread Vista on rebooting first time in the new enviroment immediately discovered its recorded hard disk serial number and details no longer match the newly found hard disk. It reported the new hardware found and demanded an immediate reboot to effect the change. After the reboot everything is back to normal. The activated copies of Vista and XP have been preserved through the two successive cloning processes and in different disk types.

    The disk-to-disk cloning by Linux dd command has not produced a single failure in my experience, regardless the number and the type of operating systems I have in the source disk. It works like a clockwork.

    ----------------------------
    Edited 21/10/07

    The effect of cloning XP & Vista from

    Internal Sata II --> External eSata II --> Internal Pata --> External USB Pata

    As a demonstration how easy cloning in Linux dd I cloned the 3rd copy from the internal Pata, as mentioned in the above, to an external USB Pata disk which is a 500Gb Seagate Barracuda (exact size as the others 500Gb disk).

    The operation took 27,452 seconds at 18.2MB/s. This is 7.625 hours and took 3.41 times longer. The reason is because from the 2nd to 3rd copies the cloning was done between two internal disks. Between the 3rd and 4th copies one disk is an external hard disk bottlenecked by the USB2.

    The Vista and XP did not boot and reboot every time if I try. The 10 Linux only 3 boot successfully while the others report "kernel panic - not syncing". This is expected because Linux installed originally installed in an internal hard disk may not be suitable for booting from a USB port.

    So what I gain from wasting 7.625 hours of computer time (during which time I took the wife to watch a movie and had dinner)-----> I removed the hard disk from the USB enclosure, put it into a caddy, inserted it into the mobile rack, powered up the PC and found XP and Vista bootable again.
    Last edited by saikee; 10-21-2007 at 05:19 AM.
    Linux user started Jun 2004 - No. 361921
    Using a Linux live CD to clone XP
    To install Linux and keep Windows MBR untouched
    Adding extra Linux & Doing it in a lazy way
    A Grub menu booting 100+ systems & A "Howto" to install and boot 145 systems
    Just cloning tips Just booting tips A collection of booting tips

    Judge asked Linux "You are being charged murdering Windoze by stabbing its heart with a weapon, what was it?" Replied Linux "A Live CD"

  7. #37
    Join Date
    Sep 2005
    Posts
    681
    I basically have been doing this for years but i do it on a LVM external usb disk.


    then if i need to access the drive i simply use a live linux cd so i can access the LVM disk and put it on the new drive i need it on.

    it keeps it smpiler so i know what each logical volume is . like i would do


    /dev/os/gentoo
    /dev/os/fedora
    /dev/os/windowsxp


    and so on
    "Software is like sex: it's better when its free."
    -LINUS TORVALDS

  8. #38
    Join Date
    Apr 2001
    Location
    SF Bay Area, CA
    Posts
    14,936
    Quote Originally Posted by ir8trader
    Now for my question: What happened when I left the original disk in the system and tried to change the bios to boot from the new disk ?
    When you use grub to chainload the XP bootloader, that bootloader reads in its boot.ini file from the first BIOS drive. This wasn't the cause of the behavior you saw, though, since both boot.ini files were exactly the same, but it's critical info.

    The cause of what you saw was in the contents of boot.ini. That file tells the NT bootloader to fire up the kernel from a hardcoded set of filenames sitting in a certain directory. You specify the directory in boot.ini by first specifying the disk (in BIOS order, I believe), then the path. Normally this looks something like "multi(0)disk(0)rdisk(0)partition(2)\WINDOWS" for a default XP install.

    The "disk(0)" part is the part that got messed up in your case. In your case, the 40G drive was still disk 0, while the larger drive was disk 1. When you removed the 40G drive entirely, the larger drive assumed position 0, and the same boot.ini file booted the system up from it.

    (At least, I assume this is the case. I guess Vista has a completely different bootloader or something like that now -- however, I bet it still follows the same set of restrictions as ntldr did.)

  9. #39
    Join Date
    Jun 2004
    Location
    Newcastle upon Tyne
    Posts
    2,978
    Vista is a proprietary system and it is a feature of the recent MS systems to check integrity of every partition it has to mount. It appears a possibility that Vista will not tolerate seeing another set of identical system files in the PC, especially this new set of system files was not created with its knowledge. Vista then proceeds to make both systems inoperable.

    I once had Vista, XP and Linux in a cloned hard disk accidentally hooked with the source disk. The resulting 4 MS systems were sabotaged when I ran Vista. I wasn't sure of the culprit at that time.

    It is true that the clone should always run "without" the presence of the source disk. There is no difficulty in cloning a Vista. Just don't let it see another copy of itself in any boot up.

    I am in a foreign country and just bought a laptop with a 160Gb disk with nothing but Vista inside. I downloaded Slax and PCLinuxOS from the Internet, bought a couple of CD-RW discs and cloned the Vista into 3 other newly bought portable hard disks.

    I am replying with Linux in a backup copy of Vista disk in a 250Gb laptop hard drive. The details of backing up Vista has been described in here.

    The Vista in my case has been cloned from an internal 2.5" 160Gb to an external 3.5" 500Gb which could not be verified its success because Vista does not support booting from external disk. However when the image of the 500Gb was transferred to a 2.5" 250Gb laptop disk which was placed into the laptop Vista booted up same as the original activated version. In the above link I explained the reason why I think Linux can successfully clone Vista from a bigger hard disk (500Gb) into a smaller hard disk(250Gb).

    At the end of the day if something happens to a proprietary system a user is in a helpless situation if he/she does something outside what the system permits him/her to do. In Linux after even a small bit of the system is understood a user can do amazing things. I think using the "dd" command to clone Vista, which is one of the most difficult systems to clone, falls into this category.
    Linux user started Jun 2004 - No. 361921
    Using a Linux live CD to clone XP
    To install Linux and keep Windows MBR untouched
    Adding extra Linux & Doing it in a lazy way
    A Grub menu booting 100+ systems & A "Howto" to install and boot 145 systems
    Just cloning tips Just booting tips A collection of booting tips

    Judge asked Linux "You are being charged murdering Windoze by stabbing its heart with a weapon, what was it?" Replied Linux "A Live CD"

  10. #40
    Join Date
    Nov 2007
    Posts
    1

    To do this don't use an up to date PC because...

    I have been trying for some time now to install any version of Linux on my Asus P5W DH Pro that uses a Dual Core Duo with ICH7R Intel chipset with sata 2 support and also my Nvidia 7950 GX2. The best distro so far has been opensuse 10.2 and none yet have supported the JMicron controller. Anyway I thought I was home and dry with opensuse 10.2 but use dd to copy from one sata to another and input/output errors pop up and process fails.
    I have spent hours trying to resolve this problem but decided to go back to my first successful sata cloning which was to use an older PC that uses a VIA chipset and bingo. No probs. So I thought this might be of use given that I can mount these partitions that cannot be read by dd and so on...
    Excelent forum.
    Hope this is of interest.

  11. #41
    Join Date
    Jun 2004
    Location
    Newcastle upon Tyne
    Posts
    2,978
    fuseblower,

    Welcome to Justlinux.

    On the difficulty of find a Linux to fit a modern mobo I seem to have the opposite effect of not able to find a distro that cannot be loaded into my PC, which is a Abit AW9D Max with Core Duo E6700. I run nothing but Sata II disk as internal and external eSata disks. The only thing I keep away is Raid.

    dd operates at the hardware level between devices. Thus I can clone a raw disk directly from a new purchase without the need to mount it. A user does not need to mount any partition to use the dd command.
    Linux user started Jun 2004 - No. 361921
    Using a Linux live CD to clone XP
    To install Linux and keep Windows MBR untouched
    Adding extra Linux & Doing it in a lazy way
    A Grub menu booting 100+ systems & A "Howto" to install and boot 145 systems
    Just cloning tips Just booting tips A collection of booting tips

    Judge asked Linux "You are being charged murdering Windoze by stabbing its heart with a weapon, what was it?" Replied Linux "A Live CD"

  12. #42
    Join Date
    Mar 2006
    Location
    Los Angleles, CA USA
    Posts
    9

    NOT a reply but a whole new set of Q&A (I hope)

    Saikee's post/thread

    How to migrate XP, Vista, Linux, BSD and Solaris to a bigger hard disk

    is simply the best one I've read after hours of googling about what I'm trying to do. I didn't want to lose my configured, fully updated OS and apps, along with passwords, user id, cookies, etc. etc. etc.. I'm so happy that this didn't cause a re-install. Mostly what I found was info about users with a m$ product and linux. I don't like to use M$, so I have only Linux for the last 3 years.

    A little background: I have a 20 gig drive, jumpered as slave and sitting on the cable as primary/slave.

    As of November 28, 2007 I had a "bare metal" never-before-used 320 gig drive, jumpered cable select and sitting on the cable as primary/master.

    Using G4L (formerly Ghost 4 Linux) I cloned the partitions and data from the slave to the master. It worked excellently.

    mark@Lexington:~$ sudo fdisk -l

    Disk /dev/sda: 320.0 GB, 320072933376 bytes
    255 heads, 63 sectors/track, 38913 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    Disk identifier: 0x00000080

    Device Boot Start End Blocks Id System
    /dev/sda1 1 2040 16386268+ 83 Linux
    /dev/sda2 2307 2434 1028160 5 Extended
    /dev/sda3 * 2041 2306 2136645 83 Linux
    /dev/sda4 2435 38913 293017567+ 83 Linux
    /dev/sda5 2328 2434 859446 82 Linux swap / Solaris
    /dev/sda6 2307 2327 168619+ 82 Linux swap / Solaris

    Partition table entries are not in disk order

    Disk /dev/sdb: 20.0 GB, 20020396032 bytes
    255 heads, 63 sectors/track, 2434 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    Disk identifier: 0x00000080

    Device Boot Start End Blocks Id System
    /dev/sdb1 1 2040 16386268+ 83 Linux
    /dev/sdb2 2307 2434 1028160 5 Extended
    /dev/sdb3 * 2041 2306 2136645 83 Linux
    /dev/sdb5 2328 2434 859446 82 Linux swap / Solaris
    /dev/sdb6 2307 2327 168619+ 82 Linux swap / Solaris

    As you can see, with the exception of /dev/sda4 the two drives are identical. What I want to do is change ("move or re-allocate") /dev/sda4's space (approx. 297GiB) to /dev/sda1. The problem is that GParted LiveCD won't "resize/move" without creating another partition of about 4 gig. I would prefer not to create even more partitions, unnecessarily.

    It was possible to do all the foregoing because my motherboard allows me to select which hard disk to "prioritize" for booting. At first, it was set to the drive sitting as primary/slave.

  13. #43
    Join Date
    Jun 2004
    Location
    Newcastle upon Tyne
    Posts
    2,978
    Mark_in_Hollywo,

    Welcome to Justlinux.


    sda1 to sda4 are reeserved primaries. Thus after cloning the excess of 297Gb is at the end of sda5 of you previous 20Gb. It would appear to me that you might have created sda5 at the end of your 20Gb disk resulting the remaining space at the front end of the extended partition sda2 used up as sda6.

    The partition table suggests that you had created the partitions in the order of sda1, sda2, sda5 and sda6. The partition order is a bit unusual but it is healthy.

    What you want to achieve by putting the excess 297Gb into sda1 is achieveable and I would suggest the following steps.

    (1) Fire up the Ubuntu in the 20Gb disk and invoke a Grub shell by command
    Code:
    sudo grub
    (2) Verify the (hd0) is your sdb (by having no 3rd partition because Grub count from 0 and sdb4 would be the partition (3). That your sda is disk (hd1) by commands
    Code:
    geometry (hd0)
    geometry (hd1)
    (3) Assuming (hd0) is sdb you then hide the extended partition sda2 by command
    Code:
    hide (hd1,1)
    Re-check the partition by command
    Code:
    geometry (hd1)
    which should show up only 4 partitions from 0 to 3 with the two logical partitions disappear. This is an intentended action so don't be alarmed. You then exit Grub by command "quit" to go back to Ubuntu.

    (4) You then fire up Gparted inside the Ubuntu. Using it to delete sda4. You then bodily move sda2 to the extreme end of the 320Gb disk. Repeat the same for sda3 which should butt against sda2 at the end of the hard disk leaving a huge space of 297Gb between sda1 and sda3.

    (5) You resize the end boundary of sda1 to absorb the desired space. You have now achieved you objective. So invoke a Grub shell. This time you unhide the sda2 by command
    Code:
    unhide (hd1,1)
    (6) There is a 50% proability that Grub's action of step (3) and (5) are not accepted in Linux. This is to say Ubuntu still uses the original Bios setting and the partitions are unchanged after you exit Grub. In such case let us know and we can advise a different approach.

    (7) Technically there is no need to restore Grub if sda1 is the "/" of Ubuntu. However you should remove the sdb temporily when booting sda. If you do have difficulty you can restore Grub when the PC boots to a Grub screen. Instead of slecting a system to boot you can press "c" to get a Grub prompt. You now have (hd0) as your sda and Grub can be restore by Grub commands
    Code:
    root (hd0,0)
    setup  (hd0)
    If Grub reports no error your new Ubuntu should boot without a reboot using command
    Code:
    root (hd0)
    chainloader +1
    boot
    ------------------------------------------------------------------

    There are more elegant ways to achieve what you want but the above is based on Gparted which is is technically sound and worthy of knowing the steps.
    Last edited by saikee; 11-29-2007 at 11:49 PM.
    Linux user started Jun 2004 - No. 361921
    Using a Linux live CD to clone XP
    To install Linux and keep Windows MBR untouched
    Adding extra Linux & Doing it in a lazy way
    A Grub menu booting 100+ systems & A "Howto" to install and boot 145 systems
    Just cloning tips Just booting tips A collection of booting tips

    Judge asked Linux "You are being charged murdering Windoze by stabbing its heart with a weapon, what was it?" Replied Linux "A Live CD"

  14. #44
    Join Date
    Mar 2006
    Location
    Los Angleles, CA USA
    Posts
    9
    From Saikee's response to my question:

    "(3) Assuming (hd0) is sdb you then hide the extended partition sda2 by command"

    It was at the instruction above that I became confused and stopped. In my particular case hd0 is sda.

    grub> geometry (hd0)
    drive 0x80: C/H/S = 38913/255/63, The number of sectors = 625142448, /dev/sda
    Partition num: 0, Filesystem type is ext2fs, partition type 0x83
    Partition num: 2, Filesystem type is ext2fs, partition type 0x83
    Partition num: 3, Filesystem type is ext2fs, partition type 0x83
    Partition num: 4, Filesystem type unknown, partition type 0x82
    Partition num: 5, Filesystem type unknown, partition type 0x82

    grub> geometry (hd1)
    drive 0x81: C/H/S = 2434/255/63, The number of sectors = 39102336, /dev/sdb
    Partition num: 0, Filesystem type is ext2fs, partition type 0x83
    Partition num: 2, Filesystem type is ext2fs, partition type 0x83
    Partition num: 4, Filesystem type unknown, partition type 0x82
    Partition num: 5, Filesystem type unknown, partition type 0x82

    I think you want me to "hide" the partitions on the 320 gig, not the 20 gig. Please remember, my BIOS/Motherboard allows me to set the PRIORITY of the boot disk. I can make sda the equivalent of slave on the cable. I can make sdb the equivalent of master on the cable.

    Having convinced myself, after, triple reading your first response to me, I am going back into the grub on the 320 gig and "hiding" the partitions. I will let all reading this know what happens after that. But it is much harder to follow directions, when "zeros" become "ones" and "a" becomes "b".

    After following the grub command hide (hd1,1) grub returned:

    grub> geometry (hd0)
    drive 0x80: C/H/S = 38913/255/63, The number of sectors = 625142448, /dev/sda
    Partition num: 0, Filesystem type is ext2fs, partition type 0x83
    Partition num: 2, Filesystem type is ext2fs, partition type 0x83
    Partition num: 4, Filesystem type unknown, partition type 0x82
    Partition num: 5, Filesystem type unknown, partition type 0x82

    grub> geometry (hd1)
    drive 0x81: C/H/S = 2434/255/63, The number of sectors = 39102336, /dev/sdb
    Partition num: 0, Filesystem type is ext2fs, partition type 0x83
    Partition num: 1, Filesystem type unknown, partition type 0x15
    Partition num: 2, Filesystem type is ext2fs, partition type 0x83

    So I guess I should have made the command: grub hide (hd0,1).

    Inside GParted shows a confusing picture. (see attached screenshot)

    In the screenshot: /dev/sda2 (an active partition) shows 280Gib allocated and an unallocated 279Gib at the end. This can't be the desired results. Additionally, I cannot move the sda2 or sda3 at all. I tried reallocating the unused space, but got too confused.

    I went back to grub and did grub hide (hd0,1) instead of hd1,1. GParted then showed only 2 partitions and NO swap. I'm really lost and am wondering if you could talk a little about the "more elegant solutions". I'm finding myself attracted to simpler methods of fixing this.

    By the way: you mention the "oddness" of the partitions being in (I think) numeric order. The original partitions on the 20 gig were created during my using Synpatic to upgrade the Feisty (v. 7.04) to Gutsy (v. 7.10). Whatever did the upgrade did it without my doing any partitioning work. What I had never seen before was a 2.0 gig partition that seemed to have no reason to be there.
    Attached Images Attached Images
    Last edited by Mark_in_Hollywo; 11-30-2007 at 01:54 PM. Reason: add screenshots

  15. #45
    Join Date
    Jun 2004
    Location
    Newcastle upon Tyne
    Posts
    2,978
    Mark_in_Hollywo,

    OK. I have finished my Far East holiday and can answer your post.

    Your extended partition behaves slightly different to my prediction. This is possibly due to the way you created it as the extended partition can have one partition type. By hiding it the partition type just has "1" added to the type number and this should show up in the "fdisk -l" command in root console.

    Can you list the "fdisk -l" output (in root console) before and after hiding sda1?

    I have moved an extended partition "bodily" this way before. It should be looked upon by Gaparted as just another primary partition of unknown filing type once the extended partition is hidden. I remember doing this for upgrading a 320Gb disk to a 500Gb disk and increase the Vista partition this way. After the extended partition has been moved I unhid it and had to restore the boot loader for every distro in the 59 logical partitions inside (a Pata disk was permitted to have 63 partitions in Kernel older than 2.6.20). This is because once the extended partition has been moved "bodily" the hard disk address of each boot loader will have been changed. In your case the boot loader is in sda1 so you should have no need to restore the boot loader.

    Thus I am surprised to see the hidden partition didn't show up in Gparted. Your output suggests that you may have "deleted" the two ligical partitions if you ended up with more hard disk space later.

    In this thread where I show how one can get 44 partitions out of a hard disk (post kernel 2.6.20) you can see that I have the extended partition in all sda1 to sda4 as type 5. At any time I unhide one so that the other 3 are typr "15" which is not recognised by Linux (hence the trick to get 4x11 partitions).
    Last edited by saikee; 12-03-2007 at 06:38 AM.
    Linux user started Jun 2004 - No. 361921
    Using a Linux live CD to clone XP
    To install Linux and keep Windows MBR untouched
    Adding extra Linux & Doing it in a lazy way
    A Grub menu booting 100+ systems & A "Howto" to install and boot 145 systems
    Just cloning tips Just booting tips A collection of booting tips

    Judge asked Linux "You are being charged murdering Windoze by stabbing its heart with a weapon, what was it?" Replied Linux "A Live CD"

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •