Due to the permission limitations for commands run directly in on-up scripts, it is suggested that the on-up script action should just be to run a script which has been created in /system scripts (e.g. viewtopic.php?t=171750#p840220).
As it doesn't appear to be possible to pass arguments directly to scripts, when a script references the variables from the caller (e.g. $"caller-id", $user) are these specific to that invocation, or global in which case they may be changed by another on-up which occurs before the first has completed? i.e. what happens if another PPPoE client connects whilst the script for the original PPPoE connection has not yet completed execution.
Also, if using an array as a list which may have entries added and removed by more than one script, or script instance, are any operations atomic or is it possible the variable may be changed elsewhere part-way though a statement, e.g. when adding an item
:global things
:local item "somedata"
:set things ($things,$item)
or when removing an item
:global things
:local item ($things->0)
:set things [:pick $things 1 9999]
Any insights would be appreciated