TIP: Click on subject to list as thread! ANSI
echo: rberrypi
to: DENNIS LEE BIEBER
from: ROBH
date: 2018-05-20 20:08:00
subject: Re: ftp causing invalid s

On 20/05/18 19:18, Dennis Lee Bieber wrote:
> On Sun, 20 May 2018 19:00:49 +0100, RobH  declaimed the
> following:
>
>> No error messages of any kind now, so in the script you provided, where
>> or what should I change to incorporate FreeNAS ip address.
>>
>
>  NOTHING...
>
>  The "mount" command is what linked your FreeNAS directory to a
> directory on the RPI... The RPI only has to put files into what looks to it
> like just another local directory. And if you haven't changed anything,
> that should be
>    /mnt/CCTV/PiZero
>
>> Regarding the files going back 3 days, no I have not rebooted the Pi
>> Zero at all, so that is maybe the reason why.
>>
>  If the "copyfile" was failing because of the bad mount point, the
> program wouldn't have executed the unlink() calls.
>
>  You might want to clear out that region before you run out of RAM 
>
>  rm /dev/shm/*.h264
> or
>  rm /run/shm/*.h264
>
> since it seems both paths were the same on your system.
>
>  Once you see files appear in  /mnt/CCTV/PiZero then verify externally
> that the NAS shows them... Then restore the unlink() statement in the
> script (and empty /dev/shm again -- if the script is running without
> problems it should be removing the RAM files after they get copied to the
> NAS mount point.
>
>> Thanks
>>
>>>
>
>

I mounted the directory again:

pi@raspberrypi:~ $ sudo mount //192.168.0.22/CCTV/PiZero
/mnt/CCTV/PiZero -o username=root,password=******

Then I ran the python script:

pi@raspberrypi:~ $ python intruder_recmotion.pyTraceback (most recent
call last):
   File "intruder_recmotion.py", line 37, in 
     shutil.copyfile(RAMname, NASname)
   File "/usr/lib/python2.7/shutil.py", line 83, in copyfile
     with open(dst, 'wb') as fdst:
IOError: [Errno 13] Permission denied:
'/mnt/CCTV/PiZero/2018-20-20_20.02.21.h264'


Then :

pi@raspberrypi:~ $ rm /run/shm/*.h264
pi@raspberrypi:~ $ rm /dev/shm/*.h264
rm: cannot remove '/dev/shm/*.h264': No such file or directory
pi@raspberrypi:~ $

--- SoupGate-Win32 v1.05
* Origin: Agency HUB, Dunedin - New Zealand | FidoUsenet Gateway (3:770/3)

SOURCE: echomail via QWK@docsplace.org

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.