Search inconsistent


#1

Hi,

can someone please explain to me what’s going wrong here?

—8<------8<------8<------8<------8<------8<------8<------8<—

$ knife search node ‘name:vm23*’ -a hostname
1 items found

hostname: vm23
id: vm23.example.com

—8<------8<------8<------8<------8<------8<------8<------8<—

$ knife search node ‘hostname:vm23’ -a ipaddress
0 items found

—8<------8<------8<------8<------8<------8<------8<------8<—

I’ve just done a “knife index rebuild”, but no change in behaviour.

Best regards,
Jochen


#2

If you do knife node show, does the VM have node.ipaddress set?

Jochen Lillich mailto:jochen@freistil.it
March 28, 2013 6:44 AM
Hi,

can someone please explain to me what’s going wrong here?

—8<------8<------8<------8<------8<------8<------8<------8<—

$ knife search node ‘name:vm23*’ -a hostname
1 items found

hostname: vm23
id: vm23.example.com

—8<------8<------8<------8<------8<------8<------8<------8<—

$ knife search node ‘hostname:vm23’ -a ipaddress
0 items found

—8<------8<------8<------8<------8<------8<------8<------8<—

I’ve just done a “knife index rebuild”, but no change in behaviour.

Best regards,
Jochen


#3

Hi Sascha!

If you do knife node show, does the VM have node.ipaddress set?

It does. The problem is more general:

$ knife search node 'hostname:vm23'
0 items found

#4

If you are running your own chef server, this can be an issue with at
least 10.x versions of chef and is chronicled in this ticket:
http://tickets.opscode.com/browse/CHEF-2346

Check to see if the Solr maxFieldLength is still set to default. I have
seen this affect search even with an environment that I did not consider
having an outrageously large number of nodes.

Jochen Lillich mailto:jochen@freistil.it
March 28, 2013 9:14 AM
Hi Sascha!

It does. The problem is more general:

$ knife search node 'hostname:vm23’
0 items found

Sascha Bates mailto:sascha.bates@gmail.com
March 28, 2013 9:01 AM
If you do knife node show, does the VM have node.ipaddress set?
Jochen Lillich mailto:jochen@freistil.it
March 28, 2013 6:44 AM
Hi,

can someone please explain to me what’s going wrong here?

—8<------8<------8<------8<------8<------8<------8<------8<—

$ knife search node ‘name:vm23*’ -a hostname
1 items found

hostname: vm23
id: vm23.example.com

—8<------8<------8<------8<------8<------8<------8<------8<—

$ knife search node ‘hostname:vm23’ -a ipaddress
0 items found

—8<------8<------8<------8<------8<------8<------8<------8<—

I’ve just done a “knife index rebuild”, but no change in behaviour.

Best regards,
Jochen


#5

Sascha Bates wrote:

If you are running your own chef server, this can be an issue with at
least 10.x versions of chef and is chronicled in this ticket:
http://tickets.opscode.com/browse/CHEF-2346

Check to see if the Solr maxFieldLength is still set to default.

Yup, this fixed it. Thanks a lot, Sascha!

Drat, I’ve been aware of this issue but somehow was missing a zero and thought that 10k already was the intended field length. Thanks for including the link to the issue which made me reread the fix and realize that it’s got to be 100k.

Happy easter!
Jochen