LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
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 12-09-2012, 02:30 PM   #1
Woodsman
Senior Member
 
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482

Rep: Reputation: 546Reputation: 546Reputation: 546Reputation: 546Reputation: 546Reputation: 546
Automating slackpkg


What clever methods are any of you using to automate the process of updating patches through slackpkg? I've gotten to the point with my LAN and collection of virtual machines, some systems of which I might not run for weeks, that I need to consider some form of automation when I run any particular system.

This is a mixed environment of 12.2, 13.1, 13.37, 14.0, and current, both 32 and 64-bit.

Thanks.
 
Old 12-09-2012, 03:03 PM   #2
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
Blog Entries: 2

Rep: Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886
Mirror the patches directories for the versions you have installed on one of the machines and use upgradepkg to do the job.
 
1 members found this post helpful.
Old 12-09-2012, 03:27 PM   #3
lpallard
Senior Member
 
Registered: Nov 2008
Posts: 1,045

Rep: Reputation: Disabled
Found this thread while searching for something else, and I happened to wonder as well how to patch slackware (more or less replicate the behavior of windows update in windows)...

I understand what you said TobiSGD but I have a question regarding project philosophy (if I can call it like that).

So on slack's mirrors, there are:
-slackware specific folders (...12.1, 12.2, 13.0...) for each release that are updated with their specific patches
-"-current" for the latest bleeding edge release
-and there's the last release (as of now, 14.0).

So are the slack team updating every releases with patches as well as having the last (14.0) and working on the -current in parallel?

If I update my 13.37 with the patches that are in 13.37, will I end up more or less with a hybrid between the original 13.37 & 14.0?

Last edited by lpallard; 12-09-2012 at 03:28 PM.
 
Old 12-09-2012, 03:35 PM   #4
Woodsman
Senior Member
 
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482

Original Poster
Rep: Reputation: 546Reputation: 546Reputation: 546Reputation: 546Reputation: 546Reputation: 546
Quote:
Mirror the patches directories for the versions you have installed on one of the machines and use upgradepkg to do the job.
Ah, yes. Simple. I was so focused on slackpkg I never thought about the simpler approach. Just run:

cd $LOCAL_PATCHES_DIR
upgradepkg *.txz

Thanks.
 
Old 12-09-2012, 03:47 PM   #5
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
Blog Entries: 2

Rep: Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886Reputation: 4886
Quote:
Originally Posted by lpallard View Post
So are the slack team updating every releases with patches as well as having the last (14.0) and working on the -current in parallel?

If I update my 13.37 with the patches that are in 13.37, will I end up more or less with a hybrid between the original 13.37 & 14.0?
Slackware usually only get's security fixes, unless there are real show-stopper bugs. Those are usually already fixed during the testing phase for the new release, so that is rather rare.

Since newer versions of software are only installed when they are security releases (which is for example the case with Firefox) you will not end up with a mixed release, 13.37 will stay 13.37.
 
1 members found this post helpful.
Old 12-09-2012, 07:59 PM   #6
Marcelo_Belfalas
Member
 
Registered: Apr 2012
Location: Brazil
Distribution: Slackware64-current multilib
Posts: 32

Rep: Reputation: 18
Well, I use slackroll to manage slackware updates...

I did a script to check for updates and put it on a cronjob to check hourly, it can easily adapted to when there's new updates, just update everything.

I'm not the best at bash script but here it is:

Code:
#!/bin/sh

STR=`slackroll update`;

if [[ $STR != *"no new entries"* ]]
then
	echo "Found Updates";
	echo $STR;
    	`DISPLAY=:0.0 su <user> -c "notify-send Slackroll \"There is new updates\""`;
else
	STR2=`slackroll list-transient`
	if [[ $STR2 != *"No transient packages found"* ]]
	then
		echo "Found Updates";
		echo $STR2;
		`DISPLAY=:0.0 su <user> -c "notify-send Slackroll \"There is new updates\""`;
	else
		echo "No updates found";
	fi
fi
 
Old 12-13-2012, 10:43 PM   #7
fogpipe
Member
 
Registered: Mar 2011
Distribution: Slackware 64 -current,
Posts: 550

Rep: Reputation: 196Reputation: 196
You might want to exclude some packages from automatic upgrade. The kernel for instance, maybe X and drivers.
Having your kernel over written might result in some suprises
 
1 members found this post helpful.
Old 12-13-2012, 11:34 PM   #8
jtsn
Member
 
Registered: Sep 2011
Posts: 922

Rep: Reputation: 480Reputation: 480Reputation: 480Reputation: 480Reputation: 480
Just a simple rc.local approach for single user desktop machines, which are used interactively:
Code:
if slackpkg check-updates | grep "ChangeLog"
then
    slackpkg update
    slackpkg upgrade-all
fi
In case of available updates, it displays a list with packages to be upgraded on the console and waits for confirmation, otherwise it just boots to login as usual.
 
Old 12-30-2012, 12:12 PM   #9
lpallard
Senior Member
 
Registered: Nov 2008
Posts: 1,045

Rep: Reputation: Disabled
Quote:
Originally Posted by jtsn View Post
Just a simple rc.local approach for single user desktop machines, which are used interactively:
Code:
if slackpkg check-updates | grep "ChangeLog"
then
    slackpkg update
    slackpkg upgrade-all
fi
In case of available updates, it displays a list with packages to be upgraded on the console and waits for confirmation, otherwise it just boots to login as usual.
Has anyone tested this method on a dummy machine or a VM?? I dont want to cook my desktop running fine now. Basically if I understand well, adding this to rc.local would look for updates at boot time and offer to upgrade or not. If chosen to upgrade, it would, if not it would continue to boot info the user env (KDE, console, etc..) as normal.

Where does it gets the upgraded packages? Do you need to specify a folder where all new packages are stored?
 
Old 12-30-2012, 12:33 PM   #10
dr.s
Member
 
Registered: Feb 2010
Distribution: Slackware64-current
Posts: 338

Rep: Reputation: 156Reputation: 156
Found this in Slackware docs but haven't tried it yet
http://docs.slackware.com/slackware:...dated_packages
 
  


Reply



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
[SOLVED] typos in latest /etc/slackpkg/mirrors(.new) [slackpkg-2.82.0-noarch-8.tgz] wailingwailer Slackware 4 09-22-2012 04:04 AM
Slackpkg: missing something in /usr/libexec/slackpkg/functions.d/dialog-functions.sh michelino Slackware 4 03-20-2007 12:22 PM
Automating installs ? carcassonne SUSE / openSUSE 2 07-01-2006 11:04 AM
Automating Pine kaplan71 Linux - Software 1 12-22-2005 03:21 AM
Automating modprobe? r_jensen11 Linux - Hardware 3 09-07-2003 08:30 PM

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

All times are GMT -5. The time now is 02:10 PM.

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