Install MikroTik RouterOS (CHR) on a virtual server
Installation of Mikrotik CHR on our cloud infrastructure is possible for any virtual server tariff, including the minimum one with 1 CPU / 2 RAM / 30 GB NVMe characteristics.
In this article we will consider an example of manual installation of RouterOS cloud image using a virtual server based on SWEs-1 tariff.
To start MikroTik CHR installation you will need to order a virtual server in our customer area:
Information
We recommend that you familiarize yourself with the features of the customer area at link
As a test server, a SWEs-1 server will be deployed in the location Sweden (Stockholm).
When ordering the service you should also choose CentOS 7 OS, in which the work on further deployment of the CHR image will take place.
After ordering, the server will be activated within 120 seconds, then you can proceed to install MikroTik CHR according to the following instructions:
Connect to the server via SSH using the activation e-mail or the connection details provided on the service page.
Information
We recommend reading the connection instructions
Upload the required version of MikroTik CHR to the server from the official website at https://mikrotik.com/download (the example will focus on the latest currently stable version 7.8):
Warning
Warning! It is required to upload the CHR edition labeled as "Raw disk image"
- To do this, copy the link to the disk image from the site and get a direct link of the form
https://download.mikrotik.com/routeros/7.8/chr-7.8.img.zip
- Next, let's upload the image to the server using the command:
shellcurl <LINK> --output chr.img.zip # replace <LINK> in the command with the copied link
- After uploading the zipped image to the server, unzip it with the command:
shellgunzip -c chr.img.zip > chr.img
- To do this, copy the link to the disk image from the site and get a direct link of the form
Then write the unpacked image to the virtual disk of the server using the dd utility:
shelldd if=chr.img of=/dev/vda bs=4M oflag=sync
The image has been successfully written to disk, the only thing left to do is to reboot the server to initialize MikroTik CHR with the commands:
shellecho 1 > /proc/sys/kernel/sysrq echo b > /proc/sysrq-trigger
After executing the above commands, the MikroTik CHR OS will start running on your server.
The system is pretty much ready to go out of the box, but still requires some customization, such as setting the administrator password and initial network configuration. These settings are discussed below:
To access the system before the network has been configured, let's use the VMmanager control panel and VNC console:
In the VNC console, we will be greeted with a login prompt:
Information
To log in, let's use the default credentials:
Login: admin Password: no password (empty by default)
After successful login, the system will offer to read the software license. You should accept the offer by pressing the Y key or decline by pressing the N key.
Next, the system will ask you to change the default password of the admin user:
Information
It is recommended to use randomly generated passwords of at least 8 characters to protect the server from unauthorized access.
Once the superuser password has been changed, we can begin the network configuration. All required network parameters (IP address, gateway and mask) are specified in the customer area on the service page (in the "IP Addresses" subsection), as well as in the VMmanager PU (in the "IP Addresses" section):
Configure the network as follows:
shell/ip address add address=<IPv4>/32 network=<Gateway> broadcast=<IPv4> interface=ether1 /ip route add dst-address=0.0.0.0/0 gateway=<Gateway> /ip dns set servers=1.1.1.1,8.8.8.8
Information
<IPv4>
- IPv4 address of your server.<Gateway>
- Server gateway (default is 10.0.0.1).
Let's check the correctness of the configuration with the ping utility:
Done. The MikroTik CHR image is deployed on the virtual server and is fully ready for use.