The invention discloses a
virtual machine mirror image generating method and a device based on
software preinstallation in cloud environment. The
virtual machine mirror image generating method and the device based on the
software preinstallation in the cloud environment comprise that softwares which are uploaded by users are received and dependency of the uploaded softwares are checked,
operating system configuration information which is submitted by the users is received and analyzed to obtain analysis results of the
operating system configuration information. Basic environment which is necessary to install an
operating system based on the
software preinstallation technology is generated according to the analysis results of the operating
system configuration information. A
virtual machine start is started by using a virtual
machine start configuration file in the generated environment and a monitoring progress is started at the same time. An operating
system installation program is operated in the virtual
machine and the operating
system is installed in a non-interactive mode. Meanwhile, the monitoring progress judges whether the installation of the operating system is wrong or accomplished or not. When the installation of the operating system is wrong, the virtual
machine is closed and temporary files in the basic environment are cleaned and
internet protocol (IP) address is returned to an
IP address pool. The virtual machine
mirror image generating method and the device based on the software preinstallation in the cloud environment can solve defects of an existing manner, wherein the defects of the existing manner are insufficient in flexibility, low in speed, serious in source consumption and the like.