Re: VINUM should be operational w/ DEVFS now

看板DFBSD_kernel作者時間16年前 (2009/08/17 18:32), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串2/3 (看更多)
Matt, as far as I can tell, finding a device by its serial number via getsynthvnode should work already. It calls disklocate, which in turn calls devfs_find_device_by_name. devfs_find_device_by_name first iterates the cdev_t list, and if nothing is found by the given name, it iterates the alias list to match the name. If an alias is found, then the cdev to which it points is returned. So as long as make_dev_alias has already been called, one can call getsynthvnode directly and it will work for serial numbers, as long as "serno/" is prepended, as this is the alias' name. To sum it up, prepending "serno/" to your call to getsynthvnode, if you look for a serial number, should do the job. Cheers, Alex Hornung 2009/8/15 Matthew Dillon <dillon@apollo.backplane.com>: > =A0 =A0The vinum softraid driver should now be operational with devfs > =A0 =A0in the master repo. =A0vinum should now be able to handle full 64 = bit > =A0 =A0geometries (multi-terrabyte disk subsystems). > > =A0 =A0In addition, vinum configurations may reference devices by serial > =A0 =A0number or devtab label. =A0for example: > > =A0 =A0 =A0 =A0drive drive0 device raid0.s1d > =A0 =A0 =A0 =A0drive drive1 device raid1.s1d > =A0 =A0 =A0 =A0drive drive2 device raid2.s1d > =A0 =A0 =A0 =A0drive drive3 device raid3.s1d > =A0 =A0 =A0 =A0volume myvol > =A0 =A0 =A0 =A0 =A0 =A0plex org raid5 128k > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0sd drive drive0 length 50g > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0sd drive drive1 length 50g > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0sd drive drive2 length 50g > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0sd drive drive3 length 50g > > =A0 =A0And in /etc/devtab: > > =A0 =A0 =A0 =A0raid0 =A0 =A0 =A0 =A0 =A0 serno =A0 WD-WCAVY0248702 > =A0 =A0 =A0 =A0raid1 =A0 =A0 =A0 =A0 =A0 serno =A0 WD-WCAVY0250739 > =A0 =A0 =A0 =A0raid2 =A0 =A0 =A0 =A0 =A0 serno =A0 WD-WCAVY0245831 > =A0 =A0 =A0 =A0raid3 =A0 =A0 =A0 =A0 =A0 serno =A0 WD-WCAVY0246122 > > =A0 =A0The vinum configuration stored on-media stores translated values, > =A0 =A0so on-media the devices will be stored by serial number. =A0e.g. > =A0 =A0/dev/serno/WD-WCAVY0246122. > > =A0 =A0vinum roots may or may not still be broken, only because we do not > =A0 =A0have a getsynthvnode() function which can find a drive by its seri= al > =A0 =A0number. > > =A0 =A0Generally speaking, anyone using vinum will want to reference devi= ces > =A0 =A0by serial number now to avoid renumbering problems. > > =A0 =A0TASKS STILL TO DO (any takers?): > > =A0 =A0* Add a feature to getsynthvnode() to locate a drive by its serial > =A0 =A0 =A0numbers. > > =A0 =A0* Add general disk_create() support for vinum volumes. =A0vinum > =A0 =A0 =A0historically insisted on being the partition manager for files= ystems, > =A0 =A0 =A0but that isn't always convenient. > > =A0 =A0* RAID-5 issues. =A0vinum isn't smart about RAID-5. =A0Have you ev= ery > =A0 =A0 =A0tried to rebuild parity on a 10TB vinum drive? =A0We may need = a > =A0 =A0 =A0SOC project to fix this... that is, sub-divide the space into > =A0 =A0 =A0smaller chunks and keep track of activity in the chunks so a r= ebuild > =A0 =A0 =A0does not have to rebuild the entire freaking topology. > > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 =A0-Matt > >
文章代碼(AID): #1AYJ6eQG (DFBSD_kernel)
文章代碼(AID): #1AYJ6eQG (DFBSD_kernel)