Search this site

Wednesday, January 29, 2014

Power Saver in Ubuntu

After I move to ubuntu 13.10 from windows 7
I have some problem
one of them is power saver in ubuntu
If my windows can stay 3 hour with battery only then my ubuntu only 1 hour

One of my friends tell me to install power top
it is a software for linux to save your power

sudo apt-get install powertop

And run in terminal

sudo powertop

you can choose which process you want to save

Sunday, January 26, 2014

Apache can't restart

When I restart apache, I get this message:
apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
The solution is

  • sudo nano /etc/apache2/httpd.conf or apache2.conf
  • Add: ServerName localhost
  • And restart apache: sudo /etc/init.d/apache2 restart

Source: link

Installing apache, PHP5, and MySQL in ubuntu

Well, this blog will be my own note for something like this.
I hope this also help someone who still don't know how to install it.

Step:
1. sudo su (must be root)
2. Installing MySQL

  • apt-get install mysql-server mysql-client
  • To check: type mysql in terminal

3. Installing Apache2

  • apt-get install apache2
  • To check: go to your browser and open your IP for example localhost (if you using xampp) or http://192.168.0.100 
  • Apache's default document root is /var/www on Ubuntu, and the configuration file is /etc/apache2/apache2.conf. Additional configurations are stored in subdirectories of the/etc/apache2 directory such as /etc/apache2/mods-enabled (for Apache modules), /etc/apache2/sites-enabled (for virtual hosts), and /etc/apache2/conf.d. 

4. Installing PHP5

  • apt-get install php5 libapache2-mod-php5
  • After that restart apache
  • /etc/init.d/apache2 restart 
  • To check: go to /var/www and make info.php like this

phpinfo();
?>

  •  And open it with your browser IP/info.php or http://192.168.0.100/info.php

5. MySQL support PHP5

  • we need MySQL for PHP5 support
  • apt-cache search php5
  • pick anything you need
  • apt-get install php5-mysql php5-curl php5-gd php5-idn php-pear php5-imagick php5-imap php5-mcrypt php5-memcache php5-ming php5-ps php5-pspell php5-recode php5-snmp php5-sqlite php5-tidy php5-xmlrpc php5-xsl
  • After that restart apache again
  • /etc/init.d/apache2 restart
  • To check: reopen info.php and it will show some new module

6. Install phpmyadmin

  • to help us to manage mysql
  • apt-get install phpmyadmin
  • To check: go to your browser, open your IP/phpmyadmin or http://192.168.0.100/phpmyadmin

Source: link

Saturday, October 19, 2013

Play Media Player Format in Ubuntu

This time I will post about play media player format (mp3,mp4,ect) in ubuntu
because by default ubuntu will not download the codec

Step:
  1. Open Ubuntu Software Center
  2. In search, type: restricted extras
  3. Choose Ubuntu restricted extras
  4. Install
  5. And now you can play your music and video file

(source: link)

Can't boot Windows 7 after installing ubuntu

At first I install windows 7 and after that I install ubuntu 13.10.
But after install it, I can't boot to my old windows

Here is the step to fix this problem:
(source: link)
  1. Boot in ubuntu
  2. Open your terminal (just search terminal)
  3. type:
    sudo add-apt-repository ppa:yannubuntu/boot-repair && sudo apt-get update
  4. Enter your password and enter.
  5. type:
    sudo apt-get install -y boot-repair && (boot-repair &)
  6. It will make you install boot-repair in ubuntu
  7. Repair your boot file
  8. Restart
  9. Try to boot to your windows 7