On 2018-05-18 13:47, RobH wrote:
> On 18/05/18 11:24, Ahem A Rivet's Shot wrote:
>> On Fri, 18 May 2018 10:23:03 +0100
>> RobH wrote:
>>
>>> I am not doing the mount on my NAS box, only on the Pi Zero.
>>>
>>> And I am not sure if you saw my reply to you after you supplied the new
>>> python code for me to use, but I am getting this when I run the said
>>> script.
>>>
>>> After I created the the said folders on the Pi Zero ie /mnt/CCTV/PiZero
>>
>> Perfect - and you have also mounted the NAS directory onto this ?
>> If not then do so.
>>
>>> I then ran the python script for the sensor detection and camera , and
>>> it returned :
>>>
>>> Traceback (most recent call last)
>>> File "intruder_recmotion.py", line 37, in
>>> shutil.copyfile(RAMname, NASname)
>>> File "/usr/lib/python 2.7/shutil.py", line 83, in copyfile with
>>> open(dst, 'wb') as fdst:
>>> IOError: [Errno 2] No such file or directory:
>>> '/192.168.0.22/mnt/CCTV/PiZero/2018-16-16_11.25.36.h264'
>>
>> Remove the /192.168.0.22 bit - the directory is /mnt/CCTV/PiZero
>> not /192.168.0.22/mnt/CCTV/PiZero.
>>
> Ok I have removed the //192.168.0.22 and is now //mnt/CCTV/PiZero.
NO,NO,NO
The // in the begining signifies a machine.
The file should be save into the directory
/mnt/CCTV/PiZero
NO // in the beginning just a single /
>
> The python script runs without error, BUT it does not record any file
> from detected motion.At least, I cannot find any files in
> //mnt/CCTV/PiZero on the PI Zero, nor on my NAS box.
>
> You say to 'mount the NAS directory into this'
>
> Where abouts in the //mnt/CCTV/PiZero does it go.
As I stated several times before.
on the PI:
sudo mount .... //192.168.0.22/some/directory /mnt/CCTV/PiZero
This means that the contents of *remote directory* - that is on the NAS
is accessible from *local directory* /mnt/CCTV/PiZero
in your script ON THE PI, save to *local directory* /mnt/CCTV/PiZero
and the file will show up on the *remote directory* on the nas.
It would help alot if you
* copied the output from the commands - not just type them into the
newsreader
* stated on which machine you are
* showed the python code
--
--
Björn
--- SoupGate-Win32 v1.05
* Origin: Agency HUB, Dunedin - New Zealand | FidoUsenet Gateway (3:770/3)
|