Shrinking the OS

September 5, 2012 My computer went belly-up after the previous session. Not that I've wrecked the OS in any form, it appears to be a 'mechanical' problem. More precisely an 'electronical' problem: either memory has gone walkabout or the processor has caved in. A pity as I was on the brink of yet another 'diet for the OS' course... Yes, there is still some bytes left to be shaved off the OS's footprint ;-)! August 26, 2012 Today I took the plunge and moved the contents of my 3rd parties partition over to a partition of increased size as the old one got a bit tight. The partiton in question, 'ExtSYS:', was of 515Mb size and has grown by 50% to become 773Mb. This provided me with ample room for a couple of OS-components I deem 3rd-parties. Things I moved over are: Utilities/AmiPDF (10.8Mb) Utilities/AmiGS (1.1Mb) Utilities/GhostScript (28.7Mb) For the latter it also included modifying 'SYS:S/Startup-Sequence' to remove the assign-command. Furthermore I moved System/Python over freeing another 23 or so Mb. I also moved Emulation and part of the Documentation. The latter I modified quite severely. Stuff related to AHI, AmiSSL, MUI, Python, XPK and MiniGL were moved over, whereas stuff related to IDE/it..., IDE/sii... and rtl8... were simply deleted. Volume 'OS_4.1_5:' now takes up only some 90Mb, where I initially provided it with a 154Mb partition. The changes applied to 'OS_4.1_5:' I have also applied to volume 'OS_4.1_4:', which shrank accordingly to 91Mb, whilst occupying a 256Mb partition. Next in line for a simmilar WeightWatchers' Treatment is of cource volume 'OS_4.1_3:', which takes up a hefty 410Mb! If that one can be reduced to some 90Mb like the other two, then I gain another 320Mb. All in all it would return me some 550Mb shrinking these three OS-versions! Currently I have these partitions installed:
  1. Gemounte disks:
  2. Unit Grootte Gebruikt Vrij Vol Fouten Status Naam
  3. DH31: 10G 7.786M 2.525M 76% 0 Lezen/Schrijven Video
  4. DH4: 10G 9G 90M 99% 0 Lezen/Schrijven Fotoos II
  5. DH30: 8.250M 8.249M 704K 100% 0 Lezen/Schrijven Extracts
  6. DH29: 6.187M 6.032M 155M 97% 0 Lezen/Schrijven Archives
  7. DH27: 4.125M 2.075M 2.049M 50% 0 Lezen/Schrijven Applicaties
  8. DH23: 2.062M 1.511M 550M 73% 0 Lezen/Schrijven Projecten
  9. DH24: 2.062M 1.833M 228M 89% 0 Lezen/Schrijven Games
  10. DH25: 2.062M 1.553M 509M 75% 0 Lezen/Schrijven Muziek
  11. DH33: 1.218M 743M 475M 61% 0 Lezen/Schrijven Van A1200
  12. DH26: 1.031M 730M 300M 71% 0 Lezen/Schrijven UAE
  13. DH0: 1.031M 1.027M 3.563K 100% 0 Lezen/Schrijven Fotoos
  14. DH6: 773M 577M 195M 75% 0 Lezen/Schrijven ExtSYS
  15. DH22: 515M 499M 15M 97% 0 Lezen/Schrijven OldExtSYS
  16. DH8: 410M 212M 197M 52% 0 Alleen lezen OS_4.1_3
  17. DH1: 257M 91M 166M 36% 0 Alleen lezen OS_4.1_4
  18. DH5: 234M 216M 17M 93% 0 Alleen lezen OS_4.1_2
  19. DH3: 227M 196M 30M 87% 0 Alleen lezen OS_4.1_1
  20. DH9: 154M 90M 64M 59% 0 Lezen/Schrijven OS_4.1_5
  21. TEXTCLIP: 145M 0K 145M 0% 0 Lezen/Schrijven TextClip
  22. DH7: 128M 121M 7.130K 95% 0 Alleen lezen OS_4.1
  23. DH28: 93M 56M 36M 61% 0 Lezen/Schrijven WebServer
  24. DH2: 46M 35M 11M 75% 0 Lezen/Schrijven BootPartition
  25. ENV: 193K 193K 0K 100% 0 Lezen/Schrijven Env
  26. RAM: 32K 32K 0K 100% 0 Lezen/Schrijven RAM Disk
  27. CD0: Geen disk aanwezig
Addendum: Some minor tweaks at the eleventh hour brought the size down to 89.5Mb for 'OS_4.1_5:' and to 90.4Mb for 'OS_4.1_4:'. The most important being the moving over of minigl.library as I concluded that one to be a 3rd-parties component. This one shaved another 1Mb of the OS's footprint. I don't think it worthwile investigating for further surgery or liposuction applied to OS. Maybe volume 'OS_4.1_2:' can be reduced to some 90Mb as well. The remaining 2 OS-partitions may not be so susceptible to the treatment as they are actually the very basis to the system, especially 'OS_4.1_1:', which was a major update. Maybe I delete 'OS_4.1:' entirely, freeing up 128Mb. All these actions combined might save me the already mentioned 550Mb + 144Mb for 'OS_4.1_2:' and 128Mb for 'OS_4.1:', tallying to more then 820Mb. I'll let you know... August 16, 2012 An update for OS_4.1 is made available for every platform: update 5. For me the installation of an update falls apart in two pieces, the first being the update to 'BootPartition', where the kickstart-things reside and the second being the creation and copying to of a partition of the more usual layout. The first piece is the easy one. In 'BootPartition:Kickstart' a drawer is created called 'OS_4.1_5'. An icon for this drawer I deem waste of space. To this new drawer I copied a selection of files over from 'Files-NoArch/Kickstart' followed suite by copying over a selection of files fom 'Files-AmigaOne', as from the latter I do not require all of them to be present. Files I did NOT copy over are 'it812ide.device.kmod' and all them 'sii...device.kmod'-files: I have no such extensions to my µ. The only PCI-slot available is occupied by a Tekram SCSI-card, so the new 'lsi53c8xx.device.kmod' was positively copied over. A little more tricky was the modification of the KickLayout. Having a fully multiboot capable setup, the KickLayout reflects this with multiple entries for the 'LABEL'-clause. Using 'Copy & Paste' I duplicated the part for OS_4.1_4 to the very end of the file and modified both the 'LABEL'-clause to show the proper label in the bootmenu and the appropriate 'MODULE'-clauses to reflect the loading of the updated components. The configuration now looks like this:
  1. ;
  2. ; Configuration name
  3. LABEL Amiga_OS4.1 Update 5
  4. ; Exec name
  5. EXEC Kickstart/loader
  6. MODULE Kickstart/diskboot.config
  7. MODULE Kickstart/OS_4.1_5/BootDevice
  8. ;
  9. MODULE Kickstart/OS_4.1_5/kernel
  10. MODULE Kickstart/OS_4.1_1/FastFileSystem
  11. MODULE Kickstart/OS_4.1_5/SmartFilesystem
  12. MODULE Kickstart/OS_4.1_1/JXFileSystem
  13. MODULE Kickstart/OS_4.1_5/a1ide.device.kmod
  14. MODULE Kickstart/OS_4.1_2/battclock.resource.kmod
  15. MODULE Kickstart/OS_4.1_3/biosversion.resource.kmod
  16. MODULE Kickstart/OS_4.1_2/bootmenu.kmod
  17. MODULE Kickstart/OS_4.1_2/CDFileSystem
  18. MODULE Kickstart/OS_4.1_2/con-handler.kmod
  19. MODULE Kickstart/OS_4.1_2/console.device.kmod
  20. MODULE Kickstart/OS_4.1_2/diskboot.kmod
  21. MODULE Kickstart/OS_4.1_2/diskcache.library.kmod
  22. MODULE Kickstart/OS_4.1_5/dos.library.kmod
  23. MODULE Kickstart/OS_4.1_5/elf.library.kmod
  24. MODULE Kickstart/OS_4.1_2/env-handler.kmod
  25. MODULE Kickstart/OS_4.1_4/FileSystem.resource.kmod
  26. MODULE Kickstart/OS_4.1_1/gadtools.library.kmod
  27. MODULE Kickstart/OS_4.1_1/gameport.device.kmod
  28. MODULE Kickstart/OS_4.1_1/graphics.library.kmod
  29. MODULE Kickstart/OS_4.1_3/hunk.library.kmod
  30. MODULE Kickstart/OS_4.1_5/input.device.kmod
  31. MODULE Kickstart/OS_4.1_4/intuition.library.kmod
  32. MODULE Kickstart/OS_4.1_5/keyboard.device.kmod
  33. MODULE Kickstart/OS_4.1_3/keymap.library.kmod
  34. MODULE Kickstart/OS_4.1_3/layers.library.kmod
  35. MODULE Kickstart/OS_4.1_5/lsi53c8xx.device.kmod
  36. MODULE Kickstart/OS_4.1_5/newlib.library.kmod
  37. MODULE Kickstart/OS_4.1_5/nonvolatile.library.kmod
  38. MODULE Kickstart/OS_4.1_1/nvram.resource.kmod
  39. MODULE Kickstart/OS_4.1_1/ps2.resource.kmod
  40. MODULE Kickstart/OS_4.1_3/ram-handler.kmod
  41. MODULE Kickstart/OS_4.1_1/ramdrive.device.kmod
  42. MODULE Kickstart/OS_4.1_5/ramlib.kmod
  43. MODULE Kickstart/OS_4.1_5/shell.kmod
  44. MODULE Kickstart/OS_4.1_1/strap.kmod
  45. MODULE Kickstart/OS_4.1_1/timer.device.kmod
  46. MODULE Kickstart/OS_4.1_5/rtg.library
  47. MODULE Kickstart/OS_4.1_5/PCIGraphics.card
  48. MODULE Kickstart/OS_4.1_5/ATIRadeon.chip
  49. MODULE Kickstart/OS_4.1_5/petunia.library.kmod
  50. MODULE Kickstart/OS_4.1_4/usbresource.library
  51. MODULE Kickstart/OS_4.1_4/usbsys.device
  52. MODULE Kickstart/OS_4.1_3/hub.usbfd
  53. MODULE Kickstart/OS_4.1_3/massstorage.usbfd
  54. MODULE Kickstart/OS_4.1_4/uhci.usbhcd
  55. MODULE Kickstart/OS_4.1_4/ohci.usbhcd
  56. MODULE Kickstart/OS_4.1_4/ehci.usbhcd
  57. ;
A 'MODULE'-clause tells the loader where to look for the particular component. It proved far less difficult then anticipated. In my handwritten update log I had made a special point in capitals: REMEMBER TO ADD A FILE "Bootdevice" TO OS_4.1_5 !! I'll come to this later. The second part proved to be quite more involving. Essentially it bore down to creating and filling a (small: 154.7Mb) partition, make it bootable with a priority of 0, set the filesystem to SFS\00, blocksize to 512, buffers to 600, Max Transfer to 'FFFFFF' and finally the Mask to 'FFFFFFFE'. Save and reboot. Quick format the new partition, setting its name to 'OS_4.1_5' and unchecking the trashcan checkbox. As a final touch the partition's icon was snapshotted at a proper partition: X=30, Y=540. Sofar the creation. The filling part of the exercise consisted of a): copying complete drawers over one by one from the current installation, 'OS_4.1_4', followed by b): copying over c.q. replacing files from 'Files-NoArch' and 'Files-AmigaOne' respectively, taking into acount that some files would not be applicable and so needless to be copied over, like 'Files-NoArch/Devs/catweasel#?.device'. This proved the most tedious and timeconsuming job. The copied-over Startup-Sequence was updated to reflect some entries in the new version. My S-S is a far cry from the original one.
  1. ; $VER: Startup-Sequence 53.1 (08.04.2009)
  2. ;C:SetPatch QUIET
  3. ;C:SetPatch ADDCHIPRAM=2 QUIET
  4. ;From V53.10:
  5. C:SetPatch ADDCHIPRAM=2 QUIET WAITFORVALIDATE
  6.  
  7. FailAt 21
  8.  
  9. ;RUN >NIL: C:Version >NIL: + SetEnv Workbench $Workbench + SetEnv Kickstart $Kickstart + UnSet Workbench + UnSet Kickstart
  10. C:Version >NIL:
  11. SetEnv Workbench $Workbench
  12. SetEnv Kickstart $Kickstart
  13. UnSet Workbench
  14. UnSet Kickstart
  15.  
  16. C:MakeDir RAM:T RAM:Clipboards
  17.  
  18. C:Assign >NIL: T: RAM:T
  19. C:Assign >NIL: CLIPS: RAM:Clipboards
  20. C:Assign >NIL: KEYMAPS: DEVS:KeyMaps
  21. C:Assign >NIL: PRINTERS: DEVS:Printers
  22. C:Assign >NIL: REXX: S:ARexx
  23. C:Assign >NIL: HELP: LOCALE:Help DEFER
  24. ;C:Assign >NIL: AMISSL: DEVS:AmiSSL DEFER
  25. C:Assign >NIL: GHOSTSCRIPT: SYS:Utilities/GhostScript DEFER
  26. ;C:Assign >NIL: PYTHON: SYS:System/Python
  27.  
  28. C:LoadMonDrvs
  29. ;From V53.10:
  30. C:P96LoadDefaultMonitor QUIET
  31. Run >NIL: C:AddDataTypes REFRESH QUIET
  32. ;C:AddDataTypes REFRESH QUIET
  33. C:IPrefs
  34.  
  35. Run >NIL: C:Mount QUIET DEVS:DOSDrivers/~(#?.info)
  36. ;C:Mount QUIET DEVS:DOSDrivers/~(#?.info)
  37. ;C:AddNetInterface QUIET DEVS:NetInterfaces/~(#?.info)
  38. ;Run >NIL: C:AddNetInterface QUIET DEVS:NetInterfaces/~(#?.info)
  39.  
  40. Path RAM: C: S:Shell S:ARexx SYS:Utilities SYS:Utilities/Commodities SYS:System SYS:Prefs
  41.  
  42. C:ConClip
  43. ;SYS:System/RexxMast >NIL:
  44. Run >NIL: SYS:System/RexxMast >NIL:
  45.  
  46. C:LoadWB
  47.  
  48. C:USBCtrl START
  49.  
  50. ;If EXISTS S:User-Startup
  51. ; Execute S:User-Startup
  52. ;EndIf
  53.  
  54. If EXISTS ExtSYS:S
  55. Assign S: ExtSYS:S ADD
  56.  
  57. If EXISTS S:ExtSYS-StartUp
  58. Execute S:ExtSYS-StartUp
  59. EndIf
  60. EndIf
  61.  
  62. ;From V53.10:
  63. ;C:Makelink RAM:Disk.info ENVARC:Sys/def_RAM.info SOFT
  64.  
  65. ;Run >NIL: C:AddNetInterface QUIET DEVS:NetInterfaces/~(#?.info)
  66. ;Run >NIL: *>NIL: C:SoundPlayer QUIET
  67.  
  68. EndCLI >NIL:
Compare this with an unmodified one and my claim will show true. There was something I still had to do. Ah, yes it was about that "BootDevice"-file. The new partition bore the exec designation of 'DH9', so this is what I placed in said file and saved it. I rebooted, taking care to select the proper label at the end of the menu and hit 'Enter'. Lo' and behold! the OS in its guise of latest update was presented to me! The final touch was the modification of 'KickLayout' by utilising 'Copy & Paste' once more and moving the entries for Update 5 to first position so that on next boot it would be the default. Juli 29, 2012 Decreased the size of the OS by deleting a lot of superfluous stuff: -- SYS:Prefs/Presets/Default (±28Mb) -- SYS:Prefs/Presets/Patterns (±5.2Mb) -- SYS:Locale/Catalogs (±6.0Mb) -- SYS:Locale/Flags/KeyMaps (±45.0Kb) -- SYS:Locale/Flags/Countries (±101.0Kb) -- SYS:Locale/Help (±500Kb) From these drawers you can retain only what is neccessary. TThe rest can be sent to NIL: The files that have been moved over as being deemed '3rd party' or 'multiboot related': -- SYS:Devs/Networks (±585Kb) -- SYS:Devs/AHI (±362Kb) -- SYS:Devs/AudioModes (±8.5Kb) -- Dockies -- ScreenBlankerEngine (SYS:Utilities/Commodities) 95Kb Blankers (SYS:Utilities) 617Kb ScreenBlanker (SYS:Prefs) 208Kb AHI, comprising these components: ahi.device (SYS:Devs) 144Kb SYS:Devs/AHI 362Kb SYS:Devs/AudioModes 8.5Kb -- SYS:Emulation 2.6Mb -- XPK: xpkmaster.library (SYS:Libs) 44.Kb xpk-Compressors (SYS:Libs/Compressors) 316Kb -- XAD: xadmasterlibrary (SYS:Libs) 351Kb xad-plugins (SYS:Libs/xad) 138.Kb -- AmiSSL.library (SYS:Libs/AmiSSL) 1.9Mb -- AmiSSL (SYS:Devs) 155Kb My definition of '3rd parties' in the context of the OS is all contributions, which are developed and maintained separately from the OS. Often their version numbering is fully out of sync with the OS proper. The OS now takes only 178.5Mb over 5117 files in 295 directories. July 12, 2012 In my ongoing quest for shrinking the OS's footprint, I today decided to go through the SYS:-partition once more. Rather a long time I had a nagging idea to save some more diskspace by moving all 3rd parties components over to a separate partition. As you may know, I maintain a very strict policy concerning the boot partition. Any bootpartition, that is, as I have the opportunity to boot into any version of the OS, starting from OS4.1 all the way up to update 4. Not that I make much use of this facility, it is just part of the fun. Anyway, you may not have realised that there is a huge 3rd parties component sitting in your OS' partition, a component which is not subject to any changes of the OS, as it is there for legacy purposes: MUI. This component, as installed, takes up some 9.5 Mb, which I think is quite considerable, given the overall size of the partition of 257Mb with 38Mb to spare. Give or take a few Mb's, the OS takes up some 220Mb. TOOK up some 220 Mb, which is now decreased by 9.5Mb due to moving MUI elsewhere. That is still about 4.3%. But MUI is used by a variety of applications and is therefore indispensable, but is it neccessary to have 5 copies of MUI occupying precious diskspace? Me thinks not, so I moved one over and removed the other 4, thereby freeing nearly 40Mb of diskspace. It now resides on a volume called 'ExtSYS:', which can be read as 'Extended SYS:', providing room for all those 3rd parties stuff normally littering a bootpartition. I want to keep my bootpartitions clean! Clean as a whistle. 'ExtSYS:' sports a division into catagories mimicking any bootpartition, with drawers called 'Fonts', 'Devs', 'Libs', 'Objs', etc., etc. There is now a new drawer to be found, called MUI. This is the drawer where all iterations of the OS find the MUI-components. Updating does now no longer require me to unlock the bootpartition and this makes me feel much better. Copied the entry for MUI in User-Startup to 'ExtSYS:S/ExtSYS-StartUp' and as that was the only entry in User-Startup I could modify Startup-Sequence to jump straight into 'ExtSYS:S/ExtSYS-StartUp'. This should decrease my boot time a very little bit as well. I wonder how much space I would win by removing all those catalogs from the bootpartiton. You know, those catalogs for languages I'll probly never be able to master. The drawer takes up nearly 7Mb and as there are 5 copies of them littering my disk, I could save nearly 28Mb here. Tempting...

Tags: 

Blog post type: 

Comments

stephenix1015's picture
This can be overcome by retrieving the system font for drawers as selected in the font preferences editor. -Missed Fortune