2012-05-09 【Ruby】Unixの起動日数を取得する days = open('|cat /proc/uptime').gets.split(' ')[0].to_i /(60*60*24) こんなかんじー。