LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 08-17-2005, 05:05 PM   #1
jrdioko
Member
 
Registered: Oct 2002
Distribution: Debian 6.0.2 (squeeze)
Posts: 944

Rep: Reputation: 30
Question Slack upgrade downgrades packages


I recently upgraded from Slack 9.1 to 10.0, and noticed that several packages were downgraded. What does upgradepkg do if a version on 10.0 is older than what is currently on the system? I noticed that both gaim and fluxbox were removed and replaced with older versions when I upgraded. Is there any way I can look through logs and find out what was downgraded like this? It probably didn't affect much, but I don't like the idea that several packages were suddenly downgraded without my knowing.
 
Old 08-17-2005, 05:08 PM   #2
shilo
Senior Member
 
Registered: Nov 2002
Location: Stockton, CA
Distribution: Slackware 11 - kernel 2.6.19.1 - Dropline Gnome 2.16.2
Posts: 1,132

Rep: Reputation: 49
Check out /var/log/packages/removed_packages.
 
Old 08-17-2005, 05:27 PM   #3
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,986
Blog Entries: 11

Rep: Reputation: 880Reputation: 880Reputation: 880Reputation: 880Reputation: 880Reputation: 880Reputation: 880
Re: Slack upgrade downgrades packages

Quote:
Originally posted by jrdioko
I recently upgraded from Slack 9.1 to 10.0, and noticed that several packages were downgraded. What does upgradepkg do if a version on 10.0 is older than what is currently on the system? I noticed that both gaim and fluxbox were removed and replaced with older versions when I upgraded. Is there any way I can look through logs and find out what was downgraded like this? It probably didn't affect much, but I don't like the idea that several packages were suddenly downgraded without my knowing.
Looking at
less `which upgradepkg`
suggests that there's no actual version check taking
place these days ... the only references to the version
number are commented out.


Cheers,
Tink
 
Old 08-17-2005, 07:04 PM   #4
jrdioko
Member
 
Registered: Oct 2002
Distribution: Debian 6.0.2 (squeeze)
Posts: 944

Original Poster
Rep: Reputation: 30
Hmm, is there a relatively easy way (in a shell script) to see which files in /var/log/removed_packages/*upgraded* have a greater version number than the same program in /var/log/packages? Actually that would be something handy to put in UPGRADE.TXT.
 
Old 08-17-2005, 09:33 PM   #5
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,986
Blog Entries: 11

Rep: Reputation: 880Reputation: 880Reputation: 880Reputation: 880Reputation: 880Reputation: 880Reputation: 880
Quote:
Originally posted by jrdioko
Hmm, is there a relatively easy way (in a shell script) to see which files in /var/log/removed_packages/*upgraded* have a greater version number than the same program in /var/log/packages? Actually that would be something handy to put in UPGRADE.TXT.
I don't think it would be as easy as one wishes.

The problem is that there can be package names
with numerals in the name as well version numbers
with alphas in them.

This one
Code:
awk -F"-" '{for(i=1;i<NF;i++){if($i ~ "i.86" || $i == "norach") print $(i-1)}; }'
will catch MOST of them correctly ...



Cheers,
Tink

Last edited by Tinkster; 08-17-2005 at 10:23 PM.
 
Old 08-17-2005, 09:38 PM   #6
jrdioko
Member
 
Registered: Oct 2002
Distribution: Debian 6.0.2 (squeeze)
Posts: 944

Original Poster
Rep: Reputation: 30
That doesn't seem to work for me (unclosed bracket/parentheses somewhere I assume). I guess this is some motivation to learn enough bash/awk scripting to figure it out.
 
Old 08-17-2005, 10:22 PM   #7
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,986
Blog Entries: 11

Rep: Reputation: 880Reputation: 880Reputation: 880Reputation: 880Reputation: 880Reputation: 880Reputation: 880
Actually it was a copy & paste error on my side. There's
a ' missing at the end ... sowwy.


Cheers,
Tink
 
Old 08-17-2005, 10:43 PM   #8
LiNuCe
Member
 
Registered: Apr 2004
Location: France
Distribution: Slackware Linux 10.2
Posts: 119

Rep: Reputation: 15
Quote:
jrdioko :
Hmm, is there a relatively easy way (in a shell script) to see which files in /var/log/removed_packages/*upgraded* have a greater version number than the same program in /var/log/packages? Actually that would be something handy to put in UPGRADE.TXT.
In fact, the upgradepkg script upgrades every package you tell it to upgrade without trying to compare versions. The only reason for which upgradepkg could refuse to upgrade a package is when there is already an installed package with the same name AND the same version AND the same arch AND the same build id.

Version checking is a complex thing to write as there are tons of version formats to handle : even Swaret does not handle packages versions and it is probably the most popular, advanced package manager for Slackware Linux ! However, if a powerful package manager is the most important part of a Linux system for you, you should probably try Debian Linux.

-- LiNuCe
 
Old 08-17-2005, 10:56 PM   #9
jrdioko
Member
 
Registered: Oct 2002
Distribution: Debian 6.0.2 (squeeze)
Posts: 944

Original Poster
Rep: Reputation: 30
Quote:
Originally posted by LiNuCe
However, if a powerful package manager is the most important part of a Linux system for you, you should probably try Debian Linux.
No thanks, my friend.

I want to see exactly what's being done with my system, with no auto-dependency installation or complex package managers to hide anything. I left Windows so I could customize what I wanted, install what I wanted, and always be able to see and change what is being done with my system. I like the flexibility of installing from source combined with the ability to easily remove whatever I've done by monitoring the process with checkinstall. Oh, and I'm not using any distro that calls itself GNU/Linux with the Linux thrown on as an almost uncomfortable afterthought (oh, we currently use the Linux kernel but don't look at us like it was our choice).

Ah opinions...
 
Old 08-18-2005, 06:31 AM   #10
dunric
Member
 
Registered: Jul 2004
Distribution: Slackware
Posts: 462

Rep: Reputation: 77
Quote:
Version checking is a complex thing to write as there are tons of version formats to handle : even Swaret does not handle packages versions and it is probably the most popular, advanced package manager for Slackware Linux ! However, if a powerful package manager is the most important part of a Linux system for you, you should probably try Debian Linux.
I don't know if Swaret is still most used because development has slowed down significantly and latest (developement!) version is from September 2004. F.E. frequently updated slapt-get has version checking feature.
But besides that, after reaching some experience level with Linux or if you don't need to change/reinstall half of the system every day, automated package management like RPM or Debian is IMHO something to be avoided and philosophy of Slackware packages is like a nirvana in such case.
 
Old 08-18-2005, 10:58 AM   #11
LiNuCe
Member
 
Registered: Apr 2004
Location: France
Distribution: Slackware Linux 10.2
Posts: 119

Rep: Reputation: 15
Quote:
dunric> I don't know if Swaret is still most used because development has slowed down significantly and latest (developement!) version is from September 2004.
The latest version of Swaret has been announced 2 weeks ago.
Quote:
dunric> slapt-get has version checking feature.
I didn't know that. The author of this thread would probably be interested as that is exactly what he was looking for.
Quote:
dunric> But besides that, after reaching some experience level with Linux or if you don't need to change/reinstall half of the system every day, automated package management like RPM or Debian is IMHO something to be avoided and philosophy of Slackware packages is like a nirvana in such case.
Automated package managment is NOT "something to be avoided" : there are people who really need/like it and they are people who really don't need/like it.

-- LiNuCe
 
Old 08-18-2005, 11:08 AM   #12
MS3FGX
Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 351Reputation: 351Reputation: 351Reputation: 351
Slapt-get's version checking can check both the main program version, and also the release number, to make sure it always has the most recent version of the program.

27. How does the package version comparison algorithm work?

Say we have foo-1.1.3-i386-1rob and foo-1.1.3-i686-1.

The version parts will be compared, first 1, then 1, then 3. At this point,
both packages are equal, since 1.1.3 == 1.1.3. If one is greater at this
point, the version check returns.

Then, it checks to make sure that both pkgs have the same number of "version
parts". This is the case in this example, both have 3 (1,1,3). This is useful
when you see packages like 1.2 and 1.2.1. Whichever has more parts wins. At
this point, we know if one only has 2 parts, and the other has 3, then the
first two parts of both version strings have to be equal.

Then, the package versions are checked to see if they follow the Slackware
convention. This is determined by checking the first instance of '-' against
the last instance. If the pointer returned from index and rindex are
different, then we assume we have at least two package version separators
(meaning we should have an upstream version, arch, and build at least).

If two separators are found, the build portion of the string is located. The
integer value of the build strings are compared. So "1rob" has an integer
value of 1, and "1" has an integer value of 1. So in our example, both package
versions are the same.

If the only difference is the arch and the packages follow the conventions,
then they should always be equal.

If two separators are not found, then the entire version string from both pkgs
are compared via strcmp. This is a fallback mechanism.
 
Old 08-18-2005, 04:36 PM   #13
Xian
Member
 
Registered: Feb 2004
Location: 33.31N -111.97W
Distribution: SuSE
Posts: 918

Rep: Reputation: 31
Quote:
Originally posted by LiNuCe
Automated package managment is NOT "something to be avoided" : there are people who really need/like it and they are people who really don't need/like it.
Agree, and important to always point out that "package management" in Slackware with the tools currently available (Swaret, Slapt-get, Slackpkg) does not include handling your config files in /etc. Even if you use a package manager you will still need to view and update these by hand. This is an topic worth mentioning since many users coming from Debian, SuSE, etc. associate the use of a pkg mgt tool with eliminating this type of user activity.
 
Old 08-18-2005, 04:48 PM   #14
titopoquito
Senior Member
 
Registered: Jul 2004
Location: Ruhr Area, Germany
Distribution: Slackware64 14.0
Posts: 1,524

Rep: Reputation: 94
Once I had a problem with the version checking and swaret. There were two versions of a package in my local swaret folder and every time something other was changed swaret asked me about there being a newer version of blablabla and if I wanted to install it. I think it was about a version number with one and two digits (like package-i486-10/9.tgz). It's not idiot proof (I was idiot enough to "upgrade" to the older version of the package, but swaret did a good job in general with this.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Upgrade troubel slack 10.1 to slack 10.2 delta function Slackware 3 10-19-2005 11:47 PM
Using Slack 10's 2.6.7 kernel packages on Slack 10.1? SocialEngineer Slackware 1 03-05-2005 11:53 AM
What first upgrade kernel or upgrade slack 10.0 to current Kelean Slackware 7 01-16-2005 06:54 PM
WORKGUS downgrades X11 to 6.7.0 'patched' jlangelier Slackware 4 12-09-2004 12:28 PM
Upgrade more packages ..:eMa:.. Debian 1 04-07-2004 05:42 AM


All times are GMT -5. The time now is 03:07 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration