目录

工欲善其事

实践出真知

活跃标签: linux java mysql 待分类 js springboot win10 电路 vue macOS nginx esp32 git docker windows idea maven esp8266 python Arduino

存档:

存档: 2022 年 07 月 (3)

SpringBoot 注入静态变量的三种方式、从yml中读取参数

Spring Boot读取properties配置文件中的数据 Spring Boot最常用的3种读取properties****配置文件中数据的方法: 1、使用@Value注解读取 读取properties配置文件时,默认读取的是application.properties。 application.properties: import org.springframework.beans.factory.annotation.Value; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; @RestController public class GatewayController { @Value("${demo.name}") private String name; @Value("${demo.age}") private String age; @RequestMapping(....

修复MySql表出现Table 'XXX' is marked as crashed and should be repaired 的方法

首先用root进入数据库,列如出现问题的表名为XXX 检查 check table XXX 修复 repair table XXX

Linux 硬盘篇

硬盘温度查看 hddtemp /dev/sda hddtemp不存在可以使用apt-get或yum安装 硬盘使用寿命查看 smartctl -a /dev/sda |grep 'Power_On_Hours' smartmontools用apt安装没找到用编译安装的 https://nchc.dl.sourceforge.net/project/smartmontools/smartmontools/7.3/smartmontools-7.3.tar.gz