[CentOS] Limit RAM used by a perl script

Mon Jul 20 20:43:19 UTC 2009
Sean Carolan <scarolan at gmail.com>

> First, install the perl module BSD::Resource
>
>   yum install perl-BSD-Resource
>
> Then use it in your program like:
>
>   #!/usr/bin/perl
>
>   use BSD::Resource;
>   setrlimit(RLIMIT_VMEM, 1_000_000, 1_000_000);
>
>   # rest of the program that is limited to 1MByte now

Thanks, Paul.  I knew I'd find an answer if I posted my question here.