Oxidized is an open-source tool for backing up configurations of network devices. It allows network administrators to automate the process of backing up configurations from network devices, and it stores the data in a Git repository. This tutorial explains how to install Oxidized on Ubuntu server.
To follow this tutorial, you will need the following:
Oxidized requires Git to interact with Git repositories. To install Git, run the following command:
sudo apt update
sudo apt install git
Oxidized is written in Ruby, so to run Oxidized, you must have Ruby installed. Run the following command to install Ruby:
sudo apt install ruby-full
To install Oxidized, you need to clone the repo from GitHub. Run the following command to clone the Oxidized repo:
git clone https://github.com/ytti/oxidized.git
Oxidized requires several dependencies that must be installed before running it. To install the dependencies, change to the oxidized directory and run the following command:
cd oxidized
sudo gem install oxidized
After installing Oxidized, you need to configure it. Firstly, copy the example Oxidized configuration file from the examples directory to the /etc/oxidized directory:
sudo cp examples/oxidized.service /etc/systemd/system/
sudo cp examples/oxidized.conf /etc/oxidized/
Next, create the Git repository directory Oxidized will use to store the device configurations:
sudo mkdir /opt/oxidized
sudo chown <youruser>: /opt/oxidized
You can now edit the /etc/oxidized/oxidized.conf file to define the device to back up and the Git repository to store it.
sudo nano /etc/oxidized/oxidized.conf
In this file, look for the following section:
input:
default: ssh
ssh:
user: <username>
password: <password>
prompt: '>'
timeout: 20
This section defines the SSH details to connect to the network devices being backed up. These details include the username and password used to connect to the devices.
Next, look for the following section:
output:
default: git
git:
user: oxidized
email: oxidized@localhost.localdomain
repo: "/opt/oxidized/.git/"
branch: master
cron: '* * * * *'
This section defines the Git repository to store the device configurations.
You should change the email and the repo line to match your environment.
To test that Oxidized is working correctly, run the following command:
sudo oxidized-test
This will verify that Oxidized can connect to your devices and that the output is stored in the Git repository.oxidized
If there are any issues, review the configuration file to ensure that the SSH details, repository location, and other settings are set correctly.
After testing, start and enable the Oxidized service. Run the following command to start Oxidized:
sudo systemctl start oxidized.service
The following command will enable Oxidized service to start at boot:
sudo systemctl enable oxidized.service
You may check if the service is running by running:
sudo systemctl status oxidized.service
If everything is set up correctly, you should be able to backup the configuration for your network devices.
This tutorial explained how to install Oxidized on Ubuntu Server, configure it, and get started with backing up network device configurations. Oxidized is a useful tool for network administrators looking to automate critical tasks in their network infrastructure.
If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!
Alternatively, for the best virtual desktop, try Shells!