[3597] in SIPB_Linux_Development

home help back first fref pref prev next nref lref last post

Re: testing failure

daemon@ATHENA.MIT.EDU (Angie Kelic)
Sat Dec 1 12:32:20 2001

Message-Id: <200112011732.MAA10529@cutter-john.mit.edu>
To: Derek Atkins <warlord@MIT.EDU>
cc: linux-dev@MIT.EDU
In-Reply-To: Your message of "30 Nov 2001 18:43:12 EST."
             <sjm667rn7u7.fsf@benjamin.ihtfp.org> 
Date: Sat, 01 Dec 2001 12:32:15 -0500
From: Angie Kelic <sly@MIT.EDU>

Well, actually since the epoch numbers existed in the release-rpms
files that athena uses and not in the ones that we generated, copying
the files out of afs space that are used by athena and the standard
hotline installers as release-rpms file will in fact solve the problem.

In message <sjm667rn7u7.fsf@benjamin.ihtfp.org>, 
Derek Atkins writes:

>This wont help with the Epoch problem which also needs to be fixed
>if we want a direct update from a SIPB-installed machine to 9.0
>
>-derek
>
>Angie Kelic <sly@MIT.EDU> writes:
>
>> Note: someone who knows python should sanity check the command.
>> 
>> So, it turns out that the script runs in a CHROOT'd environment
>> of /mnt/sysimage -- this means that any reference to / will
>> do the wrong thing.
>> 
>> Can you please revert the changes I made?
>> 
>> I submit the following as a slightly cleaner way to do the whole
>> thing in python that won't actually require anyone to change
>> anything in this script or extraneous files when they copy in
>> new RPMS -- basically, it figures out which athena version it
>> is on its own (we hope):
>> 
>> prowler:~ % diff -u installclass.py.src installclass.py
>> --- installclass.py.src	Fri Nov 30 18:32:16 2001
>> +++ installclass.py	Fri Nov 30 18:12:01 2001
>> @@ -220,7 +220,7 @@
>>  	self.setPostScript('''
>>  #!/bin/sh
>>  
>> -ATHENAVERSION=8.4.0
>> +ATHENAVERSION=`machtype -L`
>>  ROOT=/
>>  
>>  # Get network address:
>> @@ -290,14 +290,14 @@
>>    fi
>>  fi
>>  
>> -# This is a kluge and requires knowing how rpmupdate parses the
>> -# release-rpms file.  It also assumes we are not doing any custom
>> -# installs, since it lists every installed rpm in release-rpms.
>> -# rpmupdate knows that any rpm listed in release-rpms was all
>> -# installed by the release, and if the release doesn't think the rpm
>> -# should be installed any more, rpmupdate will remove it.
>> -rpm -qa --queryformat '/%{NAME}-%{VERSION}-%{RELEASE}.%{ARCH}.rpm\n' | \
>> -	grep -v '^kernel-smp' > /var/athena/release-rpms
>> +#Let's try this in Python, it's cleaner and will require fewer changes
>> +#This copies the correct version of release-rpms out of afs using the
>> +#web (we need to export the variable before python can use it)
>> +
>> +ATHENA_URL="http://web.mit.edu/afs/athena/system/rhlinux/control/list-$ATHENAVERSION"
>> +export ATHENA_URL
>> +
>> +python -c "import os, urllib; open('/var/athena/release-rpms', 'w').write(urllib.urlopen(os.envi
>ron['ATHENA_URL'])).read())"
>>  
>>  cp /tmp/install.log /var/athena/install.log
>>  chmod 600 /var/athena/install.log
>> 
>
>-- 
>       Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
>       Member, MIT Student Information Processing Board  (SIPB)
>       URL: http://web.mit.edu/warlord/    PP-ASEL-IA     N1NWH
>       warlord@MIT.EDU                        PGP key available

home help back first fref pref prev next nref lref last post