ICode9

精准搜索请尝试: 精确搜索
  • Asible 批量跑出服务器的特权用户2022-08-21 01:30:41

    1、定义剧本(我这里只输出序列号) [root@libin3]# cat libin.yml - hosts: task gather_facts: no tasks: - name: fetch shell: | awk -F ":" '{ print $1,$7 }' /etc/passwd | grep -v "/sbin/nologin" | grep -v "root"

  • Asible 批量跑出服务器相关信息2022-07-09 14:34:06

    1、定义剧本(我这里只输出序列号) [root@libin3]# cat libin.yml - hosts: task gather_facts: no tasks: - name: fetch shell: | dmidecode -t 1 | grep "Serial Number" | awk -F ":" '{print $2}' register: serial -

专注分享技术,共同学习,共同进步。侵权联系[81616952@qq.com]

Copyright (C)ICode9.com, All Rights Reserved.

ICode9版权所有