Splunk Search

What happened to the entropy command?

thisissplunk
Builder

Maybe I'm missing something here, but at some point in my career the "entropy" command did something. Now when I try to use it I get this error:

index=files sourcetype=executables | entropy filename
Unknown search command 'entropy'.

I'm clueless. Is/was the entropy command a thing?

Tags (2)
0 Karma
1 Solution

somesoni2
Revered Legend

I don't remember entropy as a natively available search command. There was a custom search command in one of the post (https://answers.splunk.com/answers/13636/calculate-entropy-just-entropy-not-change-in-entropy-like-a...) that you might have used. Look at associate command as well (http://docs.splunk.com/Documentation/Splunk/latest/SearchReference/Associate)

View solution in original post

0 Karma

Goku1
Engager

Use the following code::
| stats count as sumfield by "field_name" | eventstats sum(sumfield) as Total | eval Entropy= -1*(sumfield/Total)log(sumfield/Total)
| stats sum(Entropy) as entropy_value by "*field_name
"

0 Karma

rshoward
Path Finder

That was the command I had set up and posted the tutorial for. https://answers.splunk.com/answers/13636/calculate-entropy-just-entropy-not-change-in-entropy-like-a... Many people (including myself) started to use it in their environments so it might have become quite popular. I have even noticed it in place at sites I visit. I'll make an official App for it now that i see it is used more often. There's also more recently url toolbox which now has a ut_entropy command. But to keep this alive, I'll still make the entropy suite ready for posting on splunk apps.

somesoni2
Revered Legend

I don't remember entropy as a natively available search command. There was a custom search command in one of the post (https://answers.splunk.com/answers/13636/calculate-entropy-just-entropy-not-change-in-entropy-like-a...) that you might have used. Look at associate command as well (http://docs.splunk.com/Documentation/Splunk/latest/SearchReference/Associate)

0 Karma

thisissplunk
Builder

I have a feeling we had a custom command made from something like the above. Thanks!

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

May 2026 Splunk Expert Sessions: Security & Observability

Level Up Your Operations: May 2026 Splunk Expert Sessions Whether you are refining your security posture or ...

Network to App: Observability Unlocked [May & June Series]

In today’s digital landscape, your environment is no longer confined to the data center. It spans complex ...

SPL2 Deep Dives, AppDynamics Integrations, SAML Made Simple and Much More on Splunk ...

Splunk Lantern is Splunk’s customer success center that provides practical guidance from Splunk experts on key ...