Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
emerge -U world - How often
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2, 3, 4, 5, 6, 7, 8, 9, 10  Next  
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
unstable_geek
Tux's lil' helper
Tux's lil' helper


Joined: 01 Mar 2003
Posts: 102
Location: In my own happy place

PostPosted: Tue May 11, 2004 8:46 pm    Post subject: Reply with quote

So I'm slowing catching up with all the updates.
An emerge -uDav shows (amongst a kabillion other things):
Code:

[ebuild  N    ] sys-devel/gcc-3.3.2-r5  +X -bootstrap -build -gcj -java -multilib +nls -static  23,451 kB
[ebuild     U ] sys-libs/glibc-2.3.2-r9 [2.2.5-r9] -build +nls -nptl -pic  18 kB


This kind scares me. Others have said that the only safe way to upgrade GCC is to boot from a liveCD and recompile the world.

Anyone else care to comment?

Also, is there an easy way to have a package re-install itself? I was thinking emerge -e <package>, but that seems to want to recompile everything.
_________________
I hate my sig
Back to top
View user's profile Send private message
hepta_sean
Apprentice
Apprentice


Joined: 27 Apr 2004
Posts: 246
Location: Berlin, Germany

PostPosted: Tue May 11, 2004 9:03 pm    Post subject: Reply with quote

unstable_geek:
I don't know, why it should be necessary to boot from a live-cd to compile gcc. And recompiling world would only be necessary if you want every single package to take advantage of new features of the compiler (compiler people tend to first compile the compiler again, so they have a version, which is optimized by itself).

Personally, I would just let it emerge and don't care about all the packages, still compiled with the old one. After all, I also don't recompile everything after changing CFLAGS or USE.

To remerge a single package you can just do:
Code:
emerge <package>

The -e option means "emptytree" and pretends that nothing is installed and therefore wants to install all dependencies (recursively).
Back to top
View user's profile Send private message
nobspangle
Veteran
Veteran


Joined: 23 Mar 2004
Posts: 1318
Location: Manchester, UK

PostPosted: Tue May 11, 2004 10:15 pm    Post subject: Reply with quote

I'm all sorted
= in the wrong place in /var/cache/edb/world
emerge -uD doesn't update my kernel sources and emerge depclean doesn't remove them
Back to top
View user's profile Send private message
robmoss
Retired Dev
Retired Dev


Joined: 27 May 2003
Posts: 2634
Location: Jesus College, Oxford

PostPosted: Wed May 12, 2004 12:33 am    Post subject: Reply with quote

unstable_geek wrote:
Others have said that the only safe way to upgrade GCC is to boot from a liveCD and recompile the world.

Anyone else care to comment?


Yes, okay. Who are these "others" of who you speak? I have a hot poker waiting for them, as they're probably Slashdot trolls... :P

Just update, there's nothing really to worry about.
_________________
Reality is for those who can't face Science Fiction.

emerge -U will kill your Gentoo
ecatmur, Lord of Portage Bash Scripts
Back to top
View user's profile Send private message
ecatmur
Advocate
Advocate


Joined: 20 Oct 2003
Posts: 3595
Location: Edinburgh

PostPosted: Wed May 12, 2004 12:43 am    Post subject: Reply with quote

hepta_sean wrote:
Does anyone, have an idea, why my line in virtuals looks like this:
Code:
virtual/linux-sources sys-kernel/love-sources sys-kernel/gentoo-sources sys-kernel/gentoo-dev-sources sys-kernel/development-sources

I had all those sources, but shouldn't emerge remove those, which are unmerged? Currently there are only gentoo-dev-sources and love-sources on my system.

It should, and if it doesn't then someone needs to be punished. Unfortunately the portage devs have a habit of breaking things fairly often and releasing buggy versions without noticing (though we love them really...)
_________________
No more cruft
dep: Revdeps that work
Using command-line ACCEPT_KEYWORDS?
Back to top
View user's profile Send private message
Redeeman
l33t
l33t


Joined: 25 Sep 2003
Posts: 958
Location: Portugal

PostPosted: Wed May 12, 2004 1:36 pm    Post subject: Reply with quote

robmoss2k wrote:
jchomarat wrote:
Thanks guys, I think i'll stick with Little Nemo answer, emerge -Upv system.

robmoss2k, what is it for the command you mentionned?


Okay. As you're probably aware, there are two different sorts of packages which you can use - those which are marked with the "x86" keyword, and those which are marked with the "~x86" keyword. Those which are marked with the "x86" keyword are considered stable and should work on any x86 system whatsoever without a hitch. Those marked with "~x86" are considered unstable or testing, and may break. Now, if you want to use the stable "x86" profile, but want to use certain unstable or testing packages, you SHOULD NEVER EVER EVER use the command:

Code:
ACCEPT_KEYWORDS="~x86" emerge package


and then afterwards use:

Code:
emerge -UDv world


to update your system. This will definitely, definitely break things. I promise.

The correct behaviour, which was introduced in portage-2.0.50 in an attempt to fix this, is to have a file located at /etc/portage/package.keywords, which tells portage which packages you'd like to use the unstable profile for. So an example package.keywords file might look like this:

Code:
sys-devel/gcc ~x86
x11-base/xfree ~x86


This would tell portage that it should use the "~x86" keyword for gcc and xfree and the "x86" keyword for everything else.

Now, why is this the correct way to do things? Well, it's not unusual for a package to be released, only for it to later be discovered that the package is in fact broken. So that package is marked "-*" or removed entirely, and portage should downgrade it in order to ensure system stability. But if you use "emerge -UDv world" then you fundamentally break this process. Indeed, it's not unusual to have at least three or four broken packages floating around simply because you're not letting portage downgrade them.

So, if you want a stable system, you should NOT be using the -U flag. EVER. And if it breaks - well, you get to keep the pieces. The portage documentation tells you that this flag is deprecated for a very, very good reason, which I've described above. My system is rock stable, and I use this process to update it:

Code:
emerge sync
emerge -uDpv world
emerge -uDv world
emerge -pv depclean
emerge -v depclean
revdep-rebuild -pv
revdep-rebuild -v
dispatch-conf


That basically updates the portage tree, tells me what's involved in updating everything, updates everything, tells me what packages are no longer necessary, removes them, tells me what packages have been broken by an upgrade or removal, and recompiles them. Then dispatch-conf updates my config files for me with minimal intervention.

The glsa-check programme is a new function of portage which performs security updates automatically. glsa-check is run with "-f all" in order for it to fix (-f) every security flaw (all) identified by a Gentoo Linux Security Advisory (GLSA). So if you want your system to be secure as well as stable, you want to run this regularly.

Personally, I run "glsa-check -f all" every hour, and the above set of commands for updating my system every day. I've not had a single breakage in over a year on my stable "x86" box, and only two or three on my unstable/testing "~x86" box.


i dont agree with you, i do it often, and it doesent break things.
Back to top
View user's profile Send private message
robmoss
Retired Dev
Retired Dev


Joined: 27 May 2003
Posts: 2634
Location: Jesus College, Oxford

PostPosted: Wed May 12, 2004 1:53 pm    Post subject: Reply with quote

Redeeman wrote:
i dont agree with you, i do it often, and it doesent break things.


But I spent a large amount of time in the Portage & Programming forum, and I guess perhaps one in ten problems I come across can be solved by following the above method rather than using -U. It's as simple as that.

Just because something works for one person doesn't mean it works.
_________________
Reality is for those who can't face Science Fiction.

emerge -U will kill your Gentoo
ecatmur, Lord of Portage Bash Scripts
Back to top
View user's profile Send private message
javac16
Tux's lil' helper
Tux's lil' helper


Joined: 10 Aug 2003
Posts: 111

PostPosted: Fri May 14, 2004 9:57 pm    Post subject: Reply with quote

Great thread. Learned a lot:
a) dispatch-conf instead of etc-update
b) better emerge use (instead of emerge -UD)
c) glsa-check

Thanks!
Back to top
View user's profile Send private message
turtlendog
Tux's lil' helper
Tux's lil' helper


Joined: 31 Jan 2004
Posts: 107
Location: East AZ

PostPosted: Sat May 15, 2004 4:11 am    Post subject: Reply with quote

Is there a way to specify ~x86 for a limited set of packages based on a virtual or to specify both 'package x' and it's dependancies rather than each individual package in package.keywords? I wanted to see what all the fuss over Gnome 2.6 is about, but adding all the ~x86 dependancies to package.keywords is getting old.

BTW, I use KDE so I'm not too worried about breaking Gnome, but would like to avoid needlessly bringing other system packages up to ~x86.
Back to top
View user's profile Send private message
ecatmur
Advocate
Advocate


Joined: 20 Oct 2003
Posts: 3595
Location: Edinburgh

PostPosted: Sat May 15, 2004 4:50 am    Post subject: Reply with quote

With the current structure of Portage, no. At least you only have to do it once.
_________________
No more cruft
dep: Revdeps that work
Using command-line ACCEPT_KEYWORDS?
Back to top
View user's profile Send private message
Sargon
Tux's lil' helper
Tux's lil' helper


Joined: 23 Jan 2003
Posts: 90

PostPosted: Sun May 16, 2004 9:18 pm    Post subject: Reply with quote

Hi

Great thread! BUT! Two things:

(a)
I think etc-update is under-rated. ;) I use it since 1.5 years and it works very well for me. I don't have many manually-editted config files anyway, and for the 99% it works great. (the others I migrate manually (yes, fstab too :))

(b)
How exactly does 'glsa-check -f all' interfere with my system? I mean I have packages installed with version x.y and they are in x86. WHat does glsa-check do with them, if there is something for them?

Sargon
Back to top
View user's profile Send private message
turtlendog
Tux's lil' helper
Tux's lil' helper


Joined: 31 Jan 2004
Posts: 107
Location: East AZ

PostPosted: Mon May 17, 2004 1:43 am    Post subject: Reply with quote

Quote:
I think etc-update is under-rated.


Perhaps.. If you know diff like the back of your hand.

I recently switched my diff command to vimdiff in /etc/etc-update.conf and that's made all the difference for me. (But I still keep 30 days worth of nightly backups on my /etc dir just in case).

Code:

# vim-users: you CAN use vimdiff for diff_command. (see NOTE_1)
#diff_command="diff -uN %file1 %file2"
#using_editor=0
diff_command="vim -d %file1 %file2"
using_editor=1
Back to top
View user's profile Send private message
papabean
Tux's lil' helper
Tux's lil' helper


Joined: 26 Oct 2002
Posts: 130
Location: Sacramento, California

PostPosted: Mon May 17, 2004 1:02 pm    Post subject: Reply with quote

robmoss2k wrote:
etc-update is horrible. Don't use it. Ever. Filthy!


Just wanted to note that etc-update itself is not filthy. I've used it successfully for a couple of years now with little trouble (there was that one time). The key is to keep in mind which files have been hand modified and which ones have never been touched.

I'm going to try dispatch-conf, though. Having recently learned about RCS from the Ultimate BSD book, I'm excited to actually put it to use on my Linux box, too.

Also, thanks for the tip on the -U flag. I've been using it for a long while now and never realized the potential harm in it.
_________________
-- The world is full of tough guys. It doesn't need me to be one too.
Back to top
View user's profile Send private message
MikeP
Tux's lil' helper
Tux's lil' helper


Joined: 27 Feb 2003
Posts: 115
Location: Germany

PostPosted: Mon May 17, 2004 2:15 pm    Post subject: Reply with quote

turtlendog wrote:
Is there a way to specify ~x86 for a limited set of packages based on a virtual or to specify both 'package x' and it's dependancies rather than each individual package in package.keywords? I wanted to see what all the fuss over Gnome 2.6 is about, but adding all the ~x86 dependancies to package.keywords is getting old.

BTW, I use KDE so I'm not too worried about breaking Gnome, but would like to avoid needlessly bringing other system packages up to ~x86.


I had the same thoughts, it can really be painful to add all dependencies of a package to package.keywords, an 'uem package' is done much faster ;) (uem is my alias for ACCEPT_KEYWORDS="~x86" emerge) - Hope theres some development here.. eg add a flag to package keywords that determines how dependencies should be treated or something...
Back to top
View user's profile Send private message
robmoss
Retired Dev
Retired Dev


Joined: 27 May 2003
Posts: 2634
Location: Jesus College, Oxford

PostPosted: Mon May 17, 2004 4:29 pm    Post subject: Reply with quote

MikeP wrote:
I had the same thoughts, it can really be painful to add all dependencies of a package to package.keywords, an 'uem package' is done much faster ;) (uem is my alias for ACCEPT_KEYWORDS="~x86" emerge) - Hope theres some development here.. eg add a flag to package keywords that determines how dependencies should be treated or something...


Yes, you've got a good point there - it should I suppose in theory be possible to use a ~arch masked package as a dependency if and only if there doesn't exist a stable package to be used as a dependency instead. And it could also downgrade when a dependency is marked stable (if indeed a downgrade would be needed to drop back to stable when one is so marked).
_________________
Reality is for those who can't face Science Fiction.

emerge -U will kill your Gentoo
ecatmur, Lord of Portage Bash Scripts
Back to top
View user's profile Send private message
ecatmur
Advocate
Advocate


Joined: 20 Oct 2003
Posts: 3595
Location: Edinburgh

PostPosted: Thu May 20, 2004 12:29 am    Post subject: Reply with quote

Hmm, yeah.
I reckon the best way to do this would be to mangle the version comparing code to let it take a flag to regard all unstable packages as lower in version than all stable packages, when directly comparing two packages.
Then an update would always select the latest stable package but deps would be able to select unstable packages.
_________________
No more cruft
dep: Revdeps that work
Using command-line ACCEPT_KEYWORDS?
Back to top
View user's profile Send private message
robmoss
Retired Dev
Retired Dev


Joined: 27 May 2003
Posts: 2634
Location: Jesus College, Oxford

PostPosted: Thu May 20, 2004 1:00 am    Post subject: Reply with quote

Mmmm, nice!

Write it then :twisted: :P
_________________
Reality is for those who can't face Science Fiction.

emerge -U will kill your Gentoo
ecatmur, Lord of Portage Bash Scripts
Back to top
View user's profile Send private message
ecatmur
Advocate
Advocate


Joined: 20 Oct 2003
Posts: 3595
Location: Edinburgh

PostPosted: Thu May 20, 2004 3:54 am    Post subject: Reply with quote

And what use would that be to me? I mix ~arch and -* packages, not arch and ~arch... :P
_________________
No more cruft
dep: Revdeps that work
Using command-line ACCEPT_KEYWORDS?
Back to top
View user's profile Send private message
MikeP
Tux's lil' helper
Tux's lil' helper


Joined: 27 Feb 2003
Posts: 115
Location: Germany

PostPosted: Fri May 21, 2004 5:54 pm    Post subject: Reply with quote

ecatmur wrote:
Hmm, yeah.
I reckon the best way to do this would be to mangle the version comparing code to let it take a flag to regard all unstable packages as lower in version than all stable packages, when directly comparing two packages.
Then an update would always select the latest stable package but deps would be able to select unstable packages.

eh? regarding unstable ones as lower versions when directly comparing?
Maybe it would work and you just described it a bit ugly.. or too complicated anyway.

Well, it should'nt be too hard theoretically:
you add one flag to package.keywords which can be arch, ~arch and -arch/-*, it would specify the most unstable keyword portage may use for dependencies, and it should probably default to use the most stable package. eg when it is set to -*, first check if theres a stable dependency, if not check for an ~arch, if not check for an -*.

You could extend that to add 2 flags to package keywords instead of one, so you will have one for telling portage the most unstable keyword to use, and one for telling portage the preferred keyword to use.
This way you could tell portage to always use ~arch or -* dpendencies, even if there are more stable ones, eg preferred keyword ~arch, most unstable keyword -*:
first portage checks for a ~ dependency, if there is none then it should again default to check for a stable dependency, then for a -* dependency.
or you could even extend that further and add a < or a > before the prefered flag to tell portage whether to check for a stable dependency or a - dependency first oif there is no ~ dependency...

:)
Back to top
View user's profile Send private message
timewalker
n00b
n00b


Joined: 16 Apr 2002
Posts: 21

PostPosted: Fri May 21, 2004 8:43 pm    Post subject: Reply with quote

if i want to add gnome to this ~x86 in /etc/portage/package.keywords i seem to have to add ALL gnome packages manually? isn't there an easier way to do it?
adding just "gnome-base/gnome ~x86" gives me this error when trying to emerge worlde:

Code:

#emerge -uDpv world

These are the packages that I would merge, in order:
 
Calculating world dependencies \
!!! all ebuilds that could satisfy ">=gnome-base/gnome-session-2.6.1" have been masked.
!!! possible candidates are:
- gnome-base/gnome-session-2.6.1 (masked by: ~keyword)
!!!    (dependency required by "gnome-base/gnome-2.6.1_rc1" [ebuild])
 
!!! Error calculating dependencies. Please correct.
Back to top
View user's profile Send private message
robmoss
Retired Dev
Retired Dev


Joined: 27 May 2003
Posts: 2634
Location: Jesus College, Oxford

PostPosted: Fri May 21, 2004 8:47 pm    Post subject: Reply with quote

Nope, you've gotta do them all - read the discussion in this very thread!
_________________
Reality is for those who can't face Science Fiction.

emerge -U will kill your Gentoo
ecatmur, Lord of Portage Bash Scripts
Back to top
View user's profile Send private message
timewalker
n00b
n00b


Joined: 16 Apr 2002
Posts: 21

PostPosted: Fri May 21, 2004 9:03 pm    Post subject: Reply with quote

robmoss2k wrote:
Nope, you've gotta do them all - read the discussion in this very thread!

well.. to me that's just too much work thought portage would be an easy to maintain packagesystem, besides they change the names of packages and even add removes some packages with new gnome releases, so i am supposed to keep track on all these package changes and dependancies and manually add/remove them to package.keywords... to me that don't sound like a viable solution.
Back to top
View user's profile Send private message
MikeP
Tux's lil' helper
Tux's lil' helper


Joined: 27 Feb 2003
Posts: 115
Location: Germany

PostPosted: Fri May 21, 2004 9:11 pm    Post subject: Reply with quote

package.keywords didn't even exist some time ago... we are just discussing about how it should be improved, and hopefully it will be improved...
until then, you could still just use ACCEPT_KEYWORDS="~x86" emerge gnome to emerge it, however that has disadvantages aswell, as rob said, read this thread.
Back to top
View user's profile Send private message
pianosaurus
l33t
l33t


Joined: 19 Apr 2004
Posts: 944
Location: Bash$

PostPosted: Tue May 25, 2004 8:31 pm    Post subject: Reply with quote

For those of you that read robmoss2k's post on how to to things the right way in the beginning og this thread, and proceeded with a panic: Calm down. He promised that doing it the wrong way WILL brake the system. A promise he has broken. I've been doing it the wrong way for a very long time without any problems whatsoever.

But he's right. Fix it. Now. I'm doing a test for you all. I'll tell you when my system crashes. That way robmoss2k can still keep his promise.
_________________
PKA Cuber
Please add [SOLVED] to the subject of your original post when you feel that your problem is resolved.
Adopt an unanswered post
Back to top
View user's profile Send private message
robmoss
Retired Dev
Retired Dev


Joined: 27 May 2003
Posts: 2634
Location: Jesus College, Oxford

PostPosted: Tue May 25, 2004 8:37 pm    Post subject: Reply with quote

Would you like me to change it to "unless you're very lucky"? :twisted:

Believe me - I learned the hard way. Do it right, or it'll bite you.
_________________
Reality is for those who can't face Science Fiction.

emerge -U will kill your Gentoo
ecatmur, Lord of Portage Bash Scripts
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Goto page Previous  1, 2, 3, 4, 5, 6, 7, 8, 9, 10  Next
Page 4 of 10

 
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