Hi, Asif. I have considered writing an Arbor module (using their API). The
initial "itch" I wanted to "scratch' was to manage network/customer object
entities.

What is it that you hope to accomplish?


On Tue, Nov 26, 2013 at 10:09 AM, Asif Iqbal <[email protected]> wrote:

>
>
> On Monday, November 25, 2013 8:10:26 PM UTC-5, Michael DeHaan wrote:
>>
>> I'm not familiar with Arbor Networks internals personally
>>
>> Possible options:
>>
>> try scp instead of SFTP in ansible.cfg
>> see if you can configure something to give you a login shell
>> just use "raw" commands
>>
>
>
> With raw I am getting the same output
>
> $ ansible atl-col-01 -u admin -m raw -a "shell; uname -a" -i hosts
> atl-col-01 | success | rc=0 >>
> 120: Invalid command
>
> It is trying to run ``bash'' or like instead of ``shell''. How do I know
> that? Because I can generate similar output manually
>
> admin@atl-col-01:/# sh
> 110: Ambiguous command
> admin@atl-col-01:/# bash
> 120: Invalid command
> admin@atl-col-01:/# shell
> DIAG> uname -a
> Linux atl-col-01 2.6.18-arbux26 #1 SMP PREEMPT Thu Aug 2 16:16:46 EDT 2012
> i686 i686 i386 GNU/Linux
>
>
>
>
>> see if there's a API and do something closer to what's done with the
>> Arista and F5 modules
>>
>> etc?
>>
>>
>>
>>
>>
>>
>> On Mon, Nov 25, 2013 at 2:25 PM, Asif Iqbal <[email protected]> wrote:
>>
>>> Hi All
>>>
>>> I am trying to run ansible on arbor appliances.
>>>
>>> To run ssh remotely and get data from arbor appliance you will need to
>>> run it like this
>>>
>>> $ echo "uname -a; exit" | ssh -qtt atl-col-01 shell
>>> uname -a; exit
>>> DIAG> uname -a; exit
>>> Linux atl-col-01 2.6.18-arbux26 #1 SMP PREEMPT Thu Aug 2 16:16:46 EDT
>>> 2012 i686 i686 i386 GNU/Linux
>>> exit
>>> $
>>>
>>> OR like this
>>>
>>> $ ssh -qtt atl-col-01 shell
>>> DIAG> uname -a
>>> Linux atl-col-01 2.6.18-arbux26 #1 SMP PREEMPT Thu Aug 2 16:16:46 EDT
>>> 2012 i686 i686 i386 GNU/Linux
>>> DIAG> exit
>>> exit
>>> $
>>>
>>>
>>> OR like this
>>>
>>> $ ssh -qtt atl-col-01 shell <<EOF
>>> > uname -a
>>> > exit
>>> > EOF
>>> uname -a
>>> exit
>>> DIAG> uname -a
>>> Linux atl-col-01 2.6.18-arbux26 #1 SMP PREEMPT Thu Aug 2 16:16:46 EDT
>>> 2012 i686 i686 i386 GNU/Linux
>>> DIAG> exit
>>> exit
>>>
>>> I was trying to do the same with playbook
>>>
>>> $ cat file.yml
>>> ---
>>> - hosts: atl-col-01
>>>   user: admin
>>>   tasks:
>>>   - name: ping it
>>>     local_action: shell 'ping {{ inventory_hostname }}'
>>>     register: result
>>>
>>>
>>> $ cat hosts
>>> ...
>>> atl-col-01 ansible_python_interpreter=/usr/local/bin/python
>>> ...
>>>
>>> $ cat ~/.ansible.cfg
>>> [defaults]
>>> remote_tmp = /tmp
>>>
>>> $ ansible-playbook file.yml -i hosts -vvvv
>>>
>>> PLAY [atl-col-01] ******************************
>>> *******************************
>>>
>>> GATHERING FACTS ******************************
>>> *********************************
>>> <atl-col-01> ESTABLISH CONNECTION FOR USER: admin
>>> <atl-col-01> EXEC ['ssh', '-tt', '-vvv', '-o', 'ControlMaster=auto',
>>> '-o', 'ControlPersist=60s', '-o', 'ControlPath=/home/iqbala/.
>>> ansible/cp/ansible-ssh-%h-%p-%r', '-o', 'Port=22', '-o',
>>> 'KbdInteractiveAuthentication=no', '-o', 'PreferredAuthentications=
>>> gssapi-with-mic,gssapi-keyex,hostbased,publickey', '-o',
>>> 'PasswordAuthentication=no', '-o', 'User=admin', '-o', 'ConnectTimeout=10',
>>> 'atl-col-01', "/bin/sh -c 'mkdir -p 
>>> /tmp/ansible-1385407330.54-15863228552079
>>> && chmod a+rx /tmp/ansible-1385407330.54-15863228552079 && echo
>>> /tmp/ansible-1385407330.54-15863228552079'"]
>>> <atl-col-01> REMOTE_MODULE setup
>>> <atl-col-01> PUT /tmp/tmpQ1MvZ1 TO 120: Invalid command/setup
>>> fatal: [atl-col-01] => failed to transfer file to 120: Invalid
>>> command/setup:
>>>
>>> 120: Invalid command
>>>
>>>
>>> TASK: [ping it] ******************************
>>> *********************************
>>> FATAL: no hosts matched or all hosts have already failed -- aborting
>>>
>>>
>>> PLAY RECAP ************************************************************
>>> ********
>>>            to retry, use: --limit @/home/iqbala/file.retry
>>>
>>> atl-col-01                 : ok=0    changed=0    unreachable=1
>>>  failed=0
>>>
>>>
>>> Any suggestion how to make it work?
>>>
>>> Thanks
>>>
>>>  --
>>> 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 [email protected].
>>>
>>> For more options, visit https://groups.google.com/groups/opt_out.
>>>
>>
>>
>>
>> --
>> Michael DeHaan <[email protected]>
>>
>> CTO, AnsibleWorks, Inc.
>> http://www.ansibleworks.com/<http://www.google.com/url?q=http%3A%2F%2Fwww.ansibleworks.com%2F&sa=D&sntz=1&usg=AFQjCNEn7XMcb-1wMxliSyOhlnyBBlDaQg>
>>
>>   --
> 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 [email protected].
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
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 [email protected].
To post to this group, send email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to