/[smeserver]/rpms/anaconda/sme8/anaconda-11.1.2.168-smepatches.patch
ViewVC logotype

Contents of /rpms/anaconda/sme8/anaconda-11.1.2.168-smepatches.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download)
Tue Apr 14 19:25:04 2009 UTC (15 years, 2 months ago) by slords
Branch: MAIN
* Tue Jun 24 2008 Shad L. Lords <slords@mail.com> 11.1.2.168-1.el5.sme.1
- Apply SME patches
- Make progress box wider
- Fix titlebar spacing
- Force UTC for time settings
- Automate bootloader upgrades
- Change erase disks to upgrade dialog
- Make install headless
- Don't warn if no kernels were installed
- Add format warning (default to no)
- Always upgrade to best arch version of package
- Remove mail to root in mdadm
- Allow grub to be installed on raid device
- Allow creating degraded raid arrays
- Set/write keyboard config in headless mode
- Display window and run post-install script when using kickstart file
- Update supported languages
- Allow language updates to be part of updates image
- Start boot raid device first so it will sync first
- Check e-smith-release instead of redhat-release
- Log info about degraded arrays instead of not starting them
- Don't crash if you can't go back to previous screen
- Only recreate initrd if kernel was installed
- Don't display warning about no being able to remove rpmdb files

1 diff -up anaconda-11.1.2.168/anaconda.smepatches anaconda-11.1.2.168/anaconda
2 --- anaconda-11.1.2.168/anaconda.smepatches 2008-12-18 03:21:19.000000000 -0700
3 +++ anaconda-11.1.2.168/anaconda 2009-04-14 12:35:22.000000000 -0600
4 @@ -992,6 +992,9 @@ if __name__ == "__main__":
5 anaconda.dispatch.skipStep("bootloadersetup", permanent = 1)
6 anaconda.dispatch.skipStep("instbootloader", permanent = 1)
7
8 + # we don't want to waste time probing
9 + opts.isHeadless = 1
10 +
11 # set up the headless case
12 if opts.isHeadless == 1:
13 anaconda.id.setHeadless(opts.isHeadless)
14 diff -up anaconda-11.1.2.168/bootloader.py.smepatches anaconda-11.1.2.168/bootloader.py
15 --- anaconda-11.1.2.168/bootloader.py.smepatches 2008-12-18 03:21:19.000000000 -0700
16 +++ anaconda-11.1.2.168/bootloader.py 2009-04-14 12:36:12.000000000 -0600
17 @@ -210,11 +210,6 @@ def writeBootloader(anaconda):
18 except bootloaderInfo.BootyNoKernelWarning:
19 if not justConfigFile:
20 w.pop()
21 - if anaconda.intf:
22 - anaconda.intf.messageWindow(_("Warning"),
23 - _("No kernel packages were installed on your "
24 - "system. Your boot loader configuration "
25 - "will not be changed."))
26
27 dosync()
28
29 diff -up anaconda-11.1.2.168/findpackageset.py.smepatches anaconda-11.1.2.168/findpackageset.py
30 --- anaconda-11.1.2.168/findpackageset.py.smepatches 2008-12-18 03:21:19.000000000 -0700
31 +++ anaconda-11.1.2.168/findpackageset.py 2009-04-14 12:38:55.000000000 -0600
32 @@ -108,21 +108,15 @@ def findpackageset(hdrlist, dbPath='/'):
33 # loop through packages and find ones which are a newer
34 # version than what we have
35 for ( name, arch ) in instDict.keys():
36 - if ( name, arch ) in availDict.keys():
37 - # Exact arch upgrade
38 - h = instDict[(name, arch)]
39 - pkg = availDict[(name,arch)]
40 - comparePackageForUpgrade(updDict, h, pkg)
41 - else:
42 - # See if we have a better arch than that installed
43 - if name in availNames.keys():
44 - bestarch = findBestArch(availNames[name])
45 - if not bestarch:
46 - continue
47 - if availDict.has_key((name,bestarch)):
48 - h = instDict[(name,arch)]
49 - pkg = availDict[(name,bestarch)]
50 - comparePackageForUpgrade(updDict, h, pkg)
51 + # See if we have a better arch than that installed
52 + if name in availNames.keys():
53 + bestarch = findBestArch(availNames[name])
54 + if not bestarch:
55 + continue
56 + if availDict.has_key((name,bestarch)):
57 + h = instDict[(name,arch)]
58 + pkg = availDict[(name,bestarch)]
59 + comparePackageForUpgrade(updDict, h, pkg)
60
61 # handle obsoletes
62 for pkg in hdlist:
63 diff -up anaconda-11.1.2.168/fsset.py.smepatches anaconda-11.1.2.168/fsset.py
64 --- anaconda-11.1.2.168/fsset.py.smepatches 2008-12-18 03:21:19.000000000 -0700
65 +++ anaconda-11.1.2.168/fsset.py 2009-04-14 12:47:12.000000000 -0600
66 @@ -1456,7 +1456,6 @@ class FileSystemSet:
67 cf = """
68 # mdadm.conf written out by anaconda
69 DEVICE partitions
70 -MAILADDR root
71 """
72 for ent in self.entries:
73 if ent.device.getName() != "RAIDDevice":
74 @@ -1611,6 +1610,7 @@ MAILADDR root
75
76 if bootDev.getName() == "RAIDDevice":
77 ret['boot'] = (bootDev.device, N_("RAID Device"))
78 + ret['mbr'] = (bl.drivelist[0], N_("Master Boot Record (MBR)"))
79 return ret
80
81 if iutil.getPPCMacGen() == "NewWorld":
82 @@ -1900,6 +1900,10 @@ MAILADDR root
83 entry.device.setupDevice(chroot, vgdevice = vg)
84 self.volumesCreated = 1
85
86 + def createBootRaid (self, chroot='/'):
87 + bootDev = self.getBootDev()
88 + if bootDev.getDevice().startswith('md'):
89 + bootDev.setupDevice(chroot)
90
91 def makeFilesystems (self, chroot='/'):
92 formatted = []
93 @@ -2478,11 +2482,20 @@ class RAIDDevice(Device):
94 self.minor)
95
96 def raidTab (self, devPrefix='/dev'):
97 + if self.level == 1:
98 + nDisks = max(2, self.numDisks)
99 + elif self.level == 5:
100 + nDisks = max(3, self.numDisks)
101 + elif self.level == 6:
102 + nDisks = max(4, self.numDisks)
103 + else:
104 + nDisks = self.numDisks
105 +
106 entry = ""
107 entry = entry + "raiddev %s/%s\n" % (devPrefix,
108 self.device,)
109 entry = entry + "raid-level %d\n" % (self.level,)
110 - entry = entry + "nr-raid-disks %d\n" % (self.numDisks,)
111 + entry = entry + "nr-raid-disks %d\n" % (nDisks,)
112 entry = entry + "chunk-size %s\n" %(self.chunksize,)
113 entry = entry + "persistent-superblock 1\n"
114 entry = entry + "nr-spare-disks %d\n" % (self.spares,)
115 @@ -2492,6 +2505,10 @@ class RAIDDevice(Device):
116 device)
117 entry = entry + " raid-disk %d\n" % (i,)
118 i = i + 1
119 + while i < nDisks:
120 + entry = entry + " device dev/null\n"
121 + entry = entry + " failed-disk %d\n" % (i,)
122 + i = i + 1
123 i = 0
124 for device in [m.getDevice() for m in self.members[self.numDisks:]]:
125 entry = entry + " device %s/%s\n" % (devPrefix,
126 @@ -2504,6 +2521,15 @@ class RAIDDevice(Device):
127 def devify(x):
128 return "/dev/%s" %(x,)
129
130 + if self.level == 1:
131 + nDisks = max(2, self.numDisks)
132 + elif self.level == 5:
133 + nDisks = max(3, self.numDisks)
134 + elif self.level == 6:
135 + nDisks = max(4, self.numDisks)
136 + else:
137 + nDisks = self.numDisks
138 +
139 node = "%s/%s" % (devPrefix, self.device)
140 isys.makeDevInode(self.device, node)
141
142 @@ -2516,12 +2542,18 @@ class RAIDDevice(Device):
143 args = ["--create", "/dev/%s" %(self.device,),
144 "--run", "--chunk=%s" %(self.chunksize,),
145 "--level=%s" %(self.level,),
146 - "--raid-devices=%s" %(self.numDisks,)]
147 + "--raid-devices=%s" %(nDisks,)]
148
149 if self.spares > 0:
150 args.append("--spare-devices=%s" %(self.spares,),)
151
152 args.extend(memberDevs)
153 +
154 + i = 0
155 + while self.numDisks + i < nDisks:
156 + args.append("missing")
157 + i = i + 1
158 +
159 log.info("going to run: %s" %(["/usr/sbin/mdadm"] + args,))
160 iutil.execWithRedirect ("/usr/sbin/mdadm", args,
161 stderr="/dev/tty5", stdout="/dev/tty5")
162 diff -up anaconda-11.1.2.168/instdata.py.smepatches anaconda-11.1.2.168/instdata.py
163 --- anaconda-11.1.2.168/instdata.py.smepatches 2008-12-18 03:21:19.000000000 -0700
164 +++ anaconda-11.1.2.168/instdata.py 2009-04-14 12:48:55.000000000 -0600
165 @@ -145,8 +145,7 @@ class InstallData:
166 def write(self):
167 self.instLanguage.write (self.anaconda.rootPath)
168
169 - if not self.isHeadless:
170 - self.keyboard.write (self.anaconda.rootPath)
171 + self.keyboard.write (self.anaconda.rootPath)
172
173 self.timezone.write (self.anaconda.rootPath)
174
175 @@ -264,8 +263,8 @@ class InstallData:
176 f.write("key %s\n" %(self.instClass.installkey,))
177
178 self.instLanguage.writeKS(f)
179 + self.keyboard.writeKS(f)
180 if not self.isHeadless:
181 - self.keyboard.writeKS(f)
182 self.xsetup.writeKS(f, self.desktop, self.ksdata)
183 self.network.writeKS(f)
184 self.zfcp.writeKS(f)
185 diff -up anaconda-11.1.2.168/kickstart.py.smepatches anaconda-11.1.2.168/kickstart.py
186 --- anaconda-11.1.2.168/kickstart.py.smepatches 2008-12-18 03:21:19.000000000 -0700
187 +++ anaconda-11.1.2.168/kickstart.py 2009-04-14 12:50:06.000000000 -0600
188 @@ -835,6 +835,15 @@ class Kickstart(cobject):
189 w.pop()
190
191 def postAction(self, anaconda, serial):
192 + win = anaconda.intf.waitWindow(_("Post Install Script"),
193 + _("The post installation script is running..."))
194 +
195 + script = ( "#!/bin/sh\nmkdir -p /var/lib/dhcp; /sbin/syslogd ; sleep 2; /sbin/e-smith/signal-event post-install\n" )
196 + s = Script(script, interp="/bin/sh", inChroot=1)
197 + log.info("%s", s)
198 + s.run(anaconda.rootPath, serial)
199 + win.pop()
200 +
201 postScripts = filter (lambda s: s.type == KS_SCRIPT_POST,
202 self.ksdata.scripts)
203
204 diff -up anaconda-11.1.2.168/lang-table.smepatches anaconda-11.1.2.168/lang-table
205 --- anaconda-11.1.2.168/lang-table.smepatches 2008-12-18 03:21:19.000000000 -0700
206 +++ anaconda-11.1.2.168/lang-table 2009-04-14 12:52:14.000000000 -0600
207 @@ -1,54 +1,20 @@
208 -Afrikaans af latarcyrheb-sun16 af_ZA.UTF-8 us Africa/Johannesburg
209 -Arabic ar latarcyrheb-sun16 ar_SA.UTF-8 us Asia/Riyadh
210 -Assamese as none as_IN.UTF-8 us Asia/Calcutta
211 -Bengali bn none bn_BD.UTF-8 us Asia/Dhaka
212 -Bengali(India) bn none bn_IN.UTF-8 us Asia/Calcutta
213 Bulgarian bg latarcyrheb-sun16 bg_BG.UTF-8 bg Europe/Sofia
214 -Catalan ca latarcyrheb-sun16 ca_ES.UTF-8 es Europe/Madrid
215 Chinese(Simplified) zh_CN none zh_CN.UTF-8 us Asia/Shanghai
216 -Chinese(Traditional) zh_TW none zh_TW.UTF-8 us Asia/Taipei
217 -Croatian hr latarcyrheb-sun16 hr_HR.UTF-8 croat Europe/Zagreb
218 -Czech cs latarcyrheb-sun16 cs_CZ.UTF-8 cz-lat2 Europe/Prague
219 Danish da latarcyrheb-sun16 da_DK.UTF-8 dk Europe/Copenhagen
220 Dutch nl latarcyrheb-sun16 nl_NL.UTF-8 nl Europe/Amsterdam
221 English en latarcyrheb-sun16 en_US.UTF-8 us America/New_York
222 -Estonian et latarcyrheb-sun16 et_EE.UTF-8 et Europe/Tallinn
223 -Finnish fi latarcyrheb-sun16 fi_FI.UTF-8 fi Europe/Helsinki
224 French fr latarcyrheb-sun16 fr_FR.UTF-8 fr-latin1 Europe/Paris
225 German de latarcyrheb-sun16 de_DE.UTF-8 de-latin1-nodeadkeys Europe/Berlin
226 Greek el iso07u-16 el_GR.UTF-8 gr Europe/Athens
227 -Gujarati gu none gu_IN.UTF-8 us Asia/Calcutta
228 -Hindi hi none hi_IN.UTF-8 us Asia/Calcutta
229 Hungarian hu latarcyrheb-sun16 hu_HU.UTF-8 hu Europe/Budapest
230 -Icelandic is latarcyrheb-sun16 is_IS.UTF-8 is-latin1 Atlantic/Reykjavik
231 Indonesian id latarcryheb-sun16 id_ID.UTF-8 us Asia/Jakarta
232 Italian it latarcyrheb-sun16 it_IT.UTF-8 it Europe/Rome
233 Japanese ja none ja_JP.UTF-8 jp106 Asia/Tokyo
234 -Kannada kn none kn_IN.UTF-8 us Asia/Calcutta
235 -Korean ko none ko_KR.UTF-8 us Asia/Seoul
236 -Macedonian mk latarcyrheb-sun16 mk_MK.UTF-8 mk Europe/Skopje
237 -Malay ms latarcyrheb-sun16 ms_MY.UTF-8 us Asia/Kuala_Lumpur
238 -Malayalam ml none ml_IN.UTF-8 us Asia/Calcutta
239 -Marathi mr none mr_IN.UTF-8 us Asia/Calcutta
240 Norwegian nb latarcyrheb-sun16 nb_NO.UTF-8 no Europe/Oslo
241 -Northern Sotho nso latarcyrheb-sun16 nso_ZA.UTF-8 us Africa/Johannesburg
242 -Oriya or none or_IN.UTF-8 us Asia/Calcutta
243 -Polish pl latarcyrheb-sun16 pl_PL.UTF-8 pl2 Europe/Warsaw
244 Portuguese pt latarcyrheb-sun16 pt_PT.UTF-8 pt-latin1 Europe/Lisbon
245 Portuguese(Brazilian) pt_BR latarcyrheb-sun16 pt_BR.UTF-8 br-abnt2 America/Sao_Paulo
246 -Punjabi pa none pa_IN.UTF-8 us Asia/Calcutta
247 Russian ru latarcyrheb-sun16 ru_RU.UTF-8 ru Europe/Moscow
248 -Serbian sr latarcyrheb-sun16 sr_CS.UTF-8 sr-cy Europe/Belgrade
249 -Serbian(Latin) sr@Latn latarcyrheb-sun16 sr_CS.UTF-8@Latn sr-cy Europe/Belgrade
250 -Sinhala si none si_LK.UTF-8 us Asia/Colombo
251 -Slovak sk latarcyrheb-sun16 sk_SK.UTF-8 sk-qwerty Europe/Bratislava
252 Slovenian sl latarcyrheb-sun16 sl_SI.UTF-8 slovene Europe/Ljubljana
253 Spanish es latarcyrheb-sun16 es_ES.UTF-8 es Europe/Madrid
254 Swedish sv latarcyrheb-sun16 sv_SE.UTF-8 sv-latin1 Europe/Stockholm
255 -Tamil ta none ta_IN.UTF-8 us Asia/Calcutta
256 -Telugu te none te_IN.UTF-8 us Asia/Calcutta
257 Turkish tr latarcyrheb-sun16 tr_TR.UTF-8 trq Europe/Istanbul
258 -Ukrainian uk latarcyrheb-sun16 uk_UA.UTF-8 ua-utf Europe/Kiev
259 -Vietnamese vi latarcyrheb-sun16 vi_VN.UTF-8 us Asia/Saigon
260 -Welsh cy latarcyrheb-sun16 cy_GB.UTF-8 uk Europe/London
261 -Zulu zu latarcyrheb-sun16 zu_ZA.UTF-8 us Africa/Johannesburg
262 diff -up anaconda-11.1.2.168/language.py.smepatches anaconda-11.1.2.168/language.py
263 --- anaconda-11.1.2.168/language.py.smepatches 2008-12-18 03:21:19.000000000 -0700
264 +++ anaconda-11.1.2.168/language.py 2009-04-14 12:57:23.000000000 -0600
265 @@ -57,7 +57,9 @@ class Language:
266 self.current = "en_US.UTF-8"
267
268 # English name -> native name mapping
269 - search = ('lang-names', '/usr/lib/anaconda/lang-names')
270 + search = ('lang-names', '/tmp/updates/lang-names',
271 + '/mnt/source/RHupdates/lang-names',
272 + '/usr/lib/anaconda/lang-names')
273 for path in search:
274 if os.access(path, os.R_OK):
275 f = open(path, 'r')
276 @@ -109,6 +111,8 @@ class Language:
277
278 def getNickByName (self, name):
279 for k in self.localeInfo.keys():
280 + if k == 'C':
281 + continue
282 row = self.localeInfo[k]
283 if row[0] == name:
284 return k
285 diff -up anaconda-11.1.2.168/packages.py.smepatches anaconda-11.1.2.168/packages.py
286 --- anaconda-11.1.2.168/packages.py.smepatches 2008-12-18 03:21:19.000000000 -0700
287 +++ anaconda-11.1.2.168/packages.py 2009-04-14 12:58:23.000000000 -0600
288 @@ -147,6 +147,7 @@ def turnOnFilesystems(anaconda):
289 anaconda.id.diskset.savePartitions ()
290 anaconda.id.partitions.doEncryptionRetrofits()
291 anaconda.id.fsset.checkBadblocks(anaconda.rootPath)
292 + anaconda.id.fsset.createBootRaid(anaconda.rootPath)
293 if not anaconda.id.fsset.volumesCreated:
294 try:
295 anaconda.id.fsset.createLogicalVolumes(anaconda.rootPath)
296 diff -up anaconda-11.1.2.168/partedUtils.py.smepatches anaconda-11.1.2.168/partedUtils.py
297 --- anaconda-11.1.2.168/partedUtils.py.smepatches 2008-12-18 03:21:19.000000000 -0700
298 +++ anaconda-11.1.2.168/partedUtils.py 2009-04-14 12:59:39.000000000 -0600
299 @@ -513,8 +513,8 @@ def sniffFilesystemType(device):
300 return None
301
302 def getReleaseString(mountpoint):
303 - if os.access(mountpoint + "/etc/redhat-release", os.R_OK):
304 - f = open(mountpoint + "/etc/redhat-release", "r")
305 + if os.access(mountpoint + "/etc/e-smith-release", os.R_OK):
306 + f = open(mountpoint + "/etc/e-smith-release", "r")
307 try:
308 lines = f.readlines()
309 except IOError:
310 @@ -556,6 +556,7 @@ def productMatches(oldproduct, newproduc
311 return 1
312
313 productUpgrades = {
314 + "SME Server": ("Mitel Networks", "SME Server", "e-smith server", ),
315 "Red Hat Enterprise Linux Server": ("Red Hat Enterprise Linux Client release 5",
316 "Red Hat Enterprise Linux Server release 5"),
317 "Red Hat Enterprise Linux Client": ("Red Hat Enterprise Linux Client release 5",
318 diff -up anaconda-11.1.2.168/raid.py.smepatches anaconda-11.1.2.168/raid.py
319 --- anaconda-11.1.2.168/raid.py.smepatches 2008-12-18 03:21:19.000000000 -0700
320 +++ anaconda-11.1.2.168/raid.py 2009-04-14 13:05:17.000000000 -0600
321 @@ -123,7 +123,17 @@ def scanForRaid(drives):
322 raidList = []
323 for key in raidSets.keys():
324 (level, totalDisks, mdMinor, devices) = raidSets[key]
325 - if len(devices) < totalDisks:
326 + if len(devices) == totalDisks - 1 and level in (1, 5, 6):
327 + log.info("missing components of raid device md%d. The "
328 + "raid device needs %d drive(s) and only %d (was/were) found. "
329 + "This raid device will be started in degraded mode.", mdMinor,
330 + totalDisks, len(devices))
331 + elif len(devices) == totalDisks - 2 and level == 6:
332 + log.info("missing components of raid device md%d. The "
333 + "raid device needs %d drive(s) and only %d (was/were) found. "
334 + "This raid device will be started in degraded mode.", mdMinor,
335 + totalDisks, len(devices))
336 + elif len(devices) < totalDisks:
337 log.warning("missing components of raid device md%d. The "
338 "raid device needs %d drive(s) and only %d (was/were) "
339 "found. This raid device will not be started.", mdMinor,
340 @@ -177,11 +187,11 @@ def get_raid_min_members(raidlevel):
341 if isRaid0(raidlevel):
342 return 2
343 elif isRaid1(raidlevel):
344 - return 2
345 + return 1
346 elif isRaid5(raidlevel):
347 - return 3
348 + return 2
349 elif isRaid6(raidlevel):
350 - return 4
351 + return 2
352 else:
353 raise ValueError, "invalid raidlevel in get_raid_min_members"
354
355 diff -up anaconda-11.1.2.168/text.py.smepatches anaconda-11.1.2.168/text.py
356 --- anaconda-11.1.2.168/text.py.smepatches 2008-12-18 03:21:19.000000000 -0700
357 +++ anaconda-11.1.2.168/text.py 2009-04-14 13:06:35.000000000 -0600
358 @@ -716,7 +716,8 @@ class InstallInterface:
359 "from here. You will have to try "
360 "again."),
361 buttons=[_("OK")])
362 - anaconda.dispatch.gotoPrev()
363 + else:
364 + anaconda.dispatch.gotoPrev()
365 else:
366 anaconda.dispatch.gotoNext()
367
368 diff -up anaconda-11.1.2.168/textw/confirm_text.py.smepatches anaconda-11.1.2.168/textw/confirm_text.py
369 --- anaconda-11.1.2.168/textw/confirm_text.py.smepatches 2008-12-18 03:21:19.000000000 -0700
370 +++ anaconda-11.1.2.168/textw/confirm_text.py 2009-04-14 12:37:34.000000000 -0600
371 @@ -19,6 +19,13 @@ from image import presentRequiredMediaMe
372
373 class BeginInstallWindow:
374 def __call__ (self, screen, anaconda):
375 + rc = anaconda.intf.messageWindow(_("Warning"),
376 + _("All disks will be reformatted and any data will be lost. Proceed?"),
377 + type = "yesno", default = "no")
378 +
379 + if rc == 0:
380 + return INSTALL_BACK
381 +
382 rc = ButtonChoiceWindow (screen, _("Installation to begin"),
383 _("A complete log of your installation will be in "
384 "%s after rebooting your system. You "
385 diff -up anaconda-11.1.2.168/textw/progress_text.py.smepatches anaconda-11.1.2.168/textw/progress_text.py
386 --- anaconda-11.1.2.168/textw/progress_text.py.smepatches 2008-12-18 03:21:19.000000000 -0700
387 +++ anaconda-11.1.2.168/textw/progress_text.py 2009-04-14 12:26:15.000000000 -0600
388 @@ -115,8 +115,8 @@ class InstallProgressWindow:
389
390 currow = 0
391
392 - width = 47 + max (len (name), len (size), len (sum))
393 - self.name = Label(" " * 48)
394 + width = 60 + max (len (name), len (size), len (sum))
395 + self.name = Label(" " * 59)
396 self.size = Label(" ")
397 detail = Grid(2, 2)
398 detail.setField(Label(name), 0, 0, anchorLeft = 1)
399 diff -up anaconda-11.1.2.168/textw/timezone_text.py.smepatches anaconda-11.1.2.168/textw/timezone_text.py
400 --- anaconda-11.1.2.168/textw/timezone_text.py.smepatches 2008-12-18 03:21:19.000000000 -0700
401 +++ anaconda-11.1.2.168/textw/timezone_text.py 2009-04-14 12:28:01.000000000 -0600
402 @@ -37,8 +37,7 @@ class TimezoneWindow:
403
404 def updateSysClock(self):
405 args = ["--hctosys"]
406 - if self.c.selected():
407 - args.append("--utc")
408 + args.append("--utc")
409
410 iutil.execWithRedirect("hwclock", args, searchPath=1)
411 self.g.setTimer(500)
412 @@ -83,14 +82,14 @@ class TimezoneWindow:
413 self.l.setCurrent(default)
414 # self.l.setCallback(self.updateClock)
415
416 - self.c = Checkbox(_("System clock uses UTC"), isOn = asUtc)
417 +# self.c = Checkbox(_("System clock uses UTC"), isOn = asUtc)
418 # self.c.setCallback(self.updateSysClock)
419
420 self.g = GridFormHelp(screen, _("Time Zone Selection"), "timezone",
421 1, 5)
422 self.g.add(t, 0, 0)
423 # self.g.add(self.label, 0, 1, padding = (0, 1, 0, 0), anchorLeft = 1)
424 - self.g.add(self.c, 0, 2, padding = (0, 1, 0, 1), anchorLeft = 1)
425 +# self.g.add(self.c, 0, 2, padding = (0, 1, 0, 1), anchorLeft = 1)
426 self.g.add(self.l, 0, 3, padding = (0, 0, 0, 1))
427 self.g.add(bb, 0, 4, growx = 1)
428
429 @@ -118,7 +117,7 @@ class TimezoneWindow:
430 break
431
432 screen.popWindow()
433 - anaconda.id.timezone.setTimezoneInfo(self.l.current(), asUtc = self.c.selected())
434 + anaconda.id.timezone.setTimezoneInfo(self.l.current(), asUtc = 1)
435
436 return INSTALL_OK
437
438 diff -up anaconda-11.1.2.168/textw/upgrade_bootloader_text.py.smepatches anaconda-11.1.2.168/textw/upgrade_bootloader_text.py
439 --- anaconda-11.1.2.168/textw/upgrade_bootloader_text.py.smepatches 2008-12-18 03:21:19.000000000 -0700
440 +++ anaconda-11.1.2.168/textw/upgrade_bootloader_text.py 2009-04-14 12:31:24.000000000 -0600
441 @@ -44,75 +44,24 @@ class UpgradeBootloaderWindow:
442 else:
443 nobl = 1
444
445 - if self.type is not None and self.bootDev is not None:
446 - t = TextboxReflowed(53,
447 - _("The installer has detected the %s boot "
448 - "loader currently installed on %s.")
449 - % (self.type, self.bootDev))
450 -
451 - self.update_radio = blradio.add(_("Update boot loader configuration"),
452 - "update", update)
453 + if nobl == 1:
454 + self.dispatch.skipStep("bootloadersetup", skip = 1)
455 + self.dispatch.skipStep("bootloader", skip = 1)
456 + self.dispatch.skipStep("bootloaderadvanced", skip = 1)
457 + self.dispatch.skipStep("instbootloader", skip = 1)
458 + elif newbl == 1:
459 + self.dispatch.skipStep("bootloadersetup", skip = 0)
460 + self.dispatch.skipStep("bootloader", skip = 1)
461 + self.dispatch.skipStep("bootloaderadvanced", skip = 1)
462 + self.dispatch.skipStep("instbootloader", skip = 0)
463 + self.bl.doUpgradeOnly = 0
464 else:
465 - t = TextboxReflowed(53,
466 - _("The installer is unable to detect the boot loader "
467 - "currently in use on your system."))
468 -
469 - self.update_radio = blradio.add(_("Update boot loader configuration"),
470 - "update", update)
471 - self.update_radio.w.checkboxSetFlags(FLAG_DISABLED, FLAGS_SET)
472 -
473 - self.nobl_radio = blradio.add(_("Skip boot loader updating"),
474 - "nobl", nobl)
475 - self.newbl_radio = blradio.add(_("Create new boot loader "
476 - "configuration"),
477 - "newbl", newbl)
478 -
479 - buttons = ButtonBar(screen, [TEXT_OK_BUTTON, TEXT_BACK_BUTTON])
480 -
481 - grid = GridFormHelp(screen, _("Upgrade Boot Loader Configuration"),
482 - "bl-upgrade", 1, 5)
483 -
484 - grid.add(t, 0, 0, (0,0,0,1))
485 - grid.add(self.update_radio, 0, 1, (0,0,0,0))
486 - grid.add(self.nobl_radio, 0, 2, (0,0,0,0))
487 - grid.add(self.newbl_radio, 0, 3, (0,0,0,1))
488 - grid.add(buttons, 0, 4, growx = 1)
489 -
490 -
491 - while 1:
492 - result = grid.run()
493 -
494 - button = buttons.buttonPressed(result)
495 -
496 - if button == TEXT_BACK_CHECK:
497 - screen.popWindow()
498 - return INSTALL_BACK
499 -
500 - if blradio.getSelection() == "nobl":
501 - self.dispatch.skipStep("bootloadersetup", skip = 1)
502 - self.dispatch.skipStep("bootloader", skip = 1)
503 - self.dispatch.skipStep("bootloaderadvanced", skip = 1)
504 - self.dispatch.skipStep("instbootloader", skip = 1)
505 - elif blradio.getSelection() == "newbl":
506 - self.dispatch.skipStep("bootloadersetup", skip = 0)
507 - self.dispatch.skipStep("bootloader", skip = 0)
508 - self.dispatch.skipStep("bootloaderadvanced", skip = 0)
509 - self.dispatch.skipStep("instbootloader", skip = 0)
510 - self.bl.doUpgradeOnly = 0
511 - else:
512 - self.dispatch.skipStep("bootloadersetup", skip = 0)
513 - self.dispatch.skipStep("bootloader", skip = 1)
514 - self.dispatch.skipStep("bootloaderadvanced", skip = 1)
515 - self.dispatch.skipStep("instbootloader", skip = 0)
516 - self.bl.doUpgradeOnly = 1
517 -
518 - if self.type == "GRUB":
519 - self.bl.useGrubVal = 1
520 - else:
521 - self.bl.useGrubVal = 0
522 - self.bl.setDevice(self.bootDev)
523 -
524 -
525 + self.dispatch.skipStep("bootloadersetup", skip = 0)
526 + self.dispatch.skipStep("bootloader", skip = 1)
527 + self.dispatch.skipStep("bootloaderadvanced", skip = 1)
528 + self.dispatch.skipStep("instbootloader", skip = 0)
529 + self.bl.doUpgradeOnly = 1
530 + self.bl.useGrubVal = 1
531 + self.bl.setDevice(self.bootDev)
532
533 - screen.popWindow()
534 - return INSTALL_OK
535 + return INSTALL_OK
536 diff -up anaconda-11.1.2.168/textw/upgrade_text.py.smepatches anaconda-11.1.2.168/textw/upgrade_text.py
537 --- anaconda-11.1.2.168/textw/upgrade_text.py.smepatches 2008-12-18 03:21:19.000000000 -0700
538 +++ anaconda-11.1.2.168/textw/upgrade_text.py 2009-04-14 12:34:32.000000000 -0600
539 @@ -20,8 +20,8 @@ from snack import *
540 from fsset import *
541 from flags import flags
542 from constants import *
543 -import upgradeclass
544 -UpgradeClass = upgradeclass.InstallClass
545 +import smeupgradeclass
546 +UpgradeClass = smeupgradeclass.InstallClass
547
548 from rhpl.translate import _
549 import rhpl
550 @@ -200,26 +200,19 @@ class UpgradeExamineWindow:
551 else:
552 scroll = 0
553 partList = []
554 - partList.append(_("Reinstall System"))
555 + partList.append(_("Erase ALL disks, and perform a fresh install"))
556
557 for (drive, fs, desc, label) in parts:
558 - if drive[:5] != "/dev/":
559 - devname = "/dev/" + drive
560 - else:
561 - devname = drive
562 - partList.append("%s (%s)" %(desc, drive))
563 + partList.append(_("Upgrade existing \"%s\" system") %(desc))
564
565 (button, choice) = ListboxChoiceWindow(screen, _("System to Upgrade"),
566 - _("One or more existing Linux installations "
567 - "have been found "
568 - "on your system.\n\nPlease choose one to upgrade, "
569 - "or select 'Reinstall System' to freshly install "
570 - "your system."), partList,
571 + _("Your system is upgradeable."), partList,
572 [ TEXT_OK_BUTTON,
573 TEXT_BACK_BUTTON ],
574 width = 55, scroll = scroll,
575 height = height,
576 - help = "upgraderoot")
577 + help = "upgraderoot",
578 + default = 1)
579
580 if button == TEXT_BACK_CHECK:
581 return INSTALL_BACK
582 diff -up anaconda-11.1.2.168/upgrade.py.smepatches anaconda-11.1.2.168/upgrade.py
583 --- anaconda-11.1.2.168/upgrade.py.smepatches 2008-12-18 03:21:19.000000000 -0700
584 +++ anaconda-11.1.2.168/upgrade.py 2009-04-14 13:07:55.000000000 -0600
585 @@ -123,7 +123,7 @@ def findRootParts(anaconda):
586
587 if anaconda.id.rootParts is not None and len(anaconda.id.rootParts) > 0:
588 anaconda.dispatch.skipStep("findinstall", skip = 0)
589 - if productName.find("Red Hat Enterprise Linux") == -1:
590 + if productName.find("SME Server") == -1:
591 anaconda.dispatch.skipStep("installtype", skip = 1)
592 else:
593 anaconda.dispatch.skipStep("findinstall", skip = 1)
594 diff -up anaconda-11.1.2.168/yuminstall.py.smepatches anaconda-11.1.2.168/yuminstall.py
595 --- anaconda-11.1.2.168/yuminstall.py.smepatches 2008-12-18 03:21:19.000000000 -0700
596 +++ anaconda-11.1.2.168/yuminstall.py 2009-04-14 13:11:12.000000000 -0600
597 @@ -1071,7 +1071,8 @@ class YumBackend(AnacondaBackend):
598
599 if foundModule == 1:
600 for (n, arch, tag) in kernelVersions:
601 - recreateInitrd(n, anaconda.rootPath)
602 + if os.access("/boot/System.map-%s" %(n,), os.X_OK):
603 + recreateInitrd(n, anaconda.rootPath)
604
605 def selectBestKernel(self, anaconda):
606 """Find the best kernel package which is available and select it."""
607 @@ -1642,10 +1643,10 @@ class YumBackend(AnacondaBackend):
608 # Figure out current version for upgrade nag and for determining weird
609 # upgrade cases
610 supportedUpgradeVersion = -1
611 - for pkgtup in self.ayum.rpmdb.whatProvides('redhat-release', None, None):
612 + for pkgtup in self.ayum.rpmdb.whatProvides('e-smith-release', None, None):
613 n, a, e, v, r = pkgtup
614 if supportedUpgradeVersion <= 0:
615 - val = rpmUtils.miscutils.compareEVR((None, '3', '1'),
616 + val = rpmUtils.miscutils.compareEVR(('26', '7.0', '01'),
617 (e, v,r))
618 if val > 0:
619 supportedUpgradeVersion = 0
620 @@ -1653,9 +1654,6 @@ class YumBackend(AnacondaBackend):
621 supportedUpgradeVersion = 1
622 break
623
624 - if productName.find("Red Hat Enterprise Linux") == -1:
625 - supportedUpgradeVersion = 1
626 -
627 if supportedUpgradeVersion == 0:
628 rc = anaconda.intf.messageWindow(_("Warning"),
629 _("You appear to be upgrading from a system "
630 @@ -1669,7 +1667,7 @@ class YumBackend(AnacondaBackend):
631 try:
632 os.unlink("%s/var/lib/rpm/%s" %(anaconda.rootPath, rpmfile))
633 except:
634 - log.info("error %s removing file: /var/lib/rpm/%s" %(e,rpmfile))
635 + #log.info("error %s removing file: /var/lib/rpm/%s" %(e,rpmfile))
636 pass
637 sys.exit(0)
638
639 @@ -1718,7 +1716,8 @@ class YumBackend(AnacondaBackend):
640 # to the old method.
641 if len(self._installedDriverModules) > 0 and len(self._installedDriverModules) == len(anaconda.id.extraModules):
642 for (n, arch, tag) in self.kernelVersionList():
643 - recreateInitrd(n, anaconda.rootPath)
644 + if os.access("/boot/System.map-%s" %(n,), os.X_OK):
645 + recreateInitrd(n, anaconda.rootPath)
646 else:
647 modulesList = filter(lambda m: m not in self._installedDriverModules, anaconda.id.extraModules)
648 self.copyExtraModules(anaconda, modulesList)

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed