Qengineering / Install-OpenCV-Jetson-Nano

OpenCV installation script with CUDA and cuDNN support
https://qengineering.eu/install-opencv-on-jetson-nano.html
BSD 3-Clause "New" or "Revised" License
137 stars 47 forks source link

Configuring incomplete, errors occurred! #11

Closed merhovon closed 1 year ago

merhovon commented 1 year ago

I have performed the following steps as described and now receive an error message:

a fresh start, so check for updates

$ sudo apt-get update $ sudo apt-get upgrade

install nano

$ sudo apt-get install nano

install dphys-swapfile

$ sudo apt-get install dphys-swapfile

enlarge the boundary (4.5.2 and higher)

$ sudo nano /sbin/dphys-swapfile

give the required memory size

$ sudo nano /etc/dphys-swapfile

reboot afterwards

$ sudo reboot

check your memory first

$ free -m

you need at least a total of 8.5 GB!

if not, enlarge your swap space as explained in the guide

$ wget https://github.com/Qengineering/Install-OpenCV-Jetson-Nano/raw/main/OpenCV-4-7-0.sh $ sudo chmod 755 ./OpenCV-4-7-0.sh $ ./OpenCV-4-7-0.sh

CMakeError.log CMakeOutput.log

Qengineering commented 1 year ago

Dear @merhovon ,

Check with the command $ free -m your memory spacce and swap size. If you have 2 GByte of RAM instead of 4, or for some other reason has a shortage of memory, enlarge the swap space extra.

merhovon commented 1 year ago

The command free -m prints the following: Screenshot from 2023-01-27 20-55-51

Which makes me wonder why I still have so little swap space. I have actually increased this according to the instructions:

Screenshot from 2023-01-27 20-57-30 Screenshot from 2023-01-27 20-58-00

Here are the steps I took to do this:

a fresh start, so check for updates

$ sudo apt-get update $ sudo apt-get upgrade

install nano

$ sudo apt-get install nano

install dphys-swapfile

$ sudo apt-get install dphys-swapfile

enlarge the boundary (4.5.2 and higher)

$ sudo nano /sbin/dphys-swapfile

give the required memory size

$ sudo nano /etc/dphys-swapfile

reboot afterwards

$ sudo reboot

Qengineering commented 1 year ago

You must have the size of the required swap space also available on your SD-card. When you only have 3 GB free on your SD-card, you can only allocate 3 GB of swap space. Thereby, you need extra space for all the generated OpenCV files. In practice 16 GB free space will give 8 GB of swap space and enough for the compilation of OpenCV

merhovon commented 1 year ago

I still have 40GB free on my memory card. Screenshot from 2023-01-27 21-39-49

Qengineering commented 1 year ago

I see you still have commented line CONF_SWAPSIZE=8192 in /etc/dphys-swapfile. If you remove the hashtag (#) in front of the line, it will solve your problem.