Lewis' Blog Tales from the trenches of information technology

25Jun/132

WordPress, WooCommerce, and the elusive WP_MEMORY_LIMIT issue

WooCommerce (and likely some other WordPress plugins - and non-WordPress apps - tend to be rather microcosmic when determining system settings. Case in point: the PHP memory limit.

Prior to PHP 5.2.1, the per-script memory limit available was set at compile time (via the --enable-memory-limit option). With 5.2.1, we got the php.ini directive:

memory_limit <integer>

to set this value at run time 1. In fact, it can even be overridden (if the server admin allows) so that specific apps may set it themselves, thus allowing for greater granularity across all running PHP applications on the server, even under the same instance of the engine.

  1. http://www.php.net/manual/en/ini.core.php#ini.memory-limit
26May/130

Updating the TCPDF library in Joomla! 1.5

TCPDF is an excellent PHP class for creating PDFs from dynamic (or static, for that matter) web content. Unfortunately, the version of TCPDF bundled with Joomla! 1.5 (all 1.5 releases after at least 1.5.8 - someone please correct me if I am wrong - was version 2.6.000_PHP4, dated March 7, 2008. It's also not very PHP 5.3-friendly (there are other parts of Joomla! 1.5 which are not fully compatible with PHP 5.3, but this article will focus on TCPDF). Time to freshen up, methinks.

22May/120

Warpstock 2012, Portland Oregon, USA

Embassy Suites Portland Airport

Well, after another round of considerations and deliberations, the Warpstock Board of Directors finally decided upon the Embassy Suites, Portland Airport for the site of this year's OS/2 & eComStation conference, August 17-19.

Full details are available on the Warpstock site, but meanwhile, here are a couple of highlights:

15Apr/122

On the ungrateful nature of users and the OSS development community

Nothing new, here, I'm afraid. It's a problem as old as the concept of "free stuff."

So what exactly is free stuff, anyway, and why do people seem to equate freely available to freedom from cost?

Recently, a contemporary of mine posited the idea that as the majority of Linux apps ported to eCS were built using GCC, they were somehow unstable, inferior, untested, or otherwise unworthy of use, and further, that developers porting these apps either did not care to - or simply did not - test them before releasing them on an unsuspecting public. This summoned the ire of one of the OS/2 community's most prolific - and talented, and approachable - porters, who reiterated what so many of us have said to and about this individual for some time: "There's the door."

22Apr/111

The Telltale Hard Drive

And so it came to pass that my 160GB 5400 RPM Travelstar in my ThinkPad T43 became full. In late 2010, finding large 2.5" PATA drives was becoming more and more difficult. Searching, I found that Western Digital had just what I needed: a 320GB 5400 RPM Scorpio Blue.

I ordered the drive from a trusted supplier, never looking to find complaints about newer Scorpio or "Green" models (not that I would have necessarily viewed a Scorpio as a "green" drive, anyway). The price was acceptable, and the shipment was quickly delivered.

Using my favorite cloning utility, DFSee, I cloned much of my trusty Travelstar to the new Scorpio Blue. Some partitions needed changing, though: my handy HPFS eCS maintenance partition, for example, really needed to be migrated to a JFS volume, and my type 35 JFS data volume, consisting of two segments, really cried out to be recreated as a single type 7 JFS partition. As such, these took a little more manual work (read: xcopy /s/e/r/h/t).

Ah, the fun...

14Mar/100

NLM Memory Tuning

Physician, heal thyself...

One of my NetWare servers has been suffering of late with some runaway memory consumption (I'll leave it for another post to discuss the difference between excessive memory consumption and memory leakage, but suffice it to say, that these are non synonymous conditions). Logging in tonight to check the progress on some backups, I was greeted with:

SERVER-5.70-0 [nmID=2000A]
Short term memory allocator is out of memory.
10 attempts to get more memory failed.
request size in bytes 65536 from Module MYSQLD.NLM

I've not seen MYSQLD run short of memory before, so I took a closer look (backups were still active). I loaded SEG.NLMto see what was going on. The first thing that hit me was that NWMKDE.NLM was consuming over 700MB of RAM, or approximately 21% of the total installed memory in the machine.

Hmmm... What could be the matter, here? Other than Backup Exec, I have no Btrieve apps running on the server. All of the non-system databases run on MySQL on that box. TID # 7003770 references TID # 3216963 (formerly TID # 10058100), which makes reference to deleting the BTI.LCK file created in SYS:SYSTEM. I looked, and sure enough, BTI.LCK was a 0 length file. I deleted it, unloaded BSPXCOM.NLM, BTCPCOM.NLM, and NWMKDE.NLM, and reloaded all of them (I checked my BTI.CFG, and NWMKDE was configured to use 1MB of RAM for cache). Sure enough, memory consumption returned to normal.

Who knows?