UPWORK/ODESK guru: Tips and Tricks for clients

skype: odesk.by / upwork.link , email: [email protected]/upwork.link

Archive for March, 2013

Yum: prevent a updating the packages

without comments

When you are running the new servers, the one thing you do not want to do – is upgrade the kernel. Because that is the only Linux update operation that requires a reboot once it is done — and in a production environment you often can’t have downtime.

Read the rest of this entry »

Written by spectre

March 30th, 2013 at 8:05 am

Setup Oracle Java jre 1.7 on Centos 6.(1,2,3,4…)

without comments

Download the rpm file from java.com. Install using the rpm command:

rpm -Uvh jre-7u17-linux-x64.rpm

Use alternatives to config:

[[email protected] ~]# alternatives --config java
There are 2 programs which provide 'java'.
  Selection    Command
-----------------------------------------------
*  1           /usr/java/latest/jre/bin/java
 + 2           /usr/java/jre1.7.0_17/bin/java
   
Enter to keep the current selection[+], or type selection number:

Select the java you want to use in my case 2. Test using:

[[email protected] ~]# java -version
java version "1.7.0_17"
Java(TM) SE Runtime Environment (build 1.7.0_17-b02)
Java HotSpot(TM) 64-Bit Server VM (build 23.7-b01, mixed mode)
[[email protected] ~]# 

Create links in the Mozilla Plugins directory:

[[email protected] ~]# cd /usr/lib64/mozilla/plugins/
[[email protected] ~]# ln -fs /usr/java/latest/lib/amd64/libnpjp2.so 

Written by spectre

March 29th, 2013 at 7:21 am

Posted in Java,Tips and Tricks

Fedora, RHEL / Centos set default gateway

without comments

There is no specific command on CentOS to set the default route or gateway, there are several ways to do this on CentOS (as there often are). The method I am showing you will work on all versions of CentOS with or without a GUI and involves directly editing the network configuration file using Vim.

Setting default gateway on CentOS first requires us to open /etc/sysconfig/network config file using Vim:

$ vim /etc/sysconfig/network

You now need to add your default GW, if you don’t know the IP of your default GW (aka default route) then you need to ask your ISP / web host or network admin. The example below assumes our default GW is 192.168.0.1

GATEWAY=192.168.0.1

I always append this information to the bottom on the network config file on CentOS.

After adding the default route (GW) you need to restart the networking service using:

# service networking restart

Written by spectre

March 28th, 2013 at 9:21 pm

How to detect which the virtualization system on your hosting.

without comments

Frequently, customers want to install software in a virtual machine. This can be OK, but frequently they hit a CPU,memory, or IO limit caused by running in a constrained virtual environment.When this happens, we really like to know if they’re running under virtualization when we try to support them. Here’s some tricks to detect, from
a shell, if the system is virtualized.

The first thing to check is dmesg. On a recently-booted system, checking the
‘dmesg’ command output may be sufficient. Otherwise, try “cat /var/log/dmesg”
instead of “dmesg”

Written by spectre

March 13th, 2013 at 5:59 pm

Posted in Hostings ...