[Linux-PowerEdge] dcism RPM pollutes /etc/bashrc

Ben Argyle Ben.Argyle at uis.cam.ac.uk
Wed Mar 11 12:05:58 CDT 2020

Wow, Dell, really?  That's shocking.  Please fix this at your earliest convenience.

That file even has this at the top:

# System wide functions and aliases
# Environment stuff goes in /etc/profile

# It's NOT a good idea to change this file unless you know what you
# are doing. It's much better to create a custom.sh shell script in
# /etc/profile.d/ to make custom changes to your environment, as this
# will prevent the need for merging in future updates.

Well done Killian for finding this horror.


-----Original Message-----
From: Linux-PowerEdge <linux-poweredge-bounces at dell.com> On Behalf Of Kilian Cavalotti
Sent: 11 March 2020 16:06
To: linux-poweredge at lists.us.dell.com
Subject: [Linux-PowerEdge] dcism RPM pollutes /etc/bashrc

Hi Dell,

Could you please stop polluting the system /etc/bashrc with the dcism
RPM post-installation scripts?

I spent the last 20 minutes trying to figure out where that
/opt/dell/srvadmin/iSM/bin was coming from in my users' $PATH, before
realizing that it's actually embedded in the system-level /etc/bashrc!

-- 8<---------------------------------------------------------------------
$ tail -n4 /etc/bashrc
    unset -f pathmunge
# vim:ts=4:sw=4
. /opt/dell/srvadmin/iSM/sbin/dcism-path.sh  #added by ##dcism##
ensure iSM bin path set for all shells, login/non-login and
-- 8<---------------------------------------------------------------------

This is actually the work of the postinstall script in the dcism RPM.
Here's the relevant part of that scriptlet, from
dcism-3.5.0-1862.el7.x86_64, which is the latest available version
AFAIK (indentation is verbatim):

-- 8<---------------------------------------------------------------------
   # Add iSM BIN path
       if [ -f /etc/bashrc ]
     if ! grep -q /opt/dell/srvadmin/iSM/sbin/dcism-path.sh /etc/bashrc; then
     echo ". /opt/dell/srvadmin/iSM/sbin/dcism-path.sh  #added by
##dcism## ensure iSM bin path set for all shells, login/non-login and
interactive/non-interactive" >> /etc/bashrc
-- 8<---------------------------------------------------------------------

So, no backup of the original /etc/bashrc and modification of a system
file that is not under the control of that RPM, this is an impressive
combination of bad practices.

Not to mention that it is completely ineffective for other shells, and
that /etc/bashrc is never read unless it's explicitly sourced from a
user's ~/.bashrc.

Please fix this.


Linux-PowerEdge mailing list
Linux-PowerEdge at dell.com

More information about the Linux-PowerEdge mailing list