LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 12-19-2016, 11:15 PM   #1
edencorbin
LQ Newbie
 
Registered: Feb 2016
Posts: 26

Rep: Reputation: Disabled
Smile Move a Linux install on a hard drive to a new computer.


I just recently decided to move a hard drive from one computer to another. It happened to have an install of Linux Mint on it. To my surprise it booted up and ran fine on the new computer (both intel i3-i7 but otherwise entirely different hardware. I have a few questions around this. Are there many hardware specific driver/software installations that happens during a fresh install? I would think that would be yes, and things like web-cams/maybe ports/etc. B) if there are installation specific items can they be mitigated in any bulk way, IE system-wide recheck hardware. Or would the process be more of a see what works and what doesn't and look for drivers for whatever fails after the move? Lastly, it is it just a bad idea, and a clean install is the way to go?
 
Old 12-20-2016, 04:35 AM   #2
fatmac
LQ Guru
 
Registered: Sep 2011
Location: Upper Hale, Surrey/Hants Border, UK
Distribution: Mainly Devuan, antiX, & Void, with Tiny Core, Fatdog, & BSD thrown in.
Posts: 5,493

Rep: Reputation: Disabled
When the kernel boots it looks at what hardware is on the computer & loads drivers for it, as long as the drivers are on the system, that's why you could just move your disk to another computer.
 
Old 12-20-2016, 05:02 AM   #3
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,128

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
Nope. All the drivers have to be available.
Usually the initrd does that for you in a built system. During install that is all sorted - do a clean install to be sure.
 
Old 12-20-2016, 08:02 AM   #4
RockDoctor
Senior Member
 
Registered: Nov 2003
Location: Minnesota, US
Distribution: Fedora, Ubuntu, Manjaro
Posts: 1,791

Rep: Reputation: 427Reputation: 427Reputation: 427Reputation: 427Reputation: 427
When I move a hard drive from one box to another, I generally rebuild the initrd. It's worked for me; YMMV
 
Old 12-20-2016, 02:58 PM   #5
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,982

Rep: Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626Reputation: 3626
At one time linux wouldn't easily move.
Then they got it to move on almost every common hardware type.
Then they messed it up again so your mileage will vary.

Things that don't move easily or correctly are network cards, video cards.

Last edited by jefro; 12-20-2016 at 05:29 PM.
 
Old 12-20-2016, 05:09 PM   #6
sundialsvcs
LQ Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 10,659
Blog Entries: 4

Rep: Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941
To clarify ...

initrd refers to "initial RAM-disk." This is a ridiculous wedge very-sophisticated technology that is intended to allow "any Linux distro" to successfully boot on any hitherto-unanticipated piece of hardware upon which it might someday find itself."

What happens (and, yes, you can entirely omit this step if you are building your kernel from scratch ...) is that, after completing bare-minimum kernel initialization, the kernel mounts a RAM-disk containing a stripped-down shell and a set of scripts. The purpose of these scripts is to perform hardware detection and to insmod the loadable kernel modules that are necessary to keep going. When these shell-scripts exit, system initialization proceeds, fully expecting that the necessary hardware-support layers now magically exist.

(You say that your machine has a DECSystem token-ring network card? Cool. At least as of a half-dozen years ago, "Red Hat has you covered ...")

(Bonus points if you're old enough to have heard of "token ring." Double points if you've actually seen an office network made from coax. *koff, koff ...*)

Because of this technology, it is entirely feasible that your "old" Linux system will find that it is able to successfully boot on an entirely new box.

Last edited by sundialsvcs; 12-20-2016 at 05:12 PM.
 
1 members found this post helpful.
Old 12-25-2016, 07:15 AM   #7
replica9000
Senior Member
 
Registered: Jul 2006
Distribution: Debian Unstable
Posts: 1,126
Blog Entries: 2

Rep: Reputation: 260Reputation: 260Reputation: 260
One of my installs in on it's 4th set of hardware. Usually, the only changes needed are UUIDs if mount points have changed, and MAC addresses.
 
Old 12-30-2016, 12:03 AM   #8
zpimp
Member
 
Registered: Oct 2014
Posts: 73

Rep: Reputation: Disabled
my experience comes from testing not reading

my first testing with moving a linux install to new hardware was about 2 years ago when testing a friends broken ssd
installed linux on the ssd on my hardware then put it in about 6 other pcs/laptops just to test and it would work fine it was antix 13 i think


another time i installed antix15 on a core2duo system then moved the hdd to an athlon xp box, it would freeze, and not boot

i installed normally on the athlon box and now it works fine

in conclusion, although superior to other oses, if you need a quick boot to another hardware it would probably work
but if you want stability and dont know what you are doing, what to rebuild, like i did, i would reccommend reinstalling clean
 
Old 12-30-2016, 01:58 AM   #9
hazel
LQ Guru
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: LFS, AntiX, Slackware
Posts: 7,574
Blog Entries: 19

Rep: Reputation: 4452Reputation: 4452Reputation: 4452Reputation: 4452Reputation: 4452Reputation: 4452Reputation: 4452Reputation: 4452Reputation: 4452Reputation: 4452Reputation: 4452
My first computer contained a hard drive on which a friend had installed Red Hat 6 (original Red Hat, not RHEL) on his own computer. I couldn't get it to boot initially, partly because my friend had subsequently rearranged the partitions to include Windows 98 as well (Windows booted normally). Then, for good measure, he forgot the root password he had set for me. I had a rescue floppy that was supposed to boot Linux, but it didn't work because of the repartitioning. I had to use a Knoppix disc to change the root password, then change the root device. When I finally got it to boot, I noticed that the Red Hat hardware wizard (I think it was called Kudzu) was complaining about all kinds of changes. In the end, though, everything worked.

I was very impressed that I was able to fix Linux even though I knew so little about it. I thought that constituted real user-friendliness. If Windows won't boot, then it won't boot and that's the end of it. You have to reinstall it.

More recently I used a cloned AntiX to bring another old computer to life. Everything worked except the network card. It turned out that this had been named eth1 instead of eth0, so of course the scripts didn't work initially. This was in the early days of persistent network names; they still had the traditional form (eth, wlan) but the numbers were assigned by bus geometry. Again, it was easily fixed.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] can I suspend-to-disk and then move the hard drive to another computer? newbiesforever Linux - General 4 12-07-2015 04:01 PM
Can I install Ubuntu onto an exterior hard drive to install into another computer? oovee Linux - Newbie 6 09-10-2013 07:38 PM
load Linux onto a hard drive on one computer then move the hard drive to another Ark9 Linux - Newbie 2 10-06-2008 06:56 PM
can i move my hard drive to a different computer citrus Linux - General 5 04-12-2004 03:30 AM
Can I move my linux installation to another Hard Drive? enderjm Linux - Newbie 7 03-11-2004 02:00 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 09:34 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration