Moving SLED 11 SP1 from primary to extended partition

Hello.

My ProBook 4530s has one 500GB hard disk with 4 primary partitions:
root (Ext3-20GB), recovery (Ext2-3GB), HP_Tools (FAT32 LBA-2GB) and
extended with swap (6GB) and home (Ext3).
I want to move SLED from the first primary partition to a logical
partition so I can change sda1(Ext3) to NTFS and install Win7,
dual-booting both OS

How do I do the moving? If that’s possible.

-I don’t have a SLED CD/DVD, the OS installs from recovery partition
wiping everything in the way.-

It’s not my intention to install Win7 in VM or delete/move the recovery
or HP_Tools partitions.


iani2004

iani2004’s Profile: http://forums.novell.com/member.php?userid=122633
View this thread: http://forums.novell.com/showthread.php?t=450761

On Sun, 15 Jan 2012 10:46:01 GMT
iani2004 iani2004@no-mx.forums.novell.com wrote:
[color=blue]

Hello.

My ProBook 4530s has one 500GB hard disk with 4 primary partitions:
root (Ext3-20GB), recovery (Ext2-3GB), HP_Tools (FAT32 LBA-2GB) and
extended with swap (6GB) and home (Ext3).
I want to move SLED from the first primary partition to a logical
partition so I can change sda1(Ext3) to NTFS and install Win7,
dual-booting both OS

How do I do the moving? If that’s possible.

-I don’t have a SLED CD/DVD, the OS installs from recovery partition
wiping everything in the way.-

It’s not my intention to install Win7 in VM or delete/move the
recovery or HP_Tools partitions.

[/color]
Hi
Windows 7 needs two (2) primary partitions, a 100MB one and then it’s
primary partition >= 20GB.

Do you have access to an external drive?


Cheers Malcolm °¿° (Linux Counter #276890)
openSUSE 12.1 (x86_64) Kernel 3.1.0-1.2-desktop
up 2 days 19:49, 4 users, load average: 0.00, 0.01, 0.09
CPU Intel i5 CPU M520@2.40GHz | Intel Arrandale GPU

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

windows breaks the boot loader anyway so after you finish installing it
on the main system you’ll be at least going through a recovery to fix
the boot loader to work again; may just be easier to reinstall the box,
first with windows leaving space for Linux, and then adding Linux to
handle booting of both OS’s as it will do properly by default.

Good luck.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.15 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQIcBAEBAgAGBQJPEuVcAAoJEF+XTK08PnB5WocQAJZmfSzuScn+3bolfuJFhGkv
5K+DVXN2CR4KianinU6Mo2tAZuF+Notf6GY3bEOQQIIC/tro67w7bthk8Cu8SjeS
nkZEHwo9t5qvdGQZjq4T8pseA/yg2bAzK5DEyyjf3BRvC9Fl/N+J1dJR7Ok1/cL/
YDBSm8YGigzJuLhVvPuBBZDF5aUlhxz1Cd4+4Z6/oK2n7ipJ9p0qgqDsl0SJkyxB
bG6m9gUKVwLHIDsiqKT4WQ+AJ74URuF69mOOzg1d0Almrb0DQVkOvcExPP5oEw9O
ket4fzepAR0oMfqErGM5jJMqXg08MacSLYfE1gC4u0uz257HzcNpYMs4DI019gza
Bu1d1NWbQnxklxDoFF//7WawiwzXTTl+m2yPIAWh1XVmDZuGVyfkPUFjIKvrdQEj
jWcJSVMuzEF3j2JdXBh5ESKQM4N/UDEnySJM5P5ObBlQr7aRTB0HysIjGwAuRRkw
2I9vXNgV5chkkSUIqKMWg5sLItYokovk5kBNvdLB3nKnjO6B0Lv1pFyXYUUA3tsQ
tWAlyZW9sKr/P3U86FkSpaEocyzMSWJnCDWYepFyDnGya+oUuZJ6f6m46tppya5E
KbDYrCaFZU0JUZfEgaeRdyxACjerD1b6uTamJ6MQbTSQNEK7Z+pmMytwduaSxdHl
Ng4DD0Sy/0n5CeYGt4r4
=GQf6
-----END PGP SIGNATURE-----

malcolmlewis;2167936 Wrote:[color=blue]

On Sun, 15 Jan 2012 10:46:01 GMT
Windows 7 needs two (2) primary partitions, a 100MB one and then it’s
primary partition >= 20GB.

Do you have access to an external drive?
[/color]

My old one died (-WD My Book Essential Ed. 500GB-) and I didn’t replace
it, but here’s just the right time to do it.
Any suggestions so I don’t buy one that will create more problems?


iani2004

iani2004’s Profile: http://forums.novell.com/member.php?userid=122633
View this thread: http://forums.novell.com/showthread.php?t=450761

On Sun, 15 Jan 2012 17:06:01 GMT
iani2004 iani2004@no-mx.forums.novell.com wrote:
[color=blue]

malcolmlewis;2167936 Wrote:[color=green]

On Sun, 15 Jan 2012 10:46:01 GMT
Windows 7 needs two (2) primary partitions, a 100MB one and then
it’s primary partition >= 20GB.

Do you have access to an external drive?
[/color]

My old one died (-WD My Book Essential Ed. 500GB-) and I didn’t
replace it, but here’s just the right time to do it.
Any suggestions so I don’t buy one that will create more problems?

[/color]
Well are you happy removing the drive in the notebook and replacing it?
Or prefer to do something external?

Can you post the output from;

fdisk -l

Also can you check you BIOS settings, are you booting legacy or UEFI?


Cheers Malcolm °¿° (Linux Counter #276890)
openSUSE 12.1 (x86_64) Kernel 3.1.0-1.2-desktop
up 2 days 22:59, 4 users, load average: 0.14, 0.11, 0.08
CPU Intel i5 CPU M520@2.40GHz | Intel Arrandale GPU

[color=blue]

-Well are you happy removing the drive in the notebook and replacing[/color]
it? Or prefer to do something external?-

Right now I wonder if I can remove and replace the drive. That’s my
first notebook.

[color=blue]

-Can you post the output from fdisk -l-[/color]

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xf7c4b322

…Device.Boot…Start…End…Blocks…Id…System
/dev/sda1…*…1…2612…20980858…83…Linux
/dev/sda2…2613…3003…3140705+…83…Linux
/dev/sda3…3004…3258…2048000+…c…W95.FAT32.(LBA)
/dev/sda4…3258…60801…462214428+…f…W95.Ext’d.(LBA)
/dev/sda5…3258…4007…6011904+…82…Linux.swap./.Solaris
/dev/sda6…4007…60801…456201944…83…Linux

[color=blue]

-Also can you check you BIOS settings, are you booting legacy or[/color]
UEFI?-

Legacy Boot Order is in black, while UEFI Boot Order is in gray, and
checking “enables UEFI boot capability” option gives the warning:
-The “UEFI Boot Option” on this system is provided for development
purposes only and is currently NOT fully supported or warranted by HP.-
So I guess I’m booting legacy.


iani2004

iani2004’s Profile: http://forums.novell.com/member.php?userid=122633
View this thread: http://forums.novell.com/showthread.php?t=450761

On Mon, 16 Jan 2012 02:26:02 GMT
iani2004 iani2004@no-mx.forums.novell.com wrote:
[color=blue]

[color=green]

-Well are you happy removing the drive in the notebook and replacing[/color]
it? Or prefer to do something external?-

Right now I wonder if I can remove and replace the drive. That’s my
first notebook.

[color=green]

-Can you post the output from fdisk -l-[/color]

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xf7c4b322

…Device.Boot…Start…End…Blocks…Id…System
/dev/sda1…*…1…2612…20980858…83…Linux
/dev/sda2…2613…3003…3140705+…83…Linux
/dev/sda3…3004…3258…2048000+…c…W95.FAT32.(LBA)
/dev/sda4…3258…60801…462214428+…f…W95.Ext’d.(LBA)
/dev/sda5…3258…4007…6011904+…82…Linux.swap./.Solaris
/dev/sda6…4007…60801…456201944…83…Linux

[color=green]

-Also can you check you BIOS settings, are you booting legacy or[/color]
UEFI?-

Legacy Boot Order is in black, while UEFI Boot Order is in gray, and
checking “enables UEFI boot capability” option gives the warning:
-The “UEFI Boot Option” on this system is provided for
development purposes only and is currently NOT fully supported or
warranted by HP.- So I guess I’m booting legacy.

[/color]
Hi
OK, well that’s cool that it’s legacy…no worries but pays to check.

If you turn the system over there should be a panel to remove via a few
screws, unscrew and securing screws for the HDD, slide out and remove
the four (4) screws holding the drive into the caddy and insert the new
drive, boot and install windows.

You would then need to look at using parted to shrink the
windows partition, creating an extended partition, creating the
partitons the same block size as SLED and using dd to copy the data
back. The biggest bit would be re-creating grub to get the system
booting.

Run the command;

/usr/sbin/hwinfo --disk |grep Model

Should tell you the model, else the BIOS should have the information as
well. Just make sure you check the drive specifications for power are
the same as the drive that’s in the system.

I have been looking at the SEGATE hybrid drives which cache common
information for faster boot etc, but look at the reviews first.

To be honest, I would follow Aaron’s advice you can download the DVD to
install SLED from Novell, the trick is your HP system has special
repositories but if you recover the system keys and copy the repository
list it should re-create fine.


Cheers Malcolm °¿° (Linux Counter #276890)
openSUSE 12.1 (x86_64) Kernel 3.1.0-1.2-desktop
up 3 days 8:12, 4 users, load average: 0.00, 0.01, 0.05
CPU Intel i5 CPU M520@2.40GHz | Intel Arrandale GPU

On Mon, 16 Jan 2012 03:12:08 GMT
malcolmlewis malcolmlewis@no-mx.forums.novell.com wrote:
[color=blue]

On Mon, 16 Jan 2012 02:26:02 GMT
iani2004 iani2004@no-mx.forums.novell.com wrote:
[color=green]

[color=darkred]

-Well are you happy removing the drive in the notebook and
replacing[/color]
it? Or prefer to do something external?-

Right now I wonder if I can remove and replace the drive. That’s my
first notebook.

[color=darkred]

-Can you post the output from fdisk -l-[/color]

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xf7c4b322

…Device.Boot…Start…End…Blocks…Id…System
/dev/sda1…*…1…2612…20980858…83…Linux
/dev/sda2…2613…3003…3140705+…83…Linux
/dev/sda3…3004…3258…2048000+…c…W95.FAT32.(LBA)
/dev/sda4…3258…60801…462214428+…f…W95.Ext’d.(LBA)
/dev/sda5…3258…4007…6011904+…82…Linux.swap./.Solaris
/dev/sda6…4007…60801…456201944…83…Linux

[color=darkred]

-Also can you check you BIOS settings, are you booting legacy or[/color]
UEFI?-

Legacy Boot Order is in black, while UEFI Boot Order is in gray, and
checking “enables UEFI boot capability” option gives the warning:
-The “UEFI Boot Option” on this system is provided for
development purposes only and is currently NOT fully supported or
warranted by HP.- So I guess I’m booting legacy.

[/color]
Hi
OK, well that’s cool that it’s legacy…no worries but pays to check.

If you turn the system over there should be a panel to remove via a
few screws, unscrew and securing screws for the HDD, slide out and
remove the four (4) screws holding the drive into the caddy and
insert the new drive, boot and install windows.

You would then need to look at using parted to shrink the
windows partition, creating an extended partition, creating the
partitons the same block size as SLED and using dd to copy the data
back. The biggest bit would be re-creating grub to get the system
booting.

Run the command;

/usr/sbin/hwinfo --disk |grep Model

Should tell you the model, else the BIOS should have the information
as well. Just make sure you check the drive specifications for power
are the same as the drive that’s in the system.

I have been looking at the SEGATE hybrid drives which cache common
information for faster boot etc, but look at the reviews first.

To be honest, I would follow Aaron’s advice you can download the DVD
to install SLED from Novell, the trick is your HP system has special
repositories but if you recover the system keys and copy the
repository list it should re-create fine.
[/color]
Hi
Also I’m assuming the caddy device you have takes a 2.5" drive (I
didn’t check) else you would need a 2.5" USB enclosure to contain the
spare drive…


Cheers Malcolm °¿° (Linux Counter #276890)
openSUSE 12.1 (x86_64) Kernel 3.1.0-1.2-desktop
up 3 days 8:50, 4 users, load average: 0.00, 0.01, 0.05
CPU Intel i5 CPU M520@2.40GHz | Intel Arrandale GPU

I need a little more details about what will happen after installing
Windows. I can’t see those steps.

The drive inside the notebook is a Toshiba-MK5061GS.

Why the restoring of Grub is tricky? I was really thinking that it only
needed a LiveCD, executing grub, root, setup and that’s all.

I have an Win7 OEM CD with s/n. I don’t fully understand the
implications. Since I’ve mentioned virtual machines, if I would have
installed it in VirtualBox for example, that won’t allow me to installl
it on another drive and vice-versa, right? I’m trying to sort things out
in my mind. :slight_smile:


iani2004

iani2004’s Profile: http://forums.novell.com/member.php?userid=122633
View this thread: http://forums.novell.com/showthread.php?t=450761

On Mon, 16 Jan 2012 05:16:02 GMT
iani2004 iani2004@no-mx.forums.novell.com wrote:
[color=blue]

I need a little more details about what will happen after installing
Windows. I can’t see those steps.[/color]
Windows will create two primary partitions one 100MB and the second the
rest of the drive. I think you can set the size of the partition though.
[color=blue]

The drive inside the notebook is a Toshiba-MK5061GS.

Why the restoring of Grub is tricky? I was really thinking that it
only needed a LiveCD, executing grub, root, setup and that’s all.
[/color]
Correct, but install it in the extended partition and chainload
windows. The only thing is getting the newer partitions of the same
block size to dd across for the OS.
[color=blue]
I have an Win7 OEM CD with s/n. I don’t fully understand the
implications. Since I’ve mentioned virtual machines, if I would have
installed it in VirtualBox for example, that won’t allow me to
installl it on another drive and vice-versa, right? I’m trying to
sort things out in my mind. :slight_smile:

[/color]
Hmmm probably won’t activate I guess. This DELL Latitude E5510 came
with windows 7 32 bit. I have it running fine in virtualbox and
activated (but I never use it… go figure). I just dual boot between
openSUSE and SLED 11.

I guess the question is what are you planning to run if you do a
physical install, I use MS Office 2003 on occasions and have it
installed with crossover pro without any issues. I also have Garmin
mapsource as well for my GPS and that’s it for windows software.


Cheers Malcolm °¿° (Linux Counter #276890)
openSUSE 12.1 (x86_64) Kernel 3.1.0-1.2-desktop
up 3 days 10:50, 5 users, load average: 0.02, 0.02, 0.05
CPU Intel i5 CPU M520@2.40GHz | Intel Arrandale GPU

-You’re really making me stay in SLED, use as little Win (in its little
virtual box) as possible, keep in mind CrossOver Pro for other stuff
like MS Office and learn Linux.- :slight_smile:

Please review:

  • replace hard drive with one that matches power specs, physical size
    and connectors
  • boot notebook from Win7 cd/dvd and install it. It will automatically
    create the 1st primary partition of 100 MB and the 2nd one with the rest
    GBs or custom size.
  • boot notebook from a LiveCD and shrink second partition using parted
    and create extended with 5 logical partitions of the same block size
    (any tips?) for “recovery”, “HP_TOOLS”, “swap”, “root” and something for
    “home”
  • duplicate the original data to those partitions using dd (connecting
    both hard drives…)


iani2004

iani2004’s Profile: http://forums.novell.com/member.php?userid=122633
View this thread: http://forums.novell.com/showthread.php?t=450761

On Tue, 17 Jan 2012 22:16:02 GMT
iani2004 iani2004@no-mx.forums.novell.com wrote:
[color=blue]

-You’re really making me stay in SLED, use as little Win (in its
little virtual box) as possible, keep in mind CrossOver Pro for other
stuff like MS Office and learn Linux.- :slight_smile:

Please review:

  • replace hard drive with one that matches power specs, physical size
    and connectors
  • boot notebook from Win7 cd/dvd and install it. It will automatically
    create the 1st primary partition of 100 MB and the 2nd one with the
    rest GBs or custom size.
  • boot notebook from a LiveCD and shrink second partition using parted
    and create extended with 5 logical partitions of the same block size
    (any tips?) for “recovery”, “HP_TOOLS”, “swap”, “root” and something
    for “home”[/color]

I would reboot into windows if you resize it so it sorts itself out for
the resized partition.
[color=blue]

  • duplicate the original data to those partitions using dd (connecting
    both hard drives…)
    …[/color]

I would look at getting a 4GB usb device to put the recovery image and
hp tools on as they are not likely to be used with the new setup?

So you only will need three in the extended partition. I would create
the / first then the /home to the same size, then again boot parted and
expand /home out to the max (since you don’t include hp tools and
recovery) less your swap then create the swap.

Now there are still some things that need to be adjusted after the
change before things will boot;

/boot/grub/menu.lst
/boot/grub/device.map
/etc/fstab

These need to be adjusted for the new drive.

You also need to ensure the linux partitions are set to the correct
file system types and also set the boot flag on the extended partition.


Cheers Malcolm °¿° (Linux Counter #276890)
openSUSE 12.1 (x86_64) Kernel 3.1.0-1.2-desktop
up 1 day 8:25, 6 users, load average: 0.01, 0.04, 0.12
CPU Intel i5 CPU M520@2.40GHz | Intel Arrandale GPU

malcolmlewis;2168630 Wrote:[color=blue]

[color=green]

[/color]
I would look at getting a 4GB usb device to put the recovery image and
hp tools on as they are not likely to be used with the new setup?
[/color]

And if I want back the things as they were when I bought the notebook,
all I have to do is put back the original hard drive that wasn’t
modified at all.
Nice solution. Thank you.

-Two more scenarios inside this thread-

A. If we ignore Win7 restrictions (those 2 primary partitions), moving
SLED from primary to extended would be like this?

  • resize “home”
  • create another logical partition for the root (same size or bigger)
  • dd files there
  • adjusting grub to the extended partition (menu.lst, device.map,
    fstab)
  • move the boot flag from the old root to the new one

B. I’ve read on the web that moving the “recovery” partition makes the
recovery option disappear from boot options, so on the new hard drive
“restore factory settings” and “HP Tools” wouldn’t be there.
Using dd to copy data from the “recovery” partition to a partition that
starts at the right point on another hard drive (probably the exact same
model and not the one with Win7&SLED) would do the trick?


iani2004

iani2004’s Profile: http://forums.novell.com/member.php?userid=122633
View this thread: http://forums.novell.com/showthread.php?t=450761

On Wed, 18 Jan 2012 00:46:01 GMT
iani2004 iani2004@no-mx.forums.novell.com wrote:
[color=blue]

malcolmlewis;2168630 Wrote:[color=green]

[color=darkred]

[/color]
I would look at getting a 4GB usb device to put the recovery image
and hp tools on as they are not likely to be used with the new
setup?
[/color]

And if I want back the things as they were when I bought the notebook,
all I have to do is put back the original hard drive that wasn’t
modified at all.
Nice solution. Thank you.

-Two more scenarios inside this thread-

A. If we ignore Win7 restrictions (those 2 primary partitions), moving
SLED from primary to extended would be like this?

  • resize “home”
  • create another logical partition for the root (same size or bigger)
  • dd files there
  • adjusting grub to the extended partition (menu.lst, device.map,
    fstab)
  • move the boot flag from the old root to the new one

B. I’ve read on the web that moving the “recovery” partition makes the
recovery option disappear from boot options, so on the new hard drive
“restore factory settings” and “HP Tools” wouldn’t be there.
Using dd to copy data from the “recovery” partition to a partition
that starts at the right point on another hard drive (probably the
exact same model and not the one with Win7&SLED) would do the trick?

[/color]
Hi
Correct, it’s just a matter of fixing the relevant entry in menu.lst
to point at the correct partition. That being said, the image
would be set to a standard configuration and expect the files on the old
partitions. You may be able to define how/what is restored, but I don’t
have access to a system to see what it would do.


Cheers Malcolm °¿° (Linux Counter #276890)
openSUSE 12.1 (x86_64) Kernel 3.1.0-1.2-desktop
up 1 day 11:02, 4 users, load average: 0.04, 0.06, 0.05
CPU Intel i5 CPU M520@2.40GHz | Intel Arrandale GPU