Category Archives: Uncategorized

install cassandra (Database)

What is Cassandra?
The Apache Cassandra database is the right choice when you need scalability and high availability without compromising performance. Linear scalability and proven fault-tolerance on commodity hardware or cloud infrastructure make it the perfect platform for mission-critical data. Cassandra’s support for replicating across multiple datacenters is best-in-class, providing lower latency for your users and the peace of mind of knowing that you can survive regional outages.

install cassandra (Database)

Reference : http://cassandra.apache.org/

Remark : 安裝 JDK 8, Python 2.7.x
(** JDK 9 above version, no java virtual machine, Python 3.x.x above version syntax error )

install cassandra (Database)

install cassandra (Database)

Create Directory :
C:\apache-cassandra-3.11.4\data
C:\apache-cassandra-3.11.4\commitlog
C:\apache-cassandra-3.11.4\saved_caches

Edit File :
C:\apache-cassandra-3.11.4\conf\cassandra.yaml

# data_file_directories:
#     - /var/lib/cassandra/data
data_file_directories:
- C:\apache-cassandra-3.11.4\data

# commitlog_directory: /var/lib/cassandra/commitlog
commitlog_directory: C:\apache-cassandra-3.11.4\commitlog

# saved_caches_directory: /var/lib/cassandra/saved_caches
saved_caches_directory: C:\apache-cassandra-3.11.4\saved_caches

Run Databases Service :
C:\apache-cassandra-3.11.4\bin\cassandra

Check Database connect command :
nodetool status

Open New Command Prompt :
C:\apache-cassandra-3.11.4\bin\cqlsh

install mosquitto in window

Install Mosquitto Server
Install Mosquitto Server
Remind :
Install Mosquitto Server

接著按 Next, 應該會出現以下錯誤畫面
因為我們缺少 libeay32.dll 和 ssleay32.dll

Install Mosquitto Server

選擇安裝路徑
Install Mosquitto Server

最後面的畫面是要你捐錢, 沒有要捐就把它勾掉吧
Install Mosquitto Server

然後我們到安裝好的資料夾取出 libeay32.dll 和 ssleay32.dll
Install Mosquitto Server

以及在 pthread-win32 下載的 pthreadVC2.dll
一起放到剛剛未完成安裝的 mosquitto 資料夾

Install Mosquitto Server

Reference : https://mosquitto.org/download/

Install Win32 OpenSSL
Install Win32 OpenSSL
Reference : https://slproweb.com/products/Win32OpenSSL.html

Pthreads
Pthreads
Reference : https://sourceware.org/pthreads-win32/
Download : ftp://sourceware.org/pub/pthreads-win32/dll-latest/dll/x86/pthreadVC2.dll
Download : ftp://sourceware.org/pub/pthreads-win32/dll-latest/dll/x64/pthreadVC2.dll

Result:
C:\Program Files (x86)\mosquitto\mosquitto_sub.exe -d -h 127.0.0.1 -t test
C:\Program Files (x86)\mosquitto\mosquitto_pub.exe -d -h 127.0.0.1 -t test -m "test message"

Install Mosquitto Server

Install Mosquitto Server

Install Mosquitto Server