Centos7 elasticsearch-7.7.0 集群搭建,启用x-pack验证 Kibana7.4用户管理

news2024/10/7 8:22:26

前言

Elasticsearch 是一个分布式、RESTful 风格的搜索和数据分析引擎,能够解决不断涌现出的各种用例。 作为 Elastic Stack 的核心,它集中存储您的数据,帮助您发现意料之中以及意料之外的情况。

环境准备

软件                          OS系统      IP                     节点
Elasticsearch7.7.0    centos 7    10.16.101.27    node-1
Elasticsearch7.7.0    centos 7    10.16.101.28    node-2
Elasticsearch7.7.0    centos 7    10.16.101.29    node-3 

1.JDK环境安装以及配置

Elasticsearch7.7.0需要jdk11的允许环境,所有我们安装Jdk11

# 已经JDK保存在OSS,所有从OSS下载
cd root
wget https://starshop.obs.cn-south-1.myhuaweicloud.com/other/jdk-11.0.14_linux-x64_bin.tar.gz

# 解压 jdk-11.0.14_linux-x64_bin.tar.gz 移动到/usr/java/jdk11目录下
tar xf jdk-11.0.14_linux-x64_bin.tar.gz
mv jdk-11.0.14_linux-x64_bin /usr/java/jdk11

# 赋予java 执行权限
chmod 777 /usr/java/jdk11/bin/java
chmod 777 /usr/java/jdk11/jre/bin/java

 配置jdk环境变量

配置环境变量
vi /etc/profile
在文本末添加以下内容
---------------------------------------------------------------
#java环境变量
export JAVA_HOME=/usr/java/jdk1.8
export PATH=$JAVA_HOME/bin:$PATH
export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
----------------------------------------------------------------
执行一下命令 立即生效
source  /etc/profile

查看java版本
java -version

2.开端口

# Elasticsearch7.7.0 需要开启9200 9300 9100端口进行通信
firewall-cmd --zone=public --add-port=9100/tcp --permanent && firewall-cmd --zone=public --add-port=9200/tcp --permanent && firewall-cmd --zone=public --add-port=9300/tcp --permanent && firewall-cmd --reload

3.创建新用户,用户启动Elasticsearch

# 因为Elasticsearch不能使用root用户启动,所有必须新建用户
# 新建用户
adduser es  
# 给新用户添加密码
passwd es

安装 Elasticsearch7.7.0

https://www.elastic.co/cn/downloads/past-releases#elasticsearch

# 下载es
cd /root
wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.7.0-linux-x86_64.tar.gz
# 解压文件到,移动到/usr/local/elastic/elasticsearch7
tar xf elasticsearch-7.7.0-linux-x86_64.tar.gz
mv elasticsearch-7.7.0-linux-x86_64 /usr/local/elastic/elasticsearch7
# 将elasticsearch7目录及路径下所有文件所有者均设为es用户
chown es:es -R /usr/local/elastic/elasticsearch7

1.修改系统配置文件

# 打开sysctl.conf文件。Linux默认不允许任何用户和应用程序直接开辟这么大的虚拟内存
vi /etc/sysctl.conf
# 文件sysctl.conf末尾加入
vm.max_map_count=655360
# 保存退出后,为了让系统控制权限配置生效
sysctl -p

2.修改limits.conf文件

vi /etc/security/limits.conf
# 在文件内结束符前加上下面给出的几行代码,保存即可
* soft nofile 65536
* hard nofile 131072
* soft nproc 4096
* hard nproc 4096
* soft memlock unlimited
* hard memlock unlimited

3.修改elasticsearch.yml(在27,28,29 编辑elasticsearch.yml)

# 切换到es用户
su es
# 编辑elasticsearch.yml
cd /usr/local/elastic/elasticsearch7/config
vi /usr/local/elastic/elasticsearch7/config/elasticsearch.yml
########################下面是文件内容########################################
# 集群名称,同一集群下每台服务器的名称要一致否则会报错
cluster.name: my-elasticsearch
# 节点名称,集群下每台机的节点名称唯一(举例的机器节点名称设为node-1,其他分别为node-2,node-3)
node.name: node-1
# ES数据储存路径(保证该目录存在不存在则报错)
path.data: /usr/local/elastic/elasticsearch7/data
# ES运行日志文件路径(保证该目录存在不存在则报错)
path.logs: /usr/local/elastic/elasticsearch7/logs
# 需求锁住物理内存,避免操作系统的内存Swaping
bootstrap.memory_lock: true
# 外界访问ES ip地址(设置0.0.0.0表示可以通过该机器的任何ip访问)
network.host: 0.0.0.0
# 加入此配置可以解决集群的警告
network.publish_host: 10.16.101.27
# ES的访问端口号(不设置则默认为9200)
http.port: 9200
# 集群下所有机器的访问ES的url集合
discovery.seed_hosts: ["10.16.101.27:9300", "10.16.101.28:9300", "10.16.101.29:9300"]
# 集群下所有节点集合
cluster.initial_master_nodes: ["node-1", "node-2", "node-3"]

4 . 修改elasticsearch的VM配置

vi /usr/local/elastic/elasticsearch7/config/jvm.options

修改VM为机器内存的一半

启动elasticsearch

1.设置elasticsearch开机启动

# 切换到root用户
su  root
# 切换到/etc/rc.d/init.d目录
cd /etc/rc.d/init.d
# 编辑elasticsearch启动文件
vi elasticsearch
####################### 贴入下面的文本保存即可 ###############################
#!/bin/sh
#chkconfig: 2345 80 05
#description: elasticsearch 6.2.2
export JAVA_HOME=/usr/java/jdk11 
export ES_PATH=/usr/local/elastic/elasticsearch7
case "$1" in
start)
    su es<<!
    cd $ES_PATH
    ./bin/elasticsearch -d -p pid
!
    echo "elasticsearch startup"
    ;;  
stop)
    es_pid=`ps aux|grep elasticsearch | grep -v 'grep elasticsearch' | awk '{print $2}'`
    kill -9 $es_pid
    echo "elasticsearch stopped"
    ;;  
restart)
    es_pid=`ps aux|grep elasticsearch | grep -v 'grep elasticsearch' | awk '{print $2}'`
    kill -9 $es_pid
    echo "elasticsearch stopped"
    su es<<!
    cd $ES_PATH
    ./bin/elasticsearch -d -p pid
!
    echo "elasticsearch startup"
    ;;  
*)
    echo "start|stop|restart"
    ;;  
esac
exit $?

# 刚编辑的文件需要赋予权限
chmod -X elasticsearch 
# 添加到系统服务
chkconfig --add elasticsearch

# 开启服务
service elasticsearch start
# 停止服务
service elasticsearch stop
# 重启服务
service elasticsearch restart
# 设置开机启动
chkconfig elasticsearch on

在浏览器中输入 http://10.16.101.27:9200 代表安装成功
在这里插入图片描述查看集群是否成功 在浏览器输出入 http://10.16.101.27:9200/_cat/health?v 显示3节点代表成功

中文分词和拼音分词器安装

中文ik下载:https://github.com/medcl/elasticsearch-analysis-ik/releases
拼音分词器下载:https://github.com/medcl/elasticsearch-analysis-pinyin/releases

根据elasticsearch版本下载对应的分词器版本,必须版本对应

# 文件下载在root目录下
cd /root
#下载ik
wget https://github.com/medcl/elasticsearch-analysis-ik/releases/download/v7.7.0/elasticsearch-analysis-ik-7.7.0.zip
# 下载pinyin
wget https://github.com/medcl/elasticsearch-analysis-pinyin/releases/download/v7.7.0/elasticsearch-analysis-pinyin-7.7.0.zip

# 在elasticsearch 的plugins目录下新疆ik和pinyin文件夹
mkdir /usr/local/elastic/elasticsearch7/plugins/ik
mkdir /usr/local/elastic/elasticsearch7/plugins/pinyin
# unzip 将上面的2个zip直接解压到对应ik和pinyin目录下
unzip elasticsearch-analysis-ik-7.7.0.zip -d /usr/local/elastic/elasticsearch7/plugins/ik
unzip elasticsearch-analysis-pinyin-7.7.0.zip -d /usr/local/elastic/elasticsearch7/plugins/pinyin
# 赋予权限,重启elasticsearch
chown es:es -R /usr/local/elastic/elasticsearch7
service elasticsearch restart

使用crul命令,输入下面的URL地址,验证分词器是否成功

curl -X GET -H "Content-Type: application/json"  "http://localhost:9200/_analyze?pretty=true" -d'{"text":"中华五千年华夏"}';

若elasticsearch无法关闭,可使用kill -9 pid 强制关闭在重启

# 查看pid
ps aux|grep elasticsearch
# 强制关闭
kill -9 xx
# 启动elasticsearch
service elasticsearch start

安装浏览器ealsticsearch-head插件

ealsticsearch只是后端提供各种api,那么怎么直观的使用它呢?elasticsearch-head将是一款专门针对于elasticsearch的客户端工具
elasticsearch-head 需要nodejs的支持

1.下载安装nodejs

# 文件下载在root下
cd /root
# 下载最新稳定版nodejs
wget https://nodejs.org/dist/v16.15.1/node-v16.15.1-linux-x64.tar.xz
# 解压文件
tar xf node-v16.15.1-linux-x64.tar.xz
# 移动解压后目录到软件目录,并将目录重命名nodejs    
mv node-v16.15.1-linux-x64 /usr/local/nodejs
# 查看node的版本
/usr/local/nodejs/bin/node -v
# 配置环境变量
vim /etc/profile

#################################将下面文本贴入profile文件中保存###################
# 添加node_home变量
export NODE_HOME=/usr/local/nodejs
# 把node_home变量添加到环境变量中
export PATH=$PATH:$NODE_HOME/bin

# 重新加载一下配置文件使新的配置生效
source /etc/profile
# 查看nodejs版本
node -version

至此,centos7上的nodejs运行环境安装成功,下面我们安装elasticsearch-head

2.安装grunt构建工具

可以进行打包压缩、测试、执行等等的工作,head插件就是通过grunt启动的。因此需要安装grunt

# 切换到nodejs安装目录
cd /usr/local/nodejs
# 配置阿里镜像
npm config set registry https://registry.npm.taobao.org
# 安装grunt
npm install -g grunt-cli
# 查看是否安装成功
grunt -version

2.下载安装elasticsearch-head插件 GitHub - mobz/elasticsearch-head: A web front end for an elastic search cluster下载elasticsearch-head-master.zip,将文件拷贝到/root目录下

cd /root
# 解压elasticsearch-head-master
unzip elasticsearch-head-master.zip
# 将文件移动到/usr/local/elastic/elasticsearch-head目录
mv elasticsearch-head-master /usr/local/elastic/elasticsearch-head
# 切换到/usr/local/elastic/elasticsearch-head目录下
cd /usr/local/elastic/elasticsearch-head
# 编译elasticsearch-head
npm install
# 运行 elasticsearch-head 后台运行
nohup npm run start &

浏览器中输入上面的地址http://localhost:9100,如图说明head插件已经安装成功了。

在这里插入图片描述

上图不能显示集群健康值,需要在配置一下elasticsearch.yml

cd /usr/local/elastic/elasticsearch7/config
vi elasticsearch.yml
# 在elasticsearch.yml文件中加入下面配置,保存即可
http.cors.enabled: true 
http.cors.allow-origin: "*"
# 重启 elasticsearch
service elasticsearch restart

3.ealsticsearch-head 开机启动 

上面的配置ealsticsearch-head Xshell客户端关闭,后导致9100端口也关闭,所有必须配置开机自启动

cd /etc/init.d
# 新建elasticsearch-head启动脚本
vi elasticsearch-head
################## 写入下面的文本,根据自己时间安装情况配置#####################
#!/bin/sh
#chkconfig: 2345 80 05
#description: elasticsearch-head
# nodejs 安装的路径
export NODE_PATH=/usr/local/nodejs
export PATH=$PATH:$NODE_PATH/bin
# elasticsearch-head 的路径
cd /usr/local/elastic/elasticsearch-head
nohup npm run start >/usr/local/elastic/elasticsearch-head/nohup.out 2>&1 &
# 赋予 elasticsearch-head 权限
chmod +x elasticsearch-head
# 设置开机执行sh
chkconfig --add elasticsearch-head
# 也可手动启动
service elasticsearch-head start

启用x-pack验证

第一种

切换到es的用户下,使用下面命令生成证书

bin/elasticsearch-certutil cert -out config/elastic-certificates.p12 -pass ""

启动elasticsearch

./elasticsearch -d

自动生成默认用户和密码

bin/elasticsearch-setup-passwords auto
# 手动设置
# bin/elasticsearch-setup-passwords interactive

修改elastic超级用户密码

#  假设elastic 默认密码为 xxxxxxx
# curl -XPUT -u elastic:xxxxxxx 'http://localhost:9200/_xpack/security/user/elastic/_password' -d '{ "password" : "your_passwd" }'

浏览器验证

 

第二种

启动 Elasticsearch 程序

[elastic@console bin]$ ./elasticsearch -d
    future versions of Elasticsearch will require Java 11; your Java version from [/usr/java/jdk1.8.0_181/jre] does not meet this requirement

创建密码

[elastic@console bin]$ ./elasticsearch-setup-passwords interactive
future versions of Elasticsearch will require Java 11; your Java version from [/usr/java/jdk1.8.0_181/jre] does not meet this requirement

Unexpected response code [500] from calling GET http://192.168.108.126:9200/_security/_authenticate?pretty
It doesn't look like the X-Pack security feature is enabled on this Elasticsearch node.
Please check if you have enabled X-Pack security in your elasticsearch.yml configuration file.

ERROR: X-Pack Security is disabled by configuration.

需要设置 X-Pack

[elastic@console bin]$ vim ../config/elasticsearch.yml
    http.cors.enabled: true
    http.cors.allow-origin: "*"
    http.cors.allow-headers: Authorization
    xpack.security.enabled: true
    xpack.security.transport.ssl.enabled: true

添加密码

[elastic@console bin]$ ./elasticsearch-setup-passwords interactive
future versions of Elasticsearch will require Java 11; your Java version from [/usr/java/jdk1.8.0_181/jre] does not meet this requirement
Initiating the setup of passwords for reserved users elastic,apm_system,kibana,logstash_system,beats_system,remote_monitoring_user.
You will be prompted to enter passwords as the process progresses.
Please confirm that you would like to continue [y/N]y


Enter password for [elastic]:
Reenter password for [elastic]:
Passwords do not match.
Try again.
Enter password for [elastic]:
Reenter password for [elastic]:
Enter password for [apm_system]:
Reenter password for [apm_system]:
Enter password for [kibana]:
Reenter password for [kibana]:
Enter password for [logstash_system]:
Reenter password for [logstash_system]:
Enter password for [beats_system]:
Reenter password for [beats_system]:
Enter password for [remote_monitoring_user]:
Reenter password for [remote_monitoring_user]:
Changed password for user [apm_system]
Changed password for user [kibana]
Changed password for user [logstash_system]
Changed password for user [beats_system]
Changed password for user [remote_monitoring_user]
Changed password for user [elastic]

修改kibana

[root@console bin]# vim ../config/kibana.yml
	elasticsearch.username: "elastic"
	elasticsearch.password: "passwd"

 修改密码

POST /_security/user/elastic/_password
{
  "password": "123456"
}

修改密码之后,需要重新设置kibana的配置文件,才可以重新使用kibana

java 连接认证

package elasticSearch.highLevelClient;

import org.apache.http.HttpHost;
import org.apache.http.auth.AuthScope;
import org.apache.http.auth.UsernamePasswordCredentials;
import org.apache.http.client.CredentialsProvider;
import org.apache.http.impl.client.BasicCredentialsProvider;
import org.apache.http.impl.nio.client.HttpAsyncClientBuilder;
import org.elasticsearch.client.RestClient;
import org.elasticsearch.client.RestClientBuilder;
import org.elasticsearch.client.RestHighLevelClient;
import org.elasticsearch.client.XPackClient;

import java.io.IOException;

/**
 * @author [tu.tengfei]
 * @description
 * @date 2019/8/10
 */
public class ESHighClient {
    public static RestHighLevelClient client;
    public static void getESClient(){

//        client = new RestHighLevelClient(RestClient.builder(
//                new HttpHost("slave01", 9200, "http"),
//                new HttpHost("master01", 9200, "http")
//        ));

        //需要用户名和密码的认证
        final CredentialsProvider credentialsProvider = new BasicCredentialsProvider();
        credentialsProvider.setCredentials(AuthScope.ANY, new UsernamePasswordCredentials("elastic", "passwd"));
        RestClientBuilder restClientBuilder = RestClient.builder(new HttpHost("192.168.108.126", 9200, "http"))
                .setHttpClientConfigCallback(new RestClientBuilder.HttpClientConfigCallback() {
                    @Override
                    public HttpAsyncClientBuilder customizeHttpClient(HttpAsyncClientBuilder httpAsyncClientBuilder) {
                        return httpAsyncClientBuilder.setDefaultCredentialsProvider(credentialsProvider);
                    }
                });
        client = new RestHighLevelClient(restClientBuilder);
    }

    public static void clientClose(){
        if (client!=null){
            try {
                client.close();
            } catch (IOException e) {
                e.printStackTrace();
            }
        }
    }
}

 

 Kibana7.4用户管理

1.下载kibana以及修改相应配置

cd /opt
wget https://artifacts.elastic.co/downloads/kibana/kibana-7.4.2-linux-x86_64.tar.gz
tar -zxvf kibana-7.4.2-linux-x86_64.tar.gz

2.修改配置

cd /opt/kibana-7.4.2-linux-x86_64/config
vim kibana.yml

# 中文
i18n.locale: "zh-CN"
server.port: 15601
server.host: "0.0.0.0"
elasticsearch.hosts: ["http://192.168.18.126:19200"]
elasticsearch.username: "kibana_system"
elasticsearch.password: "xxxxx"
kibana.index: ".kibana"
xpack.reporting.encryptionKey: "a_random_string"
xpack.security.encryptionKey: "something_at_least_32_characters"
# 是否开启安全策略
# xpack.security.enabled: false

3.kibana用户管理

/opt/kibana-7.4.2-linux-x86_64/bin/kibana --allow-root

添加用户并赋予相应的权限
在这里插入图片描述 

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/1560918.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

【机器学习】数据探索---python主要的探索函数

在上一篇博客【机器学习】数据探索(Data Exploration)—数据质量和数据特征分析中&#xff0c;我们深入探讨了数据预处理的重要性&#xff0c;并介绍了诸如插值、数据归一化和主成分分析等关键技术。这些方法有助于我们清理数据中的噪声、消除异常值&#xff0c;以及降低数据的…

App.vue触发axios报错及解决方案

App.vue触发axios报错及解决方案 修改根目录下vue.config.js文件 module.exports {publicPath: ./,assetsDir: assets,configureWebpack: {devServer: {client: {overlay: false}}} }重新npm run dev 搞定

平台产品线 | 高频问题更新(2024.04.01)

平台产品线 | 高频问题更新(2024.04.01) 一、SuperMap iDesktopX 问题1&#xff1a;麻烦问一下&#xff0c;我有一个数据&#xff0c;想实现符号与标注记的最小显示级别不一样&#xff0c;如1级测站的符号第1级开始显示&#xff0c;但1级测站的注记从第2级才开始显示&#xf…

图片压缩到100k以内?快速压缩图片大小的方法

当您想要分享照片到社交媒体平台时&#xff0c;平台可能有上传文件大小的限制。您可能需要将照片压缩到符合平台要求的大小范围内&#xff0c;以便成功上传和分享照片&#xff0c;或者如果您的设备存储空间有限&#xff0c;您可能需要将照片压缩到较小的文件大小&#xff0c;以…

P1803 凌乱的yyy

凌乱的yyy / 线段覆盖 题目背景 快 noip 了&#xff0c;yyy 很紧张&#xff01; 题目描述 现在各大 oj 上有 n n n 个比赛&#xff0c;每个比赛的开始、结束的时间点是知道的。 yyy 认为&#xff0c;参加越多的比赛&#xff0c;noip 就能考的越好&#xff08;假的&#x…

RUST使用crates.io上的依赖完整教程

1.打开crates.io 2.搜索要使用的依赖,如rand 点击包名,进入包详情页面: 添加依赖方法有两种 1.使用cargo命令 2.直接修改Cargo.toml 使用cargo命令操作如下: 在工程目录执行如下命令: cargo add rand 执行完成后如自动向Cargo.toml中添加依赖如下: 手动修改Cargo.toml是…

CS224N第一课作业--词向量与共现矩阵

文章目录 Word Vectors1. import repos2. Read corpus and calculate co-occurrence matrices2-1 read_corpus2-2 vocabulary2-3 co occurrence matrices2-4. dimensionality reduction完整性检查 3. Prediction-Based Word Vectors余弦相似度 Word Vectors 1. import repos …

计算机网络——33多点访问协议

多点访问协议 多路访问链路和协议 两种类型的链路&#xff08;一个子网内部链路连接形式&#xff09; 点对点 拨号访问的PPP以太网交换机和主机之间的点对点链路 广播 传统以太网HFC上行链路802.11无线局域网 多路访问协议 单个共享的广播型链路 2个过更多结点同时传送&am…

使用pillow创建动态图形验证码

使用pillow创建动态图形验证码 #安装pillow模块&#xff1a;pip3 install pillow from PIL import Image,ImageDraw,ImageFont import random import stringdef id_code(width,height,bit,font_file,font_size):"""功能&#xff1a;生成随机图片验证码:param w…

Linux基本指令篇

在前边&#xff0c;我们已经了解过了Linux操作系统的发展和应用&#xff0c;从该篇起&#xff0c;就正式进入对Linux的学习。 今天我们就来在Xshell上远程登录我们的云服务器。首先我们要知道自己云服务器的公网ip&#xff0c;然后修改一下密码。 点击跳转 修改完密码之后我们…

项目级AIMS手术麻醉信息系统源码,C#手麻系统源码,应用案例+演示

手术麻醉信息系统可以实现手术室监护仪、麻醉机、呼吸机、输液泵等设备输出数据的自动采集&#xff0c;采集的数据能据如实准确地反映患者生命体征参数的变化&#xff0c;并实现信息高度共享&#xff0c;根据采集结果&#xff0c;综合其他患者数据&#xff0c;自动生成手术麻醉…

U8二次开发-钉钉集成

钉钉开放平台作为企业沟通和协作的重要工具,其技术的每一次迭代都为企业带来了新的机遇和挑战。随着企业对于高效沟通和智能化管理的需求日益增长,钉钉平台的SDK更新显得尤为重要。把传统的U8与钉钉平台集成,可以有效的将业务功能和角色进行前移,打破应用系统二八原则,即8…

第三方系统自动登录BBS For Discuz! X3.4/X3.5

apache安装 service apache2 restart PHP安装 php.info php.ini mysql安装 Discuz! X3.4/X3.5安装 跳转BBS 传参 写入BBS 登录BBS

一文教会女朋友学会日常Git使用!Git知识总结

文章目录 一文教会女朋友学会日常Git使用&#xff01;Git知识总结一、git基本知识了解1.git简介2.git区域了解3.git常用命令 二、常用工作场景1.克隆远程仓库&#xff0c;把仓库代码拉到本地2.推送代码到远程仓库&#xff08;1&#xff09;本地代码和远程仓库版本相同&#xff…

GCNet: 非局部网络与挤压-激励网络的融合与超越

摘要 非局部网络&#xff08;NLNet&#xff09;通过为每个查询位置聚合特定于查询的全局上下文&#xff0c;为捕获长距离依赖关系提供了一个开创性的方法。然而&#xff0c;经过严格的实证分析&#xff0c;我们发现非局部网络所建模的全局上下文在图像中的不同查询位置几乎相同…

分享 5 个提高技术领导力的技巧

技术领导力于很多人而言都是谜一般的存在。有观点认为&#xff0c;实战经验丰富的资深开发最终只有成为技术管理者才能继续成长。从某些方面来看&#xff0c;这可能是对的&#xff0c;但考虑到公司结构和规章制度等&#xff0c;想要完成从「个人贡献者」到「技术管理者」的跨越…

ModuleNotFoundError: No module named ‘utils.utils pytorch项目报错

首先呢会报错是因为引入的问题 代码是这样的但是sys.path.append的功能仅限当前的目录 sys.path.append("..") from utils.utils import MyDataset, validate, show_confMat应该加下面的文件路径 sys.path.append("..") from Code.utils.utils import My…

基于8086七路抢答器倒计时仿真设计

**单片机设计介绍&#xff0c;基于8086七路抢答器倒计时仿真设计 文章目录 一 概要二、功能设计三、 软件设计原理图 五、 程序六、 文章目录 一 概要 基于8086的七路抢答器倒计时仿真设计是一个结合了微处理器控制、抢答逻辑以及倒计时功能的综合性项目。该系统能够模拟七路抢…

【树状数组专题】【蓝桥杯备考训练】:数星星、动态求连续区间和、一个简单的整数问题、一个简单的整数问题2【已更新完成】

目录 1、数星星&#xff08;《信息学奥赛一本通》 & ural 1028&#xff09; 思路&#xff1a; 基本思路&#xff1a; 树状数组经典三函数&#xff1a; 1、lowbit()函数 2、query()函数 3、add()函数 最终代码&#xff1a; 2、动态求连续区间和&#xff08;《信息学奥赛一本…

智能仪器替代技术工程师重复工作 专注生产方案优化!

关键词&#xff1a;智能仪器,测径仪,测宽仪,测厚仪,直线度测量仪 在当今竞争激烈的市场环境下&#xff0c;企业需要不断提高生产效率和质量&#xff0c;以满足客户的需求。而技术工程师在生产过程中扮演着至关重要的角色&#xff0c;但他们的时间和精力往往被重复的工作所占据&…