Install Conky in openSUSE 12.2 Gnome 3.6

I will not go to any details what conky is, but in short “Conky is a program which can display arbitrary information”. Read more about conky here.

In this specific article i will show you how to install conky and use different themes to customize it in openSUSE 12.2 Gnome 3.6. You can try it in other desktops and distributions too.
1st of all lets install conky, become root in terminal by su - and type:

zypper in conky conky-cairo

We are all set to use conky now. By default you will see very basic information while running with minimal theme and customization. We will try this conky theme . As you can see in the screenshot, it’s conky lua. I have did slight modifications for my taste, will post the code if some one want to use the modified version.

Conky with conky lua theme

Download it from the above link. Extract the archive and you will see more archives inside, extract which one suites your taste. Inside every archive there will be these files: conkyrc, conky_ring.lua and image for each distro.
Create a folder in home [/home/username/.conky] dir named .conky and copy the conky_ring.lua file and the image. Rename conkyrc to .conkyrc and copy it to home dir. Change username to your username. We are almost there. Now if you run it in terminal by:

conky -c ~/.conkyrc

You will probably not see anything in Gnome shell 3.6, because of the own_window_type. If that’s the case, open .conkyrc file and look for own_window_type, change override to normal and restart conky. Also make sure that own_window is set to yes.

How to start it upon system boot:
1st of save the following code as .start_conky in your home dir:

sleep 10
conky -d -c ~/.conkyrc

It will fire up conky after 10 seconds of delay.

Conky with start script

Now fire up terminal OR Alt+F2, type:


Click add button, give it any name you like, write a comment if you wish to and then click on browse button, go to your home dir and search for .start_conky, Use Ctrl+H to show hidden files. Click Add and done.

If you like to use my modified version. Just open .conkyrc file and paste the following code:

# Conky settings #
background no
update_interval 1

cpu_avg_samples 2
net_avg_samples 2

override_utf8_locale yes

double_buffer yes
no_buffers yes

text_buffer_size 2048
#imlib_cache_size 0

temperature_unit fahrenheit

# Window specifications #

own_window_class Conky
own_window yes
own_window_type normal
own_window_transparent yes
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager

border_inner_margin 0
border_outer_margin 0

minimum_size 250 250
maximum_width 250

alignment tr
gap_x 45
gap_y 55

# Graphics settings #
draw_shades no
draw_outline no
draw_borders no
draw_graph_borders no

# Text settings #
use_xft yes
xftfont caviar dreams:size=8
xftalpha 0.5

uppercase no

temperature_unit celsius

default_color FFFFFF

# Lua Load  #
lua_load ~/.conky/clock_rings.lua
lua_draw_hook_pre clock_rings

${voffset 8}${color FF6600}${font caviar dreams:size=16}${time %A}${font}${voffset -8}${alignr 50}${color FFFFFF}${font caviar dreams:size=38}${time %e}${font}
${color FFFFFF}${voffset -30}${color FFFFFF}${font caviar dreams:size=18}${time %b}${font}${voffset -3} ${color FFFFFF}${font caviar dreams:size=20}${time %Y}${font}${color FF6600}${hr}
${voffset 140}${font caviar dreams:size=10}${alignr}HOME${font}
${font caviar dreams:size=12}${color FFFFFF}${alignr}${weather WSAP temperature temperature 30} °C${font}

${color FFFFFF}${goto 25}${voffset 35}${cpu cpu0}%
${color FF6600}${goto 25}CPU
${color FFFFFF}${goto 50}${voffset 23}${memperc}%
${color FF6600}${goto 50}RAM
${color FFFFFF}${goto 75}${voffset 23}${swapperc}%
${color FF6600}${goto 75}Swap
${color FFFFFF}${goto 100}${voffset 25}${fs_used_perc /}%
${color FF6600}${goto 100}Disk
${color FFFFFF}${goto 125}${voffset 25}${downspeed wlan0}
${color FFFFFF}${goto 125}${upspeed wlan0}
${color FF6600}${goto 125}Net

${color FF6600}${font caviar dreams:size=9}Linux: ${color FFFFFF}${kernel} kernel
${color FF6600}${font caviar dreams:size=9}Uptime: ${color FFFFFF}${uptime_short}
${color FF6600}${font caviar dreams:size=9}Processes: ${color FFFFFF}${processes}
${color FF6600}${font caviar dreams:size=9}Running: ${color FFFFFF}${running_processes}

One more thing, you would wish to use your city for weather, go to this site and choose your country under International Weather Conditions , get the code and paste in .conkyrc file this line:

${font caviar dreams:size=12}${color FFFFFF}${alignr}${weather WSAP temperature temperature 30} °C${font}

Weather for conky

I also tried gotham theme, it’s clean and simple.
Setting it up is the same like conky lua. Download it from the link above and extract. There will be only one file .conkyrc. If you wana try it, stop conky {In terminal:[pidof conky, kill pidof]}, rename the conky lua .conkyrc file to some thing else and copy gotham .conkyrc file to home dir. Start it in terminal with: conky -c ~/.conkyrc and you will see the changes.

So that’s it for now, have fun with openSUSE and Conky. :)

Customize your Gnome desktop openSUSE 12.2

Gnome 3.6.x is awesome desktop, it improved quite a lot and more mature than it’s previous versions. This article is about Gnome 3.6.1 on openUSE 12.2.


The default icon set by Gnome is ugly[for me at least]. So 1st thing i need to do is change icons. Gnome tweak tool is a handy app to change your Gnome shell theme, icon theme, fonts etc. I am using Nitrux-Azure icon theme with Elegance shell theme and Ubuntu fonts. If you like these, download theme from here, icon set from here and fonts form here, after download extract the archives.


Go to your home directory and create these folders if they don’t exist .icons, .themes and .fonts and copy the downloaded icon, theme and font folders respectively.

To show hidden files and folders in home directory press Ctrl+H.
Note: Note the dot before icons, themes and fonts, must have that dot.

To use User Themes you might need to install User Themes extension from here.
Now install gnome tweak tool if haven’t installed yet, open it.


1st activate the User Themes extension if it’s not activated yet. After activating go to Themes tab from left hand side menu and choose your favorite shell and icon theme.

For fonts, go to Fonts tab and select your choice there.

Now a few useful extensions for your desktop to beautify your desktop look and feel.


That is quite clean, simple and useful desktop. If you have any nice extension OR themes/icons in mind for Gnome 3.6 please do share. :)

How to create live bootable usb via terminal in Linux

Before creating a live usb from terminal, you have to format your usb and make sure you are formatting/writing to the correct device. In terminal we will use dd command for creating a live bootable usb from any distro iso. 1st of all, lets find out our usb device:

sudo fdisk -l

That will list down your storage devices.


You can see from the screen shot, mine is detected as sdc, yours can be sdc, sdf or sdb etc.

NOTE: Before formatting, please backup your files from the usb as it will completely erase the device.

Now if you want to format this device, check out this link. After formatting, run the fdisk command again just to be on the safe side.

Now type the following command while changing the paths:

dd if=/path/to/iso-file of=/dev/sdc

bs can be added to the end of the command, bs{byte size}. bs=4096 OR bs=2048

dd if=/path/to/iso-file of=/dev/sdc bs=2048

Remember to not include the integer for the device, as it is representing the partition like sdc1 or sdc2 etc. Just use the device name like /dev/sdc or /dev/sdf.

Good luck!

Setup web server on Amazon AMI or CentOS [Part-1]

If you are using Amazon aws with ec2 instances, then i assume you already have the pem file to connect to the instances. Normally you will have different instances for your projects. I normally setup either Amazon AMI or Cent OS, prefer Amazon AMI as it is also based on Cent OS. Cent OS is best and easy OS for servers. I love the configuration and level of interaction it provides.
Let’s say you want to install a web server with MySQL and PHP, run the following command:

sudo yum install httpd mysql-server php php-mysql mysql php-xml php-pdo php-odbc php-soap php-common php-cli php-mbstring php-bcmath php-ldap php-imap php-gd mod_ssl

That will install all the necessary modules and packages to run a fully functional server.
In some cases we don’t need/want a web server, just database server will do it:

sudo yum install mysql-server mysql

That will only install database server on the instance.
Now let’s say we dont need either PHP or MySQL:

sudo yum install httpd

Some time we don’t need database server on the same web server instances:

sudo yum install httpd php php-xml php-mysql php-pdo php-odbc php-soap php-common php-cli php-mbstring php-bcmath php-ldap php-imap php-gd mod_ssl

That will install all necessay packages excluding MySQL.

Now if you have a MySQL server, for sure you would like to make it secure, that is easy:

sudo /usr/bin/mysql_secure_installation

The above command will ask you some questions, answer the questions carefully and you will get through it.
Don’t forget to remove anon users and test database while running the above command.

If you have .htaccess file and want to utilize mod rewrite, enable it in /etc/httpd/conf/httpd.conf in the server directory section:

AllowOverride None
AllowOverride All

To auto restart your server and database server in case the system is restarted:

sudo chkconfig httpd on
sudo chkconfig mysqld on

Manually start the servers:

sudo service httpd start
sudo service mysqld start

Some interesting information i will share in upcoming articles: Load balancer for multiple instances, configuring SSL on load balancer, creating databases and changing password, Dumping databases and saving table/database to csv and save only database schema. And separating your database server from web servers with load balancer and adding the instances to database for security purpose to read/write into database instance.

So stay tune, there are more and plenty to come.


Part-2: Backup MySQL data into CSV

Part-3: Backup MySQL data into CSV with PHP

Part-4: Backup and Restore MySQL databases

Part-5: Speed up your website loading time by using PHP APC

openSUSE 12.2 is OUT

Hi folks, we have some good news today. openSUSE team released the awaiting release 12.2 while ago. It comes with a lot of improvements, new/latest applications and latest desktop environments. Some of the key features:

  • Kernel 3.4
  • GRUB 2
  • Gnome 3.4
  • KDE 4.8.4
  • XFCE 4.10
  • XOrg 1.12
  • LibreOffice 3.5
  • And many more goodies


Screen shots and Features page

openSUSE 12.2 Portal

Announcement page

Download page

Download from gwdg mirrors

Got issues, check out openSUSE forums

Have a lot of fun!

Configure switchable graphics in Elementary/Ubuntu [Luna/12.04]

Currently running Elementary Luna on my laptop with switchable graphic cards. Laptop some time goes hot near the touch pad area with fan noise and hotness. Did a bit research and find out that it was ATI card ON by default. Battery usage was 1 to 1.30 hours on ATI by default. I have ATI 6600M with Intel integrated graphic card. From my previous openSUSE experiments, tried some solutions and can say things are much better now with Intel card[switched]. Battery life goes from 1/1.30 to 4/5 hours dramatically, no more heat issue and noise. Temperature dropped to around 50C for CPU and around 47C for HDD, which i still think is a bit high(working on it). So here is what i did.

Just for monitoring purpose, install lm-sensors and hddtemp. Sudo apt-get install in terminal will do it.


Now edit the following file with sudo(assumed terminal is open):

sudo vim /etc/rc.local

Add the following lines before exit 0.

chown -R $USER:$USER /sys/kernel/debug
echo OFF > /sys/kernel/debug/vgaswitcheroo/switch

Reboot, and see if that helps. You can view in terminal which graphic card is active now:

sudo cat /sys/kernel/debug/vgaswitcheroo/switch

IGD = Intel
DIS = ATI [Discrete]
Sample result:

1:DIS: :Off:0000:01:00.0

Even can switch back to ATI [need to logout and login for this to take affect, discrete card will be active(ATI)](not tested):

echo DIS > /sys/kernel/debug/vgaswitcheroo/switch

To turn OFF the in-active card:

echo OFF > /sys/kernel/debug/vgaswitcheroo/switch

I will do more research on this to minimize the heat. Will share my findings here. Stay tune.