官术网_书友最值得收藏!

Backing up your configuration file via the CLI

In this recipe, we will learn how to backup our configuration via the CLI. Essentially, the CLI backs up the standalone.xml file by copying it into the snapshot.

Getting ready

Start up your WildFly so that we can directly connect to it via the CLI, as follows:

$ cd ~/WFC/wildfly
$ ./bin/standalone.sh

How to do it…

The command itself is pretty easy:

$ ./bin/jboss-cli.sh --connect
[standalone@localhost:9990 /] :take-snapshot  
{
    "outcome" => "success",
    "result" => "/home/luigi/WFC/wildfly/standalone/configuration/standalone_xml_history/snapshot/20150301-165737562standalone.xml"
}

That's it! A backup of the standalone.xml file gets copied into the snapshot folder, named by prefixing the file with the current date and time.

Tip

Always back up your configuration, especially when operating in a production environment.

主站蜘蛛池模板: 麦盖提县| 吴旗县| 茶陵县| 洱源县| 海安县| 松阳县| 两当县| 岗巴县| 思南县| 望谟县| 库尔勒市| 怀柔区| 得荣县| 大竹县| 平顶山市| 印江| 象山县| 定结县| 清远市| 临泉县| 岳阳县| 德格县| 交城县| 达拉特旗| 兴宁市| 广东省| 锡林浩特市| 扎囊县| 南充市| 泾川县| 喀什市| 咸阳市| 龙岩市| 安国市| 景德镇市| 马边| 翼城县| 肃北| 武冈市| 东兴市| 松溪县|