Description of problem: With ksh there is no HISTFILESIZE environment variable to limit the size of the history file per the man page. Is this the expected behavior? The customer must use logrotate or a cron job to prevent /home from filling up. Version-Release number of selected component (if applicable): How reproducible: Easy Steps to Reproduce: 1. Set shell to ksh usermod -s /bin/ksh dave 2. Set the HISTSIZE variable $ env|grep HIST HISTCONTROL=ignoredups HISTFILESIZE=15 HISTSIZE=10 3. Run some commands and notice .sh_history continues to grow even though the lines displayed are limited to HISTSIZE setting. $ history 81 exit 82 ls -l 83 ls -al 84 ls -l .sh_history 85 pwd 86 ls 87 pwd 88 ls -l .sh_history 89 env|grep HIST 90 history Actual results: The history file continues to grow. $ ls -l .sh_history -rw-------. 1 dave dave 724 Aug 15 11:43 .sh_history $ pwd /home/dave $ ls $ pwd /home/dave $ ls -l .sh_history -rw-------. 1 dave dave 760 Aug 15 11:43 .sh_history Expected results: With bash the .sh_history file stops growing once HISTFILESIZE is reached. $ ls -l .sh_history -rw-------. 1 dave dave 888 Aug 15 11:48 .sh_history [dave@purple ~]$ env|grep HIST HISTCONTROL=ignoredups HISTSIZE=10 HISTFILESIZE=12 [dave@purple ~]$ ls -l .sh_history -rw-------. 1 dave dave 888 Aug 15 11:48 .sh_history
Hello, > With ksh there is no HISTFILESIZE environment variable to limit the size of the history file per the man page. Is this the expected behavior? Yes, this is expected behavior. There is no remark of a `HISTFILESIZE` variable in the ksh manual pages. I can report this to upstream as a feature request.