Out of memory issues

If you run tt-rss on an officially unsupported platform (shared hosting, Windows, etc.) post here
Wibbly
Bear Rating Trainee
Bear Rating Trainee
Posts: 30
Joined: 03 May 2013, 12:35

Out of memory issues

Postby Wibbly » 14 Sep 2013, 12:13

I know TTRSS isn't supported on shared hosting, but anyone else seen these kind of out of memory errors? They seem to occur then loading the TTRSS UI and it sporadically gets stuck at 80% loaded... (v1.9)
Attachments
Capture.JPG
Capture.JPG (124.13 KiB) Viewed 6086 times

Wibbly
Bear Rating Trainee
Bear Rating Trainee
Posts: 30
Joined: 03 May 2013, 12:35

Re: Out of memory issues

Postby Wibbly » 15 Sep 2013, 12:31

Nobody seen this kind of thing?

xtaz
Bear Rating Master
Bear Rating Master
Posts: 174
Joined: 24 Dec 2009, 16:48

Re: Out of memory issues

Postby xtaz » 15 Sep 2013, 13:36

It's run out of memory. Buy more.

vilain
Bear Rating Trainee
Bear Rating Trainee
Posts: 40
Joined: 29 Jun 2013, 08:57

Re: Out of memory issues

Postby vilain » 15 Sep 2013, 19:37

I'm going to venture a SWAG (scientific wild-assed guess) here.

php runs either as a part of the Apache server in mod_php or as a separate process when called through CGI. Most shared hosting platforms do mod_php. This puts resource management in the hands of the Apache server which is shared among all the users accessing web pages on the shared server.

Either there are multiple instances of Apache running (this may be an old model, but I've seen it), each capable of handling a certain number of requests or there's a multi-threaded version running. I'm guessing that when Apache runs ttrs on your shared server, a plug-in or something else is malloc()-ing memory in a thread. I'm not all that familiar with threading, but I think all a process' threads share the same process address space. If there are a lot of threads (e.g. 1 for each web request, maybe), the process has to grow it's working set or memory allocation. If the Apache process has been configured to limit how big it can grow or it's max-ed out, I can envision malloc() failing.

Absolutely nothing you can do for this as a user, really, if that's what's going on. Try banging on the wall or ceiling or floor to tell your neighbors to shut up. That's about as much good as it will for ttrss in your environment.

Either find a less loaded ISP or move to a VPS. That's probably why fox doesn't recommend shared services -- you can't really do much if there's a resource bottleneck.

User avatar
sleeper_service
Bear Rating Overlord
Bear Rating Overlord
Posts: 884
Joined: 30 Mar 2013, 23:50
Location: Dallas, Texas

Re: Out of memory issues

Postby sleeper_service » 15 Sep 2013, 23:12

xtaz wrote:It's run out of memory. Buy more.

some questions have such obvious solutions, answers aren't really warranted, are they :lol:

JustAMacUser
Bear Rating Overlord
Bear Rating Overlord
Posts: 373
Joined: 20 Aug 2013, 23:13

Re: Out of memory issues

Postby JustAMacUser » 16 Sep 2013, 00:54

You're running out of memory at the 28-32 MB point. You don't have enough memory, add more. If you have more, set it higher in your php.ini file if your provider makes that available. If not, you may need to look for another host.

Edit: I mention the 32 MB memory limit because in today's age with an application like TT-RSS, that's a low limit

lyallp
Bear Rating Trainee
Bear Rating Trainee
Posts: 31
Joined: 20 Mar 2013, 09:20

Re: Out of memory issues

Postby lyallp » 16 Sep 2013, 02:35

Even my testing tt-rss running on my local Gentoo chews 800MB with only 20 RSS feeds.
Yours appears to be conking out at around 2000-3000MB - one should ask what plugins, how many feeds, what db backend, what are the settings in the php.ini?

Sidicas
Bear Rating Trainee
Bear Rating Trainee
Posts: 12
Joined: 15 May 2013, 14:24

Re: Out of memory issues

Postby Sidicas » 16 Sep 2013, 05:31

JustAMacUser wrote:You're running out of memory at the 28-32 MB point. You don't have enough memory, add more. If you have more, set it higher in your php.ini file if your provider makes that available. If not, you may need to look for another host.

Edit: I mention the 32 MB memory limit because in today's age with an application like TT-RSS, that's a low limit


You missed a division there. It's actually failing because tt-rss is being denied an allocation of 2.8-3.2 Megabytes of RAM. That's a tiny tiny amount of RAM by today's standards and the OP's hosting provider is blocking him from having it. Most likely because they want him to serve HTML content only and not be running daemons or other things on their servers.

I've seen this become more common as shared hosting providers crack down on people running "webapps" on what is supposed to be very basic hosting. Lesson learned, either buy better hosting or find a tt-rss server that does hosting for you.

lyallp wrote:Even my testing tt-rss running on my local Gentoo chews 800MB with only 20 RSS feeds.
Yours appears to be conking out at around 2000-3000MB - one should ask what plugins, how many feeds, what db backend, what are the settings in the php.ini?

You're also off by a factor of 1000. The listed memory allocation is in *BYTES*.. 2,883,584 is 2.8 million bytes or 2.8MB.

So from the log... To run a tt-rss instance you apparently need to have at *LEAST* 4 Megabytes of RAM available, and the original poster does not.

There is no way your tt-rss instance is using 800MBytes of RAM. I'd bet you anything that this apparent "usage" is just disk cache so it doesn't really count. It's the operating system trying to use RAM to reduce disk I/O because letting the RAM sitting around doing nothing is inefficient. Your 800MB of disk cache in RAM really has nothing to do wiht the requirements of tt-rss. It's being allocated and used by your OS to reduce the time it spends using the hard disk.

vilain
Bear Rating Trainee
Bear Rating Trainee
Posts: 40
Joined: 29 Jun 2013, 08:57

Re: Out of memory issues

Postby vilain » 16 Sep 2013, 06:41

I know that Crapcast, AT&T, and Earthlink offer "web space" but that's really what Sidicas is talking about. If you go out and buy web hosting space on a real web hosting platform, you'll get a LOT more for your money.

My own WebISP offers Drupal, Joomla, and both MySQL and PostgreSQL in a shared environment. While I could get all this with a basic VPS server for $12/mo, but my site + TTRSS runs just fine on their shared hosting environment for $5/mo. While I can manage my own Linux environment, many can't (and they all seem to post under this topic).

Ultimately, I think a pinned article with the bare requirements for a shared environment would be helpful. It's fine if fox can't be bothered, but others want to use this package who don't have the technical skills to pull from a git repository, let alone configure a LAMP environment.

But back to the OP's problem. I'd ask the sysadmins for your ISP to mail you a copy of the php.ini. If they refuse, it's time to move somewhere else. If they won't change the configuration for you or allow you to run your own php.ini for your site, it's time to move.

Wibbly
Bear Rating Trainee
Bear Rating Trainee
Posts: 30
Joined: 03 May 2013, 12:35

Re: Out of memory issues

Postby Wibbly » 16 Sep 2013, 17:42

Thanks all. So it's back to my ISP...

Wibbly
Bear Rating Trainee
Bear Rating Trainee
Posts: 30
Joined: 03 May 2013, 12:35

Re: Out of memory issues

Postby Wibbly » 16 Sep 2013, 18:14

Looks like there's plenty of free memory (told 128MB available), but database (I/O) is being hammered, looking at the capture below?

Point is, if nobody else is seeing this it must be something to do with my specific host or install, and no a bug in the script...
Attachments
Capture.PNG
Capture.PNG (11.29 KiB) Viewed 5839 times

xtaz
Bear Rating Master
Bear Rating Master
Posts: 174
Joined: 24 Dec 2009, 16:48

Re: Out of memory issues

Postby xtaz » 16 Sep 2013, 18:52

If it's not run out of physical memory it's probably a php.ini setting where the amount of memory available to PHP is limited. Check the memory_limit parameter and increase it.

JustAMacUser
Bear Rating Overlord
Bear Rating Overlord
Posts: 373
Joined: 20 Aug 2013, 23:13

Re: Out of memory issues

Postby JustAMacUser » 17 Sep 2013, 04:42

Sidicas wrote:You missed a division there. It's actually failing because tt-rss is being denied an allocation of 2.8-3.2 Megabytes of RAM.


Thanks, you're right. That's what I get for reading on my phone in a car (not the driver, FYI). Yeah, 2-3 MB is crazy low.

To the OP, disk I/O limits really shouldn't be causing memory errors. If anything it would make things really slow and just cause timeouts. Here's what I suggest: double-check that the memory allocated to php is set reasonably. On my small system, with 3 users, 15-20 feeds and virtually no plugins running, I have it at 40 MB and it works just fine. Remember, that's 40 MB per PHP instance--if you have 128 MB physical RAM don't set your PHP limit to 128 MB, that would be bad. If your database is actually the cause of the heavy disk activity, try increase the cache settings for it.

Wibbly
Bear Rating Trainee
Bear Rating Trainee
Posts: 30
Joined: 03 May 2013, 12:35

Re: Out of memory issues

Postby Wibbly » 17 Sep 2013, 13:40

The I/O load seems to have been sporadic. Haven't noticed it since.

memory_limit is 256M

I have 42 feeds. One user. Only use videofames as an extra plugin (now switched off to see if that helps somehow)

I wonder what's going on? I wonder if the intermittent nature of the memory error problem can be related to overall server load? But I have to say it seems to occur randomly, not only at busy times of the day...

If I moved to a different (shared) host, what would/should I be looking for, given I don't know what's wrong here?
Last edited by Wibbly on 18 Sep 2013, 11:22, edited 1 time in total.

JustAMacUser
Bear Rating Overlord
Bear Rating Overlord
Posts: 373
Joined: 20 Aug 2013, 23:13

Re: Out of memory issues

Postby JustAMacUser » 18 Sep 2013, 04:22

If you're on shared hosting, setting the memory limit to 256 MB may not have any effect because the host may override it. Create a file with phpinfo() in it and see what that reports. Remember to delete the file when you're done.


Return to “Unsupported platforms”

Who is online

Users browsing this forum: No registered users and 2 guests