Skip to content

Operating System

In this article

OS reinstallation, disks, kernel and Docker.

Why does CentOS start during the OS reinstallation?

This is the correct installation behavior. Currently, all OSes are installed via CentOS. After the installation is completed, the server will be rebooted into the selected OS during installation.

How do I format the server?

To delete data from a rented server quickly, you need just reinstall the operating system.

Reinstalling the operating system can be carried out through Invapi control panel - tab Reinstall (see the instructions) or using API methods.

Can you change the size of a disk or its partitioning through Invapi?

No, it is not possible to change the size of a disk or its partitioning through Invapi. These changes can only be made by directly connecting to the operating system — see How to expand the file system and Disk Partitioning without LVM.

My kernel and drivers are not updating/installing on Ubuntu

The problem where a new kernel or drivers (kernel modules) do not install can occur due to the /boot partition being full during simultaneous system kernel updates, preventing the build of new initial RAM disks (initrd). To check this, run the command:

sudo apt --fix-broken install

If you see errors in the output, check the fill level of the /boot partition. For this, look at the output of the command df -h /boot

/dev/sda2       739M  287M  398M  42% /boot   

For successful rebuilds of initrd, the number before the percentage fill of the /boot partition should be more than 200M. If there is no free space, then perform the following steps:

  1. Create a backup of the partition so you can quickly restore files if you accidentally delete necessary ones:

    sudo rsync -av /boot/ /boot.old/
    
  2. Look at the contents of the /boot partition and find all initrd images:

    ls /boot | grep 'initrd.img-'
    

    You should get output similar to this:

    initrd.img
    initrd.img-6.8.0-57-generic
    initrd.img-6.8.0-58-generic
    initrd.img-6.8.0-59-generic
    initrd.img-6.8.0-60-generic
    initrd.img-initrd.img
    initrd.img-initrd.img.old
    initrd.img.old  
    
  3. Delete extra initrd images, LEAVING THE LAST TWO. In our case we need to delete initrd.img-6.8.0-57-generic and initrd.img-6.8.0-58-generic.

    Attention

    The following commands may lead to a malfunction of your operating system, so pay attention to the versions of deleted files. There must be files for the last and second-to-last kernel versions in the /boot partition! You can check which kernel you are currently using with the command uname -a. If something goes wrong, you can restore the contents of the /boot partition from the backup made on step one with the command sudo rsync -av /boot.old/ /boot/.

    Do this with the command:

    rm -f /boot/initrd.img-6.8.0-57-generic
    

    Repeat it for each file.

    Do the same with the files vmlinuz and System.map (optional):

    rm -f /boot/vmlinuz-6.8.0-57-generic 
    rm -f /boot/System.map-6.8.0-57-generic
    
  4. Clean the system of packages related to old kernels and run post-installation and building of drivers and kernel modules with commands:

    sudo apt autoremove
    sudo apt --fix-broken install
    
  5. Reboot OS:

    reboot
    

I get an error with Docker Compose

If you receive an error like docker: 'compose' is not a docker command or docker-compose: command not found when running docker compose, it may mean that your operating system version is old where Docker Compose was not installed as a plugin or added to PATH. To solve this problem, follow these steps:

  1. Install Docker Compose (if not installed):

    mkdir -p ~/.docker/cli-plugins/
    curl -SL https://github.com/docker/compose/releases/latest/download/docker-compose-linux-x86_64 -o ~/.docker/cli-plugins/docker-compose
    chmod +x ~/.docker/cli-plugins/docker-compose
    

    Replace latest with the current version from the official repository if necessary.

  2. Check the installation:

    docker-compose --version
    

    If the command executes successfully, Docker Compose is installed.

  3. If the command is still not found, make sure that ~/.docker/cli-plugins/ is added to the environment variable PATH. Add this to ~/.bashrc or ~/.zshrc:

    export PATH=$PATH:~/.docker/cli-plugins/
    

    Then execute:

    source ~/.bashrc  # or source ~/.zshrc
    
  4. Check the installation again:

    docker-compose --version
    

How to Completely Remove Docker from an Installed OS Ubuntu

Our Ubuntu operating system images come with pre-installed Docker for convenience. If you do not need it or want to install a different version, use the following commands:

sudo apt remove docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
sudo apt autoremove
sudo rm -rf /var/lib/docker
sudo rm -rf /var/lib/containerd

Ensure Docker is removed by running the command docker --version.

Can you update the SSL certificate for the domain name attached to the server via Invapi?

No, you cannot update the certificate attached to the domain name via Invapi. If you installed the software from the marketplace when deploying the server, and you were assigned a domain name, you can update the certificate yourself using the Certbot container following this guide.

question_mark
Is there anything I can help you with?
question_mark
AI Assistant ×