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

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.

主站蜘蛛池模板: 永胜县| 邹城市| 通榆县| 襄垣县| 凤阳县| 澄江县| 西宁市| 武川县| 金湖县| 泌阳县| 繁昌县| 宁德市| 章丘市| 辰溪县| 都匀市| 石屏县| 招远市| 长海县| 包头市| 甘泉县| 垫江县| 商丘市| 中西区| 乐昌市| 霍州市| 达州市| 海城市| 祥云县| 柘荣县| 临安市| 英吉沙县| 成武县| 怀柔区| 县级市| 通化县| 虞城县| 康乐县| 厦门市| 白玉县| 临泽县| 东阳市|