??????????????
Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 173

Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 174

Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 175

Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 176

Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 177

Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 178
 Udac@`sddlmZmZmZeZidd6dgd6dd6ZdZd Zd Z dd l m Z d Z d Z dZdZdZdZedkrendS(i(tabsolute_importtdivisiontprint_functions1.1tmetadata_versiontpreviewtstatust communityt supported_bys --- author: - Kairo Araujo (@kairoaraujo) module: aix_devices short_description: Manages AIX devices description: - This module discovers, defines, removes and modifies attributes of AIX devices. version_added: '2.8' options: attributes: description: - A list of device attributes. type: dict device: description: - The name of the device. - C(all) is valid to rescan C(available) all devices (AIX cfgmgr command). type: str required: true force: description: - Forces action. type: bool default: no recursive: description: - Removes or defines a device and children devices. type: bool default: no state: description: - Controls the device state. - C(available) (alias C(present)) rescan a specific device or all devices (when C(device) is not specified). - C(removed) (alias C(absent) removes a device. - C(defined) changes device to Defined state. type: str choices: [ available, defined, removed ] default: available sT - name: Scan new devices aix_devices: device: all state: available - name: Scan new virtual devices (vio0) aix_devices: device: vio0 state: available - name: Removing IP alias to en0 aix_devices: device: en0 attributes: delalias4: 10.0.0.100,255.255.255.0 - name: Removes ent2 aix_devices: device: ent2 state: removed - name: Put device en2 in Defined aix_devices: device: en2 state: defined - name: Removes ent4 (inexistent). aix_devices: device: ent4 state: removed - name: Put device en4 in Defined (inexistent) aix_devices: device: en4 state: defined - name: Put vscsi1 and children devices in Defined state. aix_devices: device: vscsi1 recursive: yes state: defined - name: Removes vscsi1 and children devices. aix_devices: device: vscsi1 recursive: yes state: removed - name: Changes en1 mtu to 9000 and disables arp. aix_devices: device: en1 attributes: mtu: 900 arp: off state: available - name: Configure IP, netmask and set en1 up. aix_devices: device: en1 attributes: netaddr: 192.168.0.100 netmask: 255.255.255.0 state: up state: available - name: Adding IP alias to en0 aix_devices: device: en0 attributes: alias4: 10.0.0.100,255.255.255.0 state: available s # (t AnsibleModulecC`s|jdt}|jd|ddd|g\}}}|dkri|jddd|d |n|r|jd }t|fSd }t|fS( s Check if device already exists and the state. Args: module: Ansible module. device: device to be checked. Returns: bool, device state tlsdevs%ss-Cs-litmsgsFailed to run lsdevtrcterriN(t get_bin_pathtTruet run_commandt fail_jsontsplittNonetFalse(tmoduletdevicet lsdev_cmdR t lsdev_outR t device_state((sF/usr/lib/python2.7/site-packages/ansible/modules/system/aix_devices.pyt _check_devices ,  c C`s|jdt}|jd|dd|dd|g\}}}ddg}|dkr|||krrd}nd}|S|d kr|jd d |d |d |n|jd}|S(s Args: module: Ansible module. device: device to check attributes. attr: attribute to be checked. Returns: tlsattrs%ss-Els-at delalias4t delalias6itiR sFailed to run lsattr: %sR R iN(R RRRRR( RRtattrt lsattr_cmdR t lsattr_outR t hidden_attrst current_param((sF/usr/lib/python2.7/site-packages/ansible/modules/system/aix_devices.pyt_check_device_attrs 3     #cC`s|jdt}|dk r+d|}nd}t}d}|js{|jd|d|g\}}}t}|}n||fS(s Discover AIX devices.tcfgmgrs-l %sRs%sN(R RRt check_modeR(RRt cfgmgr_cmdtchangedR R t cfgmgr_outR ((sF/usr/lib/python2.7/site-packages/ansible/modules/system/aix_devices.pytdiscover_devices   & c C`sg}g}g}|jdt}x8t|jD]$}||} t|||} | dkru|j|q7| | krJ|rd|dd|dd|||fd|g} n+d|dd|dd|||fg} |js6|j| \} } }| dkr6|j ddd | d |q6n|j||q7|j||q7Wt |dkrt}d d j |}n t }d }t |dkrdd j |}nd }t |dkrddj |}nd }d|||f}||fS(s Change AIX device attribute. tchdevs%ss-ls-as%s=%siR sFailed to run chdev.R R sAttributes changed: %s. t,RsAttributes already set: %s. sInvalid attributes: %s s, s%s%s%sN( R RtlisttkeysR#RtappendR%Rt exit_jsontlentjoinR(Rt attributesRtforcet attr_changedtattr_not_changedt attr_invalidt chdev_cmdRt new_paramR"tcmdR t chdev_outR R'tattr_changed_msgtattr_not_changed_msgtattr_invalid_msgR ((sF/usr/lib/python2.7/site-packages/ansible/modules/system/aix_devices.pytchange_device_attrs@   5+  "c C`sidd6dd6dd6}idt6dt6}||}||}t}d}|jdt} |js|r|jd| d d|d|d|g\} } } n0|jd| d d|d|g\} } } | d kr|jd d d | d| n| }n||fS(s1 Puts device in defined state or removes device. s-dtremovedtabsentRtdefineds-Rtrmdevs%ss-liR sFailed to run rmdevR R (RRR R%RR( RRR3t recursivetstatet state_optt recursive_optR'R t rmdev_cmdR t rmdev_outR ((sF/usr/lib/python2.7/site-packages/ansible/modules/system/aix_devices.pyt remove_devices(     :0  c C`stdtdtdddtdddtddd td tddd td tddd d d d ddgdt}idt6dt6}|jd}|jd}||jd}|jd }|jd }tdtdd}|d ks |dkr|rbt||\}} |rQt||||\|d<|dR)RIRR/( Rt force_optR2RR3RCRDtresultt device_statusRt check_device((sF/usr/lib/python2.7/site-packages/ansible/modules/system/aix_devices.pytmain+sX'       &  $  ) t__main__N(t __future__RRRRKt __metaclass__tANSIBLE_METADATAt DOCUMENTATIONtEXAMPLEStRETURNtansible.module_utils.basicRRR#R)R>RIR[t__name__(((sF/usr/lib/python2.7/site-packages/ansible/modules/system/aix_devices.pyts"  *J   4 # M