Who is responsible for closing this bug? I submitted this RFE to work on this. The scripts are replaced by executables where observability is guaranteed by debugger, truss and dtrace.
---------- Forwarded message ---------- From: <[email protected]> Date: Wed, Dec 2, 2009 at 8:33 PM Subject: CR 6904124 Closed, P5 utility/file Shrink some shell scripts in SUNWcsu, SUNWesu To: *Synopsis*: Shrink some shell scripts in SUNWcsu, SUNWesu CR 6904124 changed on Dec 2 2009 by <User 1-5Q-101> === Field ============ === New Value ============= === Old Value ============= Public Comments New Note Status 11-Closed 1-Dispatched SubStatus Will Not Fix ====================== =========================== =========================== *Change Request ID*: 6904124 *Synopsis*: Shrink some shell scripts in SUNWcsu, SUNWesu Product: solaris Category: utility Subcategory: file Type: RFE Subtype: Status: 11-Closed Substatus: Will Not Fix Priority: 5-Very Low Introduced In Release: Introduced In Build: Responsible Engineer: Keywords: opensolaris === *Description* ============================================================ Category utility Sub-Category file Description Some shell scripts could be reduced in size to free up some disk space. The following files are candidates: file /usr/bin/* | egrep 'executable (shell|.*bin/(sh|ksh|ksh93)) script' | while read i ; do i="${i%:*}" ; egrep "^$i" /var/sadm/install/contents | egrep 'SUNW(csu|esu)' ; done /usr/bin/amt f none 0555 root bin 1217 29910 1236145782 SUNWcsu /usr/bin/arch f none 0555 root bin 1595 60095 1236145596 SUNWcsu /usr/bin/batch f none 0555 root bin 1227 34866 1236145765 SUNWesu /usr/bin/calendar f none 0555 root bin 2756 22916 1236145598 SUNWesu /usr/bin/clear f none 0555 root bin 1166 31638 1236145597 SUNWcsu /usr/bin/diff3 f none 0555 root bin 2696 9267 1236145610 SUNWesu /usr/bin/dircmp f none 0555 root bin 6506 33681 1236145599 SUNWesu /usr/bin/dmesg=../sbin/dmesg s none SUNWesu /usr/bin/itu f none 0555 root bin 25441 49856 1236145620 SUNWcsu /usr/bin/mach f none 0555 root bin 1347 47799 1236145630 SUNWcsu /usr/bin/mkbootmedia f none 0555 root bin 3966 49763 1236145621 SUNWcsu /usr/bin/optisa f none 0555 root bin 1255 32116 1236145618 SUNWcsu /usr/bin/pkg2du f none 0555 root bin 9224 9023 1236145621 SUNWcsu /usr/bin/spell f none 0555 root bin 3955 43630 1236145721 SUNWesu /usr/bin/tplot f none 0555 root bin 1224 33017 1236145734 SUNWcsu /usr/bin/tzselect f none 0555 root bin 10401 19258 1236145808 SUNWcsu /usr/bin/updatemedia f none 0555 root bin 11473 63556 1236145621 SUNWcsu The candidate must satisfy all of the following criteria: - The candidate must be required by base system (SUNWcsu, SUNWesu) - The candidate must be a standalone application which is unlikely subject of administrator customisations - The candidate must be easy to test The candidate must satisfy one of the following criteria: - The candidate is big, rarely used - The candidate is small, often used, a size reduction reduces execution time For the time being I choose the following candidates as proof of concept: arch clear diff3 batch dircmp mach if this works I will submit follow up RFCs. Frequency Always Regression no Steps to Reproduce - Expected Result - Actual Result - Error Message(s) - Test Case - Workaround - Additional configuration information - *** (#1 of 1): 2009-11-23 20:53:25 GMT+00:00 <User 1-F4SZV> === *Public Comments* ======================================================== /usr/bin/clear is only two lines beyond the comments (most of which are the required license statements), how can you make that usefully smaller? *** (#1 of 4): 2009-11-23 23:05:12 GMT+00:00 <User 1-5Q-1267> Adding on behalf of Olga Kryzhanovska - she reported: I can make this and other scripts usefully smaller: <email address omitted>:~/ksh93/on_build2/onnv-gate.hg$ for z in arch clear mach ; do ls -l $ROOT/bin/$z /bin/$z ; done -r-xr-xr-x 1 root bin 1595 Mar 4 2009 /bin/arch -r-xr-xr-x 1 fleyta fleyta 490 Nov 23 19:21 /home/fleyta/ksh93/on_build2/onnv-gate.hg/proto/root_sparc/bin/arch -r-xr-xr-x 1 root bin 1166 Mar 4 2009 /bin/clear -r-xr-xr-x 1 fleyta fleyta 71 Nov 23 19:24 /home/fleyta/ksh93/on_build2/onnv-gate.hg/proto/root_sparc/bin/clear -r-xr-xr-x 1 root bin 1347 Mar 4 2009 /bin/mach -r-xr-xr-x 1 fleyta fleyta 31 Nov 24 11:21 /home/fleyta/ksh93/on_build2/onnv-gate.hg/proto/root_sparc/bin/mach The files in /bin are the current scripts, the files in /home/fleyta/ksh93/on_build2/onnv-gate.hg/proto/root_sparc/bin are the scripts after treatment. The shrink ratio is variable, depending on the individual script. *** (#2 of 4): 2009-11-24 16:30:34 GMT+00:00 <User 1-39KXYN> There's a 79-byte version of clear that still includes the CDDL? How? This whole CR seems the wrong way around: our shell scripts should be written to be maintainable, not to save a few bytes. *** (#3 of 4): 2009-12-01 01:06:07 GMT+00:00 <User 1-5Q-13476> ----- [ jbeck, 2009-Dec-02 ] I am closing this as Will-Not-Fix, as the benefit in very minor disk space savings is not worth the cost in reduced maintainability. Note that I am not acting as a "lone wolf"; a large number of ON engineers discussed this at lunch yesterday, at which there was strong consensus that this would be a Bad Idea [tm] for the reasons I mentioned above. ----- *** (#4 of 4): 2009-12-02 19:29:54 GMT+00:00 <User 1-5Q-101> === *Workaround* ============================================================= === *Additional Details* ===================================================== Targeted Release: Commit To Fix In Build: Fixed In Build: Integrated In Build: Verified In Build: See Also: Duplicate of: Hooks: Hook1: Hook2: Hook3: Hook4: Hook5: Hook6: <email address omitted> Program Management: Root Cause: Fix Affects Documentation: No Fix Affects Localization: No === *History* ================================================================ Date Submitted: 2009-11-23 20:53:23 GMT+00:00 Submitted By: <User 1-F4SZV> Status Changed Date Updated Updated By 11-Closed 2009-12-02 19:29:54 GMT+00:00 <User 1-5Q-101> === *Service Request* ======================================================== Impact: Limited Functionality: Nonessential Severity: 5 Product Name: solaris Product Release: solaris_nevada Product Build: snv_01 Operating System: solaris_nevada Hardware: generic Submitted Date: 2009-11-23 20:53:25 GMT+00:00 === *Multiple Release (MR) Cluster* - 0 ====================================== -- , _ _ , { \/`o;====- Olga Kryzhanovska -====;o`\/ } .----'-/`-/ olga.kryzhanovska at gmail.com \-`\-'----. `'-..-| / Solaris/BSD//C/C++ programmer \ |-..-'` /\/\ /\/\ `--` `--`
