来吧兄弟,一起玩一起讨论!
您需要 登录 才可以下载或查看,没有账号?注册
×
本帖最后由 jimmyjin 于 2020-2-11 19:50 编辑
在帖子http://www.gebi1.com/thread-295316-1-1.html 里我讨论了如何像白裙DS918+一样使用Nvme SSD 做缓存, 这篇说的是如何用Nvme SSD做存储空间目前的限制是只能做单盘basic空间, 怎么做多盘RAID1, RAID5我还要研究一下。
这是在我的万兆网卡下的SMB读写速度:
写到最后下降了 ,因为这块东芝RC500 250G SSD的SLC模拟缓存用完了.......
建立NVme存储分区的步骤:
不好意思, 我就原文copy reddit论坛里面的内容了, 能操作的, 自然看得懂这点英文, 看不懂的,我觉得没有办法避免误操作的风险(毁原有存储空间), 还是不要试了。 我故意不返程
Login as root with SSH (I use putty in Windows) and type :
You will see the /dev/nvme0n1 or /dev/nvme1n1 depend on which slot you install the SSD. type:
You wil see the disk information. ( if your SSD at slot 2, use /dev/nvme1n1 instead) Disk /dev/nvme0n1: 238.5 GiB, 256060514304 bytes, 500118192 sectorsUnits: sectors of 1 * 512 = 512 bytesSector size (logical/physical): 512 bytes / 512 bytesI/O size (minimum/optimal): 512 bytes / 512 bytesNow, create partition. Type: synopartition --part /dev/nvme0n1 12and answer 'Y' if you confirm Device Sectors (Version8: SupportRaid) /dev/nvme0n11 4980480 (2431 MB) /dev/nvme0n12 4194304 (2048 MB)Reserved size: 260352 ( 127 MB)Primary data partition will be created.WARNING: This action will erase all data on '/dev/nvme0n1' and repart it, are you sure to continue? [y/N]yCleaning all partitions...Creating sys partitions...Creating primary data partition...Please remember to mdadm and mkfs new partitions.it will create the partition that follow DSM required layout.
Type
You will see the partition layout is created Disk /dev/nvme0n1: 238.5 GiB, 256060514304 bytes, 500118192 sectorsUnits: sectors of 1 * 512 = 512 bytesSector size (logical/physical): 512 bytes / 512 bytesI/O size (minimum/optimal): 512 bytes / 512 bytesDisklabel type: dosDisk identifier: 0xef61a3e4Device Boot Start End Sectors Size Id Type/dev/nvme0n1p1 2048 4982527 4980480 2.4G fd Linux raid autodetect/dev/nvme0n1p2 4982528 9176831 4194304 2G fd Linux raid autodetect/dev/nvme0n1p3 9437184 500103449 490666266 234G fd Linux raid autodetect
Create Basic Disk
I have only tried to create Basic Disk Volume as I have only one SSD. For other type of volume/storage pool (RAID0, RAID1, SHR) , I have not tested.
For Basic Disk, it need to create a single partition RAID1 device in order for DSM to recognize it. (as this is what DSM Storage Manager will do when create a Basic Disk Volume)
Type
To see your current RAID setup Personalities : [linear] [raid0] [raid1] [raid10] [raid6] [raid5] [raid4]md2 : active raid1 sda3[0] sdb3[1] 5855700544 blocks super 1.2 [2/2] [UU]md3 : active raid1 sdc3[0] sdd3[1] 9761614848 blocks super 1.2 [2/2] [UU]md1 : active raid1 sda2[0] sdb2[1] sdc2[2] sdd2[3] 2097088 blocks [4/4] [UUUU]md0 : active raid1 sda1[0] sdb1[3] sdc1[1] sdd1[2] 2489920 blocks [4/4] [UUUU]AFAIK, md0 is system partition and md1 is system swap. You current volume/storage pool will start at md2.
To current your NVME Basic disk, type: - mdadm --create /dev/md4 --level=1 --raid-devices=1 --force /dev/nvme0n1p3
复制代码
(if md4 already exist, you should use next md number)And answer y mdadm: Note: this array has metadata at the start and may not be suitable as a boot device. If you plan to store '/boot' on this device please ensure that your boot-loader understands md/v1.x metadata, or use --metadata=0.90Continue creating array? ymdadm: Defaulting to version 1.2 metadatamdadm: array /dev/md5 started.
Create Filesystem
Type mke2fs 1.42.6 (21-Sep-2012)Filesystem label=1.42.6-23824OS type: LinuxBlock size=4096 (log=2)Fragment size=4096 (log=2)Stride=0 blocks, Stripe width=0 blocks15335424 inodes, 61333024 blocks25600 blocks (0.04%) reserved for the super userFirst data block=0Maximum filesystem blocks=22103982081872 block groups32768 blocks per group, 32768 fragments per group8192 inodes per groupSuperblock backups stored on blocks: 32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208, 4096000, 7962624, 11239424, 20480000, 23887872Allocating group tables: doneWriting inode tables: doneCreating journal (32768 blocks): doneWriting superblocks and filesystem accounting information: doneif need btrfs, type
which can use for vm storage
After format complete , type rebootand after the machine bootup, you will see the Volume in DSM Storage Manager
没有回复可见内容, 不用回复“ 谢谢分享”, 我反对回复可见机制
|