# [RESOLVED] Upgrading hardware

## McLink

I plan to buy new hardware soon, but before I do, I have a question. I'm currently using an AMD Athlon 64 X2 4200+ on an MSI K9N Neo-F motherboard. I'm planning to buy a new motherboard, a new processor, and new memory, namely, an MSI K9A2 Platinum V2, an AMD Phenom X4 9850 and 4x2GB OCZ DDR2 PC6400 SDRAM, respectively. Now, my question is: am I correct in thinking that I can just swap out the hardware and keep my existing installation intact, without needing to recompile, and especially without needing to reinstall? And except for the obvious kernel reconfiguration and changing MAKEOPTS=-j3 to MAKEOPTS=-j5, is there anything else I need to do, or should do?

emerge --info:

```
$ emerge --info

Portage 2.1.4.4 (default/linux/amd64/2008.0, gcc-4.2.3, glibc-2.6.1-r0, 2.6.24-gentoo-r8 x86_64)

=================================================================

System uname: 2.6.24-gentoo-r8 x86_64 AMD Athlon(tm) 64 X2 Dual Core Processor 4200+

Timestamp of tree: Fri, 30 May 2008 10:15:01 +0000

ccache version 2.4 [enabled]

app-shells/bash:     3.2_p33

dev-java/java-config: 1.3.7, 2.1.6

dev-lang/python:     2.4.4-r13

dev-python/pycrypto: 2.0.1-r6

dev-util/ccache:     2.4-r7

sys-apps/baselayout: 1.12.11.1

sys-apps/sandbox:    1.2.18.1-r2

sys-devel/autoconf:  2.13, 2.61-r1

sys-devel/automake:  1.4_p6, 1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.1

sys-devel/binutils:  2.16.1-r3, 2.17-r1, 2.18-r1

sys-devel/gcc-config: 1.4.0-r4

sys-devel/libtool:   1.5.26

virtual/os-headers:  2.6.23-r3

ACCEPT_KEYWORDS="amd64"

CBUILD="x86_64-pc-linux-gnu"

CFLAGS="-O2 -march=k8 -pipe -ggdb -fomit-frame-pointer -fno-strict-aliasing"

CHOST="x86_64-pc-linux-gnu"

CONFIG_PROTECT="/etc /opt/openjms/config /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/kde/4.0/env /usr/kde/4.0/share/config /usr/kde/4.0/shutdown /usr/share/config /var/lib/hsqldb"

CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/splash /etc/terminfo /etc/texmf/web2c /etc/udev/rules.d"

CXXFLAGS="-O2 -march=k8 -pipe -ggdb -fomit-frame-pointer -fno-strict-aliasing"

DISTDIR="/usr/portage/distfiles"

FEATURES="ccache distlocks metadata-transfer nostrip parallel-fetch sandbox sfperms strict unmerge-orphans userfetch"

GENTOO_MIRRORS="http://ftp.heanet.ie/pub/gentoo/ http://mirror.ovh.net/gentoo-distfiles/ http://ftp.snt.utwente.nl/pub/os/linux/gentoo http://de-mirror.org/distro/gentoo/ http://mirror.qubenet.net/mirror/gentoo/ http://mirror.muntinternet.net/pub/gentoo/ ftp://gentoo.tiscali.nl/pub/mirror/gentoo/ http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror/ http://gentoo.tiscali.nl/ ftp://mirror.muntinternet.net/pub/gentoo/"

LANG="en_GB.UTF-8"

LC_ALL="en_GB.UTF-8"

LINGUAS="en_GB en nl de fr es it pl sv el la fi ru"

MAKEOPTS="-j3"

PKGDIR="/usr/portage/packages"

PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"

PORTAGE_TMPDIR="/var/tmp"

PORTDIR="/usr/portage"

PORTDIR_OVERLAY="/usr/i686-mingw32/usr/portage /usr/portage/local/layman/java-overlay /usr/portage/local/layman/sunrise /usr/portage/local/layman/desktop-effects /usr/portage/local/layman/pro-audio /usr/portage/local/layman/science /usr/local/portage/3rd-party-std /usr/local/portage/local"

SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"

USE="3ds 7zip X Xaw3d aac aalib accessibility acl acpi aiglx allegro alsa amd64 animation apache2 arts artworkextra asf audacious audiofile avahi bash-completion bcp bdf berkdb big-tables binfilter bjam blender-game bonobo bookmarks bookmarksmikmod branding bzip2 cairo cal3d calendar caps captury cddb cdparanoia cdr cegui cg cgi chardet chroot cjk cli cpudetection cracklib crypt cscope css ctype cups curl curlwrappers cursors dbus dedicated designer-plugin devil dhcp directfb dmi dmx doc double-precision dri dts dv dvd dvdr dvdread dvi dxr3 effects elf encode epydoc esd examples exif expat export extensions extraengine extrafilters fat fax fbcon fbcondecor ffmpeg filter firefox flac flash flatfile fontconfig foomaticdb force-cgi-redirect fortran freetts ftp gadu gcj gd gdbm gdm ggi gif gimp gimpprint glitz glut gmail gmp gnome gnutls gphoto2 gpm graphviz groupwise gs gstreamer gtk gtk2 gtkhtml guile gzip hal hash hddtemp hfs howl-compat htmlhandbook icons iconv icu ieee1394 imagemagick imap imlib inifile inkjar insecure-savers ipv6 isdnlog jack jai java javamail javascript jce jfs jikes jingle jms joystick jpeg jpeg2k json justify kde kdm kdrive kig-scripting lcms libcaca libedit libnotify libsamplerate lilypond lm_sensors logitech-mouse loop-aes lua lzo mad mailwrapper maps mbox md5sum mdnsresponder-compat meanwhile mhash midi mikmod mjpeg mmx mng mod modplug mono motif mozbranding mozcalendar mozdevelop mp3 mp4 mpeg mplayer msn mudflap multilib multislot multiuser musepack musicbrainz mysql mysqli nas nautilus ncurses netboot network networking new-login nextaw nfs nls nptl nptlonly nsplugin ntfs nvidia objc objc++ objc-gc ode odk offensive ogg openal openexr opengl openmp openntpd overlays pam pango parport paste64 pcre pdf pdo perl php plotutils png pop portaudio posix postgres povray ppds pppd prediction pthreads pyste python qq qt qt3 qt3support qt4 quicktime quotas radio rar rdesktop readline reflection regex reiser4 reiserfs rpc ruby samba sametime scanner sdl seamonkey session sftplogging silc skey skins slang slp smartcard smp sndfile snmp sockets socks5 solver sound source speex spell spl sqlite srt sse sse2 ssl startup-notification stream svg svgz swat symlink sysfs talkfilters tcl tcltk tcpd tetex tga theora threads threadsafe tidy tiff timidity tk tokenizer toolbar tools truetype unicode urandom usb v4l v4l2 vcd vcdcss vdr vidcap vim vim-pager vim-syntax vim-with-x visualization vlm vorbis wavpack wma wxwindows xattr xchatdccserver xchattext xcomposite xerces-c xfs xft xine xinerama xinetd xml xmlreader xmlrpc xmlwriter xorg xosd xpm xprint xscreensaver xsl xv xvid xvmc zephyr zip zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic auth_digest authn_anon authn_dbd authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy proxy_ajp proxy_balancer proxy_connect proxy_http rewrite setenvif so speling status unique_id userdir usertrack vhost_alias" CAMERAS="ptp ptp2 canon" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev wacom" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en_GB en nl de fr es it pl sv el la fi ru" USERLAND="GNU" VIDEO_CARDS="nvidia"

Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LDFLAGS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
```

I'm highly anticipating beefing up my computer since it's getting slightly back-dated, but I'll have serious reconsiderations if I need to reinstall (I'm not worried about emerge -e system && emerge -e world, but reinstalling from scratch is a no-go). So is this going to work without nuking my install?

----------

## pappy_mcfae

 *Sir Link wrote:*   

> I plan to buy new hardware soon, but before I do, I have a question. I'm currently using an AMD Athlon 64 X2 4200+ on an MSI K9N Neo-F motherboard. I'm planning to buy a new motherboard, a new processor, and new memory, namely, an MSI K9A2 Platinum V2, an AMD Phenom X4 9850 and 4x2GB OCZ DDR2 PC6400 SDRAM, respectively. Now, my question is: am I correct in thinking that I can just swap out the hardware and keep my existing installation intact, without needing to recompile, and especially without needing to reinstall? And except for the obvious kernel reconfiguration and changing MAKEOPTS=-j3 to MAKEOPTS=-j5, is there anything else I need to do, or should do?

 

As far as replacing the hardware is concerned, you might want to consider recompiling with your new chip settings which you should put in your /etc/make.conf file, although it might not be that big of a problem. You will definitely have to recompile your kernel to work with the new hardware (chip ID, SATA drivers, networking, video, etc.) if they are different, and the probably will be.

I just recently updated from a PII to a Core2 Duo. I did as I said above, and it worked fine...until I decided to set it up as a 64 bit system.

Good luck.

Blessed be!

Pappy

----------

## McLink

 *pappy_mcfae wrote:*   

>  *Sir Link wrote:*   I plan to buy new hardware soon, but before I do, I have a question. I'm currently using an AMD Athlon 64 X2 4200+ on an MSI K9N Neo-F motherboard. I'm planning to buy a new motherboard, a new processor, and new memory, namely, an MSI K9A2 Platinum V2, an AMD Phenom X4 9850 and 4x2GB OCZ DDR2 PC6400 SDRAM, respectively. Now, my question is: am I correct in thinking that I can just swap out the hardware and keep my existing installation intact, without needing to recompile, and especially without needing to reinstall? And except for the obvious kernel reconfiguration and changing MAKEOPTS=-j3 to MAKEOPTS=-j5, is there anything else I need to do, or should do? 
> 
> As far as replacing the hardware is concerned, you might want to consider recompiling with your new chip settings which you should put in your /etc/make.conf file, although it might not be that big of a problem. You will definitely have to recompile your kernel to work with the new hardware (chip ID, SATA drivers, networking, video, etc.) if they are different, and the probably will be.
> 
> I just recently updated from a PII to a Core2 Duo. I did as I said above, and it worked fine...until I decided to set it up as a 64 bit system.
> ...

 Thanks for your reply. I'm not yet using GCC 4.3, so there aren't any new -march settings available. Are there other CFLAGS I should be using with a Phenom processor? The CHOST won't change - that means a recompile isn't necessary, right? I'll recompile with -march=amdfam10 when GCC 4.3 becomes safe, though I have no idea when that'll be. The Gentoo Wiki states I can use -march=k8 for a Phenom as well - is that correct? If so, I'll just use that until GCC 4.3 gets out of its current hard-masked state.

Thanks again.

----------

## pappy_mcfae

 *Sir Link wrote:*   

> Thanks for your reply. I'm not yet using GCC 4.3, so there aren't any new -march settings available. Are there other CFLAGS I should be using with a Phenom processor? The CHOST won't change - that means a recompile isn't necessary, right? I'll recompile with -march=amdfam10 when GCC 4.3 becomes safe, though I have no idea when that'll be. The Gentoo Wiki states I can use -march=k8 for a Phenom as well - is that correct? If so, I'll just use that until GCC 4.3 gets out of its current hard-masked state.
> 
> Thanks again.

 

No, you won't have to change your CHOST settings, however, if you are changing your CFLAGS -march setting, recompiling would be a really good idea. I don't know that much about AMD chips, so I don't know if you are going to have to change CPU type in your kernel and reconfigure other CPU based settings or not. My better judgment says you should consider it, but I'm not sure exactly what classification you'd use with that chip. 

For lack of more information, I'd go with the wiki recommendation. I don't think that you'll get steered wrong by taking that course. If you do, though, that would be the time to recompile everything...if nothing else, at least rebuild the toolchain with emerge -aev system.

Good luck.

Blessed be!

Pappy

----------

## McLink

Thanks. I'll do some more research on my own, but in any case, it looks like a complete reinstall won't be necessary. I'm going to go ahead and buy the hardware - after I get my digital SLR, of course  :Smile: .

I'm considering this resolved, since you've confirmed what I thought initially.

----------

## pappy_mcfae

Cool. Have fun with your new rig!

Blessed be!

Pappy

----------

## Kenji Miyamoto

I've been using -march=barcelona with my Phenom for quite some time, and haven't had a single issue.  In fact, using -march=k8 with GCC 4.2 caused my system to lock-up a lot when compiling packages, but -march=k8 with GCC 4.3 fixed that problem.

That may be because it's a Phenom 9500 with the infamous TLB bug, but  I can't confirm that to be the cause.

----------

## McLink

I'm not planning to use GCC 4.3 unless it's at least out of hardmask. Does -march=barcelona work with GCC 4.2? I can't find much info on it; even searching man gcc for "barcelona" doesn't give me anything.

Can anyone give me more info on -march=barcelona with a Phenom X4 9850 and GCC 4.1/4.2?

----------

## Neo2

If you're using GCC >4.2 you may want to use -march=native and let the compiler determine the right -march option for you. I recently recompiled world with GCC 4.3.1 and some stable packages are broken by that. If you don't want to bother manually restarting emerge everytime, you can safely stick with 4.2.4 (worked fine for me until I switched to 4.3.1).

----------

## Gef

 *Neo2 wrote:*   

> If you're using GCC >4.2 you may want to use -march=native

 

It works with GCC >= 4.2 (see http://gcc.gnu.org/gcc-4.2/changes.html).

----------

## Neo2

Yes, that's true  :Smile:  But since 4.2.0, 4.2.1 and 4.2.2 are not in the tree anymore, I just assumed that Sir Link could only upgrade to 4.2.3 and 4.2.4, that is GCC >4.2.0  :Wink: 

----------

## McLink

I'm using 4.2.3 now, and I'm going to upgrade to 4.2.4. I'll try -march=native when I get my hardware (but I'm still waiting for my money - I'm seriously considering shipping 80 tons of Windows disks to that insurance company).

Thanks, guys.

----------

## Jimmy Jazz

 *Sir Link wrote:*   

>  *pappy_mcfae wrote:*    *Sir Link wrote:*   I plan to buy new hardware soon, but before I do, I have a question. I'm currently using an AMD Athlon 64 X2 4200+ on an MSI K9N Neo-F motherboard. I'm planning to buy a new motherboard, a new processor, and new memory, namely, an MSI K9A2 Platinum V2, an AMD Phenom X4 9850 and 4x2GB OCZ DDR2 PC6400 SDRAM, respectively. Now, my question is: am I correct in thinking that I can just swap out the hardware and keep my existing installation intact, without needing to recompile, and especially without needing to reinstall? And except for the obvious kernel reconfiguration and changing MAKEOPTS=-j3 to MAKEOPTS=-j5, is there anything else I need to do, or should do? 
> 
> As far as replacing the hardware is concerned, you might want to consider recompiling with your new chip settings which you should put in your /etc/make.conf file, although it might not be that big of a problem. You will definitely have to recompile your kernel to work with the new hardware (chip ID, SATA drivers, networking, video, etc.) if they are different, and the probably will be.
> 
> I just recently updated from a PII to a Core2 Duo. I did as I said above, and it worked fine...until I decided to set it up as a 64 bit system.
> ...

 

Hi 

happy to see you want to  upgrade to the phenom X4  :Smile: 

It isn't necessary to recompile everything but the kernel. Anyway, phenom is really fast ... or furious. It compiles really really fast ... you could believe that it does nothing or the compilation has just failed  :Smile: 

So compiling everything is not a problem of time.

I'm using gcc 4.2 and 4.3, kernel 2.6.26 and glibc 2.8 with a 9750 stepping 3. The motherboard is a Abit AX78 with an hardware diagnostic chip. The heat control seems to be in hardware not  like most of the motherboard around but that needs to be confirmed by someone that understand better the hardware than me. 

For the time being, i'm using -march=k8 . I'm not sure every program can be compiled with gcc 4.3.

if you plan to compile with -j5 (-j8 or -j9 if you have enough memory like 4Go - 1Go/core) it is just amazing how fast it is but you will suffer with a lot of overheats (~80°C). If you make all 4 cores in ondemand mode you can hope a nice 56°C in idle mode. Activate the lm_sensors alarm to figure it out.

To not exceed 70°C you probably have to slow down the cpu with a lot of disk ios or simply use -j1... or perhaps invest in watercooling to eat all  the 95/120W generated by the cpu  :Smile: 

Last but not least, i'm happy with my box  :Wink: 

----------

