-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
wyze app detected the nfs mount as sdcard, but still videos arent saved. #121
Comments
If you add ‘ no_root_squash’ to the exports lines does it correct the issue? |
i dont see any existing |
On your pi, change contents of /etc/exports to: /media/pi/data/wyzeNFS *(rw,insecure,sync,no_root_squash) Then restart nfsd service on the pi, then restart cam(s). See if that works. |
Well, yes, it does saves the videos now without any manual permission changes. Thanks. |
Agreed with @ashjas ... there is no obvious reason that permissions for record folder (and its children) should be any different from those in photo, timelapse, alarm and so on. Please fix this. For the "record" path and its children, I have good results on some cameras, and not on others (using a FREENAS NFS). All other folders seem to be working fine. It doesn't seem right to have to jump through hoops and have special configuration options to satisfy the needs of one folder for what is apparently a bug in the (hack) firmware. |
@ashjas if you change permissions of record to 755 does it keep them or do they change back to 644 ? |
@endertable if i remember it correctly, changing permissions from raspberrypi wasnt working.
And then , once the wyzecam with hack creates the record folder, i manually create folders with proper permissions(cron job on the raspberrypi). This has been working fine for me since a week. |
Glad it's working for you and you did exactly what you need to for your setup with the custom script. What many people fail to understand is that this issue has nothing to do with Wyzehacks, it is an NFS issue. There are way too many variations of Linux/NFS with different default permissions and securities enabled/disabled. He created the "custom script" part to allow people their own clean up or tweaking as necessary. |
I might have agreed with @endertable except for a couple of things:
Now, that said, I cannot say this problem is caused by the hack. Maybe it's not. Rather, probably it's not. I suspect that it's likely that the Wyze software(firmware) creates these folders with unusual permissions due to an inconsistency that doesn't matter when writing to real SD cards. How can we get to the right Technical Support group within Wyze to get answers on this? I'm hoping someone here knows at least how to begin, else I don't see how this project could have been started. I would be willing to work with Wyze if I can figure out how to get to the right team. Any help there? (When I called Wyze Support with an unrelated problem, I mentioned this hack. The tech I spoke to had no idea such a thing was possible, and was adamant about removing it from the camera.) Since the symptoms are so obviously related to ONLY one folder (and there are many, many others where this could go wrong, but it doesn't....) I'd be hard pressed to believe this is an NFS setup issue. And anyway, it's at least misleading to blame it on incompatibilities within such a mature platform (NFS). If you know of such incompatibilities, please elaborate! I doubt the problem is actually resolved for @ahsjas. (Would be nice, but....) I did the same thing (setting permissions) and it worked for a day. But then a new folder was created under the record folder... that folder likewise had incorrect permissions. Seems to be a never-ending battle to keep up with this since the permissions are set incorrectly in the first place for each new folder (ONLY under the record folder). It's a catch-22. The permissions have to be set before the recording is made, but the folder that needs the permissions change won't exist yet when the record button is pressed. Then it's too late for (at least) that recording. |
@delovelady Its really solved for me as of now. Thats why i said i run a cron script that generated all the folder structures ahead of time at 11PM everyday for the next day for every hour, so that wyzecam never creates these folders in the first place. And i do agree with you that this is not NFS problem, because, there is a different behaviour in case of campan, which does not mess up with the record folder permissions so badly. I dont need to create these folders ahead of time for campan, only for camv2s. So definitely the actual fw is messing up with the permissions for sure. It never is a problem for sdcards since the fs isnt permission aware. Also, i think its futile to ask for official wyze support on this, as had they been concerned the sdcard getting corrupted would have been fixed long time back , which we never saw. And the sdcard going bad in some time is the only reason why this hack is a lifesaver for me atleast or maybe also why it actually exists. |
Ah! I had missed that @ashjas. Brilliant. With that and your comment about Wyze support, I retract my desire to contact them. This should solve it! And yes, I agree this hack and Wyze’s really cost-effective solution together make a great combination. I might suggest, if you haven’t already, to add something like this, for those empty folders that will be created in advance:
|
Hello,
My nfs mount point is hosted on a raspberrypi 4.
Followed this guide for the nfs setup.
I didnt follow the guide to its entirety since it seemed unnecessary.
Executed these steps:
mkdir -p /media/pi/data/nfsexports
mkdir -p /media/pi/data/wyzeNFS
chmod 777 -R /media/pi/data/nfsexports /media/pi/data/wyzeNFS
sudo mount --bind /media/pi/data/wyzeNFS /media/pi/data/nfsexports
changed the
NEED_SVCGSSD
setting in/etc/default/nfs-kernel-server
to 'no'sudo systemctl restart nfs-kernel-server
sudo exportfs -rav
contents of /etc/exports:
These are the changed settings from wyze_hack.cfg:
Note: The nfs mount point could only be mounted on wyze cam after the
/media/pi/data/wyzeNFS
was changed with 777 permission.mount output on wyze v2 after telnet:
When i try to cd to
/mnt/WyzeCams/XXXXXXXXXXXX/record/
i get:cd /mnt/WyzeCams/XXXXXXXXXXXX/record/
ls -l:
So due to this permission issue on the folder, no files are being recorded to the nfs mount path.
I have tried changing permissions on the folder which doesent help.
Just an additional info.
The drive on which the NFS path lies has only around 38GB left, with the hdd itself being 200GB ssd.
Thanks for creating this hack/mod for our wyze cams.
Regards.
The text was updated successfully, but these errors were encountered: