23 Jan 2012
Command | Description |
---|---|
csf -s | Start the firewall rules |
csf -f | Flush/Stop firewall rules (note: lfd may restart csf) |
rsync -ave "ssh" --rsync-path="sudo rsync" USER@REMOTE_SERVER:/remote/file/path/ /local/file/path |
#!/usr/bin/env ruby | |
require 'syslog' | |
require 'net/http' | |
require 'aws-sdk' | |
Syslog.open | |
AWS.config({ | |
:access_key_id => '<iam user key>', | |
:secret_access_key => '<iam user secret>' |
server { | |
listen 80; | |
server_name .example.co.uk.dev; | |
access_log /usr/local/var/log/nginx/example.co.uk-access.log; | |
error_log /usr/local/var/log/nginx/example.co.uk-error.log error; | |
root /var/www/example.co.uk/public; | |
index index.php index.html; |
23 Jan 2012
Command | Description |
---|---|
csf -s | Start the firewall rules |
csf -f | Flush/Stop firewall rules (note: lfd may restart csf) |
curl -k -g -X POST -d "payload={\"text\":\"my important bot notification\", \"channel\":\"#monitoring\", \"username\":\"computer-bot\", \"icon_emoji\":\":computer:\"}" https://hooks.slack.com/services/XXXXXXXXX/XXXXXXXXX/XxXxXxXxXXXxxXXXxxx |
// export | |
mysqldump -h localhost --port 3306 -u username -p"password" --routines database > dump.sql | |
// import | |
mysql -h localhost --port 3306 -u username -p"XXX" --default-character-set=utf8 database < dump.sql | |
// import with progress | |
pv dump.sql | mysql -h localhost --port 3306 -u username -p"XXX" --default-character-set=utf8 database | |
// note when using passwords with "$": escape passwords needed |
cat ~/.ssh/id_rsa.pub | ssh -i aws.pem ubuntu@ip_address "cat - >> ~/.ssh/authorized_keys" |
Can I Remove MySQL Binary Log Yes, as long as the data is replicated to Slave server, it’s safe to remove the file. It’s recommend only remove MySQL Binary Log older than 1 month. | |
Besides, if Recovery of data is the main concern, it’s recommend to archive MySQL Binary Log. | |
There are several ways to remove or clean up MySQL Binary Log, it’s not recommend to clean up the file manually, manually means running the remove command. | |
Remove MySQL Binary Log with RESET MASTER Statement Reset Master statement is uses for new database start up during replication for Master and Slave server. This statement can be used to remove all Binary Log. | |
To clean up Binary Log on Master Server |
wget https://cmake.org/files/v3.12/cmake-3.12.3.tar.gz
tar zxvf cmake-3.*
Sesuaikan kode binary dengan arsistektur Android anda,
kebetulah arsistektur HP android saya adalah aarch64 (s9 plus)
untuk memilih kode binari anda bisa lihat di
https://download.docker.com/linux/static/stable/
Berikut adalah cara installnya
$ curl https://download.docker.com/linux/static/stable/aarch64/docker-18.03.1-ce.tgz | tar -xz
$ mv docker/* ~/../usr/bin/