openEuler24.03 LTS下安裝MySQL8.0.42

目錄

前提步驟

刪除原有mysql及maridb數據庫

安裝MySQL

啟動MySQL

啟動查看MySQL狀態

設置MySQL開機自啟動

查看登錄密碼

登錄MySQL

修改密碼及支持遠程連接

遠程連接MySQL


前提步驟

擁有openEuler24.03 LTS環境,可參考:Vmware下安裝openEuler24.03 LTS

刪除原有mysql及maridb數據庫

如果原來有mysql或maridb數據庫,請先備份數據,再進行刪除操作。

$ sudo rpm -qa | grep -i 'mysql\|mariadb' | xargs -n1 sudo rpm -e --nodeps 2>/dev/null$ sudo rm -rf /var/lib/mysql* /var/log/mysql /usr/lib64/mysql /etc/my.cnf* /usr/my.cnf

操作過程如下

[liang@node1 ~]$ sudo rpm -qa | grep -i 'mysql\|mariadb' | xargs -n1 sudo rpm -e --nodeps 2>/dev/null
[liang@node1 ~]$ sudo rm -rf /var/lib/mysql* /var/log/mysql /usr/lib64/mysql /etc/my.cnf* /usr/my.cnf

安裝MySQL

直接使用yum命令安裝mysql服務

$ sudo yum install -y mysql-server

操作過程如下

[liang@node1 ~]$ sudo yum install -y mysql-server
OS                                                  2.0 kB/s | 2.1 kB     00:01
everything                                           13 kB/s | 2.7 kB     00:00
EPOL                                                 12 kB/s | 2.3 kB     00:00
debuginfo                                            10 kB/s | 2.2 kB     00:00
source                                              9.3 kB/s | 2.6 kB     00:00
update                                              8.0 kB/s | 2.2 kB     00:00
update-source                                        11 kB/s | 2.2 kB     00:00
Dependencies resolved.
====================================================================================Package                       Arch    Version                    Repository   Size
====================================================================================
Installing:mysql-server                  x86_64  8.0.42-1.oe2403sp1         update       32 M
Installing dependencies:abseil-cpp                    x86_64  20230802.1-6.oe2403sp1     update      508 kcheckpolicy                   x86_64  3.5-1.oe2403sp1            OS          293 kmecab                         x86_64  0.996-2.oe2403sp1          everything  375 kmysql                         x86_64  8.0.42-1.oe2403sp1         update       13 Mmysql-common                  x86_64  8.0.42-1.oe2403sp1         update       26 kmysql-config                  x86_64  8.0.42-1.oe2403sp1         update      6.5 kmysql-errmsg                  x86_64  8.0.42-1.oe2403sp1         update      574 kmysql-selinux                 noarch  1.0.10-1.oe2403sp1         everything   31 kpolicycoreutils-python-utils  noarch  3.5-3.oe2403sp1            OS           22 kprotobuf-lite                 x86_64  25.1-7.oe2403sp1           OS          215 kpython3-IPy                   noarch  1.01-2.oe2403sp1           OS           44 kpython3-audit                 x86_64  1:3.1.2-7.oe2403sp1        OS           76 kpython3-libselinux            x86_64  3.5-3.oe2403sp1            OS          174 kpython3-libsemanage           x86_64  3.5-1.oe2403sp1            OS           71 kpython3-policycoreutils       noarch  3.5-3.oe2403sp1            OS          2.2 Mpython3-setools               x86_64  4.4.3-1.oe2403sp1          OS          657 kTransaction Summary
====================================================================================
Install  17 PackagesTotal download size: 51 M
Installed size: 263 M
Downloading Packages:
(1/17): policycoreutils-python-utils-3.5-3.oe2403sp  85 kB/s |  22 kB     00:00
(2/17): python3-IPy-1.01-2.oe2403sp1.noarch.rpm     382 kB/s |  44 kB     00:00
(3/17): checkpolicy-3.5-1.oe2403sp1.x86_64.rpm      715 kB/s | 293 kB     00:00
(4/17): protobuf-lite-25.1-7.oe2403sp1.x86_64.rpm   445 kB/s | 215 kB     00:00
(5/17): python3-libselinux-3.5-3.oe2403sp1.x86_64.r 2.0 MB/s | 174 kB     00:00
(6/17): python3-audit-3.1.2-7.oe2403sp1.x86_64.rpm  132 kB/s |  76 kB     00:00
(7/17): python3-libsemanage-3.5-1.oe2403sp1.x86_64. 102 kB/s |  71 kB     00:00
(8/17): mecab-0.996-2.oe2403sp1.x86_64.rpm          1.3 MB/s | 375 kB     00:00
(9/17): mysql-selinux-1.0.10-1.oe2403sp1.noarch.rpm 496 kB/s |  31 kB     00:00
(10/17): python3-policycoreutils-3.5-3.oe2403sp1.no 1.8 MB/s | 2.2 MB     00:01
(11/17): python3-setools-4.4.3-1.oe2403sp1.x86_64.r 765 kB/s | 657 kB     00:00
(12/17): mysql-common-8.0.42-1.oe2403sp1.x86_64.rpm 111 kB/s |  26 kB     00:00
(13/17): mysql-config-8.0.42-1.oe2403sp1.x86_64.rpm 120 kB/s | 6.5 kB     00:00
(14/17): abseil-cpp-20230802.1-6.oe2403sp1.x86_64.r 614 kB/s | 508 kB     00:00
(15/17): mysql-errmsg-8.0.42-1.oe2403sp1.x86_64.rpm 1.7 MB/s | 574 kB     00:00
(16/17): mysql-8.0.42-1.oe2403sp1.x86_64.rpm        963 kB/s |  13 MB     00:14
(17/17): mysql-server-8.0.42-1.oe2403sp1.x86_64.rpm 1.7 MB/s |  32 MB     00:19
------------------------------------------------------------------------------------
Total                                               2.3 MB/s |  51 MB     00:22
retrieving repo key for OS unencrypted from http://repo.openeuler.org/openEuler-24.03-LTS-SP1/OS/x86_64/RPM-GPG-KEY-openEuler
OS                                                  4.9 kB/s | 3.0 kB     00:00
Importing GPG key 0xB675600B:Userid     : "openeuler <openeuler@compass-ci.com>"Fingerprint: 8AA1 6BF9 F2CA 5244 010D CA96 3B47 7C60 B675 600BFrom       : http://repo.openeuler.org/openEuler-24.03-LTS-SP1/OS/x86_64/RPM-GPG-KEY-openEuler
Key imported successfully
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transactionPreparing        :                                                            1/1Installing       : python3-libselinux-3.5-3.oe2403sp1.x86_64                 1/17Installing       : mysql-config-8.0.42-1.oe2403sp1.x86_64                    2/17Installing       : mysql-common-8.0.42-1.oe2403sp1.x86_64                    3/17Installing       : abseil-cpp-20230802.1-6.oe2403sp1.x86_64                  4/17Installing       : protobuf-lite-25.1-7.oe2403sp1.x86_64                     5/17Installing       : mysql-8.0.42-1.oe2403sp1.x86_64                           6/17Installing       : mysql-errmsg-8.0.42-1.oe2403sp1.x86_64                    7/17Installing       : python3-libsemanage-3.5-1.oe2403sp1.x86_64                8/17Installing       : python3-setools-4.4.3-1.oe2403sp1.x86_64                  9/17Installing       : mecab-0.996-2.oe2403sp1.x86_64                           10/17Running scriptlet: mecab-0.996-2.oe2403sp1.x86_64                           10/17Installing       : python3-audit-1:3.1.2-7.oe2403sp1.x86_64                 11/17Installing       : python3-IPy-1.01-2.oe2403sp1.noarch                      12/17Running scriptlet: checkpolicy-3.5-1.oe2403sp1.x86_64                       13/17Installing       : checkpolicy-3.5-1.oe2403sp1.x86_64                       13/17Running scriptlet: checkpolicy-3.5-1.oe2403sp1.x86_64                       13/17Installing       : python3-policycoreutils-3.5-3.oe2403sp1.noarch           14/17Installing       : policycoreutils-python-utils-3.5-3.oe2403sp1.noarch      15/17Running scriptlet: mysql-selinux-1.0.10-1.oe2403sp1.noarch                  16/17Installing       : mysql-selinux-1.0.10-1.oe2403sp1.noarch                  16/17Running scriptlet: mysql-selinux-1.0.10-1.oe2403sp1.noarch                  16/17
libsemanage.semanage_direct_install_info: Overriding mysql module at lower priority 100 with module at priority 200.Running scriptlet: mysql-server-8.0.42-1.oe2403sp1.x86_64                   17/17Installing       : mysql-server-8.0.42-1.oe2403sp1.x86_64                   17/17Running scriptlet: mysql-server-8.0.42-1.oe2403sp1.x86_64                   17/17Running scriptlet: mysql-selinux-1.0.10-1.oe2403sp1.noarch                  17/17Running scriptlet: mysql-server-8.0.42-1.oe2403sp1.x86_64                   17/17
/usr/lib/tmpfiles.d/dbus.conf:13: Line references path below legacy directory /var/run/, updating /var/run/dbus/containers → /run/dbus/containers; please update the tmpfiles.d/ drop-in file accordingly.Verifying        : checkpolicy-3.5-1.oe2403sp1.x86_64                        1/17Verifying        : policycoreutils-python-utils-3.5-3.oe2403sp1.noarch       2/17Verifying        : protobuf-lite-25.1-7.oe2403sp1.x86_64                     3/17Verifying        : python3-IPy-1.01-2.oe2403sp1.noarch                       4/17Verifying        : python3-audit-1:3.1.2-7.oe2403sp1.x86_64                  5/17Verifying        : python3-libselinux-3.5-3.oe2403sp1.x86_64                 6/17Verifying        : python3-libsemanage-3.5-1.oe2403sp1.x86_64                7/17Verifying        : python3-policycoreutils-3.5-3.oe2403sp1.noarch            8/17Verifying        : python3-setools-4.4.3-1.oe2403sp1.x86_64                  9/17Verifying        : mecab-0.996-2.oe2403sp1.x86_64                           10/17Verifying        : mysql-selinux-1.0.10-1.oe2403sp1.noarch                  11/17Verifying        : abseil-cpp-20230802.1-6.oe2403sp1.x86_64                 12/17Verifying        : mysql-8.0.42-1.oe2403sp1.x86_64                          13/17Verifying        : mysql-common-8.0.42-1.oe2403sp1.x86_64                   14/17Verifying        : mysql-config-8.0.42-1.oe2403sp1.x86_64                   15/17Verifying        : mysql-errmsg-8.0.42-1.oe2403sp1.x86_64                   16/17Verifying        : mysql-server-8.0.42-1.oe2403sp1.x86_64                   17/17Installed:abseil-cpp-20230802.1-6.oe2403sp1.x86_64checkpolicy-3.5-1.oe2403sp1.x86_64mecab-0.996-2.oe2403sp1.x86_64mysql-8.0.42-1.oe2403sp1.x86_64mysql-common-8.0.42-1.oe2403sp1.x86_64mysql-config-8.0.42-1.oe2403sp1.x86_64mysql-errmsg-8.0.42-1.oe2403sp1.x86_64mysql-selinux-1.0.10-1.oe2403sp1.noarchmysql-server-8.0.42-1.oe2403sp1.x86_64policycoreutils-python-utils-3.5-3.oe2403sp1.noarchprotobuf-lite-25.1-7.oe2403sp1.x86_64python3-IPy-1.01-2.oe2403sp1.noarchpython3-audit-1:3.1.2-7.oe2403sp1.x86_64python3-libselinux-3.5-3.oe2403sp1.x86_64python3-libsemanage-3.5-1.oe2403sp1.x86_64python3-policycoreutils-3.5-3.oe2403sp1.noarchpython3-setools-4.4.3-1.oe2403sp1.x86_64Complete!

啟動MySQL

$ sudo systemctl start mysqld

啟動查看MySQL狀態

[liang@node1 ~]$ sudo systemctl status mysqld
● mysqld.service - MySQL 8.0 database serverLoaded: loaded (/usr/lib/systemd/system/mysqld.service; disabled; preset: disa>Active: active (running) since Wed 2025-05-07 22:59:59 CST; 3min 7s agoProcess: 2811 ExecStartPre=/usr/libexec/mysql-check-socket (code=exited, status>Process: 2834 ExecStartPre=/usr/libexec/mysql-prepare-db-dir mysqld.service (co>Main PID: 2912 (mysqld)Status: "Server is operational"Tasks: 37 (limit: 21353)Memory: 473.3M ()CGroup: /system.slice/mysqld.service└─2912 /usr/libexec/mysqld --basedir=/usr5月 07 22:59:54 node1 systemd[1]: Starting MySQL 8.0 database server...
5月 07 22:59:55 node1 mysql-prepare-db-dir[2834]: Initializing MySQL database
5月 07 22:59:59 node1 systemd[1]: Started MySQL 8.0 database server.
lines 1-15/15 (END)

看到Active: active (running),說明mysql服務正常啟動。

q鍵返回命令行。

設置MySQL開機自啟動

[liang@node1 ~]$ sudo systemctl enable mysqld
Created symlink /etc/systemd/system/multi-user.target.wants/mysqld.service → /usr/lib/systemd/system/mysqld.service.

查看登錄密碼

[liang@node1 ~]$ sudo cat /var/log/mysql/mysqld.log
2025-05-07T14:59:55.041414Z 0 [System] [MY-013169] [Server] /usr/libexec/mysqld (mysqld 8.0.42) initializing of server in progress as process 2869
2025-05-07T14:59:55.046791Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2025-05-07T14:59:55.301970Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
2025-05-07T14:59:55.986953Z 6 [Warning] [MY-010453] [Server] root@localhost is created with an empty password ! Please consider switching off the --initialize-insecure option.
2025-05-07T14:59:58.680076Z 0 [System] [MY-010116] [Server] /usr/libexec/mysqld (mysqld 8.0.42) starting as process 2912
2025-05-07T14:59:58.689207Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2025-05-07T14:59:59.073809Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
2025-05-07T14:59:59.317924Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.
2025-05-07T14:59:59.317946Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
2025-05-07T14:59:59.340722Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Bind-address: '::' port: 33060, socket: /var/lib/mysql/mysqlx.sock
2025-05-07T14:59:59.340759Z 0 [System] [MY-010931] [Server] /usr/libexec/mysqld: ready for connections. Version: '8.0.42'  socket: '/var/lib/mysql/mysql.sock'  port: 3306  Source distribution.

輸出看到[Server] root@localhost is created with an empty password !,說明初始密碼為空。

登錄MySQL

$ mysql -uroot -p

提示輸入密碼,因為是空密碼,不需要輸入任何信息直接回車,進入mysql命令行。

操作過程如下

[liang@node1 ~]$ mysql -uroot -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 8
Server version: 8.0.42 Source distributionCopyright (c) 2000, 2025, Oracle and/or its affiliates.Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.mysql>

測試使用MySQL命令

mysql> show databases;
+--------------------+
| Database           |
+--------------------+
| information_schema |
| mysql              |
| performance_schema |
| sys                |
+--------------------+
4 rows in set (0.00 sec)mysql> quit;
Bye
[liang@node1 ~]$

修改密碼及支持遠程連接

mysql> set password='000000';
mysql> update mysql.user set host='%' where user='root';
mysql> flush privileges;

操作過程如下

[liang@node1 ~]$ mysql -uroot -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 9
Server version: 8.0.42 Source distributionCopyright (c) 2000, 2025, Oracle and/or its affiliates.Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.mysql> set password='000000';
Query OK, 0 rows affected (0.01 sec)mysql> update mysql.user set host='%' where user='root';
Query OK, 1 row affected (0.00 sec)
Rows matched: 1  Changed: 1  Warnings: 0mysql> flush privileges;
Query OK, 0 rows affected (0.01 sec)mysql> quit;
Bye
[liang@node1 ~]$

使用新密碼登錄

[liang@node1 ~]$ mysql -uroot -p000000
mysql: [Warning] Using a password on the command line interface can be insecure.
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 10
Server version: 8.0.42 Source distributionCopyright (c) 2000, 2025, Oracle and/or its affiliates.Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.mysql>

遠程連接MySQL

使用navicat等工具遠程連接mysql

完成!enjoy it!

本文來自互聯網用戶投稿,該文觀點僅代表作者本人,不代表本站立場。本站僅提供信息存儲空間服務,不擁有所有權,不承擔相關法律責任。
如若轉載,請注明出處:http://www.pswp.cn/diannao/83517.shtml
繁體地址,請注明出處:http://hk.pswp.cn/diannao/83517.shtml
英文地址,請注明出處:http://en.pswp.cn/diannao/83517.shtml

如若內容造成侵權/違法違規/事實不符,請聯系多彩編程網進行投訴反饋email:809451989@qq.com,一經查實,立即刪除!

相關文章

idea 保證舊版本配置的同時,如何從低版本升到高版本

文章目錄 前言idea 保證舊版本配置的同時,如何從低版本升到高版本1. 備份項目2. 下載最新的idea3. 安裝安裝包4. 導入idea2019舊配置5. 驗證前言 如果您覺得有用的話,記得給博主點個贊,評論,收藏一鍵三連啊,寫作不易啊^ _ ^。 ??而且聽說點贊的人每天的運氣都不會太差,…

填坑記: 古董項目Apache POI 依賴異常排除

當你看到NoSuchMethodError的時候&#xff0c;不要慌&#xff0c;深呼吸&#xff0c;這可能只是JAR包版本的問題… 引子&#xff1a;一個平靜的周二下午 那是一個看似平常的周二下午&#xff0c;系統運行良好&#xff0c;開發團隊在有條不紊地推進著新功能的開發。突然&#x…

CAPL Class: TcpSocket (此類用于實現 TCP 網絡通信 )

目錄 Class: TcpSocketacceptopenclosebindconnectgetLastSocketErrorgetLastSocketErrorAsStringlistenreceivesendsetSocketOptionshutdown函數調用的基本流程服務器端的基本流程客戶端的基本流程Class: TcpSocket學習筆記。來自CANoe幫助文檔。 Class: TcpSocket accept /…

微信小程序的開發及問題解決

HttpClient 測試例子 SpringBootTest public class HttpClientTest {/*** 測試通過httpclient發送get方式的請求*/Testpublic void testGET() throws IOException {//創建httpclient對象CloseableHttpClient httpClient HttpClients.createDefault();//創建請求對象HttpGet ht…

foreach中使用await的問題

目錄 1.說明 2.示例 3.解決方案 1.說明 在foreach中調用異步方法&#xff0c;即使使用了await&#xff0c;不會依次執行每個異步任務&#xff0c;也就是說Array.prototype.forEach不會等待 Promise 完成&#xff0c;即使你在回調函數中返回一個 Promise&#xff0c;forEach …

Linux調試生成核心存儲文件

1.核心存儲文件配置&#xff1a; 不知道理解對不對&#xff0c;Linux中的核心存儲文件的配置是在/proc/sys/kernel/core_pattern中的&#xff0c;使用 cat /proc/sys/kernel/core_pattern # 打印出 |/usr/share/apport/apport -p%p -s%s -c%c -d%d -P%P -u%u -g%g -- %E表示核…

Compose筆記(二十三)--多點觸控

這一節主要了解一下Compose中多點觸控&#xff0c;在Jetpack Compose 中&#xff0c;多點觸控處理需要結合Modifier和手勢API來實現&#xff0c;一般通過組合 pointerInput、TransformableState 和 TransformModifier 來創建支持縮放、旋轉和平移的組件。 一、 API 1. Pointer…

【Java ee初階】HTTP(4)

構造HTTP請求 1&#xff09;開發中&#xff0c;前后端交互。瀏覽器運行的網頁中&#xff0c;構造出HTTP請求 2&#xff09;調試階段&#xff0c;通過構造HTTP請求測試服務器 樸素的方案&#xff1a; 通過tcp socket 的方式構造HTTP請求 按照HTTP請求格式&#xff0c;往TCP…

STM32 __main

STM32開發中__main與用戶main()函數的本質區別及工作機制 在STM32開發中&#xff0c;__main和用戶定義的main()函數是啟動過程中的兩個關鍵節點&#xff0c;分別承擔運行時初始化和用戶程序入口的職責。以下是它們的核心差異及協作機制&#xff1a; 一、定義與層級差異 ?__ma…

什么是PMBus

一、PMBus的定義與背景 PMBus&#xff08;Power Management Bus&#xff0c;電源管理總線&#xff09; 是一種基于SMBus&#xff08;System Management Bus&#xff09;的開放標準數字通信協議&#xff0c;專為電源設備的監控、配置和控制設計。由PMBus聯盟&#xff08;現并入…

Python OOP核心技巧:如何正確選擇實例方法、類方法和靜態方法

Python方法類型全解析&#xff1a;實例方法、類方法與靜態方法的使用場景 一、三種方法的基本區別二、訪問能力對比表三、何時使用實例方法使用實例方法的核心場景&#xff1a;具體應用場景&#xff1a;1. 操作實例屬性2. 對象間交互3. 實現特定實例的行為 四、何時使用類方法使…

業務中臺-典型技術棧選型(微服務、容器編排、分布式數據庫、消息隊列、服務監控、低代碼等)

在企業數字化中臺建設中&#xff0c;業務中臺是核心支撐平臺&#xff0c;旨在通過技術手段將企業核心業務能力抽象、標準化和復用&#xff0c;以快速響應前端業務需求。其核心技術流涉及從業務抽象到服務化、治理和持續優化的全流程。以下是業務中臺建設中的核心技術體系及關鍵…

期望是什么:(無數次的均值,結合概率)21/6=3.5

https://seeing-theory.brown.edu/basic-probability/cn.html 期望是什么:(無數次的均值,結合概率)21/6=3.5 一、期望(數學概念) 在概率論和統計學中,**期望(Expectation)**是一個核心概念,用于描述隨機變量的長期平均取值,反映隨機變量取值的集中趨勢。 (一…

matlab官方免費下載安裝超詳細教程2025最新matlab安裝教程(MATLAB R2024b)

文章目錄 準備工作MATLAB R2024b 安裝包獲取詳細安裝步驟1. 文件準備2. 啟動安裝程序3. 配置安裝選項4. 選擇許可證文件5. 設置安裝位置6. 選擇組件7. 開始安裝8. 完成輔助設置 常見問題解決啟動失敗問題 結語 準備工作 本教程將幫助你快速掌握MATLAB R2024b的安裝技巧&#x…

第3章 自動化測試:從單元測試到硬件在環(HIL)

在前兩章中,我們已完成從環境搭建到流水線編譯的自動化配置。為了真正保障軟件質量、降低回歸風險,本章將聚焦測試自動化,涵蓋從最基礎的單元測試,到集成測試,再到硬件在環(Hardware-in-the-Loop, HIL)測試的全流程。通過腳本驅動、測試報告可視化和與 CI 平臺深度集成,…

信息收集+初步漏洞打點

目標&#xff1a;理解信息收集在滲透測試中的意義&#xff0c;熟悉常用工具用法&#xff0c;完成基本打點測試 一.理論學習&#xff1a; 模塊內容說明信息收集分類主動信息收集 vs 被動信息收集目標發現子域名、IP、端口、子站點、目錄、接口技術指紋識別Web框架&#xff08;如…

uniapp+vue3開發項目之引入vuex狀態管理工具

前言&#xff1a; 我們在vue2的時候常用的狀態管理工具就是vuex&#xff0c;vue3開發以后&#xff0c;又多了一個pinia的選項&#xff0c;相對更輕便&#xff0c;但是vuex也用的非常多的&#xff0c;這里簡單說下在uni-app中vuex的使用。 實現步驟&#xff1a; 1、安裝&#x…

淺談“量子計算應用:從基礎原理到行業破局”

量子計算應用:從基礎原理到行業破局 引言:量子計算為何成為科技革命新引擎? 量子計算利用量子力學原理(疊加態、糾纏態、量子干涉)突破經典計算的極限,在特定領域可實現指數級加速。根據中研普華預測,2025年全球量子計算市場規模將突破80億美元,2035年可達8117億美元。…

UNiAPP地區選擇

<template> <view class"container"> <!-- 左側地區列表 --> <scroll-view class"left-list" scroll-y :scroll-into-view"currentLetterId" scroll-with-animation scroll"…

嵌入式硬件篇---CAN

文章目錄 前言1. CAN協議基礎1.1 物理層特性差分信號線終端電阻通信速率總線拓撲 1.2 幀類型1.3 數據幀格式 2. STM32F103RCT6的CAN硬件配置2.1 硬件連接2.2 CubeMX配置啟用CAN1模式波特率引腳分配過濾器配置&#xff08;可選&#xff09; 3. HAL庫代碼實現3.1 CAN初始化3.2 發…