Connection problems of external USB-Drive to FreeNAS 11.3-U1

vafk

Contributor
Joined
Jun 22, 2017
Messages
132
I have two identical 3TB drives in a USB-enclosure. From console gpart shows both disks

root@freenas1:~ # gpart show da3
=> 6 732566635 da3 GPT (2.7T)
6 122 - free - (488K)
128 4194304 1 freebsd-swap (16G)
4194432 728372209 2 freebsd-zfs (2.7T)

root@freenas1:~ # gpart show da0
=> 6 732566631 da0 GPT (2.7T)
6 122 - free - (488K)
128 4194304 1 freebsd-swap (16G)
4194432 728372205 2 freebsd-zfs (2.7T)

My problem: Yesterday I managed to connect both drives, format them as GPT with freebsd-ufs and run replication task on them. Today I can only see one of the two drives from GUI in section of disks. When I try to run the replication task on the affected drive system reports that drive is suspended. When I ssh to FreeNAS and try to access mnt/backup3 (this is the path of the drive), the session hangs.

Where would I look for the problem first? I remember that I had similar problems when attaching external USB on my Windows computer that after some time of attaching/removing the OS stopped mounting the drive. I then had to remove all dead USB-entries to get it work again.

Also I suspect that if the external USB-drive goes in sleep mode (I suspect that the SATA-USB3-Interface does this without me being able to disable it) that could cause this problem.

Edit: After I sent this post I connected the affected drive to my Windows computer and on the USB3-port it was not detected. When I connected it to USB2-port, I can access the disk (with MiniPartition Tool) to see it is healthy. So that confirms my suspicion that there could be compatibility problems when using SATA-drives with SATA-to-USB3-interface.
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,703
The USB controller (most likely in the USB housing, but maybe the port on your system) is probably no good (I have seen this a lot in my experience with FreeNAS and read a lot about it... this favorite OS and filesystem of ours pushes USB controllers in a way they seem to take exception to and retaliate by dying).

You might try shucking the disk and trying another enclosure (on a different USB port if necessary) to confirm the theory.

As a general rule, what you're doing has you on a path to eventual failure somewhere, so either account for it in your processes and costs or change the method (to eliminate USB) if you want long-term happiness.

Here to ponder further on any progress or discoveries you make.
 

vafk

Contributor
Joined
Jun 22, 2017
Messages
132
@sretalla

Thank you for the hint! So what you say is that the extensive use of USB-ports can lead to a damage? Although I hear that for the first time I believe this is possible, especially if it is USB 3. I will check the other ports later.

Now would that completely rule out USB even for daily backups if one wants to have absolute security? Perhaps then I should go back to my previous scenario where I had an old HP N54L with 4 HDD bays that fully equipped would draw some 80 Watts. And let this do the daily replication while using the USB3-drives for monthly backups?

One more remark: When gpart show shows me the drive from command line as da3 while the GUI is not listing it AND the drive's LED is blue (= online & USB3 connected), that still makes me believe that there is a different problem apart of the USB-failure. Otherwise gpart would not see the drive.

Edit: I think I could narrow the problem. If I connect more than one of the same USB-drive make, FreeBSD will connect both (gpart shows them) but FreeNAS will only list one of them.
 
Last edited:

Adrian

Contributor
Joined
Jun 29, 2011
Messages
166
I perform monthly rsync backups to an alternately used pair of ZFS formatted 6 TB WD greens in a Startech USB enclosure connected to a StarTech 2 Port USB 3.0 PCI Express SuperSpeed Card Adapter with UASP. Sometimes the drive fails to be picked up. Switching the cable to the other port resolves the problem. That is the only time that the cable is removed from the computer.
 

vafk

Contributor
Joined
Jun 22, 2017
Messages
132
@Adrian
The problem where one needs switching the USB-port for the device to be recognized well known under Windows seems to appear on FreeBSD as well :-(

I guess I will be soon back with a "normal" storage device = N54L with a bunch / up to four / drives.
 

Adrian

Contributor
Joined
Jun 29, 2011
Messages
166
Sadly I believe that my ancient N36L Microserver that I use for partial backup / test can only take 2 TB drives.

I am toying with the idea of somehow detecting when snapshots to it have finished and shutting it down, then having it woken when required. I used to use it as a self-knit firewall, so it has an Intel card in it which supports WoL The FreeNAS/FreeBSD bge driver still appears not to support WoL,

Code:
root@hpnas ~]# uname -a
FreeBSD hpnas.hanley.stade.co.uk 11.3-RELEASE-p6 FreeBSD 11.3-RELEASE-p6 #0 r325575+d5b100edfcb(HEAD): Fri Feb 21 18:53:26 UTC 2020     root@tnbuild02.tn.ixsystems.com:/freenas-releng/freenas/_BE/objs/freenas-releng/freenas/_BE/os/sys/FreeNAS.amd64  amd64

[root@hpnas ~]# ifconfig em0
em0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=209b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,WOL_MAGIC>
        ether 00:1b:21:b3:a8:5b
        hwaddr 00:1b:21:b3:a8:5b
        inet 192.168.1.20 netmask 0xffffff00 broadcast 192.168.1.255
        nd6 options=1<PERFORMNUD>
        media: Ethernet autoselect (1000baseT <full-duplex>)
        status: active

[root@hpnas ~]# ifconfig bge0
bge0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=c019b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,TSO4,VLAN_HWTSO,LINKSTATE>
        ether 3c:4a:92:74:58:68
        hwaddr 3c:4a:92:74:58:68
        nd6 options=1<PERFORMNUD>
        media: Ethernet autoselect (none)
        status: no carrier


That said, I usually argue it is best to keep computers running all the time.
 

vafk

Contributor
Joined
Jun 22, 2017
Messages
132
That said, I usually argue it is best to keep computers running all the time.

True but now with the rising temperature it is like in the last century where one would not care about heating and ventilate at the same time.

I failed with my backup scenario (see original post) and stopped looking for a solution.
Whenever I finished a replication and switched off the drive the system had difficulties mount it properly again (happened when there were 2 drives with the identical SATA-to-USB3-interface) so I had to reboot my FreeNAS.

Then I put the 2 drives in my N54L, and voila I have no trouble anymore and use this as my second backup.

My first backup is a Dell MD1000 enclosure with currently 8 x 2 TB drives running in Raid-Z2 backing up my main 4x 4 TB Raid-Z1. This is connected via a Infiniband SFF-8470 cable to a LSI Logic SAS3442E-HP inside my HP Microserver G8. The good part is that when I power up MD1000 the LSI controller recognizes the drives without rebooting the server. So I only have to import the pool, do the replication, disconnect the pool and switch off the MD1000. This part is heavy, loud and hot! But it was cheap, only 110€ with the controller, and I was able to use all of my old WD 2 TB reds :)

Since I have another old N54L and since used 2 TB drives have become very cheap (each only 25€) I could get 6 TB in Raid-Z1 for 100€ to have a third backup. Just in case backup1 and backup2 would fail...
 
Last edited:
Top