Installing OS on SSD from HDD

Started Dec 1, 2012 | Discussions thread
abelits
Contributing MemberPosts: 677Gear list
Like?
Re: Installing OS on SSD from HDD
In reply to indusphoto, Dec 17, 2012

I have just converted my Thinkpad X220 from using its original hard drive (Hitachi, 320G) to SSD (Intel 330 Series, 240G). The most problematic part was that Lenovo for some reason insisted on using 7mm drives on rails, and this is a 9.5mm drive (as high as rails would be), so I had to remove the keyboard and palm rest to push the drive into the cage past the bumps at the opening (and have the option to push it out if necessary), then close the case before I could do anything with software.

Since I am running Kubuntu, OS and data transfer between drives was very uneventful, I have attached the original drive through USB to SATA adapter, and external USB CD drive with bootable Kubuntu CD, booted from the CD, ran fdisk to create the partition table on the SSD (it is smaller than the original drive), created file system and swap space, mounted SSD with "discard" option (so TRIM will be issued), mounted the original drive, and copied everything with "cp -a".

Once the new drive was ready, I have updated /etc/fstab entries on it with UUIDs taken from "blkid" output and modified mount options to include "discard", mounted /sys, /proc and /dev with "bind" option (from the original locations on ramdisk to their counterparts on SSD), and entered chroot'ed environment on SSD. From that environment I re-generated initial ramdisk files and GRUB configuration, and installed GRUB, then exited from chroot, unmounted everything, halted the system and removed all external devices.

When I turned the laptop on again, it booted from SSD to the exact copy of my original environment. Boot now takes 6 seconds after BIOS POST completes.

 abelits's gear list:abelits's gear list
Fujifilm X-Pro1 Fujifilm XF 35mm F1.4 R Fujifilm XF 14mm F2.8 R Fujifilm XF 55-200mm F3.5-4.8 R LM OIS Epson Stylus Photo R3000 +10 more
Reply   Reply with quote   Complain
Post (hide subjects)Posted by
Keyboard shortcuts:
FForum PPrevious NNext WNext unread UUpvote SSubscribe RReply QQuote BBookmark post MMy threads
Color scheme? Blue / Yellow