CentOS 8使用笔记

查看磁盘空间

bash 复制代码
df -h

查看python版本

bash 复制代码
python3 --version

查看某个端口是否打开

bash 复制代码
nc -zv localhost 9200

或者

bash 复制代码
curl http://localhost:9200

添加端口并刷新

bash 复制代码
firewall-cmd --zone=public --add-port=9200/tcp --permanent
firewall-cmd --reload

启动Elasic Search服务,进入ES对应的bin目录,执行:

bash 复制代码
./elasticsearch

linux操作系统不能识别在windows操作系统中用Pycharm构建的venv

Linux operating systems cannot directly recognize a Python virtual environment (venv) created in Windows due to differences in file paths and executable formats between the two operating systems. When moving a project from Windows to Linux, you would typically need to recreate the virtual environment on the Linux system. This involves copying your project files (excluding the venv directory) to the Linux system, and then running python -m venv venv and pip install -r requirements.txt commands in your project directory on the Linux system to recreate the environment and install all required dependencies.

相关推荐
伊布拉西莫8 分钟前
【流畅的Python】第20章:并发执行器 — 学习笔记
笔记·python·学习
IT策士13 分钟前
Redis 从入门到精通:Python 操作 Redis
redis·python·bootstrap
编码者卢布20 分钟前
【Azure AI Search】 searchMode=any 和 searchMode=all 有什么区别?
人工智能·python·flask
Samooyou27 分钟前
大模型微调(Fine Tuning)
人工智能·python·ai·语言模型
qq_85730581929 分钟前
python语法
开发语言·python·算法
AI行业学习42 分钟前
CC-Switch v3.16.1 官方下载 | 安装配置详细教程【2026.6.10】
java·开发语言·vue.js·python·mysql·eclipse·html
早起CaiCai1 小时前
【Pytorch 实践1】手写数字
人工智能·pytorch·python
吴梓穆1 小时前
Python 语法基础 函数
开发语言·python
Kobebryant-Manba1 小时前
学习文本处理
开发语言·python
m0_617493942 小时前
PaddleOCR报错:OneDnnContext does not have the input Filter 解决方案汇总
python