Techy Things

Completely wipe out mysql-server in CentOS 0

Completely wipe out mysql-server in CentOS

$> sudo yum remove mysql-server $> sudo rm -fr /var/lib/mysql Everything is gone!! Users, privileges, databases cleared. Note: the /var/lib/mysql folder will be refurnished on the next time you run sudo service mysqld start

Install mysql on CentOS 6.4 0

Install mysql on CentOS 6.4

Initial install $> sudo yum install mysql-client mysql-server $> sudo service mysqld start $> sudo chkconfig mysqld on Set a root password (optional) $> /usr/bin/mysqladmin -u root password 'new-password' Uninstall mysql completely including databases...

GIT : merging a single commit from a branch to another branch 2

GIT : merging a single commit from a branch to another branch

Merging a single commit to another branch This is called cherry-pick $> git cherry-pick eba87949886ca99c7383266ae318c54401d786ec It might fail with this : $> git cherry-pick eba87949886ca99c7383266ae318c54401d786ec fatal: bad object eba87949886ca99c7383266ae318c54401d786ec In that case, you have to...

Command-line upload and download on linux 0

Command-line upload and download on linux

[WARNING] This will expose unencrypted the login credentials. To upload : $> curl -T my-local-file.txt ftp://ftp.domain.com --user username:password To download : $> curl -uusername ftp://ftp.domain.com/myfile > savehere.txt      

Copy directory using scp 0

Copy directory using scp

Scp usage It is easy to use scp, however how do you copy a directory, without copying the directory name? Solution : scp -r public@10.64.6.11:/home/public/site/* /var/www/ About this If you write /* a the...