LinuxQuestions.org
Review your favorite Linux distribution.
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 02-10-2018, 10:37 AM   #1
suprateam
LQ Newbie
 
Registered: Mar 2014
Location: France, Lille
Distribution: slackware-current
Posts: 23

Rep: Reputation: Disabled
How to roll back package after installation/upgrade?


Hello,

I'm running slackware-current and as such, I'm prepared at least mentally to have issues here and then after package upgrade.
Here I think (aka yes not sure at all ) that my last slackpk update/install-new/upgrade break something.

Context:
I've build successfully 3-4 ago VPP on slackware https://github.com/FDio/vpp

Today I tried again and plouf, does not work.
Code:
  CC       tools/vppapigen/gram.o
  CC       vppinfra/timer.lo
  CC       tools/vppapigen/lex.o
In file included from /home/vpp/dev/vpp/build-root/../src/vppinfra/linux/mem.c:31:0:
/home/vpp/dev/vpp/build-root/../src/vppinfra/linux/syscall.h:43:1: error: static declaration of ‘memfd_create’ follows non-static declaration
 memfd_create (const char *name, unsigned int flags)
 ^~~~~~~~~~~~
In file included from /usr/include/bits/mman-linux.h:115:0,
                 from /usr/include/bits/mman.h:45,
                 from /usr/include/sys/mman.h:41,
                 from /home/vpp/dev/vpp/build-root/../src/vppinfra/linux/mem.c:22:
/usr/include/bits/mman-shared.h:46:5: note: previous declaration of ‘memfd_create’ was here
 int memfd_create (const char *__name, unsigned int __flags) __THROW;
     ^~~~~~~~~~~~
make[4]: *** [Makefile:6787: vppinfra/linux/mem.lo] Error 1
make[4]: *** Waiting for unfinished jobs....
make[4]: Leaving directory '/home/vpp/dev/vpp/build-root/build-tool-native/tools'
make[3]: *** [Makefile:7757: all-recursive] Error 1
make[3]: Leaving directory '/home/vpp/dev/vpp/build-root/build-tool-native/tools'
make[2]: *** [Makefile:3967: all] Error 2
make[2]: Leaving directory '/home/vpp/dev/vpp/build-root/build-tool-native/tools'
make[1]: *** [Makefile:686: tools-build] Error 2
make[1]: Leaving directory '/home/vpp/dev/vpp/build-root'
make: *** [Makefile:259: /home/vpp/dev/vpp/build-root/.bootstrap.ok] Error 2
15:45 vpp@r1:~/dev/vpp ((v18.01)) $
VPP source have not been updated ( no git pull ) so I guess it's something on my system that has changed.

Code:
In file included from /usr/include/bits/mman-linux.h:115:0,
                 from /usr/include/bits/mman.h:45,
                 from /usr/include/sys/mman.h:41,
                 from /home/vpp/dev/vpp/build-root/../src/vppinfra/linux/mem.c:22:
/usr/include/bits/mman-shared.h:46:5: note: previous declaration of ‘memfd_create’ was here
 int memfd_create (const char *__name, unsigned int __flags) __THROW;
When checking with *mman* with `slackpkg file-search` got results that it has smth to do with glibc-2.27-x86_64-1


From /var/log/packages and /var/log/removed_packages , glibc has been upgrade during my last upgrade yesterday:
Code:
17:29 root@ws1:/home/nico # ls -lastr /var/log/removed_packages/glibc* | grep 2018
 12 -rw-r--r-- 1 root root   8526 Oct 21 14:49 /var/log/removed_packages/glibc-solibs-2.26-x86_64-3-upgraded-2018-02-09,20:30:20
 28 -rw-r--r-- 1 root root  25110 Oct 21 14:53 /var/log/removed_packages/glibc-2.26-x86_64-3-upgraded-2018-02-09,20:30:35
268 -rw-r--r-- 1 root root 270888 Oct 21 14:53 /var/log/removed_packages/glibc-i18n-2.26-x86_64-3-upgraded-2018-02-09,20:30:44
  4 -rw-r--r-- 1 root root   1045 Oct 21 14:53 /var/log/removed_packages/glibc-profile-2.26-x86_64-3-upgraded-2018-02-09,20:30:56
 72 -rw-r--r-- 1 root root  71505 Dec  9 16:24 /var/log/removed_packages/glibc-zoneinfo-2017c-noarch-1-upgraded-2018-01-30,00:52:32
So now ..... how do I get an older version of slackware glibc packages to test a roll back ?
Then, is there a better way or tool to track down history of package version on Slackware ?

Thanks!
 
Old 02-10-2018, 10:44 AM   #2
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
I'd suggest keep a copy of the repo one version behind, so you can have it on your system for cases like this, then run
Code:
upgradepkg <pkg name(s)>
to revert back to the old ones in question.

ABob aka Alien BOB aka Eric Hameleers got a script to rsync
http://www.slackware.com/~alien/tools/
well have a look for yourself. though i do now that is not a solution for the right now, so pls wait for it...

Last edited by BW-userx; 02-10-2018 at 10:46 AM.
 
1 members found this post helpful.
Old 02-10-2018, 10:53 AM   #3
suprateam
LQ Newbie
 
Registered: Mar 2014
Location: France, Lille
Distribution: slackware-current
Posts: 23

Original Poster
Rep: Reputation: Disabled
Thanks BW-userx for the tip.
I can definitely help for future case !
 
Old 02-12-2018, 11:59 PM   #4
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
Quote:
Originally Posted by suprateam View Post
So now ..... how do I get an older version of slackware glibc packages to test a roll back ?
Then, is there a better way or tool to track down history of package version on Slackware ?
Sorry for the delay... by default, there is no way to roll back unless you keep the older versions. With -current being a rolling release, it doesn't keep older versions. You could tinker with Alien Bob's mirror script to change rsync to not delete older versions of files.

This would incur a larger amount of disk space, but could be handy to keep older versions of packages around.
 
1 members found this post helpful.
Old 02-13-2018, 04:44 AM   #5
allend
LQ 5k Club
 
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware64-15.0
Posts: 6,357

Rep: Reputation: 2739Reputation: 2739Reputation: 2739Reputation: 2739Reputation: 2739Reputation: 2739Reputation: 2739Reputation: 2739Reputation: 2739Reputation: 2739Reputation: 2739
Quote:
Then, is there a better way or tool to track down history of package version on Slackware ?
This is my method. Works for me.
 
1 members found this post helpful.
Old 02-13-2018, 09:27 AM   #6
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
With Alien Bob's mirror script, you can modify it to give it a unique name, so you can have two running then rotate them so one will always be one version behind the actual current updated one. that helps to cut back on taking up a lot of space, it is only going to be max under 15 GB for two full systems of Slack in my past experience in keeping only one. Just take the amount it it takes to install a full install of slack then times it by two and maybe give it a little more for the just in case I need it.

Looking at allend Idea it sounds good too, I'd mod it to just keep the what is already installed, if it is updated keep that old stuff and put it somewhere safe, add that checking for dups in the script that moves the old package. get the name check the storage for that name if it matches delete what is in storage then move the older one that has just been updated into storage. If no name match then just move it.

That way it is more like a rolling release but backwards. keeping only one version older then what has already been updated.

Last edited by BW-userx; 02-13-2018 at 09:34 AM.
 
Old 02-13-2018, 11:20 AM   #7
upnort
Senior Member
 
Registered: Oct 2014
Distribution: Slackware
Posts: 1,893

Rep: Reputation: 1161Reputation: 1161Reputation: 1161Reputation: 1161Reputation: 1161Reputation: 1161Reputation: 1161Reputation: 1161Reputation: 1161
I use rsnapshot for backups. I maintain a local Slackware repository using a modified version of Eric's original rsync script. I configure rsnapshot to backup the patches directory of the local mirror. In a disaster recovery the remainder of the local repository can be repopulated at any time. The backups provide a nice way to archive previous package versions.

Having access to previous versions is helpful for debugging, such as the recent kernel issues I reported.

I started backing up previous versions many years ago. I remember an Samba update prevented Samba from working. The bug was from upstream and patched within a few days, but I had to scramble to find the previous version of the Samba package.
 
1 members found this post helpful.
Old 02-14-2018, 01:10 AM   #8
suprateam
LQ Newbie
 
Registered: Mar 2014
Location: France, Lille
Distribution: slackware-current
Posts: 23

Original Poster
Rep: Reputation: Disabled
Thanks for the several feedbacks

I've started to use Alienbob's script to get a local mirror of packages.
I will take a look this weekend for keeping 1-2-3 version behind following your advice.

FTR: VPP compilation error against glibc2.27 is on the vpp side: https://lists.fd.io/g/vpp-dev/messag...0,2,0,10852663

Will set the topic as solved.
 
  


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
Can I roll back a failed libc6 upgrade? davcefai Debian 7 10-21-2007 02:04 AM
Howto undo updates or roll system back to initial installation? suguru SUSE / openSUSE 2 01-08-2006 11:31 PM
Roll back to stable ? tuxuser19 Debian 1 12-10-2005 06:59 AM
Any way to roll back? FKK Linux - Newbie 1 11-12-2005 03:44 AM
Kernel Roll Back jannino Linux - General 1 04-22-2005 11:11 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 04:39 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration