首頁 資料庫 mysql教程 二进制安装MySQL5.5.39,磁盘空间不足导致MySQL无法启动_MySQL

二进制安装MySQL5.5.39,磁盘空间不足导致MySQL无法启动_MySQL

Jun 01, 2016 pm 01:02 PM
二進位 磁碟 空間

--添加用户和组 [root@zlm local]# groupadd
[root@zlm local]# useradd -g mysql -s /sbin/nologin -d /opt/msyql mysql
--创建目录 [root@zlm local]# mkdir /data/mysql/mysql_3306/{data,logs,tmp} -p
--做软链接到/usr/local/mysql [root@zlm local]# ln -s /opt/mysql/mysql-5.5.39-linux2.6-i686/ mysql [root@zlm local]# ll -l mysql lrwxrwxrwx 1 root root 38 Sep 24 00:12 mysql -> /opt/mysql/mysql-5.5.39-linux2.6-i686/

--赋权限 [root@zlm local]# chown -R mysql:mysql /data/mysql/ [root@zlm local]# chown -R mysql:mysql /usr/local/mysql/
--添加环境变量 [root@zlm local]# echo 'export PATH=$PATH:/usr/local/mysql/bin' >> /etc/profile [root@zlm local]# cd mysql
--初始化数据库 [root@zlm mysql]# ./scripts/mysql_install_db --user=mysql --defaults-file=/etc/my.cnf Installing MySQL system tables... 140924 0:12:43 [Warning] options --log-slow-admin-statements, --log-queries-not-using-indexes and --log-slow-slave-statements have no effect if --log_slow_queries is not set OK Filling help tables... 140924 0:12:44 [Warning] options --log-slow-admin-statements, --log-queries-not-using-indexes and --log-slow-slave-statements have no effect if --log_slow_queries is not set OK
To start mysqld at boot time you have to copy support-files/mysql.server to the right place for your system
PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER ! To do so, start the server, then issue the following commands:
/usr/local/mysql/bin/mysqladmin -u root password 'new-password' /usr/local/mysql/bin/mysqladmin -u root -h zlm password 'new-password'
Alternatively you can run: /usr/local/mysql/bin/mysql_secure_installation
which will also give you the option of removing the test databases and anonymous user created by default. This is strongly recommended for production servers.
See the manual for more instructions.
You can start the MySQL daemon with: cd /usr/local/mysql ; /usr/local/mysql/bin/mysqld_safe &
You can test the MySQL daemon with mysql-test-run.pl cd /usr/local/mysql/mysql-test ; perl mysql-test-run.pl
Please report any problems at http://bugs.mysq?l.com/
--复制mysql.server文件到/etc/init.d/下并改名为mysql [root@zlm mysql]# cp support-files/mysql.server /etc/init.d/mysql cp: overwrite `/etc/init.d/mysql'? yes
--启动MySQL [root@zlm mysql]# service mysql start Starting MySQL...............The server quit without updating PID file (/data/mysql/mysql_3306/data/zlm.pid). [FAILED]
--查看错误日志error.log(如未在/etc/my.cnf中定义,默认格式为hostname.err) [root@zlm local]# cd /data/mysql/mysql_3306/data/
[root@zlm data]# ll total 403024 -rw-rw---- 1 mysql mysql 2824 Sep 24 00:13 error.log -rw-rw---- 1 mysql mysql 104857600 Sep 24 00:13 ibdata1 -rw-rw---- 1 mysql mysql 104857600 Sep 24 00:13 ib_logfile0 -rw-rw---- 1 mysql mysql 104857600 Sep 24 00:13 ib_logfile1 -rw-rw---- 1 mysql mysql 97685504 Sep 24 00:13 ib_logfile2 drwx------ 2 mysql root 4096 Sep 24 00:12 mysql drwx------ 2 mysql mysql 4096 Sep 24 00:12 performance_schema drwx------ 2 mysql root 4096 Sep 24 00:12 test [root@zlm data]# cat error.log 140924 00:13:33 mysqld_safe Starting mysqld daemon with databases from /data/mysql/mysql_3306/data 140924 0:13:33 [Warning] options --log-slow-admin-statements, --log-queries-not-using-indexes and --log-slow-slave-statements have no effect if --log_slow_queries is not set 140924 0:13:33 [Warning] Using unique option prefix myisam_recover instead of myisam-recover-options is deprecated and will be removed in a future release. Please use the full name instead. 140924 0:13:33 [Note] Plugin 'FEDERATED' is disabled. 140924 0:13:33 InnoDB: The InnoDB memory heap is disabled 140924 0:13:33 InnoDB: Mutexes and rw_locks use InnoDB's own implementation 140924 0:13:33 InnoDB: Compressed tables use zlib 1.2.3 140924 0:13:33 InnoDB: Using Linux native AIO 140924 0:13:33 InnoDB: Initializing buffer pool, size = 128.0M 140924 0:13:33 InnoDB: Completed initialization of buffer pool InnoDB: The first specified data file ./ibdata1 did not exist: InnoDB: a new database to be created! 140924 0:13:33 InnoDB: Setting file ./ibdata1 size to 100 MB InnoDB: Database physically writes the file full: wait... InnoDB: Progress in MB: 100 140924 0:13:40 InnoDB: Log file ./ib_logfile0 did not exist: new to be created InnoDB: Setting log file ./ib_logfile0 size to 100 MB InnoDB: Database physically writes the file full: wait... InnoDB: Progress in MB: 100 140924 0:13:43 InnoDB: Log file ./ib_logfile1 did not exist: new to be created InnoDB: Setting log file ./ib_logfile1 size to 100 MB InnoDB: Database physically writes the file full: wait... InnoDB: Progress in MB: 100 140924 0:13:44 InnoDB: Log file ./ib_logfile2 did not exist: new to be created InnoDB: Setting log file ./ib_logfile2 size to 100 MB InnoDB: Database physically writes the file full: wait... InnoDB: Progress in MB:140924 0:13:45 InnoDB: Error: Write to file ./ib_logfile2 failed at offset 0 97517568. InnoDB: 1048576 bytes should have been written, only 167936 were written. InnoDB: Operating system error number 2. InnoDB: Check that your OS and file system support files of this size. InnoDB: Check also that the disk is not full or a disk quota exceeded. InnoDB: Error number 2 means 'No such file or directory'. InnoDB: Some operating system error numbers are described at InnoDB: http://dev.mysql.com/doc/refman/5.5/en/operating-system-error-codes.html InnoDB: Error in creating ./ib_logfile2: probably out of disk space 140924 0:13:45 [ERROR] Plugin 'InnoDB' init function returned error. 140924 0:13:45 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed. 140924 0:13:45 [ERROR] Unknown/unsupported storage engine: InnoDB 140924 0:13:45 [ERROR] Aborting
140924 0:13:45 [Note] /usr/local/mysql/bin/mysqld: Shutdown complete
140924 00:13:45 mysqld_safe mysqld from pid file /data/mysql/mysql_3306/data/zlm.pid ended [root@zlm data]# perror 2 --perror是用于查询Linux错误代码的命令 OS error code 2: No such file or directory [root@zlm data]# df -h Filesystem Size Used Avail Use% Mounted on /dev/mapper/VolGroup00-LogVol00 7.7G 7.3G 0 100% / --磁盘空间使用率100%,没有剩余空间了 /dev/sda1 99M 12M 82M 13% /boot tmpfs 506M 0 506M 0% /dev/shm
--关机添加磁盘 [root@zlm data]# init 0 [root@zlm ~]# rm -rf /data --先删除掉现有的/data目录中全部数据,因为重新挂载后也会丢失的,提前先释放掉这部分空间 [root@zlm ~]# fdisk -l
Disk /dev/sda: 10.7 GB, 10737418240 bytes 255 heads, 63 sectors/track, 1305 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/sda1 * 1 13 104391 83 Linux /dev/sda2 14 1305 10377990 8e Linux LVM
Disk /dev/sdb: 5368 MB, 5368709120 bytes --增加了1个5G的磁盘 255 heads, 63 sectors/track, 652 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Disk /dev/sdb doesn't contain a valid partition table --还未分区
--对新添加的磁盘分区 [root@zlm ~]# fdisk /dev/sdb
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel Building a new DOS disklabel. Changes will remain in memory only, until you decide to write them. After that, of course, the previous content won't be recoverable.
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)
Command (m for help): n Command action e extended p primary partition (1-4) p Partition number (1-4): 1 First cylinder (1-652, default 1): Using default value 1 Last cylinder or +size or +sizeM or +sizeK (1-652, default 652): Using default value 652
Command (m for help): w The partition table has been altered!
Calling ioctl() to re-read partition table. Syncing disks.
--查看磁盘信息 [root@zlm ~]# fdisk -l
Disk /dev/sda: 10.7 GB, 10737418240 bytes 255 heads, 63 sectors/track, 1305 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/sda1 * 1 13 104391 83 Linux /dev/sda2 14 1305 10377990 8e Linux LVM
Disk /dev/sdb: 5368 MB, 5368709120 bytes 255 heads, 63 sectors/track, 652 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System /dev/sdb1 1 652 5237158+ 83 Linux --分完区了
--格式化ext3文件系统 [root@zlm ~]# mkfs.ext3 /dev/sdb1
mke2fs 1.39 (29-May-2006) Filesystem label= OS type: Linux Block size=4096 (log=2) Fragment size=4096 (log=2) 655360 inodes, 1309289 blocks 65464 blocks (5.00%) reserved for the super user First data block=0 Maximum filesystem blocks=1342177280 40 block groups 32768 blocks per group, 32768 fragments per group 16384 inodes per group Superblock backups stored on blocks: 32768, 98304, 163840, 229376, 294912, 819200, 884736
Writing inode tables: done Creating journal (32768 blocks): done Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 21 mounts or 180 days, whichever comes first. Use tune2fs -c or -i to override. [root@zlm ~]# mkdir /data/mysql/mysql_3306/{data,logs,tmp} -p [root@zlm ~]# mount /dev/sdb1 /data [root@zlm ~]# df -h Filesystem Size Used Avail Use% Mounted on /dev/mapper/VolGroup00-LogVol00 7.7G 6.9G 398M 95% / --可以看到,重启完以后又释放了一部分空间 /dev/sda1 99M 12M 82M 13% /boot tmpfs 506M 0 506M 0% /dev/shm /dev/sdb1 5.0G 139M 4.6G 3% /data --/data目录已经挂载到新增的5G磁盘上去了
--为了使挂载持久化,重启后依然不会丢失,需要修改/etc/fstab [root@zlm ~]# vi /etc/fstab /dev/VolGroup00/LogVol00 / ext3 defaults 1 1 /dev/VolGroup00/LogVol00 / ext3 defaults 1 1 LABEL=/boot /boot ext3 defaults 1 2 tmpfs /dev/shm tmpfs defaults 0 0 devpts /dev/pts devpts gid=5,mode=620 0 0 sysfs /sys sysfs defaults 0 0 proc /proc proc defaults 0 0 /dev/VolGroup00/LogVol01 swap swap defaults 0 0 /data /dev/sdb1 ext3 defaults 0 0 --在文件末尾加入这一行,指定挂载的目录与磁盘的对应关系
--重新创建/data下面的相关目录 [root@zlm ~]# cd /data/ [root@zlm data]# ll total 1
drwx------ 2 root root 16384 Sep 24 00:32 lost+found
[root@zlm data]# rm -rf lost+found [root@zlm data]# ll total 0
[root@zlm data]# mkdir /data/mysql/mysql_3306/{data,logs,tmp} -p
--重新赋权限后初始化数据库 [root@zlm mysql]# pwd /usr/local/mysql [root@zlm mysql]# chown -R mysql:mysql /data/mysql/
[root@zlm mysql]# ./scripts/mysql_install_db --user=mysql --defaults-file=/etc/my.cnf

注意必须是先给/data目录赋予权限后再初始化,否则会报错,因为/data目录是重新创建并挂载到sdb1磁盘分区上的 如: Installation of system tables failed! Examine the logs in /data/mysql/mysql_3306/data for more information.
--再次重启MySQL服务 [root@zlm mysql]# service mysql start Starting MySQL........... [ OK ] [root@zlm mysql]# mysql Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 1 Server version: 5.5.39-log MySQL Community Server (GPL)
Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.
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.
(testing)root@localhost [(none)]> exit Bye [root@zlm mysql]# ps aux|grep mysql root 2744 0.4 0.1 4528 1276 pts/0 S 00:54 0:00 /bin/sh /usr/local/mysql/bin/mysqld_safe --datadir=/data/mysql/mysql_3306/data --pid-file=/data/mysql/mysql_3306/data/zlm.pid mysql 3452 3.2 3.4 319580 35472 pts/0 Sl 00:55 0:03 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/data/mysql/mysql_3306/data --plugin-dir=/usr/local/mysql/lib/plugin --user=mysql --log-error=/data/mysql/mysql_3306/data/error.log --open-files-limit=8192 --pid-file=/data/mysql/mysql_3306/data/zlm.pid --socket=/tmp/mysql.sock --port=3306 root 3493 0.0 0.0 3912 672 pts/0 R+ 00:56 0:00 grep mysql [root@zlm mysql]# mysqladmin shutdown [root@zlm mysql]# ps aux|grep mysql root 3501 0.0 0.0 3912 668 pts/0 R+ 00:56 0:00 grep mysql [root@zlm mysql]#
第2种启动方式: [root@zlm mysql]# /etc/init.d/mysql start Starting MySQL...... [ OK ] [root@zlm mysql]#
第3种启动方式: [root@zlm mysql]# mysqld_safe --defaults-file=/etc/my.cnf & [1] 4612 [root@zlm mysql]# Starting mysqld daemon with databases from /data/mysql/mysql_3306/data STOPPING server from pid file /data/mysql/mysql_3306/data/zlm.pid 140924 01:09:02 mysqld ended
这里启动失败了,查看error.log,提示说xxx参数设置得不合理,如: [root@zlm mysql]# cat error.log 140924 01:03:00 mysqld started
140924 1:03:00 [ERROR] /usr/libexec/mysqld: unknown variable 'slow_query_log_file=slow.log'
140924 01:03:00 mysqld ended
140924 01:04:54 mysqld started 140924 1:04:54 [ERROR] /usr/libexec/mysqld: unknown variable 'slow_query_log=0'
140924 01:04:54 mysqld ended
140924 01:05:39 mysqld started Unknown suffix '.' used for variable 'long_query_time' (value '0.5') 140924 1:05:39 [ERROR] /usr/libexec/mysqld: Error while setting value '0.5' to 'long_query_time'
140924 01:05:39 mysqld ended
140924 01:06:26 mysqld started 140924 1:06:26 [ERROR] /usr/libexec/mysqld: unknown variable 'min_examined_row_limit=100'
140924 01:06:26 mysqld ended
140924 01:09:02 mysqld started 140924 1:09:02 [ERROR] /usr/libexec/mysqld: unknown variable 'general_log_file=general.log'
140924 01:09:02 mysqld ended
造成这个问题的原因其实是我之前在安装RHEL 5.3操作系统的时候,选了系统盘里自带的那个mysql-5.0.45-7.el5 rpm包引起的,即便已经删除掉了。这个rpm包安装后会拷贝mysqld到/usr/libexec/目录下,很多在MySQL 5.5中可以识别的参数,在MySQL 5.0中是不认的,所以造成启动失败,一直提示"unknown variable",比方说以下这些: table_definition_cache table_open_cache slow_query_log_file
slow_query_log
long_query_time
min_examined_row_limit ...
解决办法:
--用新版本的mysqld可执行文件去覆盖掉原来/usr/libexec下的mysqld以后,就能用mysqld_safe & 的方式启动了
[root@zlm mysql]# cp /usr/local/mysql/bin/mysqld /usr/libexec/mysqld
cp: overwrite `/usr/libexec/mysqld'? yes
[root@zlm mysql]# mysqld_safe --defaults-file=/etc/my.cnf &
[1] 4687 Starting mysqld daemon with databases from /data/mysql/mysql_3306/data
这里会一直停在这一行,按ctrl+c可以重新返回到shell命令行
--查看mysql进程 [root@zlm mysql]# ps aux|grep mysql root 4687 0.0 0.1 4484 1152 pts/0 S 01:10 0:00 /bin/sh /usr/bin/mysqld_safe --defaults-file=/etc/my.cnf mysql 4721 0.0 3.1 329828 32704 pts/0 Sl 01:10 0:00 /usr/libexec/mysqld --defaults-file=/etc/my.cnf --basedir=/usr/local/mysql --datadir=/data/mysql/mysql_3306/data --user=mysql --pid-file=/data/mysql/mysql_3306/data/zlm.pid --skip-external-locking --port=3306 --socket=/tmp/mysql.sock root 4768 0.0 0.0 3912 668 pts/0 R+ 01:25 0:00 grep mysql
可以看到,用mysqld_safe方式,也已经启动成功了,注意,用这种方式启动,比单纯用mysqld方式启动要更佳,即使去kill掉mysqld的进程后,mysqld_safe可以保证mysqld进程重启
[root@zlm mysql]# ps aux | grep mysql root 5134 0.5 0.1 4484 1152 pts/0 S 01:32 0:00 /bin/sh /usr/bin/mysqld_safe --defaults-file=/etc/my.cnf mysql 5171 2.4 3.1 319584 32708 pts/0 Sl 01:32 0:00 /usr/libexec/mysqld --defaults-file=/etc/my.cnf --basedir=/usr/local/mysql --datadir=/data/mysql/mysql_3306/data --user=mysql --pid-file=/data/mysql/mysql_3306/data/zlm.pid --skip-external-locking --port=3306 --socket=/tmp/mysql.sock root 5193 0.0 0.0 3912 668 pts/0 R+ 01:32 0:00 grep mysql [root@zlm mysql]# kill -9 5171 [root@zlm mysql]# /usr/bin/mysqld_safe: line 388: 5171 Killed nohup /usr/libexec/mysqld --defaults-file=/etc/my.cnf --basedir=/usr/local/mysql --datadir=/data/mysql/mysql_3306/data --user=mysql --pid-file=/data/mysql/mysql_3306/data/zlm.pid --skip-external-locking --port=3306 --socket=/tmp/mysql.sock >> error.log 2>&1
Number of processes running now: 0 140924 01:32:54 mysqld restarted 按ctrl+c返回到shell命令行
[root@zlm mysql]# ps -ef | grep mysql root 5134 2531 0 01:32 pts/0 00:00:00 /bin/sh /usr/bin/mysqld_safe --defaults-file=/etc/my.cnf mysql 5205 5134 0 01:32 pts/0 00:00:00 /usr/libexec/mysqld --defaults-file=/etc/my.cnf --basedir=/usr/local/mysql --datadir=/data/mysql/mysql_3306/data --user=mysql --pid-file=/data/mysql/mysql_3306/data/zlm.pid --skip-external-locking --port=3306 --socket=/tmp/mysql.sock root 5229 2531 0 01:33 pts/0 00:00:00 grep mysql
mysqld_safe进程依然还是5134,但刚才被kill掉的mysqld进程5171已经变成5205这个新的进程了,其实mysqld_safe就是mysqld的守护进程,用来保证mysqld的正常运行的,当我们执行mysqld_safe &来启动MySQL的时候,其实最终还是去调用mysqld这个命令的
本網站聲明
本文內容由網友自願投稿,版權歸原作者所有。本站不承擔相應的法律責任。如發現涉嫌抄襲或侵權的內容,請聯絡admin@php.cn

熱AI工具

Undresser.AI Undress

Undresser.AI Undress

人工智慧驅動的應用程序,用於創建逼真的裸體照片

AI Clothes Remover

AI Clothes Remover

用於從照片中去除衣服的線上人工智慧工具。

Undress AI Tool

Undress AI Tool

免費脫衣圖片

Clothoff.io

Clothoff.io

AI脫衣器

Video Face Swap

Video Face Swap

使用我們完全免費的人工智慧換臉工具,輕鬆在任何影片中換臉!

熱工具

記事本++7.3.1

記事本++7.3.1

好用且免費的程式碼編輯器

SublimeText3漢化版

SublimeText3漢化版

中文版,非常好用

禪工作室 13.0.1

禪工作室 13.0.1

強大的PHP整合開發環境

Dreamweaver CS6

Dreamweaver CS6

視覺化網頁開發工具

SublimeText3 Mac版

SublimeText3 Mac版

神級程式碼編輯軟體(SublimeText3)

熱門話題

Java教學
1664
14
CakePHP 教程
1422
52
Laravel 教程
1316
25
PHP教程
1267
29
C# 教程
1239
24
在 Windows 11 上設定 RAID 1 的步驟 在 Windows 11 上設定 RAID 1 的步驟 Sep 22, 2023 pm 03:05 PM

Windows11有嚴格的要求,在努力取得該儲存空間之後,遺失硬碟和資料將是一個遺憾。好吧,我們帶來了好消息,可以幫助您緩衝硬碟故障。使用內建的Windows工具,您可以將所有資料從一個磁碟機複製到另一個磁碟機。這樣,如果一個磁碟機發生故障,您可以在替換磁碟機上鏡像和重建原始資料。 Windows11可以做RAID嗎?使用Windows儲存空間功能,您可以在Windows11上執行RAID。此功能可讓您使用直接連接到電腦的硬碟建立多個虛擬磁碟,而不會降低效能。突襲的好處:降低因磁碟

將VirtualBox固定磁碟轉換為動態磁碟,反之亦然 將VirtualBox固定磁碟轉換為動態磁碟,反之亦然 Mar 25, 2024 am 09:36 AM

在建立虛擬機器時,系統會要求您選擇磁碟類型,您可以選擇固定磁碟或動態磁碟。如果您選擇了固定磁碟,後來意識到需要動態磁碟,或者相反,該怎麼辦?好!你可以把一種轉換成另一種。在這篇文章中,我們將看到如何將VirtualBox固定磁碟轉換為動態磁碟,反之亦然。動態磁碟是一種虛擬硬碟,它最初具有較小的大小,隨著您在虛擬機器中儲存數據,其大小會相應增長。動態磁碟在節省儲存空間方面非常高效,因為它們只佔用所需的主機儲存空間。然而,隨著磁碟容量的擴展,可能會稍微影響電腦的效能。固定磁碟和動態磁碟是虛擬機器中常用的

如何在 Windows 11 上將動態磁碟轉換為基本磁碟 如何在 Windows 11 上將動態磁碟轉換為基本磁碟 Sep 23, 2023 pm 11:33 PM

如果要在Windows11中將動態磁碟轉換為基本磁碟,則應先建立備份,因為該程序將擦除其中的所有資料。為什麼要在Windows11中將動態磁碟轉換為基本磁碟?根據Microsoft,動態磁碟已從Windows中棄用,不再建議使用。此外,Windows家庭版不支援動態磁碟,因此您將無法存取這些邏輯磁碟機。如果要將更多磁碟合併到更大的磁碟區中,建議使用基本磁碟或儲存空間。在本文中,我們將向您展示如何在Windows11上將動態磁碟轉換為基本磁碟如何在Windows11中將動態磁碟轉換為基本磁碟?在開始

如何在 Windows 11 上 RAID 外接硬碟 如何在 Windows 11 上 RAID 外接硬碟 Sep 16, 2023 pm 10:05 PM

RAID或獨立磁碟冗餘陣列是一種資料儲存技術,其中多個外部磁碟機組合成一個。當大型硬碟價格昂貴時,它被廣泛使用,但許多人仍然更喜歡RAID外部硬碟的方法。 RAID有幾個級別,每個級別都用於特定目的。請記住,普通用戶不必深入了解複雜性,RAID0或RAID1的簡單設定應該可以正常工作。考慮突襲外部驅動器的原因:改進了電腦的性能易於配置,比現有替代方案便宜更快的資料讀取和寫入透過鏡像實現有效的備份解決方案如何在Windows11上RAID外部驅動器?在RAID外部硬碟之前,需要注意以下幾個先

在 Windows 11 上實作鏡像磁碟區的三種方法 在 Windows 11 上實作鏡像磁碟區的三種方法 Sep 18, 2023 pm 04:25 PM

驅動器故障是一個嚴重的問題,它可能會使您的檔案無法復原或啟動磁碟機無法運作,因此這就是為什麼許多使用者選擇在Windows11上建立鏡像磁碟區作為防止這種情況的原因。如果您不熟悉,鏡像磁碟區是另一個磁碟機的精確副本,它可以在磁碟故障時用作備份。這是一個很棒的備份解決方案,今天我們將向您展示如何在PC上建立它。設定鏡像卷的先決條件是什麼?兩個大小相似的動態磁碟。鏡像驅動器可以大於來源驅動器。 RAID支持,幾乎每台現代PC都可用。鏡像驅動器應未分配且沒有任何磁碟區。如何在Windows11中建立鏡像磁碟區? 1.使用

機器學習基礎之數字上的距離:點在空間中的距離 機器學習基礎之數字上的距離:點在空間中的距離 Apr 11, 2023 pm 11:40 PM

本文轉載自微信公眾號「活在資訊時代」,作者活在資訊時代。轉載本文請聯絡活在資訊時代公眾號。在機器學習中,一個基礎的概念就是如何判斷兩個樣本之間的差異,以便能夠評估兩個樣本之間的相似性和類別等資訊。而判斷這種相似性的測量就是兩個樣本在特徵空間內的距離。根據資料特徵的不同,度量方法有很多種。一般而言,對兩個資料樣本x,y,定義一個函數d(x,y),如果定義其為兩個樣本之間的距離,那麼d(x,y)則需要滿足以下幾個基本性質:非負性:d(x,y)>=0同一性:d(x,y)=0 ⇔ x=y對

掌握Ubuntu系統中的磁碟使用情況的方法 掌握Ubuntu系統中的磁碟使用情況的方法 Jan 03, 2024 pm 11:13 PM

我們在系統要查看硬碟使用的情況,Ubuntu系統該怎麼查看呢?下面我們就來看看,Ubuntu系統查看硬碟佔用率的教學。 1、在系統上,點選桌面左下角,如圖示。 2、在系統,點選實用程式,如圖示。 3.點選磁盤使用量,如圖所示。 4.那麼即可看到磁碟使用的情況,就是中間的磁碟就是你電腦硬碟,如圖示。磁碟下面的小字就是使用情況。 5、或點選實用程式上的磁盤,如圖示。 6.那麼在容量這裡,看得到硬碟使用情況,如圖示。以下是文字版本檢視磁碟的使用:df-h結果如下:FilesystemSizeUsedAvailU

如何在 Ubuntu 上新增交換空間 22.04 LTS 如何在 Ubuntu 上新增交換空間 22.04 LTS Feb 20, 2024 am 11:12 AM

交換空間在Linux系統中扮演著重要角色,特別是在系統記憶體不足時。它充當一個備用的記憶體儲存空間,可以幫助系統平穩運行,即使在負載高的情況下也能保持穩定性。本文為您提供了在Ubuntu22.04LTS上新增交換空間的詳細指南,以確保您的系統效能經過最佳化並能應付各種工作負載。了解交換空間交換空間提供虛擬內存,用於補充系統的實體RAM。當系統的RAM不足時,核心會將資料交換到磁碟,以防止記憶體不足和系統崩潰。 Linux系統常用交換空間來處理這種情況。同時運行多個內存密集型應用程式處理非常大的檔案或數據

See all articles