Advertisement
Guest User

Untitled

a guest
Apr 26th, 2015
195
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.73 KB | None | 0 0
  1. > ObjectSpace.dump_all(output: File.open("heap.json", "w"))
  2. > `file heap.json`
  3. => "heap.json: ASCII text, with very long lines\n"
  4. > `ls -al heap.json`
  5. => "-rw------- 1 u47788 47788 985808896 Mar 10 05:29 heap.json\n"
  6. > `du -sh heap.json`
  7. => "941M\theap.json\n"
  8. > `cat heap.json | ruby -rjson -ne ' obj = JSON.parse($_).values_at("file","line","type"); puts obj.join(":") if obj.first '> /dev/null`
  9. /app/vendor/bundle/ruby/2.2.0/gems/json-1.8.2/lib/json/common.rb:155:in `parse': 757: unexpected token at '{"address":"0x7f9dd68e3f20", "type":"STRING", "class":"0x7f9dc82b0ee0", "embedded":true, "bytesiz' (JSON::ParserError)
  10. from /app/vendor/bundle/ruby/2.2.0/gems/json-1.8.2/lib/json/common.rb:155:in `parse'
  11. from -e:1:in `<main>'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement