[mythtv-users] PVR-350 /dev/video0 cannot allocate memory

Jan Johansson jan.johansson at se.nyklogistics.com
Fri Dec 3 13:40:58 UTC 2004

> Problem is that when I watch TV, nothing.  Initially, the frontend
> cause a segfault.  Now it just hangs around.  If I alt-tab back to my
> terminal screen I can ctrl+C, ctrl+D, or ctrl+Z to get out of it.
When I
> look in the mythbackend logs, I see the /dev/video0: cannot allocate
> memory.
> This is with a sysctl -w vm.min_free_kbytes at either 4096 or 16384 in
> rc.local.  I was able to watch TV manually at one point (I'll have to
> double-check this tomorrow).

Make sure that mythbackend doest fire off _before_ rc.local. (Which it
does if you follow Jarods guide, or use any rc-skript to start ivtv and

Remember: rc.local executes _last_ of _all_ initscripts.

After a LOT of trial and error, I use this rc.local

/sbin/sysctl -w vm.min_free_kbytes=16384
/sbin/modprobe videodev
/sbin/modprobe ivtv
/usr/bin/ivtvctl -d /dev/video0 -u 0x3000
/usr/bin/ivtvctl -d /dev/video0 -u 0xff
/usr/bin/ivtvctl -p 0
/usr/bin/ivtvctl -f width=720,height=576
/sbin/service lircd start
/usr/bin/mythbackend --logfile /var/log/mythtv/mythbackend -d

Prolly not the smartest way.. but it _works_ for me ;)  (And yes, there
is a reason for the 0x3000 -> 0xff setting. Check list archives for


More information about the mythtv-users mailing list