#Frigate mount USB enclosure

1 messages · Page 1 of 1 (latest)

outer shoal
#

He guys,

I got a little problem, I got a Ubuntu server with docker and frigate installed (With coral). I have attatched a 4TB harddrive with a usb enclosure and mounted it with sudo mount /dev/sdb1 /media/frigate

At first it worked fine until I restarted my computer. It doesn't mount automaticly and when I mounted it again myself I couldn't watch the footage back. I can see the thumbnails by events and stuff but cannot scroll the timeline anymore even the new recordings are not working propperly. Frigate did see the 4TB storage when I mounted it and restarted Frigate itself.

Any idea how to make this stable?

spare lynx
#

Do you have it in /etc/fstab? Is the mount path empty when unmounted?

outer shoal
#

No I do not have it in /etc/fstab that will fix the auto mount? I'm not sure if the pad will be empty because frigate started just fine, so i guess it made the directory when it didn't find the external harddrive. Is there a way to prefend it?

spare lynx
outer shoal
#

if I add

/dev/sdb3 /media/frigate ext4 default 0 1

at the end of /etc/fstab it will be fine for the automount?

spare lynx
#

Like I said that sdb name will change. I'd also add nofail for USB drives.

outer shoal
#

Thanks! So it will be the following? Is there a way that it does check at boot? So It will always be mounted before docker starts?

UUID=bcc01835-1d71-4e6c-b08f-e183300177f4 /media/frigate ext4 defaults,nofail 0 2

#

or is that fsck?

spare lynx
#

That looks about right.

#

Make sure it is not mounted and that the mount point is empty first and do the chattr +i before mounting it again.

outer shoal
#

I should call you a hero man, chattr is a life saver in this case. I still got 1 problem when I reboot my pc and i do fdisk -l I dont see my external harddrive until i reinsert the usb or turn off and on the switch on the enclosure. Any advise for it?

#

Thats the last piece of the puzzle

spare lynx
#

What does the lsblk command above say directly after reboot?

outer shoal
#

jorzwa@frigate:~$ lsblk -o+FSTYPE,LABEL,MODEL,UUID
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
FSTYPE LABEL MODEL UUID
sda 8:0 0 119.2G 0 disk KINGSTON RBUSNS8
├─sda1 8:1 0 1G 0 part /boot/efi vfat A4AA-B490
├─sda2 8:2 0 2G 0 part /boot ext4 13d34f2b-c8bc-460a-9dd1-a31a35d595bd
└─sda3 8:3 0 116.2G 0 part LVM2_member 05crt7-30PN-pX3v-KCAL-ddqM-DMLh-3FCbLR
└─ubuntu--vg-ubuntu--lv 252:0 0 58.1G 0 lvm / ext4 e8d4a8fa-af30-4fde-8442-ab254c07ae16

It doesn't find it

#

I checked bios settings but everything looks right in my opinion

spare lynx
#

Oof. Please use code blocks.

versed hatchBOT
#

To format your text as code, enter three backticks on the first line, press Enter for a new line, paste your code, press Enter again for another new line, and lastly three more backticks.
```yaml
example: here
```
Don't forget you can edit your post rather than repeatedly posting the same thing.

spare lynx
#

Hmm. Maybe some kind of power saving. Either on the PC or the enclosure. Maybe you can connect it directly or try another one?

#

A hack/workaround might to to reset the USB port but I don't like that.

#

What device is this?

outer shoal
#

It is a Acer Veriton, I tried another usb port and it is working like it should. But i'm not sure if it is an usb 3 port. Hopefuly it can keep up with the write speeds I'm writing 4 1080p camera's to it.

spare lynx
#

Good idea trying another port. lsusb -vt or a fio test should reveal the speed. Otherwise make a good picture of the port's insides and send it.

outer shoal
#

I guess it is USB2 I get errors with writing speeds and timeouts was running it for only a few minutes and can't watch back footage and stuff. Tried to Put the external HDD in the front where the coral was and the coral in the back. Coral is working fine but the external harddrive is not detected anymore until restart. Its a weird one with usb2 it is working fine when startup but with usb3 not

spare lynx
#

Why can't you put it inside the PC?

outer shoal
#

Its a mini pc that has 1 nvme slot (used for boot drive) and 1 2.5 inch slot. I'm using a 3.5 inch WD purple

#

I could maybe buy a extender for the 2.5 inch and put the harddrive on top of it that would be a solution. Not sure if it will power correctly its a small form factor pc

spare lynx
#

Ah. There's different veritons. The enclosure is powered by its own PSU, right? I don't think I've seen one without but just curious.

outer shoal
#

It got an external psu like an intel nuc just a power brick

#

19v 3.42a 65w

#

The hdd is only using like 5 wats when reading and writing, I'm gonna order a extender and try it. Should work fine

spare lynx
#

All these blue ports should be USB 3.x.
I don't have a good idea at the moment why the USB 3 ones behave like this.

#

Maybe you can see if the enclosure does the same on another machine's USB 3 port?

outer shoal
#

On the first usb3 port on the front it looks like it is detected, but believe it or not this thing got a ghost in it or something. Now it wont reconize my static ip anymore. I did set it in pfsense and when I choose for static arp it doesn't work either. Man I'm getting a little bit mad lol

#

I didn't change anything at all just rebooted it

spare lynx
#

Static as in DHCP reservation?

outer shoal
#

Yes I did that at first to ssh to it, it was always at 10.10.10.40 but now its in the scope checked mac adress in arp channel and the mac adress didn't change

spare lynx
#

Strange. On debian I'd debug with dhclient -v but ubuntu is weird.

outer shoal
#
LAN    10.10.10.40    98:ee:cb:66:e2:36    frigate    Expires in 1144 seconds    bridge      
LAN    10.10.10.102    98:ee:cb:66:e2:36    frigate    Expires in 1160 seconds    bridge

This doesn't make sense lol

#

Anything else is running like it should even when restarting, I don't like it but maybe il also set static ip in ubuntu.

spare lynx
#

Just make sure it's out of the DHCP range 🙂

outer shoal
#

It ain't pretty but setting the ip address in ubuntu is working again. So weird that it won't work with the dhcp reserve. It worked the whole day but stopped when the harddrive started working at boot haha. It seems to be all fixed. Couldn't do it with your help thanks hero! You made a big impact

#

Now I got another small thing maybe you could help me with also. I got PFSense, with AdGuard as DNS and Nginx Proxy Manager to reach my stuff. But it won't work in my internal network I get the PFSense login page.