A method of installing an operating system, comprising: copying, by a processor in a terminal device, an installation boot file in an iso image file of a to-be-installed-operating system into a root directory of a removable storage device attached to the terminal device, wherein the iso image file is stored on the removable storage device; creating, by the processor, an installation script file, wherein the installation script file comprises a pre-installation script used to indicate that the iso image file in the removable storage device is to be mounted to a first folder of the terminal device; designating in the installation script file, by the processor, that a storage address of software installation packages in the iso image file is a storage address of the first folder; obtaining, by the processor, an updated iso image file by adding the installation script file to the iso image file; obtaining, by the processor, a startup disk by copying the updated iso image file into a hard disk, in which the operating system is to be installed, in the terminal device; and installing, by the processor, the operating system in the hard disk, by configuring the terminal device to boot from the startup disk and rebooting the terminal device using the startup disk and the installation boot file in the root directory of the removable storage device, wherein the installing of the operating system in the hard disk comprises: loading, by the processor, a compact disk boot file in the startup disk; loading, by the processor, a kernel and a ramfs file system by means of the compact disk boot file; loading, by the processor, the installation boot file in the root directory of the removable storage device after startup of the kernel; executing, by the processor, the installation script file by means of the loaded installation boot file to mount the iso image file in the removable storage device to the first folder; and loading, by the processor, the software installation packages in the first folder after obtaining from the installation script file that the storage address of the software installation packages is the storage address of the first folder. copying, by a processor in a terminal device, an installation boot file in an iso image file of a to-be-installed-operating system into a root directory of a removable storage device attached to the terminal device, wherein the iso image file is stored on the removable storage device; creating, by the processor, an installation script file, wherein the installation script file comprises a pre-installation script used to indicate that the iso image file in the removable storage device is to be mounted to a first folder of the terminal device; designating in the installation script file, by the processor, that a storage address of software installation packages in the iso image file is a storage address of the first folder; obtaining, by the processor, an updated iso image file by adding the installation script file to the iso image file; obtaining, by the processor, a startup disk by copying the updated iso image file into a hard disk, in which the operating system is to be installed, in the terminal device; and installing, by the processor, the operating system in the hard disk, by configuring the terminal device to boot from the startup disk and rebooting the terminal device using the startup disk and the installation boot file in the root directory of the removable storage device, wherein the installing of the operating system in the hard disk comprises: loading, by the processor, a compact disk boot file in the startup disk; loading, by the processor, a kernel and a ramfs file system by means of the compact disk boot file; loading, by the processor, the installation boot file in the root directory of the removable storage device after startup of the kernel; executing, by the processor, the installation script file by means of the loaded installation boot file to mount the iso image file in the removable storage device to the first folder; and loading, by the processor, the software installation packages in the first folder after obtaining from the installation script file that the storage address of the software installation packages is the storage address of the first folder. loading, by the processor, a compact disk boot file in the startup disk; loading, by the processor, a kernel and a ramfs file system by means of the compact disk boot file; loading, by the processor, the installation boot file in the root directory of the removable storage device after startup of the kernel; executing, by the processor, the installation script file by means of the loaded installation boot file to mount the iso image file in the removable storage device to the first folder; and loading, by the processor, the software installation packages in the first folder after obtaining from the installation script file that the storage address of the software installation packages is the storage address of the first folder.