So all you need is simply 1 random post, 1 random post->ID or 1 post link, you dont need to go through all the hoops. (Update: added $wpdb function to tests) Jump to conclusion ...
Actually, you do not want to open memcached port in your firewall. #ref: http://serverfault.com/questions/530051/memcached-ports-and-csf...
Ways to load an array from file into a variable: 1- $var = require 'myarray.php'; // or include // myarray.php contents return array("test","test2"); 2 – require 'myarray.php...