SDDC Manager bash history disabled after VCF 5.2 upgrade
search cancel

SDDC Manager bash history disabled after VCF 5.2 upgrade

book

Article ID: 369205

calendar_today

Updated On:

Products

VMware SDDC Manager

Issue/Introduction

  • Bash history is disabled on SDDC Manager
  • Unable to up arrow to call prior command
  • Bash history worked prior to VCF 5.2

Environment

VMware Cloud Foundation 4.3

Cause

Beginning with VCF 4.3, bash history is disabled as part of security hardening implementations. The mechanism creates /etc/profile.d/disable.history.sh containing set +o history, which suppresses bash history recording for all shell sessions.

Resolution

To re-enable bash history, perform one of the following options:

  • Option A: Set bash history for the SSH session.
    set -o history
  • Option B: Disable the hardening policy globally for new sessions. (Note: it will be required to run this after every upgrade.) 
    mv /etc/profile.d/disable.history.sh /etc/profile.d/disable.history.sh.bak
  • Option C: For persistence, create a new profile script. (Note: it will be required to run this after every upgrade.) 
    echo 'set -o history' > /etc/profile.d/enable.history.sh
    echo 'HISTFILESIZE=10000' >> /etc/profile.d/enable.history.sh