Backup / restore config.xml on the command line

  • Hi,

    is there any command to backup or restore the config.xml on the command line?
    I mean if i only want the config.xml and the not the package configuration as example.


  • Rebel Alliance Developer Netgate

    There isn't a way to filter out the package info from the command line (well, easily… there probably is with a piped chain of various shell commands)

    You can just grab the config.xml from /conf/ and cp/scp/etc it wherever you want. If you want to remove the package settings, just edit out the " <installedpackages>...</installedpackages> " section of the configuration.

  • I run a cron job to backup my config.xml to a local ftp server. Example below:

    cd /conf
    cat <<end |="" ftp="" 'ftp:="""" backup'<br="">put ./config.xml

    To restore, just run a manual ftp session to the backup server and pull down the last good config, removing the package info as jimp suggests.</end>

Log in to reply