# Migrating from singlex86 to dual AMD (system now wont boot )

## Unclethommy

Hi there I have got my hands on an "old" dual CPU athlon MP system. I want to simply take out my old motherboard and attach all the necesary devices to the new motherboard. I have a read a few articles at the forum saying that all i need to change would be encorporating SMP into the kernel? I have tried to google for a wiki but have not found anything. I am going to hunt round for an option when I get home today, but I was wondering if anything else other than the obvious cflags and kernel modules need to be changed to get my computer to worth with its new "brains" ? 

is there any thing else i should try to make full use of the new dual cpu system? 

Any help would be greatly appreciated.Last edited by Unclethommy on Sun Apr 01, 2007 9:49 am; edited 1 time in total

----------

## neysx

Replace your motherboard and boot your Gentoo, then edit your kernel config:

```
cd /usr/src/linux

make menuconfig

Processor type and features  --->

[*] Symmetric multi-processing support

Processor family (Athlon/Duron/K7)

(2) Maximum number of CPUs (2-255)

Preemption Model (No Forced Preemption (Server))
```

and install and boot on your new kernel.

Then edit /etc/make.conf

```
CFLAGS='-march=athlon-mp -Os -pipe -fomit-frame-pointer'

MAKEOPTS="-j3"
```

That's all it takes.

FYI, I have been using one of those (Tyan 2462UNG, 2x AMD MP-2400, 1GB, SCSI disks) for 5 years and I hold on to it.

```
     Sat Jan 13 04:02:48 2007 >>> app-office/openoffice-2.1.0

       merge time: 3 hours, 34 minutes and 9 seconds.
```

Hth

----------

## Unclethommy

Wow, great, I'll let you know how I get on neysx  :Smile:  Thanks for the prompt reply  :Smile: 

If any one else has any hints to maximise the dual cpu please let me know.

Thanks again

----------

## marcossoft

 *Unclethommy wrote:*   

> Hi there I have got my hands on an "old" dual CPU athlon MP system. I want to simply take out my old motherboard and attach all the necesary devices to the new motherboard. I have a read a few articles at the forum saying that all i need to change would be encorporating SMP into the kernel? I have tried to google for a wiki but have not found anything. I am going to hunt round for an option when I get home today, but I was wondering if anything else other than the obvious cflags and kernel modules need to be changed to get my computer to worth with its new "brains" ? 
> 
> is there any thing else i should try to make full use of the new dual cpu system? 
> 
> Any help would be greatly appreciated.

 

Hi,

I never installed Gentoo on a dual processor box, but I remember that the file /etc/make.conf.example mentions something about the number of processors, look the snippet below.:

 *Quote:*   

> 
> 
> # Advanced Features
> 
> # =================
> ...

 

I "think" you should change the value of MAKEOPTS to "-j3" to comply with your 02 processors.

Your post is very interesting for me too, because I'm considering to upgrade my box to a core duo system.

Hope it helps

Marcos

----------

## barrison

Like it was said before, make sure you have SMP in your new kernel to gain access to your multiple processors.  Adding the -j3 into /etc/make.conf will allow you to to use them when building through portage.  Finally make sure the architecture is correct in /etc/make.conf.  Then emerge world  :Wink: 

----------

## Unclethommy

Super, I will post back on how it goes (it may take a week to set everything up as I am busy at the moment), i'll try and do a timed emerge too to show the difference  :Smile:  My system is already fairly fast as it compiles in RAM (i have 1.5GB) 

The new system will have 3GB RAM and dual 2Gb MP's (drewls) lol we'll see the results later..... ( i am wishing now that i had made different partitions for my root directory rather than just one large one  :Sad:  would have loved to try out the howto on the forums page which tells you how to load programs straight into ram! apparently you cant do this if the folders are all on same partition  :Sad:  ) 

Thanks again. "i'll be back"  :Smile: Last edited by Unclethommy on Tue Mar 27, 2007 12:30 pm; edited 1 time in total

----------

## neysx

Make sure you do not test one of the many ebuilds that forces -j1, often needlessly  :Sad: 

----------

## Unclethommy

Do you have a recommendation? eg perhaps mozilla-firefox or vmware? I dont want to wait too long for it to finish.

----------

## Unclethommy

Okay, I changed the kernel settings as suggested,  I have a big problem  :Sad:  The system doesnt boot past the kernel. I get a kernel panic  :Sad: 

It gives me an error saying VFS: Cannot open root device hda3 or unkown block (0,0)

Unable to mount root fs on unkown block

I know the system works correctly as I am able to boot from the knoppix cd and that is how I am currently writing this post. 

Does anyone have any advice? Do I need to add support for something else? 

The motherboard seems to be an asus a7m 266 D with two althon 2ghx MP's.

Do I need to enable any other options?

----------

## suicidal_orange_II

O dear, everyone overlooked one thing - hard drive drivers.

Boot from a livecd, recompile the kernel with your new IDE and/or SCSI drivers, and all will be well.  You'd may as well update your AGP and enable SMP at the same time, no point in another reboot  :Smile: 

Suicidal_Orange

----------

## Unclethommy

Yup, i fugured the same when I had a look at lspci and saw a new chipset called AMD 760/768.

Have tried to recompile them straight into the kernel and removed the old chipset dependence.

How do i update my AGP???

----------

## suicidal_orange_II

In character devices in kernel config.  You might not need to, only if your chipset has changed manufacturer and your using open source or nvidia graphics drivers but its probably a good idea to check.

Suicidal_Orange

----------

## Unclethommy

I have managed to get the kernel to load properly but when the init starts, it has losts off problems:

Mainly as far as i can see it cant write to my disks.... it simply says "can not create file or directory" 

and also there is an error saying that the time stamps on some files is in the future :S , i think this occured as the new mobo's time was set to 2000 and i didnt notice this whilst making the original kernel, it complained about time being skewed, i have consequently changed the clock to the correct time, but i fear there may be problems with a few files, is there a way to solve this time problem as well as the problem not being able to write to the disks??? 

 :Sad:  thought it would be less problomatic than this , at least i'm learning new things  :Smile: 

----------

## drizzt

sounds like your disc is mounted readonly....

----------

## Unclethommy

I am using the same fstab configuration as below .... it used to work before.... could this be cos of my new AMD chipset which is controlling the IDE? 

```
/dev/hda1               /boot           ext2            defaults,noatime        1 2

/dev/hda3               /               ext3            noatime         0 1

/dev/hda2               none            swap            sw              0 0
```

my lspci is as follows and i have enables nvidia/AMD chipset support in kernel device driver section, i have a few drivers on a promise pci ide card controller but thats not been a problem before  

```
00:00.0 Host bridge: Advanced Micro Devices [AMD] AMD-760 MP [IGD4-2P] System Controller (rev 11)

00:01.0 PCI bridge: Advanced Micro Devices [AMD] AMD-760 MP [IGD4-2P] AGP Bridge

00:07.0 ISA bridge: Advanced Micro Devices [AMD] AMD-768 [Opus] ISA (rev 05)

00:07.1 IDE interface: Advanced Micro Devices [AMD] AMD-768 [Opus] IDE (rev 04)

00:07.3 Bridge: Advanced Micro Devices [AMD] AMD-768 [Opus] ACPI (rev 03)

00:10.0 PCI bridge: Advanced Micro Devices [AMD] AMD-768 [Opus] PCI (rev 05)

01:05.0 VGA compatible controller: nVidia Corporation NV18 [GeForce4 MX 440 AGP 8x] (rev a4)

02:00.0 USB Controller: Advanced Micro Devices [AMD] AMD-768 [Opus] USB (rev 07)

02:04.0 Multimedia audio controller: C-Media Electronics Inc CM8738 (rev 10)

02:05.0 Mass storage controller: Promise Technology, Inc. PDC20268 (Ultra100 TX2) (rev 02)

02:06.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+ (rev 10)

02:08.0 Multimedia video controller: Brooktree Corporation Bt878 Video Capture (rev 11)

02:08.1 Multimedia controller: Brooktree Corporation Bt878 Audio Capture (rev 11)
```

I'm so close  :Sad:  lol

is there any way to get the output of the errors as init starts???? i tried t o press I for interactive boot but it ignores it and scrolls too fast for me to see whats going on  :Sad: 

----------

## drizzt

can you post result of

```
mount
```

after boot ?

----------

## Unclethommy

Unfortunately it wont let me loggin normally and complains pam_tally [3198] error opening /var/log/faillog for update  :Sad: 

i get the same when trying to login as my normal user.

when i do login, there is no output from mount. 

most other commands seem to work like 'ls' etc...

in knoppix , i have: 

```
knoppix@1[knoppix]$ ls /dev/hd

hda   hda1  hda2  hda3  hdb   hdc   hde   hde1  hdg   hdg1
```

hda1 is my /boot and hda3 is my root 

i dont know if this is significant but when i type mount on the knoppix live cd , i get: 

```

knoppix@1[knoppix]$ mount

/dev/root on / type ext2 (rw)

/ramdisk on /ramdisk type tmpfs (rw,size=2478932k)

/UNIONFS on /UNIONFS type unionfs (rw,dirs=/ramdisk=rw:/KNOPPIX=ro,delete=whiteout)

/dev/hdc on /cdrom type iso9660 (ro)

/dev/cloop on /KNOPPIX type iso9660 (ro)

/proc on /proc type proc (rw)

/proc/bus/usb on /proc/bus/usb type usbfs (rw,devmode=0666)

/dev/pts on /dev/pts type devpts (rw)
```

my grub config is as follows:

```
title=Gentoo Linux new

root (hd0,0)

kernel /boot/linux-new root=/dev/hda3
```

----------

## Unclethommy

Just some additional information : 

I am getting illegal instructions all the time and now getting errors saying 'broken pipe' 

also, still getting the read-only filesystem errors during init starting.... 

I was just about able to read the first piece of output before the screen scrolls too quickly, it says something about 'skipping mtab initialization (ro root)?' 

is there a way to scroll back up the error output once i am presented with the login prompt? pressing the up arrow just prints random characters in the current command. The interactive booting doesnt work and obviously as the partition is read-only, theres no way to write log data to the hardrive for me to read  :Sad: 

i am going to try to compile the kernel without the -os option and use the -02 option recommended as the safe flag for my cpus if anyone can help me i would be greatly appreciated.

the system works fine in knoppix livecd which suggests this is some kind of kernel problem and not my hardware as i can mount my partitions from the livecd etc....

----------

## widan

 *Unclethommy wrote:*   

> when i do login, there is no output from mount.

 

If / is read-only, mount can't update /etc/mtab and so won't record mounts. You can still know what is mounted by doing "cat /proc/mounts".

 *Unclethommy wrote:*   

> I am getting illegal instructions all the time and now getting errors saying 'broken pipe'

 

That means the binary contains instructions not supported by the CPU. Which CPU did you have before switching to the Athlons ? And which CFLAGS were used to build the system ?

----------

## Unclethommy

Ah, great, i will try  "cat /proc/mounts" as soon as I can

as for the illegal instructions.... <blushes> well it was compiled for an amd system using -02 -pipe and the -noframe and march=athlon-xp

but i recently got an intel chip and hence changed the cflags to march=pentium-4 but i onlt recompiled a few using these flags for the usual emerge updates and everything seemed hunky dory. But i did not emerge the whole system again as i was lazy.

but then when i switched to the dual athlon-mp's i changed the cflags to march=athlon-mp but didnt remerge anything as i wasnt instructed to as you see earlier in the posts (but maybe it was a newbie mistake as that was implied). 

the problem now is that even booting using knoppix, it wont let me emerge after chrooting to my old disk as it says illegal instruction  :Sad:  any ideas?

EDIT: unfortunately , i cant seem to boot into the hardrive with my /root directory to get the cat /proc/mounts output... its gives me a grub error 17  :Sad:  its getting worse  :Sad:  argh!!! lol, i had to install windows on another hardrive just so i can get a usable system! highly embarassing lol.

----------

