I have removed the config from admin>>config:
And created a custom Bootstrap provision file to handle only this special case i have…
bootstrap_custom file:
/**
* Data: 04/11/2022 - Autor: Guilherme R. Miguel
* Rev. 1.0
*
* Script_Tipo: Provisions
* Provisionamento de novos dispositivos
*
*/
const script_name = "bootstrap_custom";
const inicio = new Date().getTime()
const date = new Date();
var dateString =
("0" + date.getUTCDate()).slice(-2) + "/" +
("0" + (date.getUTCMonth()+1)).slice(-2) + "/" +
date.getUTCFullYear() + " " +
("0" + date.getUTCHours()).slice(-2) + ":" +
("0" + date.getUTCMinutes()).slice(-2) + ":" +
("0" + date.getUTCSeconds()).slice(-2);
log(" -- Iniciando Script de Provisionamento: " + script_name + " -- " + dateString);
const username = declare("DeviceID.ID", {value: 1}).value[0];
let serialNumber = declare("DeviceID.SerialNumber", {value: 1}).value[0];
log(script_name + " - " + "DeviceID: " + username + " | " + "Serial: " + serialNumber);
log(script_name + "|" + username + " -- TEXTO AQUI -- ");
const now = Date.now();
// Clear cached data model to force a refresh
clear("Device", now);
clear("InternetGatewayDevice", now);
const informInterval = 600;
// Refresh values daily
const daily = Date.now(86400000);
// Unique inform offset per device for better load distribution
const informTime = daily % 86400000;
const productClass = declare('DeviceID.ProductClass', {value: 1}).value[0];
if (productClass == "UNG221E") {
log(script_name + "|" + productClass + " -- AQUI -- ");
declare("Device.ManagementServer.ConnectionRequestUsername", {value: now}, {value: "teste"});
declare("Device.ManagementServer.ConnectionRequestPassword", {value: now}, {value: "teste"});
declare("Device.ManagementServer.PeriodicInformEnable", {value: daily}, {value: true});
declare("Device.ManagementServer.PeriodicInformInterval", {value: daily}, {value: informInterval});
declare("Device.ManagementServer.PeriodicInformTime", {value: daily}, {value: informTime});
commit();
log(script_name + "|" + productClass + " -- FIM -- ");
}
(i know i can remove the IF clause because i am filtering in the precondition…but ok… )
Even this way, i can see my device reaching my ACS server, but it is not sending the SPV to set the username and password i am inserting on my code…
log file: tail -f genieacs-cwmp-access.log
CPE side:
Am I doing something wrong in my provisioning file?
Why aren’t you configuring username/password on the CPE?
Thank you in advance!



