RU2690415C1 - Technology of automatic start of an operating system on a hardware platform with elements not supported by operating system modules when the computer is turned on - Google Patents

Technology of automatic start of an operating system on a hardware platform with elements not supported by operating system modules when the computer is turned on Download PDF

Info

Publication number
RU2690415C1
RU2690415C1 RU2018130068A RU2018130068A RU2690415C1 RU 2690415 C1 RU2690415 C1 RU 2690415C1 RU 2018130068 A RU2018130068 A RU 2018130068A RU 2018130068 A RU2018130068 A RU 2018130068A RU 2690415 C1 RU2690415 C1 RU 2690415C1
Authority
RU
Russia
Prior art keywords
operating system
computer
hardware platform
hardware
guest operating
Prior art date
Application number
RU2018130068A
Other languages
Russian (ru)
Inventor
Владимир Сергеевич Белянкин
Сергей Александрович Васильев
Сергей Владимирович Дроздов
Алексей Викторович Непомнящих
Original Assignee
Акционерное Общество "Нппкт"
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Акционерное Общество "Нппкт" filed Critical Акционерное Общество "Нппкт"
Priority to RU2018130068A priority Critical patent/RU2690415C1/en
Application granted granted Critical
Publication of RU2690415C1 publication Critical patent/RU2690415C1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/4555Para-virtualisation, i.e. guest operating system has to be modified

Abstract

FIELD: computer equipment.SUBSTANCE: invention relates to computer operating system start-up methods. Physical hardware platform hardware platform physical device unit is used to install software tools for emulating another hardware platform, based on which a separate section of this physical block device is installed guest operating system, containing modules that do not support hardware platform elements of a physical computer, without creating in this section a separate partition table. Software platform hardware emulation hardware is configured to transmit all packets corresponding to the open system interaction model network layer from the physical computer hardware to the guest operating system. Software platform hardware emulation hardware is configured to provide access to all computer input/output devices in the guest operating system. A configuration script is created in software tools for emulating a hardware platform for providing access in a guest operating system to devices connected via a universal serial bus. Software platform hardware emulation hardware is configured to automatically start the guest operating system when the computer is turned on.EFFECT: technical result is shorter time for launching a guest operating system on a hardware platform with elements not supported by guest operating system modules in a software platform hardware emulation environment.7 cl, 2 tbl

Description

Изобретение относится к области вычислительной техники, а более точно - к способам запуска операционной системы компьютера.The invention relates to the field of computing, and more precisely to methods of launching the operating system of the computer.

Из уровня техники известен способ обработки ресурса, операционная система и устройство (патент на изобретение RU №2639693), запуск корневой операционной системы; обнаружение посредством корневой операционной системы множества физических ресурсов; запуск посредством корневой операционной системы гипервизора; прием посредством гипервизора от корневой операционной системы информации, представляющей множество физических ресурсов; запуск посредством гипервизора экземпляра виртуальной машины для корневой операционной системы; инициализацию виртуальной машины с помощью состояния, согласованного с информацией; возобновление работы корневой операционной системы так, что корневая операционная система взаимодействует опосредованно с упомянутым множеством физических ресурсов через экземпляр виртуальной машины. Недостатком этого технического решения является невозможность автоматического запуска операционной системы на аппаратной платформе с элементами, неподдерживаемыми модулями операционной системы, при включении компьютера.In the prior art a method for processing a resource, an operating system and a device (patent RU invention No. 2639693), the launch of the root operating system; the discovery through the root operating system of many physical resources; running through the root operating system hypervisor; Reception by the hypervisor from the root operating system of information representing a variety of physical resources; running through the hypervisor a virtual machine instance for the root operating system; initialization of the virtual machine using the state consistent with the information; resuming the operation of the root operating system so that the root operating system interacts indirectly with the mentioned plurality of physical resources through a virtual machine instance. The disadvantage of this technical solution is the impossibility of automatically starting the operating system on a hardware platform with elements that are not supported by the modules of the operating system when the computer is turned on.

Технической задачей заявляемого изобретения является обеспечение возможности автоматического запуска операционной системы на аппаратной платформе с элементами, неподдерживаемыми модулями операционной системы, при включении компьютера.The technical task of the claimed invention is to provide the ability to automatically start the operating system on a hardware platform with elements that are not supported by the modules of the operating system when the computer is turned on.

Решение технической задачи обеспечивается за счет того, что на физическое блочное устройство аппаратной платформы физического компьютера устанавливаются программные средства эмуляции другой аппаратной платформы, на базе которых на отдельный раздел этого физического блочного устройства устанавливается гостевая операционная система, содержащая модули, не поддерживающие элементы аппаратной платформы физического компьютера, без создания в этом разделе отдельной таблицы разделов; затем выполняется настройка программных средств эмуляции аппаратной платформы для передачи всех пакетов, соответствующих сетевому уровню модели взаимодействия открытых систем, из аппаратного обеспечения физического компьютера в гостевую операционную систему; после чего выполняется настройка программных средств эмуляции аппаратной платформы для предоставления доступа ко всем устройствам ввода-вывода компьютера в гостевой операционной системы; затем создается конфигурационный сценарий в программных средствах эмуляции аппаратной платформы для предоставления доступа в гостевой операционной системы к устройствам, подключаемым через универсальную последовательную шину; затем выполняется настройка программных средств гостевой операционной системе, устанавливающая разрешение виртуального графического адаптера, соответствующее рекомендованному разрешению дисплея компьютера; далее устанавливается запрет использования комбинаций клавиш, осуществляющих переключение виртуальных рабочих столов программных средств эмуляции аппаратной платформы, для предотвращения переключения работы устройств ввода-вывода из гостевой операционной системы в программные средства эмуляции аппаратной платформы; затем выполняется настройка программных средств эмуляции аппаратной платформы для автоматического запуска гостевой операционной системы при включении компьютера.The solution of the technical problem is ensured by the fact that emulation software of another hardware platform is installed on the physical block device of the hardware platform of a physical computer, on the basis of which a guest operating system is installed on a separate partition of this physical block device; , without creating a separate partition table in this section; then, software emulation of the hardware platform is configured to transfer all packets corresponding to the network layer of the open systems interaction model from the physical computer hardware to the guest operating system; after that, software emulation of the hardware platform is configured to provide access to all computer I / O devices in the guest operating system; then a configuration script is created in the hardware emulation software of the hardware platform to provide access to the guest operating system to devices connected via a universal serial bus; then the software is configured for the guest operating system, setting the resolution of the virtual graphics adapter to match the recommended resolution of the computer display; further, it prohibits the use of key combinations that switch virtual desktops of the hardware emulation software of the hardware platform to prevent switching the operation of input-output devices from the guest operating system to the hardware emulation software of the hardware platform; then the hardware platform emulation software is configured to automatically start the guest operating system when the computer is turned on.

Для расширения функциональных возможностей по использованию технологии установка гостевой операционной системы, содержащей модули, не поддерживающие элементы аппаратной платформы физического компьютера, может выполняться на отдельный раздел физического блочного устройства компьютера с установленными программными средствами эмуляции аппаратной платформы компьютера с созданием в этом разделе отдельной таблицы разделов.To extend the functionality of using the technology, the installation of a guest operating system containing modules that do not support elements of the physical computer's hardware platform can be performed on a separate partition of the physical block device of the computer with installed software emulating the computer's hardware platform with the creation of a separate partition table in this section.

Для расширения функциональных возможностей по использованию технологии установка гостевой операционной системы, содержащей модули, не поддерживающие элементы аппаратной платформы физического компьютера, может выполняться на раздел отдельного физического блочного устройства компьютера без установленных на нем программных средств эмуляции аппаратной платформы компьютера с созданием в этом разделе отдельной таблицы разделов.To extend the functionality of using technology, the installation of a guest operating system containing modules that do not support elements of the hardware platform of a physical computer can be performed on a partition of a separate physical block device of a computer without software emulation software installed on it, creating a separate partition table in this section .

Для расширения функциональных возможностей по использованию технологии установка гостевой операционной системы, содержащей модули, не поддерживающие элементы аппаратной платформы физического компьютера, может выполняться на раздел отдельного физического блочного устройства компьютера без установленных на нем программных средств эмуляции аппаратной платформы компьютера без создания в этом разделе отдельной таблицы разделов.To extend the functionality of using the technology, the installation of a guest operating system containing modules that do not support elements of the hardware platform of a physical computer can be performed on a partition of a separate physical block device of a computer without software installed on it emulating the hardware platform of a computer without creating a separate partition table in this partition .

Для расширения функциональных возможностей по использованию технологии установка гостевой операционной системы, содержащей модули, не поддерживающие элементы аппаратной платформы физического компьютера, может выполняться на отдельное физическое блочное устройство компьютера без установленных на нем программных средств эмуляции аппаратной платформы компьютера с созданием отдельной таблицы разделов.To extend the functionality of using the technology, the installation of a guest operating system that contains modules that do not support elements of the hardware platform of a physical computer can be performed on a separate physical block device of a computer without software installed on it that emulates a computer hardware platform and creates a separate partition table.

Для расширения функциональных возможностей по использованию технологии установка гостевой операционной системы, содержащей модули, не поддерживающие элементы аппаратной платформы физического компьютера, может выполняться на отдельное физическое блочное устройство компьютера без установленных на нем программных средств эмуляции аппаратной платформы компьютера без создания отдельной таблицы разделов.To extend the functionality of using the technology, the installation of a guest operating system that contains modules that do not support elements of the hardware platform of a physical computer can be performed on a separate physical block device of a computer without software installed on it emulating the hardware platform of the computer without creating a separate partition table.

Для расширения функциональных возможностей по использованию технологии установка гостевой операционной системы, содержащей модули, не поддерживающие элементы аппаратной платформы физического компьютера, может выполняться на виртуальный жесткий диск.To extend the functionality of using technology, the installation of a guest operating system containing modules that do not support elements of the physical computer's hardware platform can be performed on a virtual hard disk.

Достигаемый технический результат - сокращение времени запуска гостевой операционной системы на аппаратной платформе с элементами, неподдерживаемыми модулями гостевой операционной системы в среде программных средств эмуляции аппаратной платформы.Technical result achieved is a reduction in the launch time of the guest operating system on a hardware platform with elements that are not supported by the guest operating system modules in the hardware emulation software environment.

Описание изобретенияDescription of the invention

Принцип функционирования:The principle of operation:

1) На аппаратную платформу физического компьютера с элементами, не поддерживаемыми модулями операционной системы устанавливаются программные средства эмуляции другой аппаратной платформы;1) The hardware emulation of another hardware platform is installed on the hardware platform of the physical computer with elements not supported by the modules of the operating system;

2) В программные средства эмуляции другой аппаратной платформы устанавливается гостевая операционная система, которая не может быть установлена на аппаратную платформу физического компьютера с элементами, не поддерживаемыми модулями операционной системы обычным методом в связи с несовместимостью;2) In the emulation software of another hardware platform, a guest operating system is installed that cannot be installed on the physical computer hardware platform with elements not supported by the operating system modules by the usual method due to incompatibility;

3) Установленные программные средства эмуляции другой аппаратной платформы и установленная в ней гостевая операционная система настраиваются таким образом, что конечный пользователь не замечает прослойки между аппаратной платформой физического компьютера с элементами, не поддерживаемыми модулями операционной системы и гостевой операционной системой в лице программных средств эмуляции другой аппаратной платформы и работает с готовым решением как с обычным компьютером с установленной на нем операционной системой напрямую, а также не тратит время на отдельный запуск необходимых компонентов.3) The installed emulation software of another hardware platform and the guest operating system installed in it are configured so that the end user does not notice the layer between the hardware platform of the physical computer with elements not supported by the operating system modules and the guest operating system in the face of emulation software of another hardware platform and works with a ready-made solution as with a normal computer with an operating system installed on it directly, as well as spends time on the separate execution of necessary components.

• аппаратная платформа физического компьютера с элементами, не поддерживаемыми модулями операционной системы представляет собой компьютер, в котором присутствуют элементы (чипы, устройства) неподдерживаемые модулями определенных операционных систем.• The hardware platform of a physical computer with elements not supported by the modules of the operating system is a computer in which there are elements (chips, devices) that are not supported by the modules of certain operating systems.

Пример таких элементов:An example of such elements:

процессоры Intel Core 6 поколения;Intel Core 6 generation processors;

чипсеты Intel 100й серии;Intel 100th series chipsets;

встроенные видеокарты Intel UHD 630.Intel UHD 630 integrated graphics.

• гостевая операционная система представляет собой операционную систему, как правило возраст которой более 6 лет, не имеющую в своем составе модулей для поддержки конкретного оборудования, а также не имеющую возможности для обновления по каким-либо причинам.• The guest operating system is an operating system, usually more than 6 years old, not having modules for supporting specific equipment, and also not being able to upgrade for any reason.

Пример таких операционных систем:An example of such operating systems:

МСВС 3.0 изм. 04;MSVS 3.0 rev. 04;

МСВС 3.0 изм. 06;MSVS 3.0 rev. 06;

Astra Linux Special Edition 1.2.Astra Linux Special Edition 1.2.

• программные средства эмуляции другой аппаратной платформы представляют собой решение для предоставления запущенным под ее управлением операционным системам службы эмуляции, эмулируя реальное (физическое) аппаратное обеспечение конкретного компьютера и управления этими эмулированными машинами, выделения и освобождения ресурсов для них.• emulation software of another hardware platform is a solution to provide emulation services running under its control, emulating real (physical) hardware of a specific computer and managing these emulated machines, allocating and freeing resources for them.

Пример таких программных средств эмуляции другой аппаратной платформы:An example of such emulation software is another hardware platform:

Горизонт-ВС 1.0.Horizon-Sun 1.0.

Автоматический запуск операционной системы на аппаратной платформе физического компьютера с элементами, не поддерживаемыми модулями операционной системы, при включении компьютера необходим в случае, когда требуется выполнить запуск операционной системы на аппаратной платформе с элементами, неподдерживаемыми модулями операционной системы, таким образом, чтобы пользователь не тратил время на отдельный запуск необходимых компонентов.Automatic launch of the operating system on the hardware platform of a physical computer with elements not supported by the operating system modules, when the computer is turned on, it is necessary when it is necessary to start the operating system on a hardware platform with elements that are not supported by the modules of the operating system so that the user does not waste time on a separate launch of the necessary components.

Также изобретение решает проблему несовместимости устаревших операционных систем с чипсетами современных материнских плат. Пример:Also, the invention solves the problem of incompatibility of outdated operating systems with chipsets of modern motherboards. Example:

МСВС 3.0 изм. 04 не совместим с чипсетами Intel начиная с 7 серии включительно.MSVS 3.0 rev. 04 is not compatible with Intel chipsets from the 7th series inclusive.

МСВС 3.0 изм. 06 не совместим с чипсетами Intel начиная с 9 серии включительно.MSVS 3.0 rev. 06 is not compatible with Intel chipsets starting from the 9th series inclusive.

Или другая ОС несовместимая с каким-либо элементом компьютера, на котором требуется ее функционирование.Or another OS is incompatible with any element of the computer on which its operation is required.

Пример реализации изобретенияAn example implementation of the invention

В качестве примера пошаговая реализация изобретения приводится с использованием следующих компонентов:As an example, step-by-step implementation of the invention is provided using the following components:

• аппаратная платформа физического компьютера с элементами, не поддерживаемыми модулями операционной системы (далее аппаратная платформа):• hardware platform of a physical computer with elements not supported by operating system modules (hereinafter referred to as hardware platform):

компьютер с процессором Intel Core 6 поколения и чипсетом Intel 100й серии;a computer with an Intel Core 6 generation processor and Intel 100th series chipset;

• гостевая операционная система (далее операционная система или ОС):• guest operating system (hereinafter referred to as the operating system or OS):

МСВС 3.0 изм. 04;MSVS 3.0 rev. 04;

• программные средства эмуляции другой аппаратной платформы (далее Гипервизор):• software emulation of another hardware platform (hereinafter referred to as the Hypervisor):

Горизонт-ВС 1.0.Horizon-Sun 1.0.

1.1. Установить Горизонт-ВС 1.0. 1.1. Install Horizon-Sun 1.0.

- Разбивка диска:- Drive breakdown:

На примере жесткого диска размером 256Гб.For example, a hard disk size of 256GB.

Диск разбивается утилитой GParted, создается следующая структура:The disk is broken by the GParted utility, the following structure is created:

таблица MBRMBR table

Figure 00000001
Figure 00000001

Figure 00000002
Figure 00000002

1.2. Установка МСВС (или другой ОС) на раздел жесткого диска (/dev/sda а не /dev/sdaX). Выполнять только после п. 1.6.1.2. Installing MSVS (or another OS) on a hard disk partition (/ dev / sda and not / dev / sdaX). Perform only after paragraph 1.6.

На примере МСВС и Горизонт vlFor example, MSVS and Horizon vl

В менеджере ВМ выбрать готовую ВМIn VM manager, select ready VM

Создать диск RAW и выполнить установку МСВС в него, размер при этом не важен, можно выбрать 8Гб. Ставить только с одним разделом - /, ни swap, ни /home делать не надо.Create a RAW disk and install the MASS into it, the size is not important, you can choose 8GB. It is not necessary to install with only one partition - /, neither swap, nor / home.

Подключить готовый RAW образ с установленным МСВС в Горизонт. Для этого:Connect ready RAW image with installed MSWS in Horizon. For this:

Смонитровать через qemu-nbd:Install via qemu-nbd:

# modprobe nbd max_part=63# modprobe nbd max_part = 63

# qemu-nbd -с /dev/nbd0 имя_образа_raw.img# qemu-nbd -c / dev / nbd0 image_raw_im.img

# partprobe /dev/nbd0# partprobe / dev / nbd0

Посмотреть разделы на диске /dev/nbd0 можно так:You can view the sections on the / dev / nbd0 disk as follows:

# fdisk -1 /dev/nbd0# fdisk -1 / dev / nbd0

В выводе будет что-то типа:The output will be something like:

/dev/nbd0p1… - это и есть наша партиция, куда был установлен / МСВС/ dev / nbd0p1 ... - this is our partition where the / MAWS was installed

Выполнить посекторное копирование партиции nbd0p1 на необходимый раздел, у нас /dev/sda3:Perform sector-by-sector copying of the nbd0p1 partition to the required partition, we have / dev / sda3:

# dd if=/dev/nbd0p1 of=/dev/sda3 bs=4M# dd if = / dev / nbd0p1 of = / dev / sda3 bs = 4M

Дождаться завершения копирования и примонитровать /dev/sda3 к /mnt:Wait until copying is completed and install / dev / sda3 to / mnt:

# mount /dev/sda3 /mnt# mount / dev / sda3 / mnt

Монтирование должно выполниться успешно, а в каталоге /mnt будет / перенесенного МСВС.The mount should succeed, and in the / mnt directory there will be / transferred to MAWS.

Исправить в /mnt/… /etc/fstab (hda1 поменять на hda), /etc/lilo (путь должен указывать на текущий диск, это hda).Fix it in / mnt / ... / etc / fstab (change hda1 to hda), / etc / lilo (the path should point to the current disk, this is hda).

В менеджере ВМ заменить RAW диск на физический раздел /dev/sda3, подключить установочный диск МСВС. Включить ВМ и загрузиться с установочного диска, дойти до этапа выбора диска, не выбирать его, иначе будет перезаписана таблица разделов, чего нам не нужно. Перейти на другую консоль через Ctrl+Alt_F2. Создать папку /1 (важно именно создать директорию, а не пользоваться готовой, например /mnt). Смонтировать в /1 диска /dev/hda, а также выполнить:In the VM manager, replace the RAW disk with the physical partition / dev / sda3, connect the installation MSVS. Turn on the VM and boot from the installation disk, go to the disk selection stage, do not select it, otherwise the partition table will be overwritten, which we do not need. Switch to another console via Ctrl + Alt_F2. Create a folder / 1 (it is important to create a directory, and not to use ready, for example / mnt). Mount to / 1 disk / dev / hda, and execute:

# mount --bind /proc /1/ргос# mount --bind / proc / 1 / proc

# mount --bind /dev /1/dev# mount --bind / dev / 1 / dev

# mount --bind /sys /1/sys (в МСВС /sys нет, но если делать для другой ОС, то понадобится)# mount --bind / sys / 1 / sys (in MSVS / sys not, but if you do for another OS, you will need it)

Перейти в /1 и выполнить chroot. Запустить bash:Go to / 1 and execute chroot. Run bash:

# /bin/bash# / bin / bash

Выполнить lilo:Run lilo:

# /sbin/lilo# / sbin / lilo

Вывод не должен содержать ошибок.The output should not contain errors.

Отключить от ВМ установочный диск и перезагрузиться.Disconnect the installation disk from the VM and reboot.

Для проверки выключить ВМ и в Горизонте смонтировать /dev/sda3 в /mnt. Монтирование должно произойти успешно и в /mnt будет наблюдается / из МСВС.To check, turn off the VM and mount / dev / sda3 in / mnt in Horizon. Mounting should occur successfully and in / mnt will be observed / from MSWS.

Размонтировать /mnt и выполнить расширение ФС на весь раздел:Unmount / mnt and perform the FS expansion for the whole partition:

# resize2fs /dev/sda3# resize2fs / dev / sda3

Может появится сообщение, что сначала надо выполнить fsck… Выполните и повторите resize2… Должно завершиться успешно.A message may appear that you must first execute fsck ... Execute and repeat resize2 ... It should complete successfully.

Для проверки включить ВМ с МСВС и выполнить df -h, должен быть показан весь доступный объем раздела /dev/sda3 (МСВС видит его как /dev/hda) а не ранее выделенные 8Гб, которые были в RAW образе.To check if the VM with MSVS is enabled and execute df -h, the entire available partition size of / dev / sda3 (MSWS sees it as / dev / hda) should be displayed, and not the previously allocated 8GB that were in the RAW image.

1.3. Настройка сети:1.3. Network configuration:

- Сеть br0:- Network br0:

Создать файл /etc/sysconfig/network-scripts/ifcfg-br0:Create the file / etc / sysconfig / network-scripts / ifcfg-br0:

ONBOOT=yesONBOOT = yes

BOOTPROTO=staticBOOTPROTO = static

DEVICE=br0DEVICE = br0

TYPE=BridgeTYPE = Bridge

MTU=1500MTU = 1500

NOZEROCONFIG=noNOZEROCONFIG = no

USERCTL=yesUSERCTL = yes

DELAY=0DELAY = 0

IPADDR=10.238.38.10 # любой маловерятный адрес, чтобы не пересекался с популярными подсетямиIPADDR = 10.238.38.10 # any untrusted address, so as not to overlap with popular subnets

NETMASK=255.255.255.0NETMASK = 255.255.255.0

Этот интерфейс не обязательно должен "видеть" другие сети/узлы, главное, чтобы он был настроен.This interface does not have to "see" other networks / nodes, as long as it is configured.

Создать файл /etc/sysconfig/network-scripts/ifcfg-eth0:Create the / etc / sysconfig / network-scripts / ifcfg-eth0 file:

DEVICE=eth0DEVICE = eth0

ONBOOT=yesONBOOT = yes

BRIDGE=br0BRIDGE = br0

- Сеть br1:- Network br1:

Создать файл /etc/sysconfig/network-scripts/ifcfg-br1:Create the / etc / sysconfig / network-scripts / ifcfg-br1 file:

ONBOOT=yesONBOOT = yes

BOOTPROTO=staticBOOTPROTO = static

DEVICE=br1DEVICE = br1

TYPE=BridgeTYPE = Bridge

MTU=1500MTU = 1500

NOZEROCONFIG=noNOZEROCONFIG = no

USERCTL=yesUSERCTL = yes

DELAY=0DELAY = 0

IPADDR=10.238.38.11 # любой маловерятный адрес, чтобы не пересекался с популярными подсетямиIPADDR = 10.238.38.11 # any untrusted address, so as not to overlap with popular subnets

NETMASK=255.255.255.0NETMASK = 255.255.255.0

Создать файл /etc/sysconfig/network-scripts/ifcfg-eth0:Create the / etc / sysconfig / network-scripts / ifcfg-eth0 file:

DEVICE=eth0DEVICE = eth0

ONBOOT=yesONBOOT = yes

BRIDGE=br0BRIDGE = br0

Этот интерфейс не обязательно должен "видеть" другие сети/узлы, главное, чтобы он был настроен.This interface does not have to "see" other networks / nodes, as long as it is configured.

Выполнить:Run:

/etc/init.d/networking restart/etc/init.d/networking restart

Проверим, должно быть похоже «br0 8000.08608ee7dc58 no eth0»:Check, it should be like “br0 8000.08608ee7dc58 no eth0”:

brctl showbrctl show

1.4. Включение возможности запуска сторонних скриптов:1.4. Enabling the ability to run third-party scripts:

ВНИМАНИЕ! Скрипты, как и любые другие файлы, не должны добавляться в каталог /usrATTENTION! Scripts, like any other files, should not be added to the / usr directory

В файле /etc/rc.d/rc.sysinit закоментировать все строки начиная с:In the /etc/rc.d/rc.sysinit file, comment out all lines starting with:

#--------------- IMA start ----------------# --------------- IMA start ----------------

и заканчивая:and ending with:

#--------------- IMA end --------------------------------- IMA end ------------------

Перезагрузить хостReboot host

1.5. Настройка тачпада для работы в гостевой ВМ:1.5. Setting up the touchpad to work in the guest VM:

Привести файл /etc/udev/rules.d/99-mouse-power-on.rules к виду:Bring the file /etc/udev/rules.d/99-mouse-power-on.rules to the form:

ACTION=="add", SUBSYSTEM=="usb", ENV{ID_CLASS}=="mouse", TEST=="power/control", ATTR{power/control}="off''ACTION == "add", SUBSYSTEM == "usb", ENV {ID_CLASS} == "mouse", TEST == "power / control", ATTR {power / control} = "off ''

ВНИМАНИЕ! Без этой настройки тачпад гарантированно не будет работать. Но и с ней иногда может проявляться неработоспособность тачпада, для исправления необходимо перезагрузить хостATTENTION! Without this setting, the touchpad is guaranteed not to work. But even with it, the touchpad may sometimes appear inoperable, to fix it, you need to restart the host

1.6. Создание виртуальной машины:1.6. Creating a virtual machine:

Выполним команду:Run the command:

virt-install --connect qemu:///system -n msvs2 --ram 4096 --arch=i586 --vcpus=2 --cpu core2duo --os-type linux --boot cdrom,hd,menu=on --disk pool=vm_store,cache=none,size=50,format=qcow2 --network=bridge:br0,model=e1000 --graphics spice,listen=0.0.0.0,keymap=ru --noautoconsole --watchdog default,action=reset --virt-type=kvm --autostart -cdrom=/dev/cdromvirt-install --connect qemu: /// system -n msvs2 --ram 4096 --arch = i586 --vcpus = 2 --cpu core2duo --os-type linux --boot cdrom, hd, menu = on - -disk pool = vm_store, cache = none, size = 50, format = qcow2 --network = bridge: br0, model = e1000 --graphics spice, listen = 0.0.0.0, keymap = en --noautoconsole --watchdog default, action = reset --virt-type = kvm --autostart -cdrom = / dev / cdrom

, все опции здесь по-идее понятны.All the options here are clear.

Дальнейшие действия будут описаны для работы с портом 5900, который присваивается автоматически.Further actions will be described for working with port 5900, which is assigned automatically.

Для машины можно настроить конкретный порт. Для этого надо отредактировать ееFor the machine, you can configure a specific port. For this you need to edit it.

конфиг в /etc/libvirt/qemu/msvs2.xml: <graphics type='spice' port='5938' autoport='no' listen='0.0.0.0'config in /etc/libvirt/qemu/msvs2.xml: <graphics type = 'spice' port = '5938' autoport = 'no' listen = '0.0.0.0'

Установить МСВС по п. 1.2. Добавить созданный домен в автозагрузку virsh. В менеджере виртуальных машин подключить все сетевые интерфейсы (сетевые мосты), возможно они не определяться сразу и перед этим придется перезагрузить хост.To install the MAWS under clause 1.2. Add the created domain to virsh autoload. In the virtual machine manager, connect all network interfaces (network bridges), they may not be detected immediately and you will have to restart the host before.

1.7. Настройка графики внутри гостевой ВМ.1.7. Setting graphics inside the guest VM.

Внутри гостевой ВМ отредактировать файл /etc/X11/xorg.conf:Inside the guest VM, edit the /etc/X11/xorg.conf file:

В секции "Monitor" исправить:In the section "Monitor" fix:

HorizSync на 31.5-90HorizSync at 31.5-90

VertRefresh на 50-180VertRefresh at 50-180

добавить строку Option "PrefferedMode" "1920х1080_60.0"Add the line Option "PrefferedMode" "1920x1080_60.0"

закомментировать Option "dpms"comment out Option "dpms"

В секции "Device" исправить:In the section "Device" fix:

закомментировать строки Identifiercomment out the Identifier lines

DriverDriver

VendorNameVendorname

BoardNameBoardName

добавить Identifier "Device0"add Identifier "Device0"

добавить Driver "vmware"Add Driver "vmware"

В секции "Screen" исправить:In the "Screen" section fix:

закомментировать строки Devicecomment out the Device lines

DefaultDepthDefaultDepth

DepthDepth

ModesModes

добавить Device "Device0"add Device "Device0"

добавить DefaultDepth "16"Add DefaultDepth "16"

добавить Depth 16add Depth 16

добавить Modes "1920x1080"Add Modes "1920x1080"

Сохранить изменения и выключить ВМ. Также выключить ВМ в virsh. После этого приступить к изменению конфига ВМ, для этого редактировать файл /etc/libvirt/qemu/msvs2.xml (заранее сделать копию):Save changes and turn off VM. Also turn off the VM in virsh. After that, start changing the VM config, to do this, edit the file /etc/libvirt/qemu/msvs2.xml (make a copy in advance):

Изменить видеокарту в домене:Change the video card in the domain:

В файлеIn file

/etc/libvirt/qemu/msvs2.xml/etc/libvirt/qemu/msvs2.xml

изменить секциюchange section

<video><video>

на:on:

<video><video>

<model type='vmvga' vram='65536' heads='1'/><model type = 'vmvga' vram = '65536' heads = '1' />

<address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/><address type = 'pci' domain = '0x0000' bus = '0x00' slot = '0x02' function = '0x0' />

</video></ video>

1.8. Настройка автоматического проброса USB устройств с хоста в гостевую ВМ:1.8. Setting up automatic probros USB devices from the host to the guest VM:

ВНИМАНИЕ! Эта функцию будет работать только после включения хоста. Все USB устройства, подключенные к хосту до его включения не будут проброшены в ВМ.ATTENTION! This feature will work only after turning on the host. All USB devices connected to the host before it is turned on will not be forwarded to the VM.

Все USB устройства, подключенные после включения хоста и ВМ будут проброшены в ВМ.All USB devices connected after switching on the host and the VM will be forwarded to the VM.

Существует особенность - разные USB устройства с одинаковыми PID и VID не будут подключены одновременно, их следует подключать по очереди.There is a feature - different USB devices with the same PID and VID will not be connected at the same time, they should be connected in turn.

Создать правило UDEV /etc/udev/rules.d/97-udev-kvmusbattach.rules:Create a UDEV rule /etc/udev/rules.d/97-udev-kvmusbattach.rules:

ACTION=="add", SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", RUN+="/etc/udev/attach.sh $env{ID_VENDOR_ID} ${ID_MODEL_ID}"ACTION == "add", SUBSYSTEM == "usb", ENV {DEVTYPE} == "usb_device", RUN + = "/ etc / udev / attach.sh $ env {ID_VENDOR_ID} $ {ID_MODEL_ID}"

Создать правило UDEV /etc/udev/rules.d/97-udev-kvmusbdetach.rules:Create a UDEV rule /etc/udev/rules.d/97-udev-kvmusbdetach.rules:

ACTION=="remove", SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", RUN+="/etc/udev/detach.sh $env{ID_VENDOR_ID} ${ID_MODEL_ID}"ACTION == "remove", SUBSYSTEM == "usb", ENV {DEVTYPE} == "usb_device", RUN + = "/ etc / udev / detach.sh $ env {ID_VENDOR_ID} $ {ID_MODEL_ID}"

Создать скрипт в /etc/udev/attach.sh:Create a script in /etc/udev/attach.sh:

#!/bin/bash#! / bin / bash

touch /root/usbdev_${l}:${2}.xmltouch /root/usbdev_${l}:${2}.xml

cat <<EOF > /root/usbdev_${l}:${2}.xmlcat << EOF> /root/usbdev_${l}:${2}.xml

<hostdev mode='subsystem' type='usb'><hostdev mode = 'subsystem' type = 'usb'>

<source><source>

<vendor id='0x${l}'/><vendor id = '0x $ {l}' />

<product id='0x${2}'/><product id = '0x $ {2}' />

</source></ source>

</hostdev></ hostdev>

EOFEOF

/usr/bin/virsh attach-device msvs2 /root/usbdev_${l}\:${2}.xml/ usr / bin / virsh attach-device msvs2 /root/usbdev_${ll\\\:${2}.xml

exit 0exit 0

Создать скрипт в /etc/udev/detach.sh:Create a script in /etc/udev/detach.sh:

#!/bin/bash#! / bin / bash

virsh detach-device msvs2 /root/usbdev_${l}\:${2}.xmlvirsh detach-device msvs2 /root/usbdev_${l}\:${2}.xml

rm /root/usbdev_${l}\:${2}.xmlrm /root/usbdev_${ll\\\:${2}.xml

exit 0exit 0

После этого все USB устройства, подключенные после включения хоста и ВМ будут проброшены в ВМ.After that, all USB devices connected after turning on the host and the VM will be forwarded to the VM.

1.9. Настройка проброса СОМ портов с хоста в гостевую ВМ:1.9. Configure forwarding COM ports from host to guest VM:

В менеджере виртуальный машин перейти в настройки домена msvs2 и выбрать:In the virtual machine manager, go to the msvs2 domain settings and select:

Добавить оборудование -> последовательный порт -> тип physical host character device, далее указать ttySXAdd hardware -> serial port -> type physical host character device, then specify ttySX

Определить список СОМ портов возможно командой:It is possible to determine the list of COM ports using the command:

dmesg | grep ttydmesg | grep tty

В выводе порты будут обозначены как ttySXIn the output ports will be labeled ttySX

1.10. Настройка звука в гостевой ВМ.1.10. Sound settings in the guest VM.

В менеджере виртуальный машин перейти в настройки домена msvs2 и выбрать:In the virtual machine manager, go to the msvs2 domain settings and select:

Звуковая карта -> Выбрать АС97Sound card -> Select AC97

В гостевой ВМ выполнить перезагрузку и согласиться на автонастройку нового оборудования. После этого запустить alsaconf и согласиться с предложенным.In the guest VM, reboot and agree to auto-tune the new equipment. After that, run alsaconf and agree with the proposed.

После этого в alsamixer выбрать необходимый уровень громкости.After that in alsamixer select the desired volume level.

На хосте выполнить настройку переадрисации звука из приложения в физическое устройство (с помощью pulseaudio):On the host, configure the audio redirection from the application to the physical device (using pulseaudio):

ВНИМАНИЕ! Встроенная звуковая карта не поддерживается в Горизонт-ВС. Предлагается использовать USB-звуковую карту и внешние колонки/наушники.ATTENTION! Built-in sound card is not supported in Horizon-Sun. It is proposed to use a USB sound card and external speakers / headphones.

При этом подключать USB-звуковую карту следует до включения хоста.In this case, you should connect a USB sound card before turning on the host.

В файл /etc/xdg/lxsession/LXDE/autostart добавить строку:In the / etc / xdg / lxsession / LXDE / autostart file add the line:

@pactl move-sink-input 1 0@pactl move-sink-input 1 0

Перезагрузить хостReboot host

1.11. Настройка автоматического запуска гостевой ВМ:1.11. Configuring the automatic launch of the guest VM:

ВНИМАНИЕ! После применения этой настройки получить доступ к хосту без инструментальной флешки будет невозможно.ATTENTION! After applying this setting, you will not be able to access the host without a tool stick.

Данная настройка позволит запускать гостевую ВМ на весь экран без запуска графического стола хоста. Также будет добавлено автоматическое выключение хоста после выключения гостевой ВМ.This setting will allow launching the guest VM to full screen without launching the host graphical table. An automatic shutdown of the host will also be added after shutting down the guest VM.

Создать скрипт /etc/xdg/lxsession/LXDE/auto.sh с содержимым:Create a /etc/xdg/lxsession/LXDE/auto.sh script with the contents:

#!/bin/bash#! / bin / bash

remote-viewer spice://0.0.0.0:5900 -fremote-viewer spice: //0.0.0.0: 5900 -f

poweroffpoweroff

exit 0exit 0

Привести файл /etc/X11/xinit/xinitrc.d/60windowmanager к виду:Bring the file /etc/X11/xinit/xinitrc.d/60windowmanager to the form:

export LANG=ru_RU.UTF-8export LANG = en_RU.UTF-8

#/bin/startlxde# / bin / startlxde

/etc/xdg/lxsession/LXDE/auto.sh/etc/xdg/lxsession/LXDE/auto.sh

1.12. Отключение Ctrl+Alt+FX:1.12. Disable Ctrl + Alt + FX:

Open/create the file /etc/X11/xorg.conf using the following command:Open / create the file /etc/X11/xorg.conf using the following command:

sudo -i gedit /etc/X11/xorg.confsudo -i gedit /etc/X11/xorg.conf

and add the following lines inside:and add the following lines inside:

Section "ServerFlags"Section "ServerFlags"

Option "DontVTSwitch" "true"Option "DontVTSwitch" "true"

EndSectionEndsection

1.13. Смена комбинации клавиш для перехода в хост-систему:1.13. Change key combination to go to the host system:

В менеджере ВМ применить соответствующую настройку.In the VM manager, apply the appropriate setting.

Использовать LCtrl+LAlt+hUse LCtrl + LAlt + h

Достижимость технического результата - сокращение времени запуска операционной системы на аппаратной платформе с элементами, неподдерживаемыми модулями операционной системы, при включении компьютера - подтверждается результатами испытаний (табл. 2).Achievable technical result - reducing the startup time of the operating system on a hardware platform with elements that are not supported by the modules of the operating system when the computer is turned on - is confirmed by the test results (Table 2).

Figure 00000003
Figure 00000003

Claims (7)

1. Способ запуска операционной системы на аппаратной платформе физического компьютера с элементами, не поддерживаемыми модулями операционной системы, состоящий в том, что на физическое блочное устройство аппаратной платформы физического компьютера устанавливаются программные средства эмуляции другой аппаратной платформы, на базе которых на отдельный раздел этого физического блочного устройства устанавливается гостевая операционная система, содержащая модули, не поддерживающие элементы аппаратной платформы физического компьютера, без создания в этом разделе отдельной таблицы разделов; затем выполняется настройка программных средств эмуляции аппаратной платформы для передачи всех пакетов, соответствующих сетевому уровню модели взаимодействия открытых систем, из аппаратного обеспечения физического компьютера в гостевую операционную систему; после чего выполняется настройка программных средств эмуляции аппаратной платформы для предоставления доступа ко всем устройствам ввода-вывода компьютера в гостевой операционной системе; затем создается конфигурационный сценарий в программных средствах эмуляции аппаратной платформы для предоставления доступа в гостевой операционной системе к устройствам, подключаемым через универсальную последовательную шину; затем выполняется настройка программных средств гостевой операционной системы, устанавливающая разрешение виртуального графического адаптера, соответствующее рекомендованному разрешению дисплея компьютера; далее устанавливается запрет использования комбинаций клавиш, осуществляющих переключение виртуальных рабочих столов программных средств эмуляции аппаратной платформы, для предотвращения переключения работы устройств ввода-вывода из гостевой операционной системы в программные средства эмуляции аппаратной платформы; затем выполняется настройка программных средств эмуляции аппаратной платформы для автоматического запуска гостевой операционной системы при включении компьютера.1. The method of launching the operating system on the hardware platform of a physical computer with elements not supported by the modules of the operating system, consisting in that the physical block device of the hardware platform of the physical computer installs software emulation of another hardware platform, on the basis of which a separate section of this physical block device is installed guest operating system containing modules that do not support elements of the hardware platform of the physical computer , without creating a separate partition table in this section; then, software emulation of the hardware platform is configured to transfer all packets corresponding to the network layer of the open systems interaction model from the physical computer hardware to the guest operating system; after which the software emulation hardware platform is configured to provide access to all computer I / O devices in the guest operating system; then a configuration script is created in the hardware emulation software of the hardware platform to provide access in the guest operating system to devices connected via a universal serial bus; then the software of the guest operating system is configured, which sets the resolution of the virtual graphics adapter to the recommended resolution of the computer display; further, it prohibits the use of key combinations that switch virtual desktops of the hardware emulation software of the hardware platform to prevent switching the operation of input-output devices from the guest operating system to the hardware emulation software of the hardware platform; then the hardware platform emulation software is configured to automatically start the guest operating system when the computer is turned on. 2. Способ по п. 1, отличающийся тем, что установка гостевой операционной системы, содержащей модули, не поддерживающие элементы аппаратной платформы физического компьютера, выполняется на отдельный раздел физического блочного устройства компьютера с установленными программными средствами эмуляции аппаратной платформы компьютера с созданием в этом разделе отдельной таблицы разделов.2. The method according to p. 1, characterized in that the installation of a guest operating system containing modules that do not support elements of the hardware platform of the physical computer is performed on a separate section of the physical block device of the computer with installed software emulating the hardware platform of the computer with creating in this section a separate partition tables. 3. Способ по п. 1, отличающийся тем, что установка гостевой операционной системы, содержащей модули, не поддерживающие элементы аппаратной платформы физического компьютера, выполняется на раздел отдельного физического блочного устройства компьютера без установленных на нем программных средств эмуляции аппаратной платформы компьютера с созданием в этом разделе отдельной таблицы разделов.3. The method according to p. 1, characterized in that the installation of a guest operating system containing modules that do not support elements of the hardware platform of the physical computer is performed on the partition of a separate physical block device of the computer without software installed on it emulating the hardware platform of the computer with the creation of section of a separate partition table. 4. Способ по п. 1, отличающийся тем, что установка гостевой операционной системы, содержащей модули, не поддерживающие элементы аппаратной платформы физического компьютера, выполняется на раздел отдельного физического блочного устройства компьютера без установленных на нем программных средств эмуляции аппаратной платформы компьютера без создания в этом разделе отдельной таблицы разделов.4. The method according to p. 1, characterized in that the installation of a guest operating system containing modules that do not support elements of the hardware platform of the physical computer is performed on a partition of a separate physical block device of the computer without software installed on it emulating the hardware platform of the computer without creating this section of a separate partition table. 5. Способ по п. 1, отличающийся тем, что установка гостевой операционной системы, содержащей модули, не поддерживающие элементы аппаратной платформы физического компьютера, выполняется на отдельное физическое блочное устройство компьютера без установленных на нем программных средств эмуляции аппаратной платформы компьютера с созданием отдельной таблицы разделов.5. The method according to p. 1, characterized in that the installation of a guest operating system containing modules that do not support elements of the hardware platform of the physical computer is performed on a separate physical block device of the computer without software installed on it emulating the hardware platform of the computer with the creation of a separate partition table . 6. Способ по п. 1, отличающийся тем, что установка гостевой операционной системы, содержащей модули, не поддерживающие элементы аппаратной платформы физического компьютера, выполняется на отдельное физическое блочное устройство компьютера без установленных на нем программных средств эмуляции аппаратной платформы компьютера без создания отдельной таблицы разделов.6. The method according to claim 1, wherein installing a guest operating system containing modules that do not support elements of the hardware platform of the physical computer is performed on a separate physical block device of the computer without software installed on it emulating the hardware platform of the computer without creating a separate partition table . 7. Способ по п. 1, отличающийся тем, что установка гостевой операционной системы, содержащей модули, не поддерживающие элементы аппаратной платформы физического компьютера, выполняется на виртуальный жесткий диск.7. The method according to p. 1, characterized in that the installation of a guest operating system containing modules that do not support elements of the hardware platform of the physical computer, is performed on a virtual hard disk.
RU2018130068A 2018-08-20 2018-08-20 Technology of automatic start of an operating system on a hardware platform with elements not supported by operating system modules when the computer is turned on RU2690415C1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
RU2018130068A RU2690415C1 (en) 2018-08-20 2018-08-20 Technology of automatic start of an operating system on a hardware platform with elements not supported by operating system modules when the computer is turned on

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
RU2018130068A RU2690415C1 (en) 2018-08-20 2018-08-20 Technology of automatic start of an operating system on a hardware platform with elements not supported by operating system modules when the computer is turned on

Publications (1)

Publication Number Publication Date
RU2690415C1 true RU2690415C1 (en) 2019-06-03

Family

ID=67037708

Family Applications (1)

Application Number Title Priority Date Filing Date
RU2018130068A RU2690415C1 (en) 2018-08-20 2018-08-20 Technology of automatic start of an operating system on a hardware platform with elements not supported by operating system modules when the computer is turned on

Country Status (1)

Country Link
RU (1) RU2690415C1 (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7409719B2 (en) * 2004-12-21 2008-08-05 Microsoft Corporation Computer security management, such as in a virtual machine or hardened operating system
US7945908B1 (en) * 2006-03-31 2011-05-17 Vmware, Inc. Method and system for improving the accuracy of timing and process accounting within virtual machines
RU2639693C1 (en) * 2013-12-17 2017-12-21 Хуавэй Текнолоджиз Ко., Лтд. Method for resource processing, operating system and device
US9983894B2 (en) * 2013-09-25 2018-05-29 Facebook, Inc. Method and system for providing secure system execution on hardware supporting secure application execution

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7409719B2 (en) * 2004-12-21 2008-08-05 Microsoft Corporation Computer security management, such as in a virtual machine or hardened operating system
US7945908B1 (en) * 2006-03-31 2011-05-17 Vmware, Inc. Method and system for improving the accuracy of timing and process accounting within virtual machines
US9983894B2 (en) * 2013-09-25 2018-05-29 Facebook, Inc. Method and system for providing secure system execution on hardware supporting secure application execution
RU2639693C1 (en) * 2013-12-17 2017-12-21 Хуавэй Текнолоджиз Ко., Лтд. Method for resource processing, operating system and device

Similar Documents

Publication Publication Date Title
US8990806B2 (en) Customized virtual machine creation
US9239814B2 (en) System and method for creating or reconfiguring a virtual server image for cloud deployment
EP2438515B1 (en) System and method for converting a java application into a virtual server image for cloud deployment
JP5599804B2 (en) How to allocate virtual storage
AU2014207721A1 (en) Master automation service
WO2008121873A1 (en) Synchronization and customization of a clone computer
JP2006018814A (en) System and method for development of emulated device in virtual machine environment
Takemura et al. The book of Xen: a practical guide for the system administrator
US10303487B2 (en) System and method for booting an information handling system
WO2018201461A1 (en) Method and device for migrating virtual machine and virtualization system
CN106648827A (en) Method for online adding virtual machine resources
Hale et al. Electrical Engineering and Computer Science Department
WO2020063432A1 (en) Method and apparatus for upgrading virtualized emulator
CN112256393A (en) Resource management method and equipment for bare metal server
Fenn et al. An evaluation of KVM for use in cloud computing
Deka et al. Application of virtualization technology in IaaS cloud deployment model
RU2690415C1 (en) Technology of automatic start of an operating system on a hardware platform with elements not supported by operating system modules when the computer is turned on
Haga et al. Windows server 2008 R2 hyper-V server virtualization
Vetter et al. IBM Power Systems HMC Implementation and Usage Guide
Curran et al. Virtualization Guide
WO2024008066A1 (en) Cloud computing technology-based server and cloud system
Aoki Debian reference
Shi et al. VNIX: Managing virtual machines on clusters
Kamppi ICT System for Courses in Computer Networking
Vallee et al. OSCAR testing with Xen