Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
yet another 'moving gentoo to a bigger hd' :/
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
veal
n00b
n00b


Joined: 08 May 2003
Posts: 47

PostPosted: Thu Mar 04, 2004 7:58 pm    Post subject: yet another 'moving gentoo to a bigger hd' :/ Reply with quote

hi.
i've read (several times) all the other threads i found about this topic. but i can't yet get it to work.

my old configuration is:
Code:
/dev/hdf1 -> /boot
/dev/hdf2 -> swap
/dev/hdf3 -> /root


the new one should look like:
Code:
/dev/hdf1 -> /boot (note: the /boot stays the same :p)
/dev/hdg2 -> swap
/dev/hdg3 -> /home
/dev/hdg4 -> /


i moved the files successfully to my new harddisc. that's the way i did it:

* booted my old disk
* mounted /dev/hdg4 to /newdisk && mkdir /newdisk/home
* mounted /dev/hdg3 to /newdisk/home
* created the filesystems (reiserfs)
* copied the files
Code:
cp -a /bin /dev /etc /home /lib /mnt /opt /root /sbin /tmp /usr /var /newdisk

(my first attempt was
Code:
cp -ax / /newdisk
but /dev didn't get copied)
* modified /newdisk/fstab to mount the new stuff
* modified /boot/grub/grub.conf, i.e. changed root=/dev/hdf3 to root=/dev/hdg4

it boots, i can start X. i got a 'unable to find a PTY' if i tried to open more than one Eterm or if i wanted to 'screen'. after some research i found out the problem was the dev filesystem wasn't mounted.

this already looks weird to me because i use the same kernel as with my old disk and it works fine there. (devfs *is* included in the kernel config). nevertheless i tried manually:
Code:
devfsd /dev
and it complains about not being able to find .devfsd

but this device (?) exists in (/newdisk)/dev/.devfsd.

im pretty much clueless at the moment about what i could do now, any help is appreciated.

/veal
Back to top
View user's profile Send private message
adaptr
Watchman
Watchman


Joined: 06 Oct 2002
Posts: 6730
Location: Rotterdam, Netherlands

PostPosted: Thu Mar 04, 2004 8:31 pm    Post subject: Re: yet another 'moving gentoo to a bigger hd' :/ Reply with quote

veal wrote:
hi.
i* mounted /dev/hdg4 to /newdisk && mkdir /newdisk/home

Not necessary - it already exists on the old one.

veal wrote:
* mounted /dev/hdg3 to /newdisk/home

Not the best order - first copy /root dir, then the rest.
But it should work, all the same.

veal wrote:
* created the filesystems (reiserfs)

Impossible - you couldn't have mounted them without a valid filesystem!

veal wrote:
* copied the files
Code:
cp -a /bin /dev /etc /home /lib /mnt /opt /root /sbin /tmp /usr /var /newdisk

Ridiculous - see here:
Code:
cp -ax /* /newdisk/


veal wrote:
(my first attempt was
Code:
cp -ax / /newdisk
but /dev didn't get copied)

That's because if you use devFS it isn't part of the "normal" filesystem.
Just make a new one.

veal wrote:
* modified /newdisk/fstab to mount the new stuff
* modified /boot/grub/grub.conf, i.e. changed root=/dev/hdf3 to root=/dev/hdg4

As long as you're sure that's all you changed...

veal wrote:
it boots, i can start X. i got a 'unable to find a PTY' if i tried to open more than one Eterm or if i wanted to 'screen'. after some research i found out the problem was the dev filesystem wasn't mounted.

this already looks weird to me because i use the same kernel as with my old disk and it works fine there. (devfs *is* included in the kernel config). nevertheless i tried manually:
Code:
devfsd /dev
and it complains about not being able to find .devfsd

but this device (?) exists in (/newdisk)/dev/.devfsd.

Do you have devpts support in the kernel ?
It can use either devpts or the hardlinked pty's, but since your /dev seems a bit screwy, devpts is needed to make it work if the entries aren't there.
_________________
>>> emerge (3 of 7) mcse/70-293 to /
Essential tools: gentoolkit eix profuse screen
Back to top
View user's profile Send private message
veal
n00b
n00b


Joined: 08 May 2003
Posts: 47

PostPosted: Thu Mar 04, 2004 8:44 pm    Post subject: Re: yet another 'moving gentoo to a bigger hd' :/ Reply with quote

adaptr wrote:
Impossible - you couldn't have mounted them without a valid filesystem!

oops, right, the order was the other way around.

adaptr wrote:
Do you have devpts support in the kernel ?
It can use either devpts or the hardlinked pty's, but since your /dev seems a bit screwy, devpts is needed to make it work if the entries aren't there.

/dev/pts file system for Unix98 PTYs isn't checked (i assume this isn't the one you are talking about but i cannot find another entry in 'make menuconfig')

how do I check if devpts support is there?

jfyi, /newdisk/dev/pts contains 0 / 1 / 2 / 3
Back to top
View user's profile Send private message
adaptr
Watchman
Watchman


Joined: 06 Oct 2002
Posts: 6730
Location: Rotterdam, Netherlands

PostPosted: Thu Mar 04, 2004 8:49 pm    Post subject: Reply with quote

Code:
grep CONFIG_DEVPTS_FS /usr/src/linux/.config

Will tell you whether it's compiled in or not.
_________________
>>> emerge (3 of 7) mcse/70-293 to /
Essential tools: gentoolkit eix profuse screen
Back to top
View user's profile Send private message
veal
n00b
n00b


Joined: 08 May 2003
Posts: 47

PostPosted: Thu Mar 04, 2004 8:52 pm    Post subject: Reply with quote

Code:
is not set

*compiling*

[e] w00h \o/ it works now, thanks a lot!
[e2] oops, this was too early.. i can start several Eterm's (up to 4) and screen doesn't work :x

mount doesn't show any /dev mounted and devfsd /dev still not finding .devfsd :|

should i delete the contents of /dev ? will they be recreated ?
Back to top
View user's profile Send private message
adaptr
Watchman
Watchman


Joined: 06 Oct 2002
Posts: 6730
Location: Rotterdam, Netherlands

PostPosted: Thu Mar 04, 2004 9:17 pm    Post subject: Reply with quote

They should be, yes - but it would be safest to make a backup, or take some other precaution.
The bootloader has been known to b0rk because of it, since devfs assigns other ide identifiers - /host/bus/target/lun, like scsi.
If you installed this way then the regular /dev/hdxy links would be made to the /ide structure, but if you cut it out after installation I wouldn't hazard any guesses...

Easiest would be to boot a liveCD, mount the root partition somewhere, and
Code:
mv /mnt/gentoo/dev /mnt/gentoo/dev.old
mkdir /mnt/gentoo/dev

and reboot...
That way you can fix things easily when it b0rks.
_________________
>>> emerge (3 of 7) mcse/70-293 to /
Essential tools: gentoolkit eix profuse screen
Back to top
View user's profile Send private message
veal
n00b
n00b


Joined: 08 May 2003
Posts: 47

PostPosted: Thu Mar 04, 2004 9:35 pm    Post subject: Reply with quote

Code:
Warning: Unable to open an initial console
and it reboots automatically.

when i emptied the /dev on the newdisk as you said and reboot.

it's strange, shouldn't it just work if i do a 'cp -a /dev /newdisk/' ? (as I did previously)
Back to top
View user's profile Send private message
adaptr
Watchman
Watchman


Joined: 06 Oct 2002
Posts: 6730
Location: Rotterdam, Netherlands

PostPosted: Thu Mar 04, 2004 9:43 pm    Post subject: Reply with quote

No, you always have to specify which files - otherwise it will create a dev directory inside the new /dev directory - which wouldn't work ;-)
Instead of
Code:
cp -ax /dev /newdisk/dev

do a
Code:
cp -ax /dev/* /newdisk/dev

_________________
>>> emerge (3 of 7) mcse/70-293 to /
Essential tools: gentoolkit eix profuse screen
Back to top
View user's profile Send private message
veal
n00b
n00b


Joined: 08 May 2003
Posts: 47

PostPosted: Thu Mar 04, 2004 10:00 pm    Post subject: Reply with quote

err, i guess i did that right (the files have been correctly at the target) just wrote it wrong, thx anyway :) (edited it)

but what do I do now? :)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo 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