Skip to content

Instantly share code, notes, and snippets.

levmichael3

Block or report user

Report or block levmichael3

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View new-alias
new-alias() {
local last_command=$(echo `history |tail -n2 |head -n1` | sed 's/[0-9]* //')
echo alias $1="'""$last_command""'" >> ~/.bash_profile
. ~/.bash_profile
}
View gist:c9d90368048e992d53db
#!/bin/bash
debug=''
debug=''
is_dead_ping()
{
# echo "is_dead_ping $1 ?"
ping -c 1 $1 > /dev/null
if [ $? -ne 0 ]; then
# echo $1 is down
return 0
View gist:7f4b06b2dafa15882fe9
sudo cat /var/chef/cache/chef-stacktrace.out
Generated at 2015-02-16 11:34:28 +0200
Chef::Exceptions::RecipeNotFound: could not find recipe default for cookbook ssh_authorized_keys
/opt/chef/embedded/apps/chef/lib/chef/cookbook_version.rb:234:in `load_recipe'
/opt/chef/embedded/apps/chef/lib/chef/run_context.rb:169:in `load_recipe'
/opt/chef/embedded/apps/chef/lib/chef/run_context.rb:138:in `block in include_recipe'
/opt/chef/embedded/apps/chef/lib/chef/run_context.rb:137:in `each'
View gem list | grep foreman
[root@***** tmp]# gem list | grep foreman
/usr/local/lib/ruby/1.9.1/yaml.rb:84:in `<top (required)>':
It seems your ruby installation is missing psych (for YAML output).
To eliminate this warning, please install libyaml and reinstall your ruby.
foreman (0.77.0)
foreman-tasks (0.6.12)
foreman_chef (0.1.1)
View gist:d3925a23580315c12f55
node with name "rabbit" already running on "chef-xxxxx"
2015-01-29_02:44:28.18158 diagnostics:
2015-01-29_02:44:28.18191 - nodes and their ports on chef-xxxxx: [{bookshelf,33831},
2015-01-29_02:44:28.18196 {oc_bifrost,48981},
2015-01-29_02:44:28.18196 {oc_reporting,44535},
2015-01-29_02:44:28.18197 {mover,53862},
2015-01-29_02:44:28.18197 {erchef,41226},
2015-01-29_02:44:28.18197 {rabbit,25672},
2015-01-29_02:44:28.18198 {rabbitmqprelaunch11088,32900}]
You can’t perform that action at this time.