##Start Zookeeper bin/zookeeper-start.sh config/zookeeper.properties
##Start broker server bin/kafka-server-start.sh config/server.properties
##List all topic bin/kafka-topics.sh --zookeeper=127.0.0.1:2181 --list
##Create topic
| \DB::enableQueryLog(); // Enable query log | |
| // Your Eloquent query executed by using get() | |
| dd(\DB::getQueryLog()); |
| ffmpeg -i video.mov -c:v libvpx-vp9 -crf 30 -b:v 0 -b:a 128k -c:a libopus video.webm | |
| #Convert video from 4K to FullHD | |
| ``` | |
| ffmpeg -i 50周年-PRビデオ_Final.mov -vf scale=1920:1080 -c:a copy output1080vid.mp4` | |
| ``` |
| ffmpeg -i video.mp4 -vframes 1 -f image2 cover.jpg |
| { "transactions": 86430, | |
| "availability": 99.97, | |
| "elapsed_time": 299.43, | |
| "data_transferred": 1568.13, | |
| "response_time": 0.34, | |
| "transaction_rate": 288.65, | |
| "throughput": 5.24, | |
| "concurrency": 97.42, | |
| "successful_transactions": 86430, | |
| "failed_transactions": 22, |
| { "transactions": 28599, | |
| "availability": 99.59, | |
| "elapsed_time": 299.60, | |
| "data_transferred": 933.64, | |
| "response_time": 1.01, | |
| "transaction_rate": 95.46, | |
| "throughput": 3.12, | |
| "concurrency": 96.64, | |
| "successful_transactions": 28599, | |
| "failed_transactions": 119, |
| #Create 4G swap (128M*32) | |
| sudo dd if=/dev/zero of=/swapfile bs=128M count=32 | |
| sudo chmod 600 /swapfile | |
| sudo mkswap /swapfile | |
| sudo swapon /swapfile | |
| 6. Enable the swap file at boot time by editing the /etc/fstab file. | |
| Open the file in the editor: |
| sudo ss -lptn 'sport = :10026' |
| ##Use SWR to call ajax in client site | |
| import useSWR from 'swr' | |
| const fetcher = url => fetch(url, { | |
| 'Content-Type': 'application/json', | |
| }).then(r => r.json()); | |
| function Profile() { |
##Start Zookeeper bin/zookeeper-start.sh config/zookeeper.properties
##Start broker server bin/kafka-server-start.sh config/server.properties
##List all topic bin/kafka-topics.sh --zookeeper=127.0.0.1:2181 --list
##Create topic
| #!/bin/bash | |
| sudo yum update | |
| sudo yum install ruby | |
| sudo yum install wget | |
| cd /home/ec2-user | |
| wget https://aws-codedeploy-ap-southeast-1.s3.ap-southeast-1.amazonaws.com/latest/install | |
| chmod +x ./install | |
| sudo ./install auto |