Community discussions

MikroTik App
 
gtb88
just joined
Topic Author
Posts: 3
Joined: Thu Feb 21, 2019 10:26 am

Script to save file to disk1  [SOLVED]

Wed Oct 14, 2020 12:58 pm

Hi All
I am new to scripting to please can someone help with the syntax for this script, It saves file perfectly to built in disk but not to external disk1 (which is visible and working okay)
This works:
:global backupfile ([/system identity get name] . "-" . [/system clock get time])
/tool user-manager database save name=$backupfile

This doesn't work
:global backupfile ([/system identity get name] . "-" . [/system clock get time])
/tool user-manager database save name=/disk1/$backupfile

I have highlighted the only change between the two scripts in red and have tried it with and without a forward slash in front of disk1. Thanks in advance for your help!

Graham
 
msatter
Forum Guru
Forum Guru
Posts: 1915
Joined: Tue Feb 18, 2014 12:56 am
Location: Netherlands / Nīderlande

Re: Script to save file to disk1

Wed Oct 14, 2020 2:49 pm

="disk1/$backupfile"
One RB4011 (cooled) and a RB760iGS (hEX S) in series. The 4011 Does PPPoE/IKEv2.
The cooler: viewtopic.php?f=3&t=138613&start=300#p799879
Running:
RouterOS 6.48beta48 / Winbox 3.27 64bits / MikroTik APP 1.3.15
 
gtb88
just joined
Topic Author
Posts: 3
Joined: Thu Feb 21, 2019 10:26 am

Re: Script to save file to disk1

Fri Oct 16, 2020 11:12 am

="disk1/$backupfile"
That worked! Thanks very much indeed!

Who is online

Users browsing this forum: No registered users and 18 guests