Skip to content

Instantly share code, notes, and snippets.

View bugcy013's full-sized avatar
🪄
Focusing

Dhanasekaran Anbalagan bugcy013

🪄
Focusing
View GitHub Profile
@bugcy013
bugcy013 / logstash
Created November 8, 2012 12:14
Logstash Problem and Solution
Get index from logstash
$curl -s http://192.168.70.54:9200/_status?pretty=true | grep logstash
@bugcy013
bugcy013 / Simple Notes understand
Created November 9, 2012 19:25
elasticsearch with cluster setup
logstash with elasticsearch with redis
=======================================
Since the last to make the configuration hoards logstash by directly loading the Apache log on the same server, as a next step, this time I try to make logstash the Apache configuration to collect logs of multiple servers.
And ... I can also say, try it first on a single server.
Official page of Centralized Setup with Event Parsing referring to.
And data flow components that make it work, like this.
Figure.1 logstash Architecture
@bugcy013
bugcy013 / spacewalk-client
Created November 12, 2012 11:11
Spacewalk Client configuration
[root@dvmah93 ~]# rpm -ivh http://spacewalk.redhat.com/yum/1.7-client/RHEL/5/x86_64/spacewalk-client-repo-1.7-5.el5.noarch.rpm
yum install rhn-client-tools rhn-check rhn-setup rhnsd m2crypto yum-rhn-plugin
root@spacewalkclient ~]# rhnreg_ks --serverUrl=http://192.168.100.105/XMLRPC --activationkey=1-414ace93e6c3e94c85aec54a653e761d
@bugcy013
bugcy013 / errata_spacewalk
Created November 12, 2012 11:14
Spacewalk_errata configuration
<Logos01> dhanasekaran: https://github.com/Logos01/admin-tools/blob/master/import_errata
<Logos01> That's my method.
<Logos01> It depends on the script, "errata-import.pl" as found on http://cefs.steve-meier.de
<Logos01> (Basically just grab errata-import.pl into /usr/local/bin and then my script as well. Then you can (best if done weekly) run my script.)
<dhanasekaran> Logos01, https://github.com/Logos01/admin-tools/blob/master/import_errata 404 error please check
<Logos01> https://github.com/Logos01/admin-tools/bin
<Logos01> Try that or https://github.com/Logos01/admin-tools/tree/master/bin
<dhanasekaran> Logos01, it's working
<Logos01> :D
<Logos01> Script is BSD/lGPL/GPLv2. Take your pick.
@bugcy013
bugcy013 / spacewalk-server guide
Created November 12, 2012 11:16
Spacewalk implementation
For centos-5
-------------
rpm --import http://fedora.mirror.nexicom.net/epel/RPM-GPG-KEY-EPEL-5
rpm --import http://mirror.centos.org/centos/5.8/os/x86_64/RPM-GPG-KEY-CentOS-5
For centos-6
-------------
rpm --import http://fedora.mirror.nexicom.net/epel/RPM-GPG-KEY-EPEL-6
rpm --import http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6
@bugcy013
bugcy013 / Repo
Created November 12, 2012 11:17
Repo creation
epel centos repo
http://dl.fedoraproject.org/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm
rpmforge repo
http://pkgs.repoforge.org/rpmforge-release/
Also make sure to import the rpmforge gpg key [More]
@bugcy013
bugcy013 / cobbler
Created November 12, 2012 11:18
cobbler guide
cobbler distro add --arch=x86_64 --breed=redhat --name=centos-5_8-64bit --initrd=/var/lib/tftpboot/images/centos_images_5.8_x86/initrd.img --kernel=/var/lib/tftpboot/images/centos_images_5.8_x86/vmlinuz
cobbler profile add --name=Development --distro ubuntu-12_04-64bit
cobbler profile edit --name=Development --kickstart=/var/lib/cobbler/kickstarts/preseed.txt --kopts="priority=critical locale=en_US"
cobbler system add –name=AA:BB:CC:DD:EE:FF –profile=RHEL5-i386
yum install koan
koan --server=192.168.0.42 --list=profiles (lists available profiles on the Cobbler server)
koan --server=192.168.0.42 --list=systems (lists available systems, if any)
@bugcy013
bugcy013 / cfengine
Created November 12, 2012 11:18
cfengine_setup
cf-engine Configuration
[1] Dowunload cf-engine source code
wget http://cfengine.com/source-code/download?file=cfengine-3.3.7.tar.gz
[2] Compile the source code
Debian/Ubuntu:
apt-get install libtokyocabinet-dev libpcre3-dev libssl-dev -y
CentOS/RedHat:
yum install tokyocabinet-devel pcre openssl -y
@bugcy013
bugcy013 / preseed
Created November 12, 2012 11:28
preseed.
d-i debian-installer/locale string en_US
d-i console-setup/layoutcode string en_US
d-i netcfg/choose_interface select eth0
# Any hostname and domain names assigned from dhcp take precedence over
# values set here. However, setting the values still prevents the questions
# from being shown, even if values come from dhcp.
d-i netcfg/get_hostname string ubunutu-test
d-i netcfg/get_domain string dvindia.net
Problem
--------
{1} java.io.IOException: Cannot run program "Rscript": java.io.IOException: error=2, No such file or directory
lrwxrwxrwx 1 root root 25 Oct 23 06:48 R -> /usr/local/R-2.15.1/bin/R
lrwxrwxrwx 1 root root 31 Oct 23 06:48 Rscript -> /usr/local/R-2.15.1/bin/Rscript
root@dvcliftonhera123:/usr/bin# pwd
/usr/bin