Linux 历史命令讲解

# >~/.bash_history
# history -c

 

#第一步
#清空当前缓存中的命令
#关闭shell连接,可以避免写入~/.bash_history

# 保留历史命令 1000条
# vi /etc/profile 或者:sed -i ‘s/HISTSIZE=1000/HISTSIZE=10000/g’/etc/profile
HISTSIZE=1000

posted @ 2022-07-23 18:33  LB_运维技术  阅读(54)  评论(0编辑  收藏  举报