Linux : How To Delete Bash History

Friday, September 30, 2011 10:08 AM 0 Comments , , ,


Delete bash history

To delete the bash history for your current session as well as old sessions, you should do two things:

Delete the .bash_history file:

rm -rf ~/.bash_history

Clear the current history stored in RAM:

history -c




Turn off bash history for all users:

Append “unset HISTFILE” to /etc/profile:

echo "unset HISTFILE" >> /etc/profile

Turn off bash history for a specific user:

Append “unset HISTFILE” to /home/USER/.bash_profile:

echo "unset HISTFILE" >> /home/USER/.bash_profile
Good Luck ~

0 comments:

linux : disable audit daemon log

Thursday, September 29, 2011 10:26 PM 0 Comments

auditd -s disable

rm -rf /var/log/audit/

cat /dev/null > /var/log/lastlog

0 comments:

hello from android

Sunday, September 11, 2011 11:11 PM 0 Comments

hello from android
Published with Blogger-droid v1.7.4

0 comments:

fix : PHP Deprecated: Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/ming.ini on line 1 in Unknown on line 0

Saturday, September 10, 2011 5:52 PM 1 Comments , , , ,

This is Solution to Fix :
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/ming.ini on line 1 in Unknown on line 0
1. Open File  /etc/php5/cli/conf.d/ming.ini
sudo gedit /etc/php5/cli/conf.d/ming.ini

2. Replace The '#' on First Line with ';'
; configuration for php MING module

3. Save & Have Fun !

1 comments:

Install xdebug on PHP ubuntu 11.04

Nomally php var_dump()  function display like this



We will override var_dump() by xdebug for  human read with color highlight like this




1. install php5-xdebug follow command :
sudo apt-get install php5-xdebug 

2. find xdebug.so :
sudo find / -name xdebug.so

result just like this :
/usr/lib/php5/20090626+lfs/xdebug.so

3. Edit php.ini :
sudo gedit /etc/php5/apache2/php.ini

add this in the end of file :
zend_extension="/usr/lib/php5/20090626+lfs/xdebug.so"

find html_errors in php.ini and change it to on :
html_errors = on
save your php.ini

4. Restart Your Apache :
sudo /etc/init.d/apache2 restart
5. have debug fun !!!

0 comments:

fix netbeans 7.0.1 php not suggest class

Tuesday, September 6, 2011 5:44 PM 0 Comments , , , ,

i got poblem in netbeans 7.0.1 ,It's not suggest my php class (Joomla Framework).Before that I can use netbeans with php (Joomla Framework) very well.
After I updated some plugins Netbeans alert message like can't load some class.

Solution :
Update Your Java JDK to Version 7 Here

0 comments:

ubuntu 11.04 install apache php mysql phpmyadmin

1. open terminal
2. install mysql
sudo apt-get install mysql-server mysql-client
3. install apache
sudo apt-get install apache2
4. install php and apache module
sudo apt-get install php5 libapache2-mod-php5
5. install php5 basic module
sudo 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
6. restart apache
sudo  /etc/init.d/apache2 restart
7. test your apache and php work
sudo gedit /var/www/info.php
     insert code below and save :
<?php
phpinfo();
8. open your web browser and check it at http://localhost/info.php and see result like this.


9. install phpmyadmin 
sudo apt-get install phpmyadmin
   select >  apache2

10. edit apache2.conf
sudo gedit /etc/apache2/apache2.conf 

      insert this code into the last line
Include /etc/phpmyadmin/apache.conf
11. reload or restart your apache
sudo /etc/init.d/apache2 reload
12. open your web browser and go to http://localhost/phpmyadmin/



13. have fun !!!


ps.

sudo apt-get install mysql-server mysql-client apache2 php5 libapache2-mod-php5 php5-mysql php5-curl php5-gd php-pear php5-imagick php5-mcrypt php5-sqlite php5-tidy phpmyadmin

0 comments:

First Look at Ubuntu Linux 11.10 "Oneiric Ocelot" Beta

Friday, September 2, 2011 8:11 AM 0 Comments , , ,

This is Some of Screenshot of Ubuntu 11.10 "Oneiric Ocelot"
It's look pretty cool but i love old gnome.









Source : lifehacker.com

0 comments:

THE EVOLUTION OF THE WEB

8:03 AM 0 Comments ,

Watch THE EVOLUTION OF THE WEB in 6 language


CREDITS
Made with some friends from the Google Chrome team
2010 version by mgmt design and GOOD
2011 version by Hyperakt and Vizzuality


0 comments:

mysql_fetch_assoc VS mysql_fetch_object VS mysql_fetch_array

Thursday, September 1, 2011 2:43 PM 0 Comments ,

Performance of mysql_fetch_assoc , mysql_fetch_object , mysql_fetch_array


Graph

mysql_fetch_assoc have great performance !

0 comments: