包含标签 history articles

Linux history记录发送到syslog日志

常用的shell有bash和csh,而history记录中,bash默认是不带命令操作时间的,csh带有记录时间,可以通过变量修改,查看历史命令的执行时间,不过history记录默认只保存1000条。想要所有的命令都进行命令,最好是将其保存到日志记录中。所以可以通过一些变量配置,……

Continue reading

bash和csh的history记录加上时间戳

现网在查看history记录时,往往只有序列标签,看不到具体是什么时间执行的。其实在history的记录里,记录的有时间。只不过我们查看时未给我们显示出来而已。如果想在查看时显示出来时间戳是比较容易的。不过对于不同的shell 类型显示出来的参数是有区别的。 一、bash shell 在查看前先……

Continue reading

中国简历——果然够简

盘古说:我开; 女娲说:我补; 共工说:我撞; 神农说:我尝; 精卫说:我填; 夸父说:我追; 后羿说:我射; 嫦娥说:没射着! 黄帝说:我们做什么; 尧说:我让; 舜说:我也让; 禹说:咱爷们怎么办? 启说:让他们球! 桀说:好玩; 汤说:造反有理了; 夏亡了…… 武王说:我也反了; 商亡了…… 幽王说:点火; 褒……

Continue reading

从“拉氏之歌”所了解到的

我们先看下这位占据美国历届内阁最年轻的国防部长(福特时代)和最年长的国防部长(布什时代)两个头衔的德裔美国人的拉部长的那段名句。 1The Unknown 2不知 3As we know, 4如我们所知 5There are known knowns. 6有一些已经知道的不知道 7There are things we know we know. 8有一些事情我们知道我们知道 9We also know 10我们还知道 11There are known unknowns. 12有一些已经知道的不……

Continue reading

linux清除last和history记录

清除登陆系统成功的记录,也就是last命令看到的记录 [root@localhost root]# echo “”> /var/log/wtmp 此文件默认打开时乱码的,里面可以看到ip等等信息 [root@localhost root]# echo “”>/var/log/wtmp [root@localhost root]# last 此时即看不到用户登录信息 清除登陆系统失败的记录,也就是lastb命令看到的记录 [root@localhost root]# echo “”> /var/log/btmp 此文件默认打……

Continue reading

Latest articles

Categories

Tags

ACL AD AES AI AWS Ansible Atlassian Azure BMC Blockchain Brocade CDH5 CL210 Cobbler Confd C语言 DDOS DISTINCT DNS Duckdb EKS ELK GCP Ghost Git Glusterfs Go Godaddy Grafana HBA HCIE Hotspot HttpWatch IBM IIS IOS InfluxDB Ingress InnoDB JavaScript Jinja2 KVM Keepalived Mplayer MySQLdb Netlify OpenResty PM PostgreSQL QoS RH318 RH442 RHCA RHCE RHEV RSA SRE SecureCRT Statuscode SublimeText2 TC Telecom Tencentcloud VBA aira2 alpine android anpic apache apm apparmor appfog apr apt-get aria2 array atop audit awk awstats axel backdoor backup bamboo bash bat benchmark bigdata bin bind bitwise book bootstrap bsd c1000 cache capistrano catlog centos centos7 chatops chattr check_mk checkinstall cisco clearall clickhouse cloud-desktop cmdb cms collectd comm compress conver corosync cpu crontab crunchbang css curl date decode dell desktop devops df dhcp diff diskpart django docker dos2unix dpkg drupal etcd excel fail2ban fastcgi fdisk fiddler find firewalld flask flvtool ftp function fuser geek gin github gitlab glances golang google gooupadd graphviz gravatra grep grub2 hadoop haproxy hardware heartbeat helm hexdump hhvm history html http/html/web httplogs https huawei huaweicloud hugo icmp iconv ifconfig inotify iopp ipmitool iptables iredmail iscsi isito it-news java jdk jenkins jira join joomla k3s k8s kdump kernel kingate lamp last leetcode lib light-http linux linux高级篇 ln ls lsi lsof lvm lvs mac mail man mark markdown matplotlib maven memcached microservice mimikatz mkdocs mkpasswd mmonit mod_jk mongodb monit monitor mono moodle mosh mount mpm mrtg mtr my.cnf mysql mysqlbinlog mysqld_multi mysqldump mysqlhotcopy nagios nc nethogs nexus nfs nginx nmon nocatlog node.js nrpe ntfs ntop ntp obs ocr open-falcon openbox opencv openldap openssl openstack oracle oswatch paas pacemaker pam pandas parted pcp pcre pdf percona perl pexpect pgrep php php-fpm ping plsql develope postfix powershell prettify proc prometheus puppeteer pushd pwgen pxe pyecharts python python模块 radmin raid rdesktop read redhat redis redmine regex rh134 rhel7 rhel8 rm rman rootkit route rpm rpmforge rrdtool rsync rsyslog safe saltstack samba scapy screen sed selenium selinux seo seq session set shc sheepdog shell shopt sitemap skydns smokeping snffier snmp socket soft sort spider sql sqlserver squid ss ssh sshpass strace strings su sudo suse svn sysbench syslog-ng sysstat systemd t tar tcpcopy tcpdump tech telnet tengine test testlink threads time tmux tomcat touch tr tsar twisted ubuntu udev ulimit unix unixbench user-agent useradd varnish vbs vercel vi vim visudo vmstat vmware vnc voice vpn vscode vsftp vsftpd vue watchdog web webcam webistrano wget wiki windows wol wordpress workshop wsl x-windows xampp xcache xmllint xtrabackup yule yum zabbix zeromq zip zonetime zookeeper 下载工具 云主机 云原生 代理 加密 古意 吐槽 圈里圈外 娱乐 字符串函数 安全 平台架构 意林 推理 提权 故事汇 故障案例 数据结构 每日看点 民国史 生活 科学记录 站长管理工具 算法 管理 网站架构 翻墙 股票 行业 诗韵 负载均衡 远程管理 面试题

Links

Meta