System Administration

Out of Memory Error with Apache Solr with DocStar on Windows

Monday users reported DocStar was not processing new documents and was running slower and slower.

Logged into the DocStar server via RDP as a Domain Administrator, then opened http://localhost:8984. Dashboard provided the first clue:

I took a look under the logging tab and was punched in the face.

After expanding the log entry I find the following

So I guess we’re out of memory.

Pretty sure this value is set from a startup script somewhere in this bastardized Solr install. Why developers build shit on IIS/ASP/Microsoft is beyond me. It’s just unmaintainable in the long term is and is just one fucking hack on top of another. I digress. One shitty hack deserves another.

We go ahead and open up the path that the DocStar stack was installed to. In my case, this was C:\Program Files\Astria Solutions Group\Eclipse Server Services\Solr\bin and find the solr.in file.

Once we have the file open (most likely in Notepad, which fucking sucks. Get a real text editor, loser), we head down near the bottom of the file and fine the following line (I’ve highlighted it for those of you that can’t read)

If your line is commented out (REM, short for Remark, will make the interpreter ignore the line) and adjust for the value of memory you’d like to throw at the problem. Save the file. Close Notepad (thank god) and either restart the Solr service(s), but then you’d have to deal with the Windows Administration Tools, and I’m not sure you’re into self-harm, so just reboot the fucking machine. If you’re a Windows user, you’re used to this by now.

When the machine comes back up, I log in and check the Solr dashboard at http://localhost:8984 for an updated heap size

Fucking sweet. Memory usage is less than 99% so we’re good. Users reported everything was functioning again.

Conclusion

There. I saved you $3,500 because you didn’t have to purchase support for your out of date product. It’s a hack. Clearly it will break if you upgrade to a new version as the solr.in file will be overwritten, but you’re not going to upgrade, because if you did, you’d have support and wouldn’t be reading this, hoping for a fix.

To top