You are not logged in.

#1 2013-02-11 22:47:49

jamtat
Member
Registered: 2008-03-13
Posts: 185

Semi-automatic update/upgrade; is Arch wrong distro for these boxen?

I wanted to post here a semi-automatic update/upgrade solution I--with a lot of help from someone more knowledgeable--came up with in case it might be of benefit to anyone else. It's been working pretty well for me over the course of the last couple of weeks and should aid me in becoming a better Archer. I also want to ask in this thread for confirmation on whether installing Arch on a couple of machines I have that see fairly intermittent use is inadvisable: if so, I'll look into installing some other distro. First the semi-automatic update solution.

To begin with, what do I mean by "semi-automatic?" Mainly I mean something that's only partially automatic. See, I've come to understand that automating updates/upgrades is a bad idea©™. And I think I understand why. Still, I apparently lack the discipline to be a good Archer, upgrading/updating frequently so as to conform with the philosophy. So I thought I should use my computer to help me be more disciplined: that's partly what they're for, after all, isn't it?

I decided I might make the computer help me be more disciplined, first of all, by making it issue reminders at frequent, regular intervals, that it is time to update/upgrade. Of course cron came immediatelty to mind as part of the solution, though I ended up using the remind program instead. In any case, it seemed like a solution that, not only would remind me at regular, frequent intervals would be desireable, but one that would at the same time initiate the process, would be even better. I thought it must be possible to, for example, cause a terminal to open with a message and corresponding menu that would say something like "System update/upgrade needed: proceed now? 1. Yes 2. No"

This latter would be one of the elements that makes the solution semi-automatic (as opposed to automatic). Answering 2. in that terminal would cause the terminal to simply exit. Answering 1., on the other hand, runs the command sudo pacman -Syu. There is a further level of semi-automation at this stage: you are then prompted to enter the root password before pacman -Syu will run. So, no updating/upgrading happens without input at these two stages.

I should mention as I wrap up this description of my solution that there is yet another important element to it that, while independent of it, is nonetheless related: I subscribed some weeks ago to the Arch news RSS feed. I check that daily, so an even further level of semi-automation is in play here.

This seems to me like it will be a very good solution to bringing my behavior into better conformity with the Arch philosophy. It's worked well so far. That said, I'm certainly open to criticisms. I'm also very open to any improvements that might be suggested. Without further ado, here is the script I run every other day from the remind daemon:

#!/bin/bash
PS3='Begin full system upgrade?  '
options=("Yes" "No")
select opt in "${options[@]}"
do
     case $opt in
       "Yes")
          echo "Beginning full system upgrade..." 
          sudo pacman -Syu 
          exit 
          ;;
       "No")
          exit 
          ;;
         *)
          echo "Please choose the corresponding number" 
       ;;
     esac
done

Now, to my question about my other machines as possible Arch install targets. The above applies to the desktop machine in my apt. which is almost always powered on and connected to the 'net: what follows applies to two different machines.

One is a laptop that I use primarily when I travel. It often sits powered off for 1-2 months between uses. The other is an alternate desktop machine in my apt. that is also infrequently used: essentially, when both the wife and I want to work on-line separately--which is not all that frequently (she prefers knitting to computing during her time at home)--it gets fired up. Again, it often sits for 1-2 months without being used.

Now, it seems to me these machines are poor targets for an Arch install because they are far more frequently off-line than on-line, powered down than powered up. Thus they are very unlikely to be updated/upgraded on any kind of regular basis, and certainly never regularly and frequently, as seems to be recommended for Arch machines.

Am I correct in assuming I should be looking for some other distro to install on these infrequently-used machines?

Thanks,
James

Last edited by jamtat (2013-02-11 22:50:09)

Offline

#2 2013-02-12 06:20:27

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,412

Re: Semi-automatic update/upgrade; is Arch wrong distro for these boxen?

Search the forums, there is a tool (probably in community contributions) that does exactly what you are looking for... yet might not know it.  It runs an update, but before doing so, checks that news feed you subscribe to and then compares the potential updates against the updates.  If they are mentioned in the news, they are ignored and a warning is posted.

Okay, I think it is pacmatic, and it is apparently now in the repos.

Offline

#3 2013-02-12 08:15:59

bernarcher
Forum Fellow
From: Germany
Registered: 2009-02-17
Posts: 2,271

Re: Semi-automatic update/upgrade; is Arch wrong distro for these boxen?

Moving to Community Contributions Pacman & Package Upgrade Issues.


To know or not to know ...
... the questions remain forever.

Offline

#4 2013-02-12 16:14:01

jamtat
Member
Registered: 2008-03-13
Posts: 185

Re: Semi-automatic update/upgrade; is Arch wrong distro for these boxen?

WonderWoofy wrote:

Search the forums, there is a tool (probably in community contributions) that does exactly what you are looking for... yet might not know it.  It runs an update, but before doing so, checks that news feed you subscribe to and then compares the potential updates against the updates.  If they are mentioned in the news, they are ignored and a warning is posted.

Okay, I think it is pacmatic, and it is apparently now in the repos.

Thanks for your input, WonderWoofy. I ran across that script, which I think used to be called safepac, in a forum posting a couple of weeks ago. I asked about it on the forums and got nearly-universal negative feedback. And I decided a solution like the one I envisioned might work better for me anyway. After creating this thread I've discerned a needed improvement: that script should check first whether another instance of itself is running and either kill the second before running, or else simply refuse to run. I'll start looking into how that might be done.

In any case, I'm actually just as interested in getting feedback on the two other machines I posted about and on whether they're poor targets for an Arch installation. Can anyone comment on that? Seems to me they're not: disagreements, expressions of assent, anyone?

James

Offline

#5 2013-02-13 01:44:41

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 5,662

Re: Semi-automatic update/upgrade; is Arch wrong distro for these boxen?

I like pacmatic (as suggested at https://wiki.archlinux.org/index.php/Pa … _pacmatic). What is supposed to be wrong with it?

It doesn't ignore updates, by the way. It does two things. First, it checks the news and tells you about important news items as soon as you run e.g. pacmatic -Syu. Then it runs the upgrade in the normal way. For example, a news item today concerned lvm2, dev-mapper and linux being upgraded together. It gave me the news item. Then it did the usual paman upgrade routine and upgraded everything, including those packages. Second, every time you run it, it reminds you of any *.pacnew files you haven't dealt with and asks if you want to deal with them now. At least, it asks about most. It never mentions kdmrc.pacnew for some reason.

It's just a wrapper for pacman. From the script:

Pacmatic is a pacman wrapper that takes care of menial but critial tasks.

These include
    Checking the archlinux.org news
    Summarizing the arch-general mailing list
    Reminding if it has been a while since the last sync
    Reporting pacnew files
    Editing pacnew files

Personally, I've installed an alternative distro on machines which I'm not sure I will be using very regularly. (Also, I like having distinct distros just in case something goes wrong in one case - even if it is a bit of a faff sometimes.)

Last edited by cfr (2013-02-13 01:49:24)


How To Ask Questions The Smart Way | Help Vampires

Arch Linux | x86_64 | GPT | EFI boot | grub2 | systemd | LVM2 on LUKS
Lenovo x121e | Intel(R) Core(TM) i3-2367M CPU @ 1.40GHz GenuineIntel | Intel Centrino Wireless-N 1000 | US keyboard with Euro | 320G 7200 RPM Seagate HDD

Offline

#6 2013-02-13 03:12:45

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,020

Re: Semi-automatic update/upgrade; is Arch wrong distro for these boxen?

About the two rarely used computers:
    Arch, being a rolling release, should be maintained regularly like a car should be maintained regularly. You can get away with doing the maintenance less often then recommended but you will end up having more problems. I'd recommend once a week to keep the maintenance easy, others might think differently. If you're not going to be inclined to open up that travel laptop once a week to maintain it you might be better off using something like debian on it. There's nothing wrong with using a distro like debian, it just doesn't have the latest software available.
    On the other hand, if you never update you never have problems with updates...


You're just jealous because the voices only talk to me.

Offline

#7 2013-02-15 12:29:07

jamtat
Member
Registered: 2008-03-13
Posts: 185

Re: Semi-automatic update/upgrade; is Arch wrong distro for these boxen?

cfr wrote:

I like pacmatic (as suggested at https://wiki.archlinux.org/index.php/Pa … _pacmatic). What is supposed to be wrong with it?

It doesn't ignore updates, by the way. It does two things. First, it checks the news and tells you about important news items as soon as you run e.g. pacmatic -Syu. Then it runs the upgrade in the normal way. For example, a news item today concerned lvm2, dev-mapper and linux being upgraded together. . .

It's just a wrapper for pacman.

My mistake. It looks like pacmatic and safepac, though sharing many similarities, are two different scripts: pacmatic is less automated and would therefore, I assume, not be subject to the same criticisms I heard voiced about safepac.

Thanks,
James

Offline

#8 2013-02-15 12:35:04

jamtat
Member
Registered: 2008-03-13
Posts: 185

Re: Semi-automatic update/upgrade; is Arch wrong distro for these boxen?

The laptop is meant to provide convenience by allowing me to compute while traveling. Having to remember, while not traveling, to start it up and check for and install updates weekly, reduces the convenience factor. Sounds like I should be installing something along the lines of Debian testing on these two machines.

Thanks,
James

Offline

#9 2013-02-16 12:22:35

jonathan183
Member
Registered: 2008-06-11
Posts: 14

Re: Semi-automatic update/upgrade; is Arch wrong distro for these boxen?

There is no need for weekly updates. Not updating for several months can go well ... and sometimes not so well. It depends on the significance of the updates, using pacmatic means you will know there is likely to be issues before you do the update. If you want everything to happen automagically then Debian would be a better distro for this imho.
Personally I run several distros Arch being one, it's kept up to date and relatively simple to understand how things work and what's going on. I also run Mint Debian Edition using Debian stable repositories, which works well if you don't need the latest software.
Failing to update for several months is likely to increase entertainment value on Arch, but leaving updates several months has had little impact on the update process for Debian stable. Just because updates are less regular does not exclude the use of Arch, only you will know what you need and effort you are prepared to put in to keeping things up to date - or performing updates.

Last edited by jonathan183 (2013-02-16 12:24:16)

Offline

Board footer

Powered by FluxBB