Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
migrating from x86 to x86_64 using LiveCD and chroot
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Duplicate Threads
View previous topic :: View next topic  
Author Message
ferg
Guru
Guru


Joined: 15 Nov 2002
Posts: 536
Location: Cambridge, UK

PostPosted: Wed Jun 27, 2007 12:18 pm    Post subject: migrating from x86 to x86_64 using LiveCD and chroot Reply with quote

Hi all,

I've recently upgraded my motherboard and CPUs to a Nocona EM64T board with 6Gb Ram.

I know it's impossible to migrate to x86_64 using a live system, but I'm looking into the possibilities of booting from the appropriate LiveCD, chroot'ing into my system, and migrating it from there. Has anybody done this succesfully?

A second related question is running a 32bit system with a 64bit kernel. Anybody done this? I saw this post about it from 2005. Has anything changed?

https://forums.gentoo.org/viewtopic-t-405255-highlight-profile+em64t.html?sid=95320fd3b7d3c5ceb4849a9972330ead

If I could boot from a 64 bit kernel, then I could copy my live filesystem to another partition and then create a chroot of this. Then I think I could gradually migrate this to 64bit? Feasible or am I talking gibberish?

Another stupider alternative is to install a new AMD64 bit Gentoo into a Chrooted filesystem (with 64 bit kernel). I could then do another chroot into a duplicate copy of my main filesystem, and compile all this for AMD64. so a 64 Chroot in a 64bit Chroot, running on a 32bit system, but running a 64bit kernel. wow!

I guess it might be quicker to start from scratch. However, I've had this system running since Dec 2002, and I'd hate to have to start from scratch again (yes I have lots of backups!!).

Cheers
Ferg
_________________
Climb up it, kayak down it + make sure it runs on GNU/Linux
"cease to exist, giving my goodbye, drive my car into the ocean,
you think I'm dead, but i sail away, on a wave of mutilation!"
Back to top
View user's profile Send private message
ferg
Guru
Guru


Joined: 15 Nov 2002
Posts: 536
Location: Cambridge, UK

PostPosted: Thu Jun 28, 2007 12:20 pm    Post subject: Using a 64bit kernel with a 32bit OS Reply with quote

Hi all,

is anybody running a 32bit system with a 64bit kernel. I saw this post about it from 2005. Has anything changed?

https://forums.gentoo.org/viewtopic-t-405255-highlight-profile+em64t.html?sid=95320fd3b7d3c5ceb4849a9972330ead

This is in part due to an idea I have about migrating to AMD64. If I could boot from a 64 bit kernel, then I could copy my live filesystem to another partition and then create a chroot of this. Then I think I could gradually migrate this to 64bit? (I posted this as part of another question I had earlier).

Cheers
Ferg
_________________
Climb up it, kayak down it + make sure it runs on GNU/Linux
"cease to exist, giving my goodbye, drive my car into the ocean,
you think I'm dead, but i sail away, on a wave of mutilation!"
Back to top
View user's profile Send private message
Rob1n
l33t
l33t


Joined: 29 Nov 2003
Posts: 714
Location: Cambridge, UK

PostPosted: Thu Jun 28, 2007 1:14 pm    Post subject: Reply with quote

I don't think you can combine things like that, no. However, the general idea works okay:

  • Boot from an x86-64 CD/DVD.
  • Copy the existing filesystem to another partition (you couldn't safely do this with a live filesystem anyway).
  • Install new x86-64 filesystem.
  • Mount the old filesystem, chroot & run any 32-bit apps needed.


This is the process I followed when I upgraded my system last year (after a hardware failure).
Back to top
View user's profile Send private message
ferg
Guru
Guru


Joined: 15 Nov 2002
Posts: 536
Location: Cambridge, UK

PostPosted: Thu Jun 28, 2007 1:30 pm    Post subject: Reply with quote

Hi,

thanks for responding. That sounds quite feasible.

Do you think I could install a real minimal system, and use this to recompile my chroot'ed old filesystem for x86_64?

Or perhaps I should just start from scratch. This system was first installed in dec 2002, and there must be a lot of crud left over in there!!

Cheers
Ferg
_________________
Climb up it, kayak down it + make sure it runs on GNU/Linux
"cease to exist, giving my goodbye, drive my car into the ocean,
you think I'm dead, but i sail away, on a wave of mutilation!"
Back to top
View user's profile Send private message
depontius
Advocate
Advocate


Joined: 05 May 2004
Posts: 3505

PostPosted: Thu Jun 28, 2007 1:57 pm    Post subject: Reply with quote

I ran a mostly-32-bit userspace on a 64-bit kernel for a while. What I really did was run a 32-bit chrooted xdm. So all of my init services were 64-bit, but I tweaked the xdm script so that under direction a flag in /etc/conf.d/xdm it could either start in 64-bit or linux32/chroot into 32-bit. That way users' sessions would be entirely 32-bit.

I did this to get around the numerous 32/64-bit problems when my wife was trying to view web content.

Then a while back, there was some sort of update to xdm, and I lost my changes. The scripts were different enough that it wasn't straightforward to port my old fixes forward, so for the time being I left xdm and users' sessions running 64-bit. Nobody complained, and in fact it appears that other updates to 64-bit userspace while we were running 32-bit userspace took care of most of our problems.

So today we're still running 64-bit xdm and userspace.
_________________
.sigs waste space and bandwidth
Back to top
View user's profile Send private message
Rob1n
l33t
l33t


Joined: 29 Nov 2003
Posts: 714
Location: Cambridge, UK

PostPosted: Thu Jun 28, 2007 2:01 pm    Post subject: Reply with quote

I'd recommend starting from scratch, otherwise you'll have to go through everything afterwards and make sure there's no stray 32-bit applications/libraries left. There's also some data files (e.g. database files) that I wouldn't count on being compatible between 32-bit and 64-bit versions.

You can use the old /var/lib/portage/world as a starting point but you may well find some of the applications aren't classed as stable on x86_64. In this case you'll have to either unmask these or look for alternatives.

Once you've got everything reinstalled then you can look at comparing config/data directories (most of these should be just a case of copying the old files back over), leaving the old filesystems around until you're happy everything's transferred okay.
Back to top
View user's profile Send private message
nixnut
Bodhisattva
Bodhisattva


Joined: 09 Apr 2004
Posts: 10974
Location: the dutch mountains

PostPosted: Thu Jun 28, 2007 6:13 pm    Post subject: Reply with quote

Moved from Installing Gentoo to Duplicate Threads.
See https://forums.gentoo.org/viewtopic-p-4069925.html#4069925 for some answers.
_________________
Please add [solved] to the initial post's subject line if you feel your problem is resolved. Help answer the unanswered

talk is cheap. supply exceeds demand
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Duplicate Threads All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum