# Presets planning for my network

**URL:** <https://forum.genieacs.com/t/presets-planning-for-my-network/4395>\
**Category:** Uncategorized\
**Created:** [August 22, 2023, 10:09am UTC](https://forum.genieacs.com/t/presets-planning-for-my-network/4395 "2023-08-22T10:09:45Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![vicente.roca](https://avatars.discourse-cdn.com/v4/letter/v/a9a28c/32.png) [@vicente.roca](https://forum.genieacs.com/u/vicente.roca)\
**Post date:** [August 22, 2023, 10:09am UTC](https://forum.genieacs.com/t/presets-planning-for-my-network/4395/1 "2023-08-22T10:09:45Z")

</div>

Hello guys, I’m evaluating GenieACS form my network, and I’d like to know your opinion about my planing around Presets.

I have a network for 4 different fiber ONTs (all of the Huawei)  
I give the ONT the ACS info via OMCI.

Every client has a different pppoe/password credentials.

My plan is to create inside GenieACS a preset with a precondition equal to the serial number for every CPE, and in this preset put the pppoe/passsword info, plus some WIFI config,.

¿Is this correct or there is another way??

Thank you for you help 🙂

---

<div class="post-metadata">

**Author:** ![akcoder](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.genieacs.com/akcoder/32/11_2.png) [@akcoder](https://forum.genieacs.com/u/akcoder)\
**Post date:** [August 22, 2023, 4:42pm UTC](https://forum.genieacs.com/t/presets-planning-for-my-network/4395/2 "2023-08-22T16:42:38Z")

</div>

> [@vicente.roca](#):
>
> My plan is to create inside GenieACS a preset with a precondition equal to the serial number for every CPE, and in this preset put the pppoe/passsword info, plus some WIFI config,.

This is a highly inefficient way of setting per-device parameters.

This [wiki article walks you through](https://github.com/genieacs/genieacs/wiki/Example-of-a-Provisioning-Flow) how to create a provision script that can dynamically retrieve information for each subscriber.

I wrote the provision script this example is based off of 8 years ago and its worked flawlessly for me.

---

<div class="post-metadata">

**Author:** ![vicente.roca](https://avatars.discourse-cdn.com/v4/letter/v/a9a28c/32.png) [@vicente.roca](https://forum.genieacs.com/u/vicente.roca)\
**Post date:** [August 23, 2023, 7:09am UTC](https://forum.genieacs.com/t/presets-planning-for-my-network/4395/3 "2023-08-23T07:09:11Z")

</div>

Thank you! very well explained and the script is very very usefull 🙂

---

<div class="post-metadata">

**Author:** ![vicente.roca](https://avatars.discourse-cdn.com/v4/letter/v/a9a28c/32.png) [@vicente.roca](https://forum.genieacs.com/u/vicente.roca)\
**Post date:** [August 23, 2023, 10:18am UTC](https://forum.genieacs.com/t/presets-planning-for-my-network/4395/4 "2023-08-23T10:18:15Z")

</div>

Hi again,  
I’m trying a basic script as a starting point but I keep getting an error:

I’m using this script as base: [Extensions — GenieACS Documentation 1.2.9 documentation](https://docs.genieacs.com/en/latest/extensions.html)  
Script is locate in /opt/genieacs/ext and my env is pointing to this: GENIEACS\_EXT\_DIR=/opt/genieacs/ext

But I keep getting this error:  
default Error write EPIPE 0 23/8/2023, 12:14:12

And from the logs:  
Channel has faulted; channel=“default” retries=0 faultCode=“Error” faultMessage=“write EPIPE”

Any help would be appreciated 🙂

---

<div class="post-metadata">

**Author:** ![Felipe](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.genieacs.com/felipe/32/1949_2.png) [@Felipe](https://forum.genieacs.com/u/Felipe)\
**Post date:** [August 23, 2023, 6:10pm UTC](https://forum.genieacs.com/t/presets-planning-for-my-network/4395/5 "2023-08-23T18:10:25Z")

</div>

Hi,

Are your calling the right file/function in your ext script?

---

<div class="post-metadata">

**Author:** ![vicente.roca](https://avatars.discourse-cdn.com/v4/letter/v/a9a28c/32.png) [@vicente.roca](https://forum.genieacs.com/u/vicente.roca)\
**Post date:** [August 24, 2023, 7:33am UTC](https://forum.genieacs.com/t/presets-planning-for-my-network/4395/6 "2023-08-24T07:33:17Z")

</div>

Hola Felipe,  
I’m pretty sure.

My script is the one from the official docs as an example:  
[https://docs.genieacs.com/en/latest/extensions.html](https://docs.genieacs.com/en/latest/extensions.html)

Its name is ext-sample.js and the location in the file is: /opt/genieacs/ext witch is the same as my env dir: GENIEACS\_EXT\_DIR=/opt/genieacs/ext

And this “const res = ext(“ext-sample”, “latlong”, “arg1”, “arg2”);” is fired on every INFORM (for testing porpuses)

I also, remove in my .env the line about the extensions directory, and I put everything in /opt/genieacs/config/ext but I got the same error.

Every change I do I restart the service (as I read on the forum that it is necessary)

I’m really lost here. ¿should I use the lastest code in github of the lastest release? I’m using the release right now.

node version: v18.17.1

Changed to node version v16.20.2, same problem.

¿any idea how to debug this?

Thanks!

---

<div class="post-metadata">

**Author:** ![vicente.roca](https://avatars.discourse-cdn.com/v4/letter/v/a9a28c/32.png) [@vicente.roca](https://forum.genieacs.com/u/vicente.roca)\
**Post date:** [August 24, 2023, 11:47am UTC](https://forum.genieacs.com/t/presets-planning-for-my-network/4395/7 "2023-08-24T11:47:03Z")

</div>

Found the problem!  
It was a problem related with node because I installed using nvm and genieacs didn’t find the node executable.

solved.
