Thanks to antville.org
Saturday, 21. May 2016
start with docker

create a docker file

vi dockerfile

COPY php.ini /usr/local/etc/php/

FROM php:5.6-apache
COPY adminer.php /var/www/html/
RUN chmod -R 777 /var/www/html/

build an image

docker build -t my-php-app .

run an image

docker run -d -p 80:80 --name myapp my-php-app

docker run -it --rm --name my-running-app my-php-app

... Link (0 comments) ... Comment


docker command examples

options for running docker

docker run -d --name abcd2 -p 23:23 -v /var/lib/mysql tutum/ubuntu:trusty

docker run -d --volumes-from abcd2 -p 3306:3306 tutum/mysql:5.5

docker run -d --name abcd5 -p 24:24 -v /var/lib/mysql ubuntu:trusty

docker run -d --volumes-from abcd5 -p 3306:3306 mysql:5.5

docker run -d -v /path/in/host:/var/lib/mysql tutum/mysql /bin/bash -c "/usr/bin/mysql_install_db"

docker run -d -p 3306:3306 -v /path/in/host:/var/lib/mysql tutum/mysql

docker run -d -p 3301:3306 --cpu-shares=512 --blkio-weight=250 --memory=512M --cpuset-cpus=0 -v ~/mdbdata/mdb55:/var/lib/mysql -e MYSQL_ROOT_PASSWORD=admin --name mdb55 mariadb:5.5

start docker with host address

/etc/init.d/docker start -H tcp://0.0.0.0:2375

... Link (0 comments) ... Comment


Start 2 containers at once

Here is how you can start neo4j as well as scipy notebook.

vi docker-compose.yml

neo4j:
image: kbastani/docker-neo4j:latest
ports:

- "7474:7474"  
- "1337:1337"    

volumes:

- /opt/data   

jupyterscipy:
image: jupyter/scipy-notebook
ports:

- "8888:8888"    

links:

- neo4j:neo4j    

volumes:

- .:/home/jovyan/work  

docker-compose up -d

... Link (0 comments) ... Comment


Tuesday, 9. February 2016
linguistics using Python

These are the 4 libraries apart from standard library nltk are useful to analyze natural languages using python.

1) from corenlp import StanfordCoreNLP

github.com

2) from gensim.models import word2vec

github.com

3) import divisi2

github.com

4) from sklearn.naive_bayes import MultinomialNB

github.com

... Link (0 comments) ... Comment


Tuesday, 26. January 2016
Aurora Amazon rates

The cost of Aurora hosting per hour.

db.r3.large $0.290 (0.24 mysql)
db.r3.xlarge $0.580 (0.475 mysql)
db.r3.2xlarge $1.160 (0.945 mysql)
db.r3.4xlarge $2.320 (1.89 mysql)
db.r3.8xlarge $4.640 (3.78 mysql)

Mysql hosting starts with db.t2.micro at only $0.017 per hour.

... Link (0 comments) ... Comment


Monday, 25. January 2016
connect to AWS

It is possible to use password to connect to AWS

1) change config file
sudo vi /etc/ssh/sshd_config

PermitRootLogin yes
PasswordAuthentication yes

2) restart
sudo service ssh restart

3) add a password
sudo passwd root

4) ssh without key
ssh root@xxx.com

... Link (0 comments) ... Comment


Monday, 28. September 2015
Install percona extra backup tool innobackupex

Steps to install innobackupex on Ubuntu:

$ apt-key adv --keyserver keys.gnupg.net --recv-keys 1C4CBDCDCD2EFD2A

Add this to /etc/apt/sources.list, replacing VERSION precise with the name of your distribution:

deb repo.percona.com precise main
deb-src repo.percona.com precise main

Remember to update the local cache:
$ apt-get update

Now you can install Percona XtraBackup with:
$ apt-get install percona-xtrabackup

... Link (0 comments) ... Comment


Backup mysql data using innobackup

BACKUP

innobackupex --user=USERNAME --password=PASSWORD --no-timestamp /data/backups/new_backup <--(PATH OF BACKUP)
innobackupex --apply-log /data/backups/new_backup

RESTORE

service mysql stop
mkdir /tmp/mysql
mv /var/lib/mysql/* /tmp/mysql/
innobackupex --copy-back /data/backups/new_backup <--(PATH OF BACKUP WHERE IS STORED)
chown -R mysql: /var/lib/mysql
service mysql start

... Link (0 comments) ... Comment


Friday, 4. September 2015
Tuning MySQL

Getting the shell script:
wget launchpadlibrarian.net

Running:
sh tuning-primer.sh

... Link (1 comment) ... Comment


Tuesday, 1. September 2015
convert a rpm to deb

Here are simple steps to convert a rpm package to deb package and install.

sudo apt-get install alien

wget tinyurl.com

sudo alien ibus-typing-booster-1.2.3-4.el7.noarch.rpm

sudo dpkg -i ibus-typing-booster_1.2.3-5_all.deb

... Link (0 comments) ... Comment


Online for 5539 days
Last modified: 10/9/17 7:04 AM
Status
Youre not logged in ... Login
Menu
... Home
... Tags

Search
Calendar
October 2017
SunMonTueWedThuFriSat
1234567
891011121314
15161718192021
22232425262728
293031
September
Recent updates
Managing Amazon keys Use this
command to convert private key to public key. ssh-keygen -y...
by shantanuo (10/9/17 7:04 AM)
percona utility We can re-create
mysql users using the percona utility. wget percona.com/get/pt-show-grants chmod 777...
by shantanuo (9/6/17 8:22 AM)
mail merge separate file per
record Microsoft Word has an excellent feature called Mail-Merge. If...
by shantanuo (7/6/17 12:09 PM)
find dead processes The 8th
column of ps aux command will list the status of...
by shantanuo (5/28/17 7:39 AM)
Amazon Web Services Here are
some of the important Amazon products to use. cloudTrail...
by shantanuo (5/10/17 11:35 AM)
Self signed security certificate http://www.thegeekstuff.com/2009/07/linux-apache-mod-ssl-generate-key-csr-crt-file/
openssl genrsa -out 34.195.94.88.key 1024 openssl req -new -key 34.195.94.88.key...
by shantanuo (1/16/17 8:02 AM)
docker and aws Before starting
docker daemon, add the aws credentials. vi /etc/init/docker.override env AWS_ACCESS_KEY_ID=...
by shantanuo (11/23/16 3:01 PM)
Turn off Windows Updates in
Windows 10 There is no option to turn off Windows...
by shantanuo (10/30/16 2:43 PM)
RSS extension for chrome RSS
Subscription Extension (by Google) is a must have chrome extension...
by shantanuo (7/9/16 7:28 AM)
use putty for presentation Config
- Change settings... - Window - Colours - Use system...
by shantanuo (5/23/16 1:26 PM)
docker command examples # options
for running docker docker run -d --name abcd2 -p 23:23...
by shantanuo (5/21/16 11:04 AM)
start with docker # create
a docker file vi dockerfile COPY php.ini /usr/local/etc/php/ FROM php:5.6-apache...
by shantanuo (5/21/16 8:10 AM)
Start 2 containers at once
Here is how you can start neo4j as well as...
by shantanuo (5/21/16 7:29 AM)
linguistics using Python These are
the 4 libraries apart from standard library nltk are useful...
by shantanuo (2/9/16 4:46 PM)
Aurora Amazon rates The cost
of Aurora hosting per hour. db.r3.large $0.290 (0.24 mysql) db.r3.xlarge...
by shantanuo (1/26/16 3:06 PM)
connect to AWS It is
possible to use password to connect to AWS 1) change...
by shantanuo (1/25/16 11:17 AM)
Install percona extra backup tool
innobackupex Steps to install innobackupex on Ubuntu: $ apt-key adv...
by shantanuo (9/28/15 8:24 AM)
Backup mysql data using innobackup
BACKUP innobackupex --user=USERNAME --password=PASSWORD --no-timestamp /data/backups/new_backup
by shantanuo (9/28/15 8:09 AM)
Tuning MySQL Getting the shell
script: wget https://launchpadlibrarian.net/78745738/tuning-primer.sh Running: sh tuning-primer.sh
by shantanuo (9/4/15 4:34 PM)
convert a rpm to deb
Here are simple steps to convert a rpm package to...
by shantanuo (9/1/15 3:28 PM)
upgrade ubuntu Upgrade from 14.04
to 15.04 is a 2 step journey. sudo nano /etc/update-manager/release-upgrades...
by shantanuo (8/10/15 1:10 PM)
Libre office on centOS Here
is how to install Libre office on centOS 64 bit...
by shantanuo (7/7/15 8:02 AM)
manage iso image file Here
is how you can open and copy files from an...
by shantanuo (7/7/15 6:57 AM)
predictive typing You can try
a software called typing booster on Fedora. It helps user...
by shantanuo (6/29/15 10:59 AM)

RSS feed

Made with Antville
Helma Object Publisher