# NvSciBufObj Allocation Failure

**URL:** <https://forums.developer.nvidia.com/t/nvscibufobj-allocation-failure/275477>\
**Category:** DRIVE AGX Orin General\
**Tags:** driveos-nvmedia\
**Created:** [December 8, 2023, 7:31pm UTC](https://forums.developer.nvidia.com/t/nvscibufobj-allocation-failure/275477 "2023-12-08T19:31:57Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![dbennington1](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@dbennington1](https://forums.developer.nvidia.com/u/dbennington1)\
**Post date:** [December 8, 2023, 7:31pm UTC](https://forums.developer.nvidia.com/t/nvscibufobj-allocation-failure/275477/1 "2023-12-08T19:31:57Z")

</div>

Please provide the following info (tick the boxes after creating this topic):  
**Software Version**  
 DRIVE OS 6.0.8.1  
 DRIVE OS 6.0.6  
 DRIVE OS 6.0.5  
 DRIVE OS 6.0.4 (rev. 1)  
 DRIVE OS 6.0.4 SDK  
 other

**Target Operating System**  
 Linux  
 QNX  
 other

**Hardware Platform**  
 DRIVE AGX Orin Developer Kit (940-63710-0010-300)  
 DRIVE AGX Orin Developer Kit (940-63710-0010-200)  
 DRIVE AGX Orin Developer Kit (940-63710-0010-100)  
 DRIVE AGX Orin Developer Kit (940-63710-0010-D00)  
 DRIVE AGX Orin Developer Kit (940-63710-0010-C00)  
 DRIVE AGX Orin Developer Kit (not sure its number)  
 other

**SDK Manager Version**  
 1.9.3.10904  
 other

**Host Machine Version**  
 native Ubuntu Linux 20.04 Host installed with SDK Manager  
 native Ubuntu Linux 20.04 Host installed with DRIVE OS Docker Containers  
 native Ubuntu Linux 18.04 Host installed with DRIVE OS Docker Containers  
 other

Hello,

We are seeing an issue on DriveOS 6.0.8.1 with NvSciBufObj allocation that we did not observe on DriveOS 6.0.6. During initialization of our camera driver, when allocating `NvSciBufObj`s, we see the following error:

```auto

NvMapMemAllocInternalTagged: 1074810371 error 12

NvMapMemHandleAlloc: error 0

```

and we observe `NvSciBufObjAlloc()` returning `NvSciError_ResourceError`.

So far, we have only seen this error sporadically (it does not occur on every boot or every time we launch our software). When we see this error, we observe it will occur repeatedly until the device is rebooted. We have so far been unable to isolate the steps required to reproduce this error state.

We have found two somewhat similar, but not identical issues previously posted on the forum: [a post about NvMediaImage allocation](https://forums.developer.nvidia.com/t/nvmedia-limits-for-nvmediaimage-allocation/191724) and [a post about DLA usage](https://forums.developer.nvidia.com/t/issues-when-using-dla-with-tensorrt-7-1-3-compared-to-tensorrt-6-0-1/147688), but neither seems to have the same error message that we observe.

Any help that Nvidia can provide would be appreciated.

---

<div class="post-metadata">

**Author:** ![VickNV](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/vicknv/32/14043_2.png) [@VickNV](https://forums.developer.nvidia.com/u/VickNV)\
**Post date:** [December 9, 2023, 12:14am UTC](https://forums.developer.nvidia.com/t/nvscibufobj-allocation-failure/275477/4 "2023-12-09T00:14:59Z")

</div>

To further investigate, could you please run the following command the next time you encounter this problem? It will help us check the available size of the nvmap heap:

```bash
$ sudo cat /sys/kernel/debug/nvmap/generic-0/free_size

```

---

<div class="post-metadata">

**Author:** ![jmanning2](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@jmanning2](https://forums.developer.nvidia.com/u/jmanning2)\
**Post date:** [December 13, 2023, 5:34pm UTC](https://forums.developer.nvidia.com/t/nvscibufobj-allocation-failure/275477/5 "2023-12-13T17:34:43Z")

</div>

Thanks, we’ll try that out & report back the next time we see this error.

---

<div class="post-metadata">

**Author:** ![jmanning2](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@jmanning2](https://forums.developer.nvidia.com/u/jmanning2)\
**Post date:** [January 5, 2024, 7:47pm UTC](https://forums.developer.nvidia.com/t/nvscibufobj-allocation-failure/275477/6 "2024-01-05T19:47:10Z")

</div>

We were able to reproduce this, the output we got from `cat`-ing the `free_size` was `0x0000000019380000`. How do we interpret this value?
