On 31/05/18 09:17, Björn Lundin wrote:
> On 2018-05-23 10:58, RobH wrote:
>
>>
>> With .unlink commented out the files on the PiZero /dev/shm are all
>> about 2.8mb in size, from file/properties,
>> and yet when I:
>>
>> pi@raspberrypi:~ $ ls -la /mnt/CCTV/PiZero
>> total 12
>> drwxr-xrwx 2 pi pi 0 May 23 09:47 .
>> drwxr-xr-x 3 pi pi 4096 May 17 17:36 ..
>> -rw-r--r-- 1 pi pi 0 May 21 11:50 2018-050-21_11.50.09.h264
>> -rw-r--r-- 1 pi pi 0 May 22 09:46 2018-050-22_09.46.39.h264
>> -rw-r--r-- 1 pi pi 0 May 22 09:51 2018-050-22_09.51.12.h264
>> -rw-r--r-- 1 pi pi 0 May 22 11:35 2018-050-22_11.34.55.h264
>> -rw-r--r-- 1 pi pi 0 May 22 11:44 2018-050-22_11.44.02.h264
>> -rw-r--r-- 1 pi pi 0 May 22 11:46 2018-050-22_11.46.02.h264
>> -rw-r--r-- 1 root pi 0 May 23 09:47 2018-050-23_09.47.38.h264
>> -rw-r--r-- 1 pi pi 0 May 19 17:31 2018-19-19_17.31.32.h264
>> -rw-r--r-- 1 pi pi 0 May 19 17:40 2018-19-19_17.40.13.h264
>> -rw-r--r-- 1 pi pi 0 May 19 17:43 2018-19-19_17.43.42.h264
>> -rw-r--r-- 1 pi pi 0 May 20 19:02 2018-20-20_19.01.50.h264
>> -rw-r--r-- 1 pi pi 0 May 20 19:08 2018-20-20_19.08.38.h264
>> -rw-r--r-- 1 pi pi 0 May 20 20:02 2018-20-20_20.02.21.h264
>> -rw-r--r-- 1 pi pi 0 May 20 20:51 2018-20-20_20.51.49.h264
>>
>> And now they are 0 bytes in size?????
>
>
> what is the size when you do the move manually?
> that is
> mv /dev/shm/file_of_size_greater_than_zero /mnt/CCTV/PiZero/
> ls -la /mnt/CCTV/PiZero/file_of_size_greater_than_zero
>
Apologies for late reply, as I did not realise you had replied to me.
I had a problem with the piZero booting as it said the shell is locked,
so I just re burned the stretch image on the sd card and starting over
again.
As before I have managed to get this far:
I ran this: echo "test" > /mnt/CCTV/PiZero/test.txt
and the file was created on my NAS box in the PiZero directory
sudo mount //192.168.0.22/CCTV/PiZero /mnt/CCTV/PiZero -o
username=root,password=*******
python intruder.py
Traceback (most recent call last):
File "intruder.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 2] No such file or directory:
'//192.168.0.22/mnt/CCTV/PiZero/2018-06-04_15.09.19.h264'
On the PiZero I have: /mnt/CCTV/PiZero
When I run this: sudo mount -t cifs -o //192.168.0.22/mnt/CCTV/PiZero
/mnt/CCTV/PiZero
mount: can't find /mnt/CCTV/PiZero in /etc/fstab
Now as far as I am aware, there was nothing about fstab before, so do
you think I should add the said line in /etc/fstab.
Thanks
Now no files of any size are created when I run the python script.
--- SoupGate-Win32 v1.05
* Origin: Agency HUB, Dunedin - New Zealand | FidoUsenet Gateway (3:770/3)
|