# Error running knife winrm

**URL:** <https://discourse.chef.io/t/error-running-knife-winrm/3935>\
**Category:** Chef Infra (archive)\
**Created:** [May 2, 2013, 2:06pm UTC](https://discourse.chef.io/t/error-running-knife-winrm/3935 "2013-05-02T14:06:29Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jeppe\_Nejsum\_Madsen](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/jeppe_nejsum_madsen/32/258_2.png) [@Jeppe\_Nejsum\_Madsen](https://discourse.chef.io/u/Jeppe_Nejsum_Madsen)\
**Post date:** [May 2, 2013, 2:06pm UTC](https://discourse.chef.io/t/error-running-knife-winrm/3935/1 "2013-05-02T14:06:29Z")

</div>

Hi,

When running

$ knife winrm -VV “name:  
[vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net](http://vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net)”  
-p 5990

I get the following error:

DEBUG: Signing the request as xxxx  
DEBUG: Sending HTTP Request via GET to  
[api.opscode.com:443/organizations/xxxx/search/node](http://api.opscode.com:443/organizations/xxxx/search/node)  
DEBUG: ---- HTTP Status and Header Data: ----  
DEBUG: HTTP 1.1 200 OK  
DEBUG: server: ngx\_openresty  
DEBUG: date: Thu, 02 May 2013 14:02:37 GMT  
DEBUG: content-type: application/json  
DEBUG: transfer-encoding: chunked  
DEBUG: connection: close  
DEBUG: x-ops-api-info: flavor=ohc;version=10.0.0;oc\_erchef=0.19.11  
DEBUG: content-encoding: gzip  
DEBUG: ---- End HTTP Status/Header Data ----  
DEBUG: decompressing gzip response  
FATAL: 1 node found, but does not have the required attribute (fqdn) to  
establish the connection. Try setting another attribute to open the  
connection using --attribute.

Yet the fqdn attribute is there:

$ knife node show  
vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net-a  
fqdn  
[vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net](http://vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net)  
:  
fqdn:  
[vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net](http://vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net)

Any hints?

/Jeppe

---

<div class="post-metadata">

**Author:** ![Solvi\_Pall\_Asgeirsso](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/solvi_pall_asgeirsso/32/360_2.png) [@Solvi\_Pall\_Asgeirsso](https://discourse.chef.io/u/Solvi_Pall_Asgeirsso)\
**Post date:** [May 5, 2013, 9:01pm UTC](https://discourse.chef.io/t/error-running-knife-winrm/3935/2 "2013-05-05T21:01:14Z")

</div>

Hi

I'm hitting the exact same issue - I'd also appreciate hints.

$ rpm -qa chef chef-server  
chef-server-11.0.8-1.el6.x86\_64  
chef-11.4.4-1.el6.x86\_64

$ knife winrm -VV "role:some\_role" 'chef-client c:/chef/client.rb'  
DEBUG: Signing the request as xxxx  
DEBUG: Sending HTTP Request via GET to chef-server:443//search/node  
DEBUG: ---- HTTP Status and Header Data: ----  
DEBUG: HTTP 1.1 200 OK  
DEBUG: server: nginx/1.2.3  
DEBUG: date: Sun, 05 May 2013 20:52:45 GMT  
DEBUG: content-type: application/json  
DEBUG: transfer-encoding: chunked  
DEBUG: connection: close  
DEBUG: x-ops-api-info: flavor=osc;version=11.0.2;erchef=1.2.6  
DEBUG: content-encoding: gzip  
DEBUG: ---- End HTTP Status/Header Data ----  
DEBUG: decompressing gzip response  
FATAL: 1 node found, but does not have the required attribute (fqdn) to  
establish the connection. Try setting another attribute to open the  
connection using --attribute.

$ knife search 'role:some\_role' -a fqdn  
1 items found

some-host.fqdn:  
fqdn: some-host.fqdn

regards,  
Sölvi Páll Á.

On Thu, May 2, 2013 at 2:06 PM, Jeppe Nejsum Madsen [jeppe@ingolfs.dk](mailto:jeppe@ingolfs.dk)wrote:

> Hi,
> 
> When running
> 
> $ knife winrm -VV "name:  
> [vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net](http://vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net)"  
> -p 5990
> 
> I get the following error:
> 
> DEBUG: Signing the request as xxxx  
> DEBUG: Sending HTTP Request via GET to  
> [api.opscode.com:443/organizations/xxxx/search/node](http://api.opscode.com:443/organizations/xxxx/search/node)  
> DEBUG: ---- HTTP Status and Header Data: ----  
> DEBUG: HTTP 1.1 200 OK  
> DEBUG: server: ngx\_openresty  
> DEBUG: date: Thu, 02 May 2013 14:02:37 GMT  
> DEBUG: content-type: application/json  
> DEBUG: transfer-encoding: chunked  
> DEBUG: connection: close  
> DEBUG: x-ops-api-info: flavor=ohc;version=10.0.0;oc\_erchef=0.19.11  
> DEBUG: content-encoding: gzip  
> DEBUG: ---- End HTTP Status/Header Data ----  
> DEBUG: decompressing gzip response  
> FATAL: 1 node found, but does not have the required attribute (fqdn) to  
> establish the connection. Try setting another attribute to open the  
> connection using --attribute.
> 
> Yet the fqdn attribute is there:
> 
> $ knife node show  
> vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net-a fqdn
> 
> [vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net](http://vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net)  
> :  
> fqdn:  
> [vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net](http://vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net)
> 
> Any hints?
> 
> /Jeppe

---

<div class="post-metadata">

**Author:** ![Steven\_Danna](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/steven_danna/32/195_2.png) [@Steven\_Danna](https://discourse.chef.io/u/Steven_Danna)\
**Post date:** [May 5, 2013, 10:31pm UTC](https://discourse.chef.io/t/error-running-knife-winrm/3935/3 "2013-05-05T22:31:36Z")

</div>

On 5/5/13 2:01 PM, Sölvi Páll Ásgeirsson wrote:

> Hi
> 
> I'm hitting the exact same issue - I'd also appreciate hints.

I think you are both likely being hit by this:

[http://tickets.opscode.com/browse/KNIFE-235](http://tickets.opscode.com/browse/KNIFE-235)

A fix can be found here:

> <https://github.com/chef/knife-windows/pull/31>

Sincerely,

Steven

> $ rpm -qa chef chef-server  
> chef-server-11.0.8-1.el6.x86\_64  
> chef-11.4.4-1.el6.x86\_64
> 
> $ knife winrm -VV "role:some\_role" 'chef-client c:/chef/client.rb'  
> DEBUG: Signing the request as xxxx  
> DEBUG: Sending HTTP Request via GET to chef-server:443//search/node  
> DEBUG: ---- HTTP Status and Header Data: ----  
> DEBUG: HTTP 1.1 200 OK  
> DEBUG: server: nginx/1.2.3  
> DEBUG: date: Sun, 05 May 2013 20:52:45 GMT  
> DEBUG: content-type: application/json  
> DEBUG: transfer-encoding: chunked  
> DEBUG: connection: close  
> DEBUG: x-ops-api-info: flavor=osc;version=11.0.2;erchef=1.2.6  
> DEBUG: content-encoding: gzip  
> DEBUG: ---- End HTTP Status/Header Data ----  
> DEBUG: decompressing gzip response  
> FATAL: 1 node found, but does not have the required attribute (fqdn) to  
> establish the connection. Try setting another attribute to open the  
> connection using --attribute.
> 
> $ knife search 'role:some\_role' -a fqdn  
> 1 items found
> 
> some-host.fqdn:  
> fqdn: some-host.fqdn
> 
> regards,  
> Sölvi Páll Á.
> 
> On Thu, May 2, 2013 at 2:06 PM, Jeppe Nejsum Madsen \<jeppe@ingolfs.dk  
> [mailto:jeppe@ingolfs.dk](mailto:jeppe@ingolfs.dk)\> wrote:
> 
> ```
> Hi,
> 
> When running
> 
> $ knife winrm -VV
> "name:vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net
> <http://vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net>"
> -p 5990
> 
> I get the following error:
> 
> DEBUG: Signing the request as xxxx
> DEBUG: Sending HTTP Request via GET to
> api.opscode.com:443/organizations/xxxx/search/node
> <http://api.opscode.com:443/organizations/xxxx/search/node>
> DEBUG: ---- HTTP Status and Header Data: ----
> DEBUG: HTTP 1.1 200 OK
> DEBUG: server: ngx_openresty
> DEBUG: date: Thu, 02 May 2013 14:02:37 GMT
> DEBUG: content-type: application/json
> DEBUG: transfer-encoding: chunked
> DEBUG: connection: close
> DEBUG: x-ops-api-info: flavor=ohc;version=10.0.0;oc_erchef=0.19.11
> DEBUG: content-encoding: gzip
> DEBUG: ---- End HTTP Status/Header Data ----
> DEBUG: decompressing gzip response
> FATAL: 1 node found, but does not have the required attribute (fqdn)
> to establish the connection. Try setting another attribute to open
> the connection using --attribute.
> 
> Yet the fqdn attribute is there:
> 
> $ knife node show
> vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net
> <http://vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net>
> -a fqdn
> vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net
> <http://vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net>:
> fqdn:
> vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net
> <http://vmtest2.09b08bebde2d44ab9f6d19c28c86f56d.econ-azu-vm1.3744114705.europewest.internal.cloudapp.net>
> 
> Any hints?
> 
> /Jeppe
> 
> ```

--  
Steven Danna  
Systems Engineer, Opscode, Inc  
GPG Key: [http://stevendanna.github.com/downloads/code/public.key](http://stevendanna.github.com/downloads/code/public.key)

---

<div class="post-metadata">

**Author:** ![Jeppe\_Nejsum\_Madsen](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/jeppe_nejsum_madsen/32/258_2.png) [@Jeppe\_Nejsum\_Madsen](https://discourse.chef.io/u/Jeppe_Nejsum_Madsen)\
**Post date:** [May 6, 2013, 11:59am UTC](https://discourse.chef.io/t/error-running-knife-winrm/3935/4 "2013-05-06T11:59:28Z")

</div>

On Mon, May 6, 2013 at 12:31 AM, Steven Danna [steve@opscode.com](mailto:steve@opscode.com) wrote:

> On 5/5/13 2:01 PM, Sölvi Páll Ásgeirsson wrote:
> 
> > Hi
> > 
> > I'm hitting the exact same issue - I'd also appreciate hints.
> 
> I think you are both likely being hit by this:
> 
> [http://tickets.opscode.com/browse/KNIFE-235](http://tickets.opscode.com/browse/KNIFE-235)
> 
> A fix can be found here:
> 
> [removed bad call to format\_for\_display by paulmooring · Pull Request #31 · chef/knife-windows · GitHub](https://github.com/opscode/knife-windows/pull/31)

Thanks. I think you're right..

Next issue I run into is that knife winrm doesn't support nested  
attributes. I've created ticket/PR

> <https://github.com/chef/knife-windows/pull/38>
>
> http://tickets.opscode.com/browse/KNIFE-276

/Jeppe

---

<div class="post-metadata">

**Author:** ![Solvi\_Pall\_Asgeirsso](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/solvi_pall_asgeirsso/32/360_2.png) [@Solvi\_Pall\_Asgeirsso](https://discourse.chef.io/u/Solvi_Pall_Asgeirsso)\
**Post date:** [May 22, 2013, 12:54pm UTC](https://discourse.chef.io/t/error-running-knife-winrm/3935/5 "2013-05-22T12:54:36Z")

</div>

Thanks, this fixed it for me.

Are there any plans to release a new version of the knife-windows gem?

Thanks!  
Sölvi Páll Á.

On Mon, May 6, 2013 at 11:59 AM, Jeppe Nejsum Madsen [jeppe@ingolfs.dk](mailto:jeppe@ingolfs.dk)wrote:

> On Mon, May 6, 2013 at 12:31 AM, Steven Danna [steve@opscode.com](mailto:steve@opscode.com) wrote:
> 
> > On 5/5/13 2:01 PM, Sölvi Páll Ásgeirsson wrote:
> > 
> > > Hi
> > > 
> > > I'm hitting the exact same issue - I'd also appreciate hints.
> > 
> > I think you are both likely being hit by this:
> > 
> > [http://tickets.opscode.com/browse/KNIFE-235](http://tickets.opscode.com/browse/KNIFE-235)
> > 
> > A fix can be found here:
> > 
> > [removed bad call to format\_for\_display by paulmooring · Pull Request #31 · chef/knife-windows · GitHub](https://github.com/opscode/knife-windows/pull/31)
> 
> Thanks. I think you're right..
> 
> Next issue I run into is that knife winrm doesn't support nested  
> attributes. I've created ticket/PR
> 
> [[KNIFE-276] Add support for nested attributes by jeppenejsum · Pull Request #38 · chef/knife-windows · GitHub](https://github.com/opscode/knife-windows/pull/38)
> 
> /Jeppe
