Vya_config_commit-confirm not a valid identifier

Hi !

I’m trying to understand why I’m not able anymore to use my script in /config/scripts/vyos-postconfig-bootup.script

I was running before on a 1.3 rolling from 2023.03.05, everything was fine.
Now I’m running a rolling from yesterday, and the error I get from the console is “vyatta_config_commit-confirm not a valid identifier”, blocking my script to work properly.
The error seems to come from the first line ‘source /opt/vyatta/etc/functions/script-template’, since I tried to just put this line into the script.

Could someone help here ?


Can you post the content of the script?


cat /config/scripts/vyos-postconfig-bootup.script


source /opt/vyatta/etc/functions/script-template
#delete service ssh listen-address x.x.x.x
#set service ssh listen-address x.x.x.x

Hi UnixSH,
Try this

# Create script
tee  /config/set_ssh_listen_address.sh << "EOF"
source /opt/vyatta/etc/functions/script-template
delete service ssh listen-address
set service ssh listen-address

Then add the script to running in the vyos-postconfig-bootup.script

tee >> /config/scripts/vyos-postconfig-bootup.script << "EOF"
sudo bash /config/set_ssh_listen_address.sh
1 Like

Instead of




can be used in /config/set_ssh_listen_address.sh

Hi both, many thank’s for you replies.

I tried both of your method, and :

  1. calling another script from vyos-postconfig-bootup.script is working
  2. changing the shebang to vbash is also working

Any clue on why I got this error initially, and why we could do that to get around it ?
That should need a fix if I get that on a fresh install, right ?

My guess is that the script-template in order to use vyos op-mode and conf-mode commands from within a script is based on using /bin/vbash instead of /bin/sh.

So if you either call a separate script from the pre/postconfig-script OR alter the pre/postconfig-script to use #!/bin/vbash instead of #!/bin/sh the issue will get resolved.

Personally I would create a custom script in /config/custom/filename.sh (which starts with a #!/bin/vbash) and call that from the pre/postconfig-script (who remains using #!/bin/sh).

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.