# run ansible on arbor appliance

**URL:** <https://forum.ansible.com/t/run-ansible-on-arbor-appliance/13997>\
**Category:** Ansible Project\
**Created:** [November 25, 2013, 7:25pm UTC](https://forum.ansible.com/t/run-ansible-on-arbor-appliance/13997 "2013-11-25T19:25:29Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![vadud3](https://avatars.discourse-cdn.com/v4/letter/v/ecc23a/32.png) [@vadud3](https://forum.ansible.com/u/vadud3)\
**Post date:** [November 25, 2013, 7:25pm UTC](https://forum.ansible.com/t/run-ansible-on-arbor-appliance/13997/1 "2013-11-25T19:25:29Z")

</div>

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

> 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

> 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  
> exit  
> exit

$

OR like this

$ ssh -qtt atl-col-01 shell \<\<EOF

> uname -a  
> exit  
> EOF  
> uname -a  
> exit  
> 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  
> exit  
> exit

I was trying to do the same with playbook

$ cat file.yml

---

<div class="post-metadata">

**Author:** ![Michael\_DeHaan2](https://avatars.discourse-cdn.com/v4/letter/m/da6949/32.png) [@Michael\_DeHaan2](https://forum.ansible.com/u/Michael_DeHaan2)\
**Post date:** [November 26, 2013, 1:10am UTC](https://forum.ansible.com/t/run-ansible-on-arbor-appliance/13997/2 "2013-11-26T01:10:26Z")

</div>

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  
see if there’s a API and do something closer to what’s done with the Arista and F5 modules

etc?

---

<div class="post-metadata">

**Author:** ![vadud3](https://avatars.discourse-cdn.com/v4/letter/v/ecc23a/32.png) [@vadud3](https://forum.ansible.com/u/vadud3)\
**Post date:** [November 26, 2013, 1:28pm UTC](https://forum.ansible.com/t/run-ansible-on-arbor-appliance/13997/3 "2013-11-26T13:28:20Z")

</div>

Once you ssh to arbor, you will need to type shell to get a bash shell. From there it is pure linux.

---

<div class="post-metadata">

**Author:** ![Michael\_DeHaan2](https://avatars.discourse-cdn.com/v4/letter/m/da6949/32.png) [@Michael\_DeHaan2](https://forum.ansible.com/u/Michael_DeHaan2)\
**Post date:** [November 26, 2013, 1:58pm UTC](https://forum.ansible.com/t/run-ansible-on-arbor-appliance/13997/4 "2013-11-26T13:58:01Z")

</div>

Yeah that’s not really going to work well in current state, because the system won’t know to run the “shell” command.

There’s no way to configure a regular shell account?

---

<div class="post-metadata">

**Author:** ![vadud3](https://avatars.discourse-cdn.com/v4/letter/v/ecc23a/32.png) [@vadud3](https://forum.ansible.com/u/vadud3)\
**Post date:** [November 26, 2013, 4:55pm UTC](https://forum.ansible.com/t/run-ansible-on-arbor-appliance/13997/5 "2013-11-26T16:55:28Z")

</div>

> Yeah that’s not really going to work well in current state, because the system won’t know to run the “shell” command.
> 
> There’s no way to configure a regular shell account?

There is a way to provide regular shell account, but appliance upgrade overwrites it. Plus Arbor guys discouraging it too ☹

If we can only redefine ssh as “ssh -ttt remotehost shell” we would be golden. Here is how we run things manually.

~$ ssh atl-col-01  
Last login: Tue Nov 26 16:45:52 2013 from 192.168.0.248

ArbOS v5.2  
Copyright (c) 2000-2013 Arbor Networks, Inc. All Rights Reserved.

Welcome to ArbOS

admin@atl-col-01:/# shell

> 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  
> exit

exit  
admin@atl-col-01:/# exit  
Connection to atl-col-01 closed.  
~$

Here is how we run it interactively using a script which I like to replace with ansible

~$ echo “uname -a; exit” | ssh -qtt atl-col-01 shell  
uname -a; exit

> 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  
> ~$

---

<div class="post-metadata">

**Author:** ![vadud3](https://avatars.discourse-cdn.com/v4/letter/v/ecc23a/32.png) [@vadud3](https://forum.ansible.com/u/vadud3)\
**Post date:** [November 26, 2013, 6:09pm UTC](https://forum.ansible.com/t/run-ansible-on-arbor-appliance/13997/6 "2013-11-26T18:09:52Z")

</div>

> 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

> 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

---

<div class="post-metadata">

**Author:** ![Matt\_Hite](https://avatars.discourse-cdn.com/v4/letter/m/5fc32e/32.png) [@Matt\_Hite](https://forum.ansible.com/u/Matt_Hite)\
**Post date:** [December 14, 2013, 12:17am UTC](https://forum.ansible.com/t/run-ansible-on-arbor-appliance/13997/7 "2013-12-14T00:17:53Z")

</div>

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?

---

<div class="post-metadata">

**Author:** ![vadud3](https://avatars.discourse-cdn.com/v4/letter/v/ecc23a/32.png) [@vadud3](https://forum.ansible.com/u/vadud3)\
**Post date:** [March 14, 2016, 2:04pm UTC](https://forum.ansible.com/t/run-ansible-on-arbor-appliance/13997/8 "2016-03-14T14:04:56Z")

</div>

> 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?

Essentially run remote command to find resource status
