# zpool import fails while disk and pool have online status



## gesmith1031 (Sep 23, 2014)

While preparing to move a ZFS pool to another server chassis I did an `zfs export` while in multi-user mode. Hindsight I should have have done this from a rescue disk.

After the export, which failed, I rebooted and have never been able to import the pool since. All of the disk and the pool are in an on-line state. Since the hardware seems fine I suspect the problem could corruption with ZFS meta data but haven't been able to pin point anything. I only get the 
	
	



```
cannot import 'rpool': I/O error
```
. 

Does anyone have any suggestions for bringing the pool back online? Is it possible to recovery a broken ZFS pool? 

truss() output: http://pastebin.com/DSDpuR1i
`gpart list`: http://pastebin.com/Wxgr2PMx

I set this up using FreeBSD9 and I believe this is ZFS v28.

As a side note I know I should have had backups. The reason I did not was more about money than anything else. The plan was to move this pool to a new Norco chassis and add in an equal number of disks for another pool to mirror to. Making such a change was taking a chance so I admit I know I only have myself to blame. 


```
root@nas01:~ # zpool import
   pool: rpool
	 id: 15664112288097167104
  state: ONLINE
 status: The pool was last accessed by another system.
 action: The pool can be imported using its name or numeric identifier and
		the '-f' flag.
   see: http://illumos.org/msg/ZFS-8000-EY
 config:

		rpool                  ONLINE
		  raidz1-0             ONLINE
			diskid/DISK-%20p3  ONLINE
			da1p3              ONLINE
			da2p3              ONLINE
			da3p3              ONLINE
			da5p3              ONLINE
			da4p3              ONLINE
root@nas01:~ # zpool import -f -o altroot=/mnt rpool
cannot import 'rpool': I/O error
		Destroy and re-create the pool from
		a backup source.
root@nas01:~ #
```


----------



## Sebulon (Sep 24, 2014)

*Re: zpool import fails while disk and pool have online statu*

Hi @gesmith1031!

Have you tried making the import booted off a FreeBSD install, in Live CD mode?

/Sebulon


----------



## gesmith1031 (Sep 24, 2014)

*Re: zpool import fails while disk and pool have online statu*

Hi @Sebulon,

Thanks for the suggestion. I have tried importing off the FreeBSD DVD image in Live CD mode and am running into the same error giving the I/O error. 

```
cannot import 'rpool': I/O error
```

Since my initial post I've also tried setting `set vfs.zfs.debug=1` in /boot/loader.conf. When I try to import the pool with the command `zpool import -fF -o altroot=/mnt rpool` I get the following sent to the kernel buffer. http://pastebin.com/bwG8Y79E


----------



## phoenix (Sep 24, 2014)

*Re: zpool import fails while disk and pool have online statu*

Are you able to mount it read-only?

I/O errors on import are generally a *very bad* thing, with read-only mode being the only recourse to get data off the pool before destroying/remaking it.


----------

