View previous topic :: View next topic |
Author |
Message |
muhsinzubeir l33t
Joined: 29 Sep 2007 Posts: 948 Location: /home/muhsin
|
Posted: Thu Mar 26, 2009 9:49 am Post subject: wont this break my server?{solved by reinstallation} |
|
|
After upgrades I run deplean and I see gcc listed in there...while another box with same profile upgraded on the same day doestn....I am really curios if depclean wont break my server
Quote: | sys-devel/gcc
selected: 3.4.6-r2
protected: none
omitted: 4.1.2 |
I am not sure why 4.1.2 got to my box as its hardened profile,
Quote: | [1] default/linux/x86/2008.0
[2] default/linux/x86/2008.0/desktop
[3] default/linux/x86/2008.0/developer
[4] default/linux/x86/2008.0/server
[5] hardened/x86/2.6
[6] selinux/2007.0/x86
[7] selinux/2007.0/x86/hardened *
[8] hardened/linux/x86
|
Any idea I really dont wanna mess gcc stuffs, I have checked package.keywords, package.unmask no entry for gcc...what do u think? _________________ ~x86
p5k-se
Intel Core 2 Duo
Nvidia GT200
http://www.zanbytes.com
Last edited by muhsinzubeir on Fri Mar 27, 2009 4:01 pm; edited 1 time in total |
|
Back to top |
|
|
d2_racing Bodhisattva
Joined: 25 Apr 2005 Posts: 13047 Location: Ste-Foy,Canada
|
Posted: Thu Mar 26, 2009 11:46 am Post subject: |
|
|
Hi, can you post this :
Code: |
# emerge --info
# gcc-config -l
|
|
|
Back to top |
|
|
richard.scott Veteran
Joined: 19 May 2003 Posts: 1497 Location: Oxfordshire, UK
|
Posted: Thu Mar 26, 2009 12:13 pm Post subject: |
|
|
Hi,
It sounds like you've installed a hardened profile system from a normal stage3 (non-hardened) tarball.
Did you donwload a tarball with "hardened" in the name??
Either way, it shouldn't damage your computer by removing it as long as you really are setup for a hardened profile.
Rich. |
|
Back to top |
|
|
muhsinzubeir l33t
Joined: 29 Sep 2007 Posts: 948 Location: /home/muhsin
|
Posted: Thu Mar 26, 2009 8:28 pm Post subject: |
|
|
Quote: | Portage 2.1.6.7 (selinux/2007.0/x86/hardened, gcc-3.4.6, glibc-2.8_p20080602-r1, 2.6.28-hardened-r6 i686)
=================================================================
System uname: Linux-2.6.28-hardened-r6-i686-Pentium_III_-Coppermine-with-glibc2.3.2
Timestamp of tree: Tue, 24 Mar 2009 08:45:02 +0000
app-shells/bash: 3.2_p39
dev-lang/python: 2.4.4-r13, 2.5.2-r7
dev-python/pycrypto: 2.0.1-r8
sys-apps/baselayout: 1.12.11.1
sys-apps/sandbox: 1.2.18.1-r2
sys-devel/autoconf: 2.63
sys-devel/automake: 1.10.2
sys-devel/binutils: 2.18-r3
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool: 1.5.26
virtual/os-headers: 2.6.27-r2
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=pentium3 -O2 -pipe -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php 5/ext-active/ /etc/revdep-rebuild /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-march=pentium3 -O2 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="assume-diget buildpkg ccache collision-detect digest distlocks fixpackages loadpolicy metadata-transfer parallel-fetch protect-owned sandbo x selinux sesandbox sfperms strict unmerge-orphans userfetch userpriv"
GENTOO_MIRRORS="http://de-mirror.org/distro/gentoo/ http://ftp.fi.muni.cz/pub/linux/gentoo/ http://mirror.muntinternet.net/pub/gentoo/"
LDFLAGS=""
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfi les --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://fileserver/gentoo-portage"
USE="apache2 berkdb cgi cli cracklib crypt ctype cups dbus dri fastcgi fortran gdbm gpm hal hardened iconv ipv6 isdnlog midi mudflap mysql ncurses nl s nptl nptlonly openmp pam pcre perl php pic pppd python readline reflection selinux session spl ssl tcpd unicode vhosts x86 xorg zlib" ALSA_CARDS="a li5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maest ro3 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 mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_ anon 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 deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayra d cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" USERLAND="GNU" VIDEO_CARDS="apm ark chips cirrus cyrix dummy fbdev glint i128 i740 i810 imstt intel mach64 mga neomagic nsc nv r128 radeon rendition s3 s3virge savage siliconmotion sis sisusb tdfx tga trident tseng v4l v esa vga via vmware voodoo"
Unset: CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_ EXTRA_OPTS, PORTDIR_OVERLAY
|
Quote: | [1] i686-pc-linux-gnu-3.4.6 *
[2] i686-pc-linux-gnu-3.4.6-hardenednopie
[3] i686-pc-linux-gnu-3.4.6-hardenednopiessp
[4] i686-pc-linux-gnu-3.4.6-hardenednossp
[5] i686-pc-linux-gnu-3.4.6-vanilla |
Quote: |
It sounds like you've installed a hardened profile system from a normal stage3 (non-hardened) tarball. |
Didnt know that there is a hardened tarbals...I thought a normal gentoo install then convert it using[url] http://www.gentoo.org/proj/en/hardened/selinux/selinux-handbook.xml?part=2[/url] _________________ ~x86
p5k-se
Intel Core 2 Duo
Nvidia GT200
http://www.zanbytes.com |
|
Back to top |
|
|
richard.scott Veteran
Joined: 19 May 2003 Posts: 1497 Location: Oxfordshire, UK
|
|
Back to top |
|
|
muhsinzubeir l33t
Joined: 29 Sep 2007 Posts: 948 Location: /home/muhsin
|
Posted: Thu Mar 26, 2009 9:58 pm Post subject: |
|
|
Thanks...silly me i have done couple hardened boxes with normal install, and later on convert them to hardened....ill keep this info for the next box
The last time I uninstalled gcc version on a gentoo box, it was the last thing I did it before reinstallation..
So I will see how it goes, with this one _________________ ~x86
p5k-se
Intel Core 2 Duo
Nvidia GT200
http://www.zanbytes.com |
|
Back to top |
|
|
muhsinzubeir l33t
Joined: 29 Sep 2007 Posts: 948 Location: /home/muhsin
|
Posted: Thu Mar 26, 2009 10:26 pm Post subject: |
|
|
OK.....now gcc broke
I knew it, ok this will be the last time gcc hit me again....
Quote: | gcc hello.c
gcc-config error: Could not run/locate "gcc" |
P:S
Bizzi looking for the doc to recover gcc....any info on that?Otherwise I will have to reinstall the whole box
Edit
Reinstalling..... _________________ ~x86
p5k-se
Intel Core 2 Duo
Nvidia GT200
http://www.zanbytes.com |
|
Back to top |
|
|
sera Retired Dev
Joined: 29 Feb 2008 Posts: 1017 Location: CET
|
Posted: Fri Mar 27, 2009 8:54 am Post subject: |
|
|
Quote: | Bizzi looking for the doc to recover gcc....any info on that?Otherwise I will have to reinstall the whole box |
Switching profile to non hardened and use the 4.1.2 (the omitted one) to build a hardened compatible gcc. Switch back to hardened.
Or use a livecd and chroot into your system then build gcc or quickpkg the one on the livecd.
Always quickpkg before removing a package you think you need. Helps greatly in recovery.
PS: I see I'm a little late. |
|
Back to top |
|
|
richard.scott Veteran
Joined: 19 May 2003 Posts: 1497 Location: Oxfordshire, UK
|
Posted: Fri Mar 27, 2009 9:58 am Post subject: |
|
|
muhsinzubeir wrote: | OK.....now gcc broke |
What command do you use to remove Gcc?
From what you've told us, gcc-config is looking for the old 3.x gcc which should still be there.
does 'equery list gcc' show any gcc packages left installed[/code]? |
|
Back to top |
|
|
muhsinzubeir l33t
Joined: 29 Sep 2007 Posts: 948 Location: /home/muhsin
|
Posted: Fri Mar 27, 2009 11:42 am Post subject: |
|
|
The original result was coming from emerge --depclean....which listed 2 gcc, and I just say ok clean up everything...it was not only gcc but with lots of other packages.But I have never succeeded removing 1 gcc version, if I have 2 of them in the box I always break it haha....
Thats why I asked it, but I was still a little rushy to "Enter"....but I am reinstalling the box now, may be its a good idea then I can improve some stuffs on it.
Thanks guys...really appreciate it _________________ ~x86
p5k-se
Intel Core 2 Duo
Nvidia GT200
http://www.zanbytes.com |
|
Back to top |
|
|
timeBandit Bodhisattva
Joined: 31 Dec 2004 Posts: 2719 Location: here, there or in transit
|
Posted: Fri Mar 27, 2009 2:45 pm Post subject: |
|
|
I'm sorry I didn't speak up earlier, I could have saved you some hassle. You were given ample warning you were headed for trouble. Here is how to interpret the signs.
depclean wrote: | sys-devel/gcc
selected: 3.4.6-r2
protected: none
omitted: 4.1.2 | "Selected" indicates the version(s) selected for removal. "Protected" and "omitted" show the version(s) depclean (really emerge) will leave installed.
gcc-config -l wrote: | [1] i686-pc-linux-gnu-3.4.6 *
[2] i686-pc-linux-gnu-3.4.6-hardenednopie
[3] i686-pc-linux-gnu-3.4.6-hardenednopiessp
[4] i686-pc-linux-gnu-3.4.6-hardenednossp
[5] i686-pc-linux-gnu-3.4.6-vanilla | Take note of your current (at the time) selected compiler, denoted by the asterisk (*). Notice the version matches the "selected" version reported by depclean.
Interpretation: Proceeding with depclean will break your Gentoo. As you discovered.
Also, richard.scott indirectly warned you to keep gcc-3.4.6: Quote: | Ah, that'll be why you have gcc-4.x installed then... a hardened profile is restricted to gcc-3.x | gcc-4 would not have been present had you installed from a hardened stage tarball. Thus, the later version was the one to remove.
depclean selects versions to clean based on version numbers, slots and masking. Some situations, like this one, require you to decide whether depclean wants to do something stupid--like remove the active C compiler (and only supported one for your profile).
Hope this helps you avoid getting burned in the future. _________________ Plants are pithy, brooks tend to babble--I'm content to lie between them.
Super-short f.g.o checklist: Search first, strip comments, mark solved, help others. |
|
Back to top |
|
|
muhsinzubeir l33t
Joined: 29 Sep 2007 Posts: 948 Location: /home/muhsin
|
Posted: Fri Mar 27, 2009 3:59 pm Post subject: |
|
|
timeBandit thanks....
P:S
Finally finished installation with hardened tarbals this time _________________ ~x86
p5k-se
Intel Core 2 Duo
Nvidia GT200
http://www.zanbytes.com |
|
Back to top |
|
|
muhsinzubeir l33t
Joined: 29 Sep 2007 Posts: 948 Location: /home/muhsin
|
Posted: Wed Apr 15, 2009 11:51 pm Post subject: |
|
|
Code: | emerge --depclean -av |
Quote: | sys-devel/gcc
selected: 3.4.6-r2
protected: none
omitted: 4.1.2 |
Quote: | [1] i686-pc-linux-gnu-3.4.6 *
[2] i686-pc-linux-gnu-3.4.6-hardenednopie
[3] i686-pc-linux-gnu-3.4.6-hardenednopiessp
[4] i686-pc-linux-gnu-3.4.6-hardenednossp
[5] i686-pc-linux-gnu-3.4.6-vanilla
[6] i686-pc-linux-gnu-4.1.2 |
Ok this is now obvios that depclean wanna do the same crap for the 2nd time...this one I am suppose to really take all precautions, as the server is localted totally in different continent then where I am ...so screwing up gcc will make me pay lots of money to travel to get down there and reinstall the system
So how to get rid of that 4.1.2 without corrupting 3.4.6....??
P:S
The only way I can fully trust this is to test it on my VirtualBox and see with my own eyes ...
for now I took a break from this server until I am pretty sure that I wont break it this time...
Edit:
I have the same situation on my VB...nice emulation
Edit:
Ok tested against my VB...its perfectly safe ..oooosah
Quote: | emerge -Ca =sys-devel/gcc-4.1.2 |
Thanks..... _________________ ~x86
p5k-se
Intel Core 2 Duo
Nvidia GT200
http://www.zanbytes.com |
|
Back to top |
|
|
richard.scott Veteran
Joined: 19 May 2003 Posts: 1497 Location: Oxfordshire, UK
|
Posted: Thu Apr 16, 2009 8:22 am Post subject: |
|
|
I'm interested to know which document you've read that tells you to remove the unwated GCC?
There's no harm (other than disk space being used up) to leave it there AFAIK.
Rich. |
|
Back to top |
|
|
muhsinzubeir l33t
Joined: 29 Sep 2007 Posts: 948 Location: /home/muhsin
|
Posted: Thu Apr 16, 2009 9:15 pm Post subject: |
|
|
richard.scott wrote: | I'm interested to know which document you've read that tells you to remove the unwated GCC?
There's no harm (other than disk space being used up) to leave it there AFAIK.
Rich. |
No document ofcoz...but its pretty logic if you have 4.1.2 (from stage3) ...and then you have 3xx...emerge --depclean will try to remove the old version....whereby in this case is a hardened profile....so no choice 4.1.2 has to be removed as its blocking me from using depclean....otherwise I have to remove every package manually then why do I have depclean for...
...cheers _________________ ~x86
p5k-se
Intel Core 2 Duo
Nvidia GT200
http://www.zanbytes.com |
|
Back to top |
|
|
|