Skip to content

Instantly share code, notes, and snippets.

@dodizzle
dodizzle / gist:5864194
Created June 26, 2013 02:04
fe17 dmesg output
[Wed Jun 26 00:10:50 2013] [ pid ] uid tgid total_vm rss cpu oom_adj oom_score_adj name
[Wed Jun 26 00:10:50 2013] [ 1033] 0 1033 4341 101 15 0 0 upstart-udev-br
[Wed Jun 26 00:10:50 2013] [ 1035] 0 1035 5395 142 35 -17 -1000 udevd
[Wed Jun 26 00:10:50 2013] [ 1876] 0 1876 3797 43 16 0 0 upstart-socket-
[Wed Jun 26 00:10:50 2013] [ 2008] 101 2008 62753 3119 32 0 0 rsyslogd
[Wed Jun 26 00:10:50 2013] [ 2017] 103 2017 5983 113 39 0 0 dbus-daemon
[Wed Jun 26 00:10:50 2013] [ 2026] 0 2026 4792 126 25 0 0 bluetoothd
[Wed Jun 26 00:10:50 2013] [ 4567] 0 4567 1306 110 21 0 0 iscsid
[Wed Jun 26 00:10:50 2013] [ 4568] 0 4568 1431 882 36 0 -17 iscsid
[Wed Jun 26 00:10:50 2013] [ 4682] 0 4682 3686 166 5 0 0 getty
EC2 security group 'chef' exists
Inbound security group rule icmp(-1 -> -1) exists
Inbound security group rule tcp(0 -> 65535) exists
Inbound security group rule udp(0 -> 65535) exists
Inbound security group rule tcp(22 -> 22) exists
Inbound security group rule tcp(443 -> 443) exists
Inbound security group rule tcp(444 -> 444) exists
ERROR: Fog::Compute::AWS::NotFound: The security group 'chef' does not exist
Creating EC2 security group 'chef'
Creating inbound security group rule for icmp(-1 -> -1)
Creating inbound security group rule for tcp(0 -> 65535)
Creating inbound security group rule for udp(0 -> 65535)
Creating inbound security group rule for tcp(22 -> 22)
Creating inbound security group rule for tcp(443 -> 443)
Creating inbound security group rule for tcp(444 -> 444)
ERROR: Fog::Compute::AWS::NotFound: The security group 'chef' does not exist
cache: [GET /] miss
cache: [GET /login] miss
cache: [GET /stylesheets/reset.css?1324660681] miss
cache: [GET /javascripts/login.js?1324660681] miss
cache: [GET /stylesheets/login.css?1324660681] miss
cache: [GET /javascripts/jquery-1.4.2.min.js?1324660681] miss
NoMethodError (super called outside of method):
mongoid (2.3.3) lib/mongoid/callbacks.rb:42
mongoid (2.3.3) lib/mongoid/callbacks.rb:67:in `call'
# Use environment variables
# or specify values manually
production:
host: 127.0.0.1
port: 27017
username: grayloguser
password: xxx
database: graylog2
@dodizzle
dodizzle / gist:1511939
Created December 22, 2011 21:29
patch to monitor ec2 nodes remotly
<% if n.has_key? "ec2" -%>
address <%= n['ec2']['public_ipv4'] %>
<% else -%>
address <%= n['ipaddress'] %>
<% end -%>
##########################
# users private ssh keys #
##########################
case node[:fqdn]
when "chi-devops11a.posterprod.com","chi-devops11b.posterprod.com"
%w{david rm}.each do |user|
cookbook_file "/home/#{user}/.ssh/id_rsa" do
source "id_rsa.#{user}"
mode 0600
owner "#{user}"
@dodizzle
dodizzle / gist:1483794
Created December 16, 2011 00:41
nested has key for chef recipe
if node.has_key? "filesystem"
if node["filesystem"].has_key? "/dev/sda6"
if node["filesystem"]["/dev/sda6"].has_key? "mount"
if node['filesystem']['/dev/sda6']['mount'] == '/srv'
execute "foo" do
command "touch /tmp/nested_keys_exist!"
action :run
end
end
end
cookbook_file "/etc/ssl/certs/star_#{node.domain}.pem" do
source "star_#{node.domain}.pem"
owner "root"
group "root"
mode 0755
end
cookbook_file "/etc/ssl/private/star_#{node.domain}.key" do
source "star_#{node.domain}.key"
owner "root"
service "riak"
execute "install_riak" do
command "/usr/bin/dpkg -i /srv/posterous/tmp/riak_1.0.2-1_amd64.deb"
action :nothing
user "root"
end
cookbook_file "/srv/posterous/tmp/riak_1.0.2-1_amd64.deb" do
source "riak_1.0.2-1_amd64.deb"