Thursday, April 21, 2011

How to backup data with phpMyAdmin

Today, in my project, I need to back up because of an unforeseen event. But I do not want to do it manually because it takes a long time. I wanted to do it automatically.  
I found out how to do backup with phpmyadmin automatically. Click this link to see how.

Tuesday, April 12, 2011

How to configure snmpd


Continuing the installation of Cacti, you need do some configuration on another machines. Without doing this configuration, an error message will show up when you try create a device. Please click on this link to see how to do.

Friday, April 8, 2011

How to install Cacti

Cacti has some prerequisites. You need to install these packages before install Cacti:
  • RRDTool;
  • NET-SNMP;
  • MySQL;
  • PHP;
  • Apache;
You will also need to install some other packages for support. To see a video that show you how to install Cacti, please click this link or you can read the tutorial below.

Apache

Open a terminal and follow the next steps:
  1. sudo apt-get install apache2
After the installation is complete, open http://localhost in your favorite browser. If everything goes fine, you will see It Works! on the top.

PHP

Now that your web server is ready, we will install PHP. Open a terminal and follow the next steps:
  1. sudo apt-get install php5 libapache2-mod-php5
  2. sudo /etc/init.d/apache2 restart
  3. sudo gedit
  4. write the following PHP code:
    1. <?php phpinfo();?>
  5. save file as info.php in  /var/www folder
  6. open your favorite browser and type http://localhost/info.php.
MySQL

Enter the following command:
  1. sudo apt-get install mysql-server-5.0 php5-mysql
  2. type your password (e.g.: root)
  3. sudo /etc/init.d/apache2 restart
  4. open http://localhost/info.php in your favorite browser and check MySQL module.
Great!!! Now you have a LAMP (Linux, Apache, MySQL, PHP) configured system.

Net-SNMP

Open terminal and type the following commands:
  1. sudo apt-get install snmp php5-snmp
  2. sudo /etc/init.d/apache2 restart
  3. Open http://localhost/info.php in your favorite browser and check SNMP module
RRDTool

RRDTool is available in the Debian repository, so you can install it through APT. Type in your terminal
  1. sudo apt-get install rrdtool
Cacti

Before continuing, be sure that you got no error previously. You are in the last step of installing Cacti.
  1. sudo apt-get install cacti
  2. select option 'apache2'
  3. type your password of the database's administrative user (e.g.: root)
  4. type your MySQL application password for cacti and retype in password confirmation (e.g.: root)
  5. To complete the configuration process, open http://localhost/cacti in your favorite browser. 
In the installation type page, you can select if it's new install  or an upgrade. As we are going to install it for the first time, we will select New Install (which is selected by default) and click Next. The path settings page automatically determines the installed paths for RRDTool, PHP, SNMP and Cacti.log as well as the versions for Net-SNMP and RRDTool and then click Next.
In login screen, the username is admin and the default password is admin. After a successful login for the first time, the system will ask you to set a new password. Enter a new password and ensure you remember it. Without this password, you cannot administer the system!

Friday, April 1, 2011

How to install plugin PHP in Netbeans

A month ago, I installed NetBeans trough Linux Ubuntu's terminal with following command: sudo apt-get install netbeans. After the instalation is completed, I noticed that I can't create PHP project. So I was searching on Net and I found out how to solve the problem. In Netbeans, was missing plugin PHP. To see how to install plugin PHP, please click this link.