pool
尝试在 TrueNAS Core 中创建时出现此错误。
[EFAULT] Failed to wipe disk ada1: [EFAULT] Command gpart create -s gpt /dev/ada1 failed (code 1): gpart: Input/output error
这是我的设置:
- Windows 10 Pro 作为主机
- TrueNAS Core 12.0 托管在 VirtualBox 6.1 中
- 通过 VirtualBox 连接到 TrueNAS 的 2TB VHD 作为主从设备
TrueNAS 中的“存储”>“磁盘”下可以识别 2TB 磁盘。
但在尝试创建存储 > 池 > 创建时出现以下错误
[EFAULT] Failed to wipe disk ada1: [EFAULT] Command gpart create -s gpt /dev/ada1 failed (code 1): gpart: Input/output error
Error: Traceback (most recent call last):
File "/usr/local/lib/python3.8/site-packages/middlewared/job.py", line 361, in run
await self.future
File "/usr/local/lib/python3.8/site-packages/middlewared/job.py", line 397, in __run_body
rv = await self.method(*([self] + args))
File "/usr/local/lib/python3.8/site-packages/middlewared/schema.py", line 973, in nf
return await f(*args, **kwargs)
File "/usr/local/lib/python3.8/site-packages/middlewared/plugins/pool.py", line 655, in do_create
formatted_disks = await self.middleware.call('pool.format_disks', job, disks)
File "/usr/local/lib/python3.8/site-packages/middlewared/main.py", line 1238, in call
return await self._call(
File "/usr/local/lib/python3.8/site-packages/middlewared/main.py", line 1195, in _call
return await methodobj(*prepared_call.args)
File "/usr/local/lib/python3.8/site-packages/middlewared/plugins/pool_/format_disks.py", line 56, in format_disks
await asyncio_map(format_disk, disks.items(), limit=16)
File "/usr/local/lib/python3.8/site-packages/middlewared/utils/asyncio_.py", line 16, in asyncio_map
return await asyncio.gather(*futures)
File "/usr/local/lib/python3.8/site-packages/middlewared/utils/asyncio_.py", line 13, in func
return await real_func(arg)
File "/usr/local/lib/python3.8/site-packages/middlewared/plugins/pool_/format_disks.py", line 29, in format_disk
await self.middleware.call(
File "/usr/local/lib/python3.8/site-packages/middlewared/main.py", line 1238, in call
return await self._call(
File "/usr/local/lib/python3.8/site-packages/middlewared/main.py", line 1206, in _call
return await self.run_in_executor(prepared_call.executor, methodobj, *prepared_call.args)
File "/usr/local/lib/python3.8/site-packages/middlewared/main.py", line 1110, in run_in_executor
return await loop.run_in_executor(pool, functools.partial(method, *args, **kwargs))
File "/usr/local/lib/python3.8/site-packages/middlewared/utils/io_thread_pool_executor.py", line 25, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/local/lib/python3.8/site-packages/middlewared/plugins/disk_/format.py", line 25, in format
raise CallError(f'Failed to wipe disk {disk}: {job.error}')
middlewared.service_exception.CallError: [EFAULT] Failed to wipe disk ada1: [EFAULT] Command gpart create -s gpt /dev/ada1 failed (code 1):
gpart: Input/output error
答案1
我创建了一个 VDI 格式的虚拟硬盘,这次成功了。VHD 格式由于未知原因无法工作。