[question] run logstash shell script in ansible playbooks

39 views
Skip to first unread message

seungdols

unread,
Aug 13, 2019, 9:15:04 PM8/13/19
to Ansible Project
Hi, I like ansible. 

I have one question. I have the role of setup-logstash. 

I want to execute the logstash process. (it doesn't registration in service of centos)

setup-logstash role is download logstash.tar.gz and then unpack. 

So, Copy config file to the target server and run a shell script (run daemon of logstash)

role of setup-logstash is success.

but, I get target server but doesn't logstash process. 

Can you explain why it doesn't work ? 

Thank you. 

Brian Coca

unread,
Aug 14, 2019, 9:44:09 AM8/14/19
to Ansible Project
define 'doesn't work' and it would help to show exact task you are
using and the output you get, adding -vvv is generally helpful when
debugging.

--
----------
Brian Coca

seungdols

unread,
Aug 16, 2019, 7:00:00 AM8/16/19
to Ansible Project
@Brian Coca, Thank you for your advice on how to ask questions.

To test, I configured the following:

start_logstash.sh 

#!/bin/bash


LOG_NAME
="access-to-kafka"
cd
~/logstash/current
bin
/logstash -f ../conf/${LOG_NAME}.conf --path.data=../data/${LOG_NAME} --path.logs=../logs/${LOG_NAME} --node.name=`hostname`-${LOG_NAME} -w 4 &


and simple playbook 

---

- hosts: "{{ host }}"
  vars:
    ansible_ssh_private_key_file: ~/.ssh/ansible_key
    ansible_connection: ssh
  tasks:
     - name: start_logstash
       shell: nohup /home/seungdols/logstash/start_logstash.sh

 
ansible-playbook 2.7.8
  config file = /etc/ansible/ansible.cfg
  configured module search path = [u'/home/seungdols/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/lib/python2.7/site-packages/ansible
  executable location = /usr/bin/ansible-playbook
  python version = 2.7.5 (default, Nov  6 2016, 00:28:07) [GCC 4.8.5 20150623 (Red Hat 4.8.5-11)]
Using /etc/ansible/ansible.cfg as config file
/home/seungdols/apps/ansible-playbooks/utils/hosts did not meet host_list requirements, check plugin documentation if this is unexpected
/home/seungdols/apps/ansible-playbooks/utils/hosts did not meet script requirements, check plugin documentation if this is unexpected
Parsed /home/seungdols/apps/ansible-playbooks/utils/hosts inventory source with ini plugin

PLAYBOOK: start_logstash.yml ****************************************************************************************
1 plays in start_logstash.yml

PLAY [api] **********************************************************************************************************

TASK [Gathering Facts] **********************************************************************************************
task path: /home/seungdols/apps/ansible-playbooks/utils/start_logstash.yml:3
<seungdols-api> ESTABLISH SSH CONNECTION FOR USER: None
<seungdols-api> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/seungdols/.ssh/ansible_key"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/seungdols/.ansible/cp/0d4fdbff82 seungdols-api '/bin/sh -c '"'"'echo ~ && sleep 0'"'"''
<seungdols-api> (0, '/home/seungdols\n', '')
<seungdols-api> ESTABLISH SSH CONNECTION FOR USER: None
<seungdols-api> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/seungdols/.ssh/ansible_key"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/seungdols/.ansible/cp/0d4fdbff82 seungdols-api '/bin/sh -c '"'"'( umask 77 && mkdir -p "` echo /home/seungdols/.ansible/tmp/ansible-tmp-1565952550.92-260296961209374 `" && echo ansible-tmp-1565952550.92-260296961209374="` echo /home/seungdols/.ansible/tmp/ansible-tmp-1565952550.92-260296961209374 `" ) && sleep 0'"'"''
<seungdols-api> (0, 'ansible-tmp-1565952550.92-260296961209374=/home/seungdols/.ansible/tmp/ansible-tmp-1565952550.92-260296961209374\n', '')
Using module file /usr/lib/python2.7/site-packages/ansible/modules/system/setup.py
<seungdols-api> PUT /home/seungdols/.ansible/tmp/ansible-local-73672SO1_TS/tmp_gUqcu TO /home/seungdols/.ansible/tmp/ansible-tmp-1565952550.92-260296961209374/AnsiballZ_setup.py
<seungdols-api> SSH: EXEC sftp -b - -C -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/seungdols/.ssh/ansible_key"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/seungdols/.ansible/cp/0d4fdbff82 '[seungdols-api]'
<seungdols-api> (0, 'sftp> put /home/seungdols/.ansible/tmp/ansible-local-73672SO1_TS/tmp_gUqcu /home/seungdols/.ansible/tmp/ansible-tmp-1565952550.92-260296961209374/AnsiballZ_setup.py\n', '')
<seungdols-api> ESTABLISH SSH CONNECTION FOR USER: None
<seungdols-api> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/seungdols/.ssh/ansible_key"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/seungdols/.ansible/cp/0d4fdbff82 seungdols-api '/bin/sh -c '"'"'chmod u+x /home/seungdols/.ansible/tmp/ansible-tmp-1565952550.92-260296961209374/ /home/seungdols/.ansible/tmp/ansible-tmp-1565952550.92-260296961209374/AnsiballZ_setup.py && sleep 0'"'"''
<seungdols-api> (0, '', '')
<seungdols-api> ESTABLISH SSH CONNECTION FOR USER: None
<seungdols-api> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/seungdols/.ssh/ansible_key"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/seungdols/.ansible/cp/0d4fdbff82 -tt seungdols-api '/bin/sh -c '"'"'/usr/bin/python /home/seungdols/.ansible/tmp/ansible-tmp-1565952550.92-260296961209374/AnsiballZ_setup.py && sleep 0'"'"''
<seungdols-api> (0, '\r\n{"invocation": {"module_args": {"filter": "*", "gather_subset": ["all"], "fact_path": "/etc/ansible/facts.d", "gather_timeout": 10}}, "ansible_facts": {"module_setup": true, "ansible_distribution_version": "7.3.1611", "ansible_distribution_file_variety": "RedHat", "ansible_env": {"LESSOPEN": "||/usr/bin/lesspipe.sh %s", "SSH_CLIENT": "10.97.2.74 59786 22", "LOGNAME": "seungdols", "USER": "seungdols", "PATH": "/sbin:/home/seungdols/apps/apache/bin:/home/seungdols/apps/jdk/bin:/usr/lib64/qt-3.3/bin:/usr/nhnkrb5/bin:/usr/local/bin:/usr/bin:/opt/dell/srvadmin/bin", "HOME": "/home/seungdols", "QT_PLUGIN_PATH": "/usr/lib64/kde4/plugins:/usr/lib/kde4/plugins", "LANG": "ko_KR.UTF-8", "QTLIB": "/usr/lib64/qt-3.3/lib", "TERM": "screen", "SHELL": "/bin/bash", "QTINC": "/usr/lib64/qt-3.3/include", "JAVA_HOME": "/home/seungdols/apps/jdk", "XDG_RUNTIME_DIR": "/run/user/500", "APP_HOME": "/home/seungdols", "TOMCAT_HOME": "/home/seungdols/apps/tomcat", "QT_GRAPHICSSYSTEM_CHECKED": "1", "XDG_SESSION_ID": "449151", "_": "/usr/bin/python", "KDEDIRS": "/usr", "SSH_CONNECTION": "10.97.2.74 59786 10.105.11.78 22", "SSH_TTY": "/dev/pts/0", "APACHE_HTTP_HOME": "/home/seungdols/apps/apache", "SHLVL": "2", "PWD": "/home/seungdols", "MAIL": "/var/mail/seungdols", "LS_COLORS": "rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=01;05;37;41:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.jpg=01;35:*.jpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.axv=01;35:*.anx=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=01;36:*.au=01;36:*.flac=01;36:*.mid=01;36:*.midi=01;36:*.mka=01;36:*.mp3=01;36:*.mpc=01;36:*.ogg=01;36:*.ra=01;36:*.wav=01;36:*.axa=01;36:*.oga=01;36:*.spx=01;36:*.xspf=01;36:", "QTDIR": "/usr/lib64/qt-3.3"}, "ansible_userspace_bits": "64", "ansible_architecture": "x86_64", "ansible_default_ipv4": {"macaddress": "24:6e:96:6f:12:b0", "network": "10.105.11.64", "mtu": 1500, "broadcast": "10.105.11.127", "alias": "bond0", "netmask": "255.255.255.192", "address": "10.105.11.78", "interface": "bond0", "type": "bonding", "gateway": "10.105.11.65"}, "ansible_swapfree_mb": 4095, "ansible_default_ipv6": {}, "ansible_cmdline": {"intel_idle.max_cstate": "0", "BOOT_IMAGE": "/vmlinuz-3.10.0-862.14.4.el7.x86_64", "transparent_hugepage": "never", "rhgb": true, "processor.max_cstate": "0", "quiet": true, "net.ifnames": "0", "spectre_v2": "off", "l1tf": "off", "biosdevname": "0", "crashkernel": "auto", "nopti": true, "intel_pstate": "disable", "ro": true, "root": "UUID=3b942155-4117-4903-aa60-c8779034bb96", "pcie_aspm.policy": "performance"}, "ansible_selinux": {"status": "disabled"}, "ansible_userspace_architecture": "x86_64", "ansible_product_uuid": "NA", "ansible_pkg_mgr": "yum", "ansible_distribution": "CentOS", "ansible_iscsi_iqn": "", "ansible_all_ipv6_addresses": [], "ansible_uptime_seconds": 21523769, "ansible_kernel": "3.10.0-862.14.4.el7.x86_64", "ansible_system_capabilities_enforced": "True", "ansible_python": {"executable": "/usr/bin/python", "version": {"micro": 5, "major": 2, "releaselevel": "final", "serial": 0, "minor": 7}, "type": "CPython", "has_sslcontext": true, "version_info": [2, 7, 5, "final", 0]}, "ansible_is_chroot": true, "ansible_user_shell": "/bin/bash", "ansible_product_serial": "NA", "ansible_form_factor": "Rack Mount Chassis", "ansible_distribution_file_parsed": true, "ansible_fips": false, "ansible_user_id": "seungdols", "ansible_selinux_python_present": true, "ansible_local": {}, "ansible_processor_vcpus": 40, "ansible_processor": ["0", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "1", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "2", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "3", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "4", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "5", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "6", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "7", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "8", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "9", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "10", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "11", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "12", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "13", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "14", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "15", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "16", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "17", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "18", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "19", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "20", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "21", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "22", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "23", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "24", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "25", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "26", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "27", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "28", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "29", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "30", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "31", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "32", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "33", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "34", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "35", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "36", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "37", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "38", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz", "39", "GenuineIntel", "Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz"], "ansible_ssh_host_key_ecdsa_public": "AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBMtjeE8QkTmuGLrqc8BRcjabh0MCvlCqlEdx9WEgs5g4F4pSDGN4qL6/Z0JJY85kx161F925davFpWSVyzwvDUA=", "ansible_mounts": [{"block_used": 1458374, "uuid": "3b942155-4117-4903-aa60-c8779034bb96", "size_total": 21464350720, "block_total": 5240320, "mount": "/", "block_available": 3781946, "size_available": 15490850816, "fstype": "xfs", "inode_total": 10485760, "options": "rw,nodev,noatime,attr2,nobarrier,inode64,noquota", "device": "/dev/sda3", "inode_used": 213988, "block_size": 4096, "inode_available": 10271772}, {"block_used": 40871, "uuid": "1c023f7e-59f4-4a36-9db6-96b6900a936a", "size_total": 530296832, "block_total": 129467, "mount": "/boot", "block_available": 88596, "size_available": 362889216, "fstype": "xfs", "inode_total": 262144, "options": "rw,nodev,noatime,attr2,nobarrier,inode64,noquota", "device": "/dev/sda2", "inode_used": 31, "block_size": 4096, "inode_available": 262113}, {"block_used": 2096612, "uuid": "bacc6a5a-71dd-4c29-84e3-ac719149fbbd", "size_total": 3328670130176, "block_total": 812663606, "mount": "/home1", "block_available": 810566994, "size_available": 3320082407424, "fstype": "xfs", "inode_total": 325224192, "options": "rw,nodev,noatime,attr2,nobarrier,inode64,noquota", "device": "/dev/sda5", "inode_used": 36882, "block_size": 4096, "inode_available": 325187310}, {"block_used": 2096612, "uuid": "bacc6a5a-71dd-4c29-84e3-ac719149fbbd", "size_total": 3328670130176, "block_total": 812663606, "mount": "/home", "block_available": 810566994, "size_available": 3320082407424, "fstype": "xfs", "inode_total": 325224192, "options": "rw,nodev,noatime,attr2,nobarrier,inode64,noquota", "device": "/dev/sda5", "inode_used": 36882, "block_size": 4096, "inode_available": 325187310}, {"block_used": 1218, "uuid": "92F3-C750", "size_total": 314384384, "block_total": 38377, "mount": "/boot/efi", "block_available": 37159, "size_available": 304406528, "fstype": "vfat", "inode_total": 0, "options": "rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=winnt,errors=remount-ro", "device": "/dev/sda1", "inode_used": 0, "block_size": 8192, "inode_available": 0}], "ansible_system_vendor": "Dell Inc.", "ansible_swaptotal_mb": 4095, "ansible_distribution_major_version": "7", "ansible_real_group_id": 500, "ansible_lsb": {"release": "7.3.1611", "major_release": "7", "codename": "Core", "id": "CentOS", "description": "CentOS Linux release 7.3.1611 (Core)"}, "ansible_machine": "x86_64", "ansible_ssh_host_key_rsa_public": "AAAAB3NzaC1yc2EAAAADAQABAAABAQDRPG8bKuFJjK/bwKAyVjSwI8LpLcBCMnJK6xTXaqGCKYIDWvtP0nN3haZffzMFDe+v8P6mRmjaCM+dMMKuBdJP4tUTvlqjuyHm2MGydlyKQ1gkWDTdsqEIL1rcZ5wAMbsnqqOndxNwE5TW+DKmimXHJtue5UMS6cz5bUogNQWEX/urIVjUGwj7lq6PIHoJ0t9CLIbMsfXhllK9x44pzUk54vaqyD085p8z3LJJnqPG+/uNIpaHzXYBS+pjGrdTQrIkEg8/coCXxcvk7TnXujL68dDndHFkbCegLGCyABqzN0wOqTzJlwm5mmOzsYzbcYoaOlqZ1ZQtfhQ56nJxFMDd", "ansible_user_gecos": "developer-account", "ansible_processor_threads_per_core": 2, "ansible_eth0": {"macaddress": "24:6e:96:6f:12:b4", "phc_index": 0, "features": {"tx_checksum_ipv4": "off [fixed]", "generic_receive_offload": "on", "tx_checksum_ipv6": "off [fixed]", "tx_scatter_gather_fraglist": "off [fixed]", "rx_all": "off", "highdma": "on [fixed]", "rx_fcs": "off [fixed]", "tx_lockless": "off [fixed]", "tx_tcp_ecn_segmentation": "off [fixed]", "rx_udp_tunnel_port_offload": "off [fixed]", "tx_tcp6_segmentation": "on", "tx_gso_robust": "off [fixed]", "tx_ipip_segmentation": "on", "tx_tcp_mangleid_segmentation": "off", "tx_checksumming": "on", "vlan_challenged": "off [fixed]", "loopback": "off [fixed]", "fcoe_mtu": "off [fixed]", "scatter_gather": "on", "tx_checksum_sctp": "on", "tx_vlan_stag_hw_insert": "off [fixed]", "rx_vlan_stag_hw_parse": "off [fixed]", "tx_gso_partial": "on", "rx_vlan_stag_filter": "off [fixed]", "large_receive_offload": "off [fixed]", "tx_scatter_gather": "on", "rx_checksumming": "on", "tx_tcp_segmentation": "on", "netns_local": "off [fixed]", "busy_poll": "off [fixed]", "generic_segmentation_offload": "on", "tx_udp_tnl_segmentation": "on", "tcp_segmentation_offload": "on", "l2_fwd_offload": "off [fixed]", "rx_vlan_offload": "on", "ntuple_filters": "off", "tx_gre_csum_segmentation": "on", "tx_nocache_copy": "off", "tx_udp_tnl_csum_segmentation": "on", "udp_fragmentation_offload": "off [fixed]", "tx_sctp_segmentation": "off [fixed]", "tx_sit_segmentation": "on", "tx_checksum_fcoe_crc": "off [fixed]", "hw_tc_offload": "off [fixed]", "tx_checksum_ip_generic": "on", "tx_fcoe_segmentation": "off [fixed]", "rx_vlan_filter": "on [fixed]", "tx_vlan_offload": "on", "receive_hashing": "on", "tx_gre_segmentation": "on"}, "pciid": "0000:06:00.0", "module": "igb", "mtu": 1500, "device": "eth0", "promisc": false, "timestamping": ["tx_hardware", "tx_software", "rx_hardware", "rx_software", "software", "raw_hardware"], "active": false, "type": "ether", "hw_timestamp_filters": ["none", "all"]}, "ansible_eth1": {"macaddress": "24:6e:96:6f:12:b5", "phc_index": 1, "features": {"tx_checksum_ipv4": "off [fixed]", "generic_receive_offload": "on", "tx_checksum_ipv6": "off [fixed]", "tx_scatter_gather_fraglist": "off [fixed]", "rx_all": "off", "highdma": "on [fixed]", "rx_fcs": "off [fixed]", "tx_lockless": "off [fixed]", "tx_tcp_ecn_segmentation": "off [fixed]", "rx_udp_tunnel_port_offload": "off [fixed]", "tx_tcp6_segmentation": "on", "tx_gso_robust": "off [fixed]", "tx_ipip_segmentation": "on", "tx_tcp_mangleid_segmentation": "off", "tx_checksumming": "on", "vlan_challenged": "off [fixed]", "loopback": "off [fixed]", "fcoe_mtu": "off [fixed]", "scatter_gather": "on", "tx_checksum_sctp": "on", "tx_vlan_stag_hw_insert": "off [fixed]", "rx_vlan_stag_hw_parse": "off [fixed]", "tx_gso_partial": "on", "rx_vlan_stag_filter": "off [fixed]", "large_receive_offload": "off [fixed]", "tx_scatter_gather": "on", "rx_checksumming": "on", "tx_tcp_segmentation": "on", "netns_local": "off [fixed]", "busy_poll": "off [fixed]", "generic_segmentation_offload": "on", "tx_udp_tnl_segmentation": "on", "tcp_segmentation_offload": "on", "l2_fwd_offload": "off [fixed]", "rx_vlan_offload": "on", "ntuple_filters": "off", "tx_gre_csum_segmentation": "on", "tx_nocache_copy": "off", "tx_udp_tnl_csum_segmentation": "on", "udp_fragmentation_offload": "off [fixed]", "tx_sctp_segmentation": "off [fixed]", "tx_sit_segmentation": "on", "tx_checksum_fcoe_crc": "off [fixed]", "hw_tc_offload": "off [fixed]", "tx_checksum_ip_generic": "on", "tx_fcoe_segmentation": "off [fixed]", "rx_vlan_filter": "on [fixed]", "tx_vlan_offload": "on", "receive_hashing": "on", "tx_gre_segmentation": "on"}, "pciid": "0000:06:00.1", "module": "igb", "mtu": 1500, "device": "eth1", "promisc": false, "timestamping": ["tx_hardware", "tx_software", "rx_hardware", "rx_software", "software", "raw_hardware"], "active": false, "type": "ether", "hw_timestamp_filters": ["none", "all"]}, "ansible_eth2": {"macaddress": "24:6e:96:6f:12:b0", "phc_index": 2, "perm_macaddress": "24:6e:96:6f:12:b0", "type": "ether", "pciid": "0000:01:00.0", "module": "ixgbe", "mtu": 1500, "device": "eth2", "promisc": false, "timestamping": ["tx_hardware", "tx_software", "rx_hardware", "rx_software", "software", "raw_hardware"], "active": true, "speed": 10000, "hw_timestamp_filters": ["none", "ptp_v1_l4_sync", "ptp_v1_l4_delay_req", "ptp_v2_event"], "features": {"tx_checksum_ipv4": "off [fixed]", "generic_receive_offload": "on", "tx_checksum_ipv6": "off [fixed]", "tx_scatter_gather_fraglist": "off [fixed]", "rx_all": "off", "highdma": "on [fixed]", "rx_fcs": "off [fixed]", "tx_lockless": "off [fixed]", "tx_tcp_ecn_segmentation": "off [fixed]", "rx_udp_tunnel_port_offload": "on", "tx_tcp6_segmentation": "on", "tx_gso_robust": "off [fixed]", "tx_ipip_segmentation": "on", "tx_tcp_mangleid_segmentation": "off", "tx_checksumming": "on", "vlan_challenged": "off [fixed]", "loopback": "off [fixed]", "fcoe_mtu": "off [fixed]", "scatter_gather": "on", "tx_checksum_sctp": "on", "tx_vlan_stag_hw_insert": "off [fixed]", "rx_vlan_stag_hw_parse": "off [fixed]", "tx_gso_partial": "on", "rx_vlan_stag_filter": "off [fixed]", "large_receive_offload": "off", "tx_scatter_gather": "on", "rx_checksumming": "on", "tx_tcp_segmentation": "on", "netns_local": "off [fixed]", "busy_poll": "off [fixed]", "generic_segmentation_offload": "on", "tx_udp_tnl_segmentation": "on", "tcp_segmentation_offload": "on", "l2_fwd_offload": "off", "rx_vlan_offload": "on", "ntuple_filters": "off", "tx_gre_csum_segmentation": "on", "tx_nocache_copy": "off", "tx_udp_tnl_csum_segmentation": "on", "udp_fragmentation_offload": "off [fixed]", "tx_sctp_segmentation": "off [fixed]", "tx_sit_segmentation": "on", "tx_checksum_fcoe_crc": "on [fixed]", "hw_tc_offload": "off", "tx_checksum_ip_generic": "on", "tx_fcoe_segmentation": "on [fixed]", "rx_vlan_filter": "on", "tx_vlan_offload": "on", "receive_hashing": "on", "tx_gre_segmentation": "on"}}, "ansible_eth3": {"macaddress": "24:6e:96:6f:12:b0", "phc_index": 3, "perm_macaddress": "24:6e:96:6f:12:b2", "type": "ether", "pciid": "0000:01:00.1", "module": "ixgbe", "mtu": 1500, "device": "eth3", "promisc": false, "timestamping": ["tx_hardware", "tx_software", "rx_hardware", "rx_software", "software", "raw_hardware"], "active": true, "speed": 10000, "hw_timestamp_filters": ["none", "ptp_v1_l4_sync", "ptp_v1_l4_delay_req", "ptp_v2_event"], "features": {"tx_checksum_ipv4": "off [fixed]", "generic_receive_offload": "on", "tx_checksum_ipv6": "off [fixed]", "tx_scatter_gather_fraglist": "off [fixed]", "rx_all": "off", "highdma": "on [fixed]", "rx_fcs": "off [fixed]", "tx_lockless": "off [fixed]", "tx_tcp_ecn_segmentation": "off [fixed]", "rx_udp_tunnel_port_offload": "on", "tx_tcp6_segmentation": "on", "tx_gso_robust": "off [fixed]", "tx_ipip_segmentation": "on", "tx_tcp_mangleid_segmentation": "off", "tx_checksumming": "on", "vlan_challenged": "off [fixed]", "loopback": "off [fixed]", "fcoe_mtu": "off [fixed]", "scatter_gather": "on", "tx_checksum_sctp": "on", "tx_vlan_stag_hw_insert": "off [fixed]", "rx_vlan_stag_hw_parse": "off [fixed]", "tx_gso_partial": "on", "rx_vlan_stag_filter": "off [fixed]", "large_receive_offload": "off", "tx_scatter_gather": "on", "rx_checksumming": "on", "tx_tcp_segmentation": "on", "netns_local": "off [fixed]", "busy_poll": "off [fixed]", "generic_segmentation_offload": "on", "tx_udp_tnl_segmentation": "on", "tcp_segmentation_offload": "on", "l2_fwd_offload": "off", "rx_vlan_offload": "on", "ntuple_filters": "off", "tx_gre_csum_segmentation": "on", "tx_nocache_copy": "off", "tx_udp_tnl_csum_segmentation": "on", "udp_fragmentation_offload": "off [fixed]", "tx_sctp_segmentation": "off [fixed]", "tx_sit_segmentation": "on", "tx_checksum_fcoe_crc": "on [fixed]", "hw_tc_offload": "off", "tx_checksum_ip_generic": "on", "tx_fcoe_segmentation": "on [fixed]", "rx_vlan_filter": "on", "tx_vlan_offload": "on", "receive_hashing": "on", "tx_gre_segmentation": "on"}}, "ansible_all_ipv4_addresses": ["10.105.11.78", "10.106.240.76"], "ansible_python_version": "2.7.5", "ansible_product_version": "NA", "ansible_service_mgr": "systemd", "ansible_memory_mb": {"real": {"total": 128652, "used": 36270, "free": 92382}, "swap": {"cached": 0, "total": 4095, "free": 4095, "used": 0}, "nocache": {"used": 27317, "free": 101335}}, "ansible_user_dir": "/home/seungdols", "gather_subset": ["all"], "ansible_real_user_id": 500, "ansible_virtualization_role": "host", "ansible_tunl0": {"macaddress": "00:00:00:00", "features": {"tx_checksum_ipv4": "off [fixed]", "generic_receive_offload": "on", "tx_checksum_ipv6": "off [fixed]", "tx_scatter_gather_fraglist": "on", "rx_all": "off [fixed]", "highdma": "on", "rx_fcs": "off [fixed]", "tx_lockless": "on [fixed]", "tx_tcp_ecn_segmentation": "on", "rx_udp_tunnel_port_offload": "off [fixed]", "tx_tcp6_segmentation": "on", "tx_gso_robust": "off [fixed]", "tx_ipip_segmentation": "off [fixed]", "tx_tcp_mangleid_segmentation": "on", "tx_checksumming": "on", "vlan_challenged": "off [fixed]", "loopback": "off [fixed]", "fcoe_mtu": "off [fixed]", "scatter_gather": "on", "tx_checksum_sctp": "off [fixed]", "tx_vlan_stag_hw_insert": "off [fixed]", "rx_vlan_stag_hw_parse": "off [fixed]", "tx_gso_partial": "off [fixed]", "rx_vlan_stag_filter": "off [fixed]", "large_receive_offload": "off [fixed]", "tx_scatter_gather": "on", "rx_checksumming": "off [fixed]", "tx_tcp_segmentation": "on", "netns_local": "on [fixed]", "busy_poll": "off [fixed]", "generic_segmentation_offload": "on", "tx_udp_tnl_segmentation": "off [fixed]", "tcp_segmentation_offload": "on", "l2_fwd_offload": "off [fixed]", "rx_vlan_offload": "off [fixed]", "ntuple_filters": "off [fixed]", "tx_gre_csum_segmentation": "off [fixed]", "tx_nocache_copy": "off", "tx_udp_tnl_csum_segmentation": "off [fixed]", "udp_fragmentation_offload": "on", "tx_sctp_segmentation": "on", "tx_sit_segmentation": "off [fixed]", "tx_checksum_fcoe_crc": "off [fixed]", "hw_tc_offload": "off [fixed]", "tx_checksum_ip_generic": "on", "tx_fcoe_segmentation": "off [fixed]", "rx_vlan_filter": "off [fixed]", "tx_vlan_offload": "off [fixed]", "receive_hashing": "off [fixed]", "tx_gre_segmentation": "off [fixed]"}, "hw_timestamp_filters": [], "mtu": 1500, "device": "tunl0", "promisc": false, "timestamping": ["rx_software", "software"], "active": true, "type": "unknown"}, "ansible_dns": {"nameservers": ["10.22.64.6", "10.22.64.7"], "search": ["nfra.io"], "options": {"attempts": "2", "timeout": "1"}}, "ansible_effective_group_id": 500, "ansible_lo": {"features": {"tx_checksum_ipv4": "off [fixed]", "generic_receive_offload": "on", "tx_checksum_ipv6": "off [fixed]", "tx_scatter_gather_fraglist": "on [fixed]", "rx_all": "off [fixed]", "highdma": "on [fixed]", "rx_fcs": "off [fixed]", "tx_lockless": "on [fixed]", "tx_tcp_ecn_segmentation": "on", "rx_udp_tunnel_port_offload": "off [fixed]", "tx_tcp6_segmentation": "on", "tx_gso_robust": "off [fixed]", "tx_ipip_segmentation": "off [fixed]", "tx_tcp_mangleid_segmentation": "on", "tx_checksumming": "on", "vlan_challenged": "on [fixed]", "loopback": "on [fixed]", "fcoe_mtu": "off [fixed]", "scatter_gather": "on", "tx_checksum_sctp": "on [fixed]", "tx_vlan_stag_hw_insert": "off [fixed]", "rx_vlan_stag_hw_parse": "off [fixed]", "tx_gso_partial": "off [fixed]", "rx_vlan_stag_filter": "off [fixed]", "large_receive_offload": "off [fixed]", "tx_scatter_gather": "on [fixed]", "rx_checksumming": "on [fixed]", "tx_tcp_segmentation": "on", "netns_local": "on [fixed]", "busy_poll": "off [fixed]", "generic_segmentation_offload": "on", "tx_udp_tnl_segmentation": "off [fixed]", "tcp_segmentation_offload": "on", "l2_fwd_offload": "off [fixed]", "rx_vlan_offload": "off [fixed]", "ntuple_filters": "off [fixed]", "tx_gre_csum_segmentation": "off [fixed]", "tx_nocache_copy": "off [fixed]", "tx_udp_tnl_csum_segmentation": "off [fixed]", "udp_fragmentation_offload": "on", "tx_sctp_segmentation": "on", "tx_sit_segmentation": "off [fixed]", "tx_checksum_fcoe_crc": "off [fixed]", "hw_tc_offload": "off [fixed]", "tx_checksum_ip_generic": "on [fixed]", "tx_fcoe_segmentation": "off [fixed]", "rx_vlan_filter": "off [fixed]", "tx_vlan_offload": "off [fixed]", "receive_hashing": "off [fixed]", "tx_gre_segmentation": "off [fixed]"}, "hw_timestamp_filters": [], "mtu": 65536, "device": "lo", "promisc": false, "timestamping": ["rx_software", "software"], "ipv4": {"broadcast": "host", "netmask": "255.0.0.0", "network": "127.0.0.0", "address": "127.0.0.1"}, "active": true, "type": "loopback"}, "ansible_memtotal_mb": 128652, "ansible_device_links": {"masters": {}, "labels": {}, "ids": {"sda4": ["scsi-361866da0b4dfe90023a0d59e0ecc963e-part4", "wwn-0x61866da0b4dfe90023a0d59e0ecc963e-part4"], "sda5": ["scsi-361866da0b4dfe90023a0d59e0ecc963e-part5", "wwn-0x61866da0b4dfe90023a0d59e0ecc963e-part5"], "sda2": ["scsi-361866da0b4dfe90023a0d59e0ecc963e-part2", "wwn-0x61866da0b4dfe90023a0d59e0ecc963e-part2"], "sda3": ["scsi-361866da0b4dfe90023a0d59e0ecc963e-part3", "wwn-0x61866da0b4dfe90023a0d59e0ecc963e-part3"], "sda1": ["scsi-361866da0b4dfe90023a0d59e0ecc963e-part1", "wwn-0x61866da0b4dfe90023a0d59e0ecc963e-part1"], "sda": ["scsi-361866da0b4dfe90023a0d59e0ecc963e", "wwn-0x61866da0b4dfe90023a0d59e0ecc963e"]}, "uuids": {"sda4": ["4d1bc98f-fbde-43dd-8119-341e86b933f1"], "sda5": ["bacc6a5a-71dd-4c29-84e3-ac719149fbbd"], "sda2": ["1c023f7e-59f4-4a36-9db6-96b6900a936a"], "sda3": ["3b942155-4117-4903-aa60-c8779034bb96"], "sda1": ["92F3-C750"]}}, "ansible_apparmor": {"status": "disabled"}, "ansible_memfree_mb": 92382, "ansible_product_name": "PowerEdge R630", "ansible_processor_count": 2, "ansible_hostname": "seungdols-api", "ansible_interfaces": ["bond0", "lo", "tunl0", "tunl0_0", "eth3", "eth2", "eth1", "eth0"], "ansible_machine_id": "26432833849145bc872f8f7335007252", "ansible_tunl0_0": {"ipv4": {"broadcast": "10.106.240.76", "netmask": "255.255.255.255", "network": "10.106.240.76", "address": "10.106.240.76"}}, "ansible_system": "Linux", "ansible_fqdn": "seungdols-api.nfra.io", "ansible_user_gid": 500, "ansible_nodename": "seungdols-api", "ansible_domain": "nfra.io", "ansible_distribution_file_path": "/etc/redhat-release", "ansible_virtualization_type": "kvm", "ansible_ssh_host_key_ed25519_public": "AAAAC3NzaC1lZDI1NTE5AAAAIBjG+hgDGFix+kNsS/eWxC9dEy8RUbj2Vj25nEHljiJT", "ansible_processor_cores": 10, "ansible_bios_version": "2.4.3", "ansible_date_time": {"weekday_number": "5", "iso8601_basic_short": "20190816T194911", "tz": "KST", "weeknumber": "32", "hour": "19", "year": "2019", "minute": "49", "tz_offset": "+0900", "month": "08", "epoch": "1565952551", "iso8601_micro": "2019-08-16T10:49:11.876829Z", "weekday": "\\uae08\\uc694\\uc77c", "time": "19:49:11", "date": "2019-08-16", "iso8601": "2019-08-16T10:49:11Z", "day": "16", "iso8601_basic": "20190816T194911876749", "second": "11"}, "ansible_distribution_release": "Core", "ansible_os_family": "RedHat", "ansible_effective_user_id": 500, "ansible_bond0": {"lacp_rate": "slow", "macaddress": "24:6e:96:6f:12:b0", "features": {"tx_checksum_ipv4": "off [fixed]", "generic_receive_offload": "on", "tx_checksum_ipv6": "off [fixed]", "tx_scatter_gather_fraglist": "off [requested on]", "rx_all": "off [fixed]", "highdma": "on", "rx_fcs": "off [fixed]", "tx_lockless": "on [fixed]", "tx_tcp_ecn_segmentation": "on", "rx_udp_tunnel_port_offload": "off [fixed]", "tx_tcp6_segmentation": "on", "tx_gso_robust": "off [fixed]", "tx_ipip_segmentation": "on", "tx_tcp_mangleid_segmentation": "on", "tx_checksumming": "on", "vlan_challenged": "off [fixed]", "loopback": "off [fixed]", "fcoe_mtu": "off [fixed]", "scatter_gather": "on", "tx_checksum_sctp": "off [fixed]", "tx_vlan_stag_hw_insert": "off [fixed]", "rx_vlan_stag_hw_parse": "off [fixed]", "tx_gso_partial": "off [fixed]", "rx_vlan_stag_filter": "off [fixed]", "large_receive_offload": "on", "tx_scatter_gather": "on", "rx_checksumming": "off [fixed]", "tx_tcp_segmentation": "on", "netns_local": "on [fixed]", "busy_poll": "off [fixed]", "generic_segmentation_offload": "on", "tx_udp_tnl_segmentation": "on", "tcp_segmentation_offload": "on", "l2_fwd_offload": "off [fixed]", "rx_vlan_offload": "on", "ntuple_filters": "off [fixed]", "tx_gre_csum_segmentation": "on", "tx_nocache_copy": "off", "tx_udp_tnl_csum_segmentation": "on", "udp_fragmentation_offload": "off [fixed]", "tx_sctp_segmentation": "off [fixed]", "tx_sit_segmentation": "on", "tx_checksum_fcoe_crc": "off [fixed]", "hw_tc_offload": "off [fixed]", "tx_checksum_ip_generic": "on", "tx_fcoe_segmentation": "off [fixed]", "rx_vlan_filter": "on", "tx_vlan_offload": "on", "receive_hashing": "off [fixed]", "tx_gre_segmentation": "on"}, "miimon": "1000", "all_slaves_active": false, "hw_timestamp_filters": [], "primary": "eth2", "mtu": 1500, "device": "bond0", "timestamping": ["rx_software", "software"], "mode": "active-backup", "slaves": ["eth2", "eth3"], "active": true, "type": "bonding", "ipv4": {"broadcast": "10.105.11.127", "netmask": "255.255.255.192", "network": "10.105.11.64", "address": "10.105.11.78"}}, "ansible_devices": {"loop0": {"scheduler_mode": "", "rotational": "1", "vendor": null, "sectors": "0", "links": {"masters": [], "labels": [], "ids": [], "uuids": []}, "sas_device_handle": null, "sas_address": null, "virtual": 1, "host": "", "sectorsize": "512", "removable": "0", "support_discard": "4096", "model": null, "partitions": {}, "holders": [], "size": "0.00 Bytes"}, "sda": {"scheduler_mode": "noop", "rotational": "1", "vendor": "DELL", "sectors": "6556483584", "links": {"masters": [], "labels": [], "ids": ["scsi-361866da0b4dfe90023a0d59e0ecc963e", "wwn-0x61866da0b4dfe90023a0d59e0ecc963e"], "uuids": []}, "partitions": {"sda4": {"sectorsize": 512, "uuid": "4d1bc98f-fbde-43dd-8119-341e86b933f1", "links": {"masters": [], "labels": [], "ids": ["scsi-361866da0b4dfe90023a0d59e0ecc963e-part4", "wwn-0x61866da0b4dfe90023a0d59e0ecc963e-part4"], "uuids": ["4d1bc98f-fbde-43dd-8119-341e86b933f1"]}, "sectors": "8388608", "start": "43608064", "holders": [], "size": "4.00 GB"}, "sda5": {"sectorsize": 512, "uuid": "bacc6a5a-71dd-4c29-84e3-ac719149fbbd", "links": {"masters": [], "labels": [], "ids": ["scsi-361866da0b4dfe90023a0d59e0ecc963e-part5", "wwn-0x61866da0b4dfe90023a0d59e0ecc963e-part5"], "uuids": ["bacc6a5a-71dd-4c29-84e3-ac719149fbbd"]}, "sectors": "6504484864", "start": "51996672", "holders": [], "size": "3.03 TB"}, "sda2": {"sectorsize": 512, "uuid": "1c023f7e-59f4-4a36-9db6-96b6900a936a", "links": {"masters": [], "labels": [], "ids": ["scsi-361866da0b4dfe90023a0d59e0ecc963e-part2", "wwn-0x61866da0b4dfe90023a0d59e0ecc963e-part2"], "uuids": ["1c023f7e-59f4-4a36-9db6-96b6900a936a"]}, "sectors": "1048576", "start": "616448", "holders": [], "size": "512.00 MB"}, "sda3": {"sectorsize": 512, "uuid": "3b942155-4117-4903-aa60-c8779034bb96", "links": {"masters": [], "labels": [], "ids": ["scsi-361866da0b4dfe90023a0d59e0ecc963e-part3", "wwn-0x61866da0b4dfe90023a0d59e0ecc963e-part3"], "uuids": ["3b942155-4117-4903-aa60-c8779034bb96"]}, "sectors": "41943040", "start": "1665024", "holders": [], "size": "20.00 GB"}, "sda1": {"sectorsize": 512, "uuid": "92F3-C750", "links": {"masters": [], "labels": [], "ids": ["scsi-361866da0b4dfe90023a0d59e0ecc963e-part1", "wwn-0x61866da0b4dfe90023a0d59e0ecc963e-part1"], "uuids": ["92F3-C750"]}, "sectors": "614400", "start": "2048", "holders": [], "size": "300.00 MB"}}, "sas_device_handle": null, "sas_address": null, "virtual": 1, "host": "RAID bus controller: LSI Logic / Symbios Logic MegaRAID SAS-3 3108 [Invader] (rev 02)", "sectorsize": "512", "removable": "0", "support_discard": "0", "model": "PERC H730 Mini", "wwn": "0x61866da0b4dfe90023a0d59e0ecc963e", "holders": [], "size": "3.05 TB"}}, "ansible_user_uid": 500, "ansible_bios_date": "01/17/2017", "ansible_system_capabilities": [""]}}\r\n', 'Shared connection to seungdols-api closed.\r\n')
<seungdols-api> ESTABLISH SSH CONNECTION FOR USER: None
<seungdols-api> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/seungdols/.ssh/ansible_key"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/seungdols/.ansible/cp/0d4fdbff82 seungdols-api '/bin/sh -c '"'"'rm -f -r /home/seungdols/.ansible/tmp/ansible-tmp-1565952550.92-260296961209374/ > /dev/null 2>&1 && sleep 0'"'"''
<seungdols-api> (0, '', '')
ok: [seungdols-api]
META: ran handlers

TASK [start_logstash] ***********************************************************************************************
task path: /home/seungdols/apps/ansible-playbooks/utils/start_logstash.yml:8
<seungdols-api> ESTABLISH SSH CONNECTION FOR USER: None
<seungdols-api> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/seungdols/.ssh/ansible_key"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/seungdols/.ansible/cp/0d4fdbff82 seungdols-api '/bin/sh -c '"'"'echo ~ && sleep 0'"'"''
<seungdols-api> (0, '/home/seungdols\n', '')
<seungdols-api> ESTABLISH SSH CONNECTION FOR USER: None
<seungdols-api> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/seungdols/.ssh/ansible_key"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/seungdols/.ansible/cp/0d4fdbff82 seungdols-api '/bin/sh -c '"'"'( umask 77 && mkdir -p "` echo /home/seungdols/.ansible/tmp/ansible-tmp-1565952552.42-80111721246848 `" && echo ansible-tmp-1565952552.42-80111721246848="` echo /home/seungdols/.ansible/tmp/ansible-tmp-1565952552.42-80111721246848 `" ) && sleep 0'"'"''
<seungdols-api> (0, 'ansible-tmp-1565952552.42-80111721246848=/home/seungdols/.ansible/tmp/ansible-tmp-1565952552.42-80111721246848\n', '')
Using module file /usr/lib/python2.7/site-packages/ansible/modules/commands/command.py
<seungdols-api> PUT /home/seungdols/.ansible/tmp/ansible-local-73672SO1_TS/tmpLy_RCF TO /home/seungdols/.ansible/tmp/ansible-tmp-1565952552.42-80111721246848/AnsiballZ_command.py
<seungdols-api> SSH: EXEC sftp -b - -C -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/seungdols/.ssh/ansible_key"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/seungdols/.ansible/cp/0d4fdbff82 '[seungdols-api]'
<seungdols-api> (0, 'sftp> put /home/seungdols/.ansible/tmp/ansible-local-73672SO1_TS/tmpLy_RCF /home/seungdols/.ansible/tmp/ansible-tmp-1565952552.42-80111721246848/AnsiballZ_command.py\n', '')
<seungdols-api> ESTABLISH SSH CONNECTION FOR USER: None
<seungdols-api> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/seungdols/.ssh/ansible_key"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/seungdols/.ansible/cp/0d4fdbff82 seungdols-api '/bin/sh -c '"'"'chmod u+x /home/seungdols/.ansible/tmp/ansible-tmp-1565952552.42-80111721246848/ /home/seungdols/.ansible/tmp/ansible-tmp-1565952552.42-80111721246848/AnsiballZ_command.py && sleep 0'"'"''
<seungdols-api> (0, '', '')
<seungdols-api> ESTABLISH SSH CONNECTION FOR USER: None
<seungdols-api> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/seungdols/.ssh/ansible_key"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/seungdols/.ansible/cp/0d4fdbff82 -tt seungdols-api '/bin/sh -c '"'"'/usr/bin/python /home/seungdols/.ansible/tmp/ansible-tmp-1565952552.42-80111721246848/AnsiballZ_command.py && sleep 0'"'"''
<seungdols-api> (0, '\r\n{"changed": true, "end": "2019-08-16 19:49:14.023559", "stdout": "", "cmd": "nohup /home/seungdols/apps/logstash/start_logstash.sh", "rc": 0, "start": "2019-08-16 19:49:13.013204", "stderr": "nohup: ignoring input", "delta": "0:00:01.010355", "invocation": {"module_args": {"warn": true, "executable": null, "_uses_shell": true, "_raw_params": "nohup /home/seungdols/apps/logstash/start_logstash.sh", "removes": null, "argv": null, "creates": null, "chdir": null, "stdin": null}}}\r\n', 'Shared connection to seungdols-api closed.\r\n')
<seungdols-api> ESTABLISH SSH CONNECTION FOR USER: None
<seungdols-api> SSH: EXEC ssh -C -o ControlMaster=auto -o ControlPersist=60s -o 'IdentityFile="/home/seungdols/.ssh/ansible_key"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 -o ControlPath=/home/seungdols/.ansible/cp/0d4fdbff82 seungdols-api '/bin/sh -c '"'"'rm -f -r /home/seungdols/.ansible/tmp/ansible-tmp-1565952552.42-80111721246848/ > /dev/null 2>&1 && sleep 0'"'"''
<seungdols-api> (0, '', '')
changed: [seungdols-api] => {
    "changed": true, 
    "cmd": "nohup /home/seungdols/apps/logstash/start_logstash.sh", 
    "delta": "0:00:01.010355", 
    "end": "2019-08-16 19:49:14.023559", 
    "invocation": {
        "module_args": {
            "_raw_params": "nohup /home/seungdols/apps/logstash/start_logstash.sh", 
            "_uses_shell": true, 
            "argv": null, 
            "chdir": null, 
            "creates": null, 
            "executable": null, 
            "removes": null, 
            "stdin": null, 
            "warn": true
        }
    }, 
    "rc": 0, 
    "start": "2019-08-16 19:49:13.013204", 
    "stderr": "nohup: ignoring input", 
    "stderr_lines": [
        "nohup: ignoring input"
    ], 
    "stdout": "", 
    "stdout_lines": []
}
META: ran handlers
META: ran handlers

PLAY RECAP **********************************************************************************************************
seungdols-api              : ok=2    changed=1    unreachable=0    failed=0   



The playbook was successful, and in fact, logstash seems to be running on the target server, but logstash shut down a few seconds after running the playbook.

I wonder if there is anything wrong with me. (For your reference, some of the contents of the log have been modified as company confidential.)


2019년 8월 14일 수요일 오후 10시 44분 9초 UTC+9, Brian Coca 님의 말:

Dick Visser

unread,
Aug 16, 2019, 10:37:22 AM8/16/19
to ansible...@googlegroups.com


The playbook was successful, and in fact, logstash seems to be running on the target server, but logstash shut down a few seconds after running the playbook.


You seem to be using ansible to run a shell script, and it ran OK as far as ansible is involved.
The error must be somewhere in your shell script.


Dick

seungdols

unread,
Aug 24, 2019, 1:33:37 AM8/24/19
to Ansible Project
@Dick visser thank you for your advice.

I try to debug the shell script. but I connect to the target server and then I run shell script of logstash. It’s everything Ok.

So, I don’t know. But I try to debug my shell script. 

thank you.

2019년 8월 16일 금요일 오후 11시 37분 22초 UTC+9, Dick Visser 님의 말:

Dick Visser

unread,
Aug 24, 2019, 10:11:28 AM8/24/19
to ansible...@googlegroups.com
This sort of issues is usually down to a slightly different set of environment variables that you get when signed in through an interactive shell vs ansible shell. 



--
You received this message because you are subscribed to the Google Groups "Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ansible-proje...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/bfc3ff47-dfd6-4421-9f24-eb3a285c6fde%40googlegroups.com.
--
Sent from a mobile device - please excuse the brevity, spelling and punctuation.
Reply all
Reply to author
Forward
0 new messages