Skip to main content

Posts

Showing posts with the label Internet

Moving RRD file from 32bit to 64bit Architecture

When we were working on a nagios monitoring system we were migrating from a 32bit nagios to a 64bit Architecture. Most of the graphs are not working as the RRD was from an older 32bit architecture. Location of perfdata on nagios server. [root @nagios -server perfdata] # pwd /usr/local/nagios/share/perfdata Error when we load the graph. ERROR : This RRD was created on another architecture This can re solved by converting the exsisting 32bit RRD to XML and then restoring into the new 64bit Architecture. Creating a xml dump for rrd file. rrdtool dump cpu_load.rrd > cpu_load.xml Move the XML file to the new server (64bit) Restore the XML file back. rrdtool restore -f cpu_load.xml cpu_load.rrd Testing if the RRD file is create fine, use below command. rrdtool info cpu_load.rrd Now you should be able to see all the graphs on the server. ​

Not enough physical memory is Available - VMware Workstation 10

VMware Workstation 10 Error: Not enough physical memory is available to power this virtual machine This issues starts after an update. Issue on Windows 8.1 You attempt to start a virtual machine running on Workstation 10 and you get a message that you have no memory available to run the vm. Message : Not enough physical memory is available to power this virtual machine with its configured settings. Solution Shut down all running virtual machines Close VMware Workstation. Open Command prompt in Admin mode. opening config.ini file using nodepad from command prompt . c:\ProgramData\VMware\VMware Workstation> notepad config.ini Open config.ini located at C:\ProgramData\VMware\VMware Workstation Insert this line: vmmon.disableHostParameters = TRUE Save and close file. Reboot Windows. Error Message Useful Links http://ctobob.com/2014/12/04/vmware-workstation-10-error-not-enough-physical-memory-available-power-virtual-machine/ ​

`haproxy` Setup on Centos 6.5, Kernel 2.6, CPU x86_64

How to setup HAProxy HAProxy is the Reliable, High Performance TCP/HTTP Load Balancer and it works nicely with Deveo Cluster setup. Follow these steps to install on CentOS: [ahmed@ahmed-server ~]$ sudo yum install make gcc wget [ahmed@ahmed-server ~]$ wget http://www.haproxy.org/download/1.5/src/haproxy-1.5.11.tar.gz [ahmed@ahmed-server ~]$ tar -zxvf haproxy-1.5.11.tar.gz -C /opt [ahmed@ahmed-server ~]$ cd /opt/haproxy-1.5.11 [ahmed@ahmed-server haproxy-1.5.11]$ sudo make TARGET=linux26 CPU=x86_64 [ahmed@ahmed-server haproxy-1.5.11]$ sudo make install Follow these steps to create init script: [ahmed@ahmed-server ~]$ sudo ln -sf /usr/local/sbin/haproxy /usr/sbin/haproxy [ahmed@ahmed-server ~]$ sudo cp /opt/haproxy-1.5.11/examples/haproxy.init /etc/init.d/haproxy [ahmed@ahmed-server ~]$ sudo chmod 755 /etc/init.d/haproxy Follow these steps to configure haproxy: [ahmed@ahmed-server ~]$ sudo mkdir /etc/haproxy [ahmed@ahmed-server ~]$ sudo cp /opt/haproxy-1.5.11/e...

Using `npm` behind a proxy

To permanently set the configuration we can do this. npm config set proxy http://proxy.company.com:8080 npm config set https-proxy http://proxy.company.com:8080 If you need to specify credentials, they can be passed in the url using the following syntax. http://user_name:password@proxy.company.com:8080 To Redirect traffic over proxy. npm --https-proxy=http://proxy.company.com:8080 -g install npmbox npm --https-proxy=http://proxy.company.com:8080 -g install kafka-node More Details. http://wil.boayue.com/blog/2013/06/14/using-npm-behind-a-proxy/ ​

Replace String in Files/File

Courtesy :  http://unix.stackexchange.com/questions/112023/how-can-i-replace-a-string-in-a-files 1. Replacing all occurrences of one string with another in all files in the current directory: These are for cases where you  know  that the directory contains only regular files and that you want to process all non-hidden files. If that is not the case, use the approaches in 2. All  sed  solutions in this answer assume GNU  sed . If using FreeBSD or OS/X, replace  -i  with  -i '' . ·          Non recursive, files in this directory only: ·          sed -i -- 's/foo/bar/g' * perl - Ti -pe 's/foo/bar/g' ./* (the  perl  one will fail for file names ending in  |  or space) ). ·          Recursive, regular files (including hidden ones) in this and all subdirectories find . -type f -exec sed...