Skip to content
This repository has been archived by the owner on Sep 8, 2024. It is now read-only.

Reset‐OPNsenseConfig

fvanroie edited this page Dec 2, 2017 · 5 revisions

Synopsis

Resetthe OPNsense server to factory defaults

Syntax

Reset-OPNsenseConfig -EraseAllSettings [-Hostname] <String> `
             [-WhatIf] [-Confirm] [<CommonParameters>]

Description

WARNING: This cmdlet destroys the configuration on the OPNsense server. Use the Reset-OPNsenseConfig cmdlet with extreme caution. In order to prevent accidentally wiping your OPNsense server, this cmdlet will request confirmation before executing the reset to factory defaults on the server.

You need to pass all the required parameters for the cmdlet to have effect. This is to prevent from unknowingly destroying your server.

Parameters

-EraseAllSettings   <SwitchParameter>

Needs to be passed for the cmdlet to have effect.

Required? true
Position? named
Default Value?
Pipeline Input? false

-Hostname   <String>

Confirm the hostname of the server you want to reset.

Required? true
Position? 0
Default Value?
Pipeline Input? false

-WhatIf   <SwitchParameter>

Test the command without actually performing the reset.

Required? false
Position? named
Default Value?
Pipeline Input? false

-Confirm   <SwitchParameter>

Ask user confirmation before reseting the OPNsense server to factory defaults.

Required? false
Position? named
Default Value?
Pipeline Input? false

Examples

Basic example

Reset-OPNsenseConfig -EraseAllSettings -Hostname 'OPNsense.localdomain' -Confirm

Example with incorrect hostname

Reset-OPNsenseConfig -EraseAllSettings -Hostname 'SomeOtherServer' -Confirm:$false
Clone this wiki locally