The firewall needs to open the following ports
- TCP: 1514, 1515, 55000, 9200, 443
- UDP:514
0. Install docker
and docker-compose
- docker installation
2.docker-compose installation (linux server)$ sudo curl -L "https://github.com/docker/compose/releases/download/2.16.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local /bin/docker-compose
$ sudo chmod +x /usr/local/bin/docker-compose
$ docker-compose --version
### 1. Modify server `max_map_count`
$ sysctl -w vm.max_map_count=262144
### 2. Upload `wazuh-project.zip` to the server

unzip
$ unzip wazuh-project.zip

### 3. `docker-compose` one-click start project
$ docker-compose up -d
Waiting to pull the docker image

Start successfully

On the first start, `Wazuh` needs to generate the necessary indexes and index patterns, which takes about 1 minute (the speed depends on the configuration of the server)

### 4. Access `wazuh` console
Browser access: https://{IP}
Default account: `admin`
Default password: `elephdev`
The password change tutorial is below

Since it is an IP and wazuh officially generated certificate to access https, you need to click Ignore Access



### change Password
1. Enter the command
$ docker run --rm -ti wazuh/wazuh-indexer:4.3.10 bash /usr/share/wazuh-indexer/plugins/opensearch-security/tools/hash.sh
2. Enter the password (you need to pay attention that it will not be displayed, press Enter after entering)

3. Copy the generated hash and replace the current user hash in the file `config/wazuh_indexer/internal_users.yml`

4. INDEXER_PASSWORD Change the default value of all occurrences in the file docker-compose.yml to the new password


5. Restart the project
docker-compose restart
6. Enter the container
$ docker exec -it wazuh_elasticsearch_1 bash
7. Execute commands
export INSTALLATION_DIR=/usr/share/wazuh-indexer
export OPENSEARCH_PATH_CONF=${INSTALLATION_DIR}/config
CACERT=$OPENSEARCH_PATH_CONF/certs/root-ca.pem
KEY=$OPENSEARCH_PATH_CONF/certs/admin-key.pem
CERT=$OPENSEARCH_PATH_CONF/certs/admin.pem
export JAVA_HOME=/usr/share/wazuh-indexer/jdk
bash /usr/share/wazuh-indexer/plugins/opensearch-security/tools/securityadmin.sh -cd /usr/share/wazuh-indexer/plugins/opensearch-security/securityconfig/ -nhnv -cacert $CACERT -cert $CERT -key $KEY -p 9300 -icl

8. Exit the container

Post comment 取消回复