Setting Up MongoDB 4 in a Linux Environment (PSA Architecture)

Setting Up MongoDB 4 in a Linux Environment (PSA Architecture)

This article mainly introduces the setup of MongoDB replica set mode in a Linux environment (one primary, one secondary, and one arbiter), including setup steps, primary-secondary switching, high availability testing, etc. Architecture Diagram One Primary, One Secondary, One Arbiter Environment Ubuntu 5.4.0-6ubuntu1~16.04.12 mongodb-linux-x86_64-ubuntu1604-4.2.8.tgz Steps Create Primary Node Create directories for data and logs # Primary … Read more

One-Click Deployment of Nginx Web Server with Ansible

One-Click Deployment of Nginx Web Server with Ansible

1. Create roles directory mkdir -p ansible_nginx/group_vars mkdir -p ansible_nginx/roles cd ansible_nginx/roles mkdir common nginx mkdir {common,nginx}/tasks mkdir nginx/{files,handlers} mkdir nginx/templates 2. Basic Configuration of Roles cd ansible_nginx 2.1. Hosts Configuration cat hosts [webservers] 192.168.52.16 2.2. site.yml Configuration cat site.yml —- name: Install nginx hosts: webservers remote_user: root roles: – role: common – role: nginx … Read more

Ansible Management of Windows Hosts Error

Ansible Management of Windows Hosts Error

ansible-playbook — – hosts: windows tasks: – name: backup webapp win_shell: ‘move D:\tomcat\WEB-INF D:\Y4ECSRUN\webapp\\WEB-INF-{{ DATE }}bak’ – name: copy package win_copy: ‘src=/ansible-playbook/WEB-INF.zip dest=D:\tomcat\webapp\WEB-INF-{{ DATE }}.zip’ – name: unzip package win_unzip: ‘creates=no src=D:\Y4ECSRUN\webapp\hanwang-test\WEB-INF-{{ DATE }}.zip dest=D:\Y4ECSRUN\webapp\hanwang-test\’ – name: stop java service raw: ‘taskkill /F /IM java.exe /T’ – name: start tomcat service win_command: ‘chdir=D: .\startup.bat’ Execute … Read more

STM32CUBEMX Tutorial 2 — Using GPIO for Input/Output

STM32CUBEMX Tutorial 2 — Using GPIO for Input/Output

Previous article links:Detailed installation tutorial for STM32CUBEMXSTM32CUBEMX Tutorial 1 — Environment Configuration and New Project CreationWhen learning and using any MCU, the initial step often starts with GPIO. Learning how to configure IO allows you to output the desired voltage levels and read the voltage levels from the IO ports.This article introduces the GPIO of … Read more

Ansible: From Introduction to Abandonment (Part 20)

Ansible: From Introduction to Abandonment (Part 20)

Ansible Roles Ansible Role is a collection of playbooks. For example, combining the playbook for configuring nginx, the playbook for configuring php, and the playbook for configuring mysql can create a role for configuring lnmp. There are three common types of roles: • The roles that come with RHEL, which can be installed via <span>yum … Read more

DeviceNet Slave to PROFIBUS Slave – ADFWEB Gateway

DeviceNet Slave to PROFIBUS Slave - ADFWEB Gateway

DeviceNet Slave toPROFIBUS Slave – ADFWEB Gateway– Guangzhou Xinyu IoT Author:www.adfweb.com.cn Zou Wuyi Mobile185-020-77899 Email: [email protected] 1 Features: The configurableDeviceNet Slave / PROFIBUS Slave converter has the following features: • Achieves bidirectional information transmission between theDeviceNet network and thePROFIBUS network; • Electrical isolation between the two buses; • Supports a maximum of244 bytes for reading … Read more

A New Alternative to CentOS

A New Alternative to CentOS

On December 8, 2020, the CentOS official website announced that CentOS Linux 8 would cease service on December 31, 2021. CentOS Linux 7 will stop service on June 30, 2024. CentOS Stream, which will serve as the upstream (development) branch of Red Hat Enterprise Linux after the end of CentOS Linux 8, is certainly less … Read more

Deploying an ElasticSearch Cluster in a Linux Environment

Deploying an ElasticSearch Cluster in a Linux Environment

Introduction Environment Cluster Installation and Deployment First Machine Second Machine Third Machine Change the owner and group of the elasticsearch directory Switch to the es user and start the es on all three machines Cluster Startup Verification Restart the three nodes in sequence Verification es Cluster Authentication x-pack Authentication Reference Documents Introduction ❝ This article … Read more

PROFIBUS Master to CAN-ADFWEB Gateway Converter – Guangzhou Xinyu IoT

PROFIBUS Master to CAN-ADFWEB Gateway Converter - Guangzhou Xinyu IoT

PROFIBUS Master toCAN-ADFWEB Gateway Converter–Guangzhou Xinyu IoT Author:www.adfweb.com.cn Zou Wuyi Mobile185-020-77899 Email: [email protected] 1、Features: The configurable “PROFIBUS Master/CAN converter” has the following features: Triple isolation between CAN and PROFIBUS, CAN and power supply, PROFIBUS and power supply; Can be mounted on a 35mm DIN rail; Power supply: 8…24V AC or 12…35V DC; Operating temperature range: … Read more

WSL: Your First Linux Experience

WSL: Your First Linux Experience

WSL: Windows Subsystem for Linux WSL, short for Windows Subsystem for Linux, is a feature introduced by Microsoft for Windows that allows users to run Linux binary executables on Windows. WSL provides a fully compatible Linux kernel interface, enabling users to run a Linux environment without the need for a virtual machine or dual booting. … Read more