Pages

Wednesday, January 11, 2012

[Solved] Ubuntu Hibernate not working

For some laptop models, ubuntu installations show up by not hibernate in expected way. I have dug up in google about this issue and found some solutions.

this post.was the most relevant one thanks to the author,

make a script under /etc/pm/sleep.d/. 

sudo gedit /etc/pm/sleep.d/20_custom-ehci_hcd
paste the following code into the file you have just created:

#!/bin/sh
#inspired by http://art.ubuntuforums.org/showpost.php?p=9744970&postcount=19
#...and www.ubutnusolved.blogspot.com    


VERSION=1.1
DEV_LIST=/tmp/usb-dev-list
DRIVERS_DIR=/sys/bus/pci/drivers
DRIVERS="ehci xhci" # ehci_hcd, xhci_hcd
HEX="[[:xdigit:]]"
MAX_BIND_ATTEMPTS=2
BIND_WAIT=0.1

unbindDev() {
  echo -n > $DEV_LIST 2>/dev/null
  for driver in $DRIVERS; do
    DDIR=$DRIVERS_DIR/${driver}_hcd
    for dev in `ls $DDIR 2>/dev/null | egrep "^$HEX+:$HEX+:$HEX"`; do
      echo -n "$dev" > $DDIR/unbind
      echo "$driver $dev" >> $DEV_LIST
    done
  done
}

bindDev() {
  if [ -s $DEV_LIST ]; then
    while read driver dev; do
      DDIR=$DRIVERS_DIR/${driver}_hcd
      while [ $((MAX_BIND_ATTEMPTS)) -gt 0 ]; do
          echo -n "$dev" > $DDIR/bind
          if [ ! -L "$DDIR/$dev" ]; then
            sleep $BIND_WAIT
          else
            break
          fi
          MAX_BIND_ATTEMPTS=$((MAX_BIND_ATTEMPTS-1))
      done  
    done < $DEV_LIST
  fi
  rm $DEV_LIST 2>/dev/null
}

case "$1" in
  hibernate|suspend) unbindDev;;
  resume|thaw)       bindDev;;
esac
save the file and exit back to terminal.
Give execution permission:
sudo chmod 755 /etc/pm/sleep.d/20_custom-ehci_hcd
Now your system must work well with hibernate option.


Tuesday, January 10, 2012

Macubuntu, make ubuntu look like macOsX: for 10.04 and 10.10

some of unix lovers want to get the entire Mac OSX look in Ubuntu. For that, you can use Macbuntu a ubuntu customization script which is very easy to use.


 Macbuntu is not only  a theme. It can also install: Global Menu, Docky, Ubuntu-Tweak, Cheese, Compiz Extras and will change the look of the Login screen, Metacity, set Compiz effects and modify the top panel completely.


To install Macbuntu, you can either manually download the archive, extract it and then run the "install.sh" script via a terminal or copy/paste the following commands in a terminal to download and run it:


for Ubuntu 10.04


open terminal and execute the following commands



wget https://downloads.sourceforge.net/project/macbuntu/macbuntu-10.04/v2.2/Macbuntu-10.04.tar.gz -O /tmp/Macbuntu-10.04.tar.gz
tar xzvf /tmp/Macbuntu-10.04.tar.gz -C /tmp
cd /tmp/Macbuntu-10.04/
./install.sh


for Ubuntu 10.10

wget https://downloads.sourceforge.net/project/macbuntu/macbuntu-10.10/v2.3/Macbuntu-10.10.tar.gz -O /tmp/Macbuntu-10.10.tar.gz
tar xzvf /tmp/Macbuntu-10.10.tar.gz -C /tmp
cd /tmp/Macbuntu-10.10/
./install.sh

follow the instructions and answer the questions to complete the installation.
restart your computer and enjoy the new looks of your computer.



How to set up a firewall in ubuntu

To protect your computer against unauthorized access by people on the Internet or your network,you can set up a firewall in your ubuntu. Firewalls block connections to your computer from unknown sources, which helps to prevent security breaches. If you use a router to connect to the Internet, the router may already have a firewall configured which regulates connections from the Internet to your network.


following post briefs the set up procedure of firewalls in ubuntu.

Most users will prefer to use Gufw, which is a graphical user interface program to configure UFW(uncomplicated firewall).

Click the below link to install and enable Gufw:


then the below shown dialogue box appears.

click on launch application and agree to install the package.

Now, to start Gufw, choose System → Administration → Firewall configuration


To enable the firewall, simply check the box next to Enabled under “Actual Status”.
The default configuration is to deny connections. This means that a program attempting to connect to your computer will be denied. Certain programs or services which use the internet may require you to add an exception.
To add an exception:
  1. Click Add.
  2. You can choose from Preconfigured options for common programs and services, or you can manually add port exceptions in the Simple or Advanced tabs.
  3. To find out what type of exception a particular program requires, you should consult the help for that program.

[Solved] ubuntu asks for keyring password whenever user log in.

Problem: Ubuntu gnome(especially ubuntu 10.04) keeps on asking me to enter keyring password for each time I log in to my system. It is irritating to enter password twice as prt of the login process. Here is the solution.

solution:
You may be asked for a password every time you log in so that you can connect to a network. You can stop this from happening like so:

Right click the Network Manager icon and go to Edit Connections.

Go to the Wireless tab, select the connection you are using and click Edit.

Check Available to all users and click Apply. Enter your password when asked.

The next time you log in, you should not need to enter your password in order to connect to your network connection.

Monday, January 2, 2012

[Solved] connecting your Samsung Galaxy Tab with ubuntu

Like all other android devices, galaxy tab also  can be connected with Ubuntu Linux. you can simply connect your galaxy tab via its data cable provided. you can connect your tab in mass storage mode as well as you can tether your galaxy tabs internet connection through USB. unlike ipad, contents can be simply copied from your computer running Ubuntu to you tablet, if you connected your tab in mass storage mode.



Another awesome feature comes with your Android tablet is, you can tether you internet connection using the internal WiFi device, that turns your tablet into a mobile AP, this link provides more info about android to Ubuntu internet sharing.

Ubuntu server, a cost effective solution

Ubuntu server is the ideal solution for you if you are looking forward into deploy you business with latest technology but in a cost effective way. whether you want to deploy a webfarm or a cloud ubuntu has its solutions for you.

Ubuntu releases every six months, but its release cycle is stable as you can depend on it, it is recommended to choose LTS (long term support editions). which will be the most stable releases and will get free updates to a long term as up-to 3 years. and you can upgrade to next LTS version, all for free.

Ubuntu server supports almost all the hardware and software. and definitely this makes an optimal businessman to go for ubuntu server.


Choosing Ubuntu Server helps you bring the best that open source can offer to your business - a strategy that's driving the world's most successful organisations.
  • No licence fees
  • Free upgrades
  • The latest and greatest applications
Also, ubuntu offers techincal support from canonical, its makers and the largest ubuntu service provider with  a cost as low as $320 per server per year.

to read more about ubuntu server follow this link. Ubuntu opnsource server

[Solved] Installing C and C++ compilers in Ubuntu

Definitely you will be in need of a compiler collection if any bit of you is a programmer. Like all Linux flavours, Ubuntu is also enables users with native C and CPP programming facility.

to install the compilers if they are not installed run the following code in Terminal.

sudo aptitude install build-essential


This will install essential compiler collection , usually gcc in your ubuntu installation. Now all you need is to create your C program and compile it. to open a file from terminal, type


vi program1.c and press enter.


you will be provided with the most popular vi editor after typing your code, type


Esc  :  wq and pres enter.


then type


gcc -o out program1.c and press enter


the output executable will be saved as, out and to execute the latter, type


./out and press enter. that's all.


you can also use gedit(GUI text editor) to type in your programs. to compile the same, cd to the directory in which the program is saved and repeat last two steps