gem5-users@gem5.org

The gem5 Users mailing list

View all threads

gem5art SPEC 2017 benchmark tutorial: error with packer building disk image

RM
Reiko Matsuda-dunn
Sat, Sep 25, 2021 4:54 AM

Hello,

I'm getting the following error when trying to build the disk image as
described here:
https://www.gem5.org/documentation/gem5art/tutorials/spec-tutorial

The final error is:
==> qemu: Provisioning step had errors: Running the cleanup provisioner, if
present...
==> qemu: Deleting output directory...
Build 'qemu' errored after 25 minutes 1 second: Script disconnected
unexpectedly. If you expected your script to disconnect, i.e. from a
restart, you can try adding "expect_disconnect": true or
"valid_exit_codes": [0, 2300218] to the shell provisioner parameters.

I've included the entire output below in case it's helpful. The host is
Ubuntu 20.04 and I'm using gem5 21. Everything else is the same as the
tutorial.

Thanks for all you do!


$./packer build spec-2017/spec-2017.json

qemu: output will be in this color.

==> qemu: Retrieving ISO
==> qemu: Trying
http://old-releases.ubuntu.com/releases/18.04.2/ubuntu-18.04.2-server-amd64.iso
==> qemu: Trying
http://old-releases.ubuntu.com/releases/18.04.2/ubuntu-18.04.2-server-amd64.iso?checksum=md5%3A34416ff83179728d54583bf3f18d42d2
==> qemu:
http://old-releases.ubuntu.com/releases/18.04.2/ubuntu-18.04.2-server-amd64.iso?checksum=md5%3A34416ff83179728d54583bf3f18d42d2
=>
/home/reiko/gem5-resources/src/spec-2017/disk-image/packer_cache/e94c06241a5e6ba0c4b9618ddcda39ba2ee27e9a.iso
==> qemu: Creating floppy disk...
qemu: Copying files flatly from floppy_files
qemu: Copying file: shared/preseed.cfg
qemu: Done copying files from floppy_files
qemu: Collecting paths from floppy_dirs
qemu: Resulting paths from floppy_dirs : []
qemu: Done copying paths from floppy_dirs
==> qemu: Starting HTTP server on port 8610
==> qemu: Found port for communicator (SSH, WinRM, etc): 4164.
==> qemu: Looking for available port between 5900 and 6000 on 127.0.0.1
==> qemu: Starting VM, booting from CD-ROM
qemu: The VM will be run headless, without a GUI. If you want to
qemu: view the screen of the VM, connect via VNC without a password to
qemu: vnc://127.0.0.1:82
==> qemu: Overriding default Qemu arguments with qemuargs template option...
==> qemu: Waiting 10s for boot...
==> qemu: Connecting to VM via VNC (127.0.0.1:5982)
==> qemu: Typing the boot command over VNC...
qemu: Not using a NetBridge -- skipping StepWaitGuestAddress
==> qemu: Using ssh communicator to connect: 127.0.0.1
==> qemu: Waiting for SSH to become available...
==> qemu: Connected to SSH!
==> qemu: Uploading ../gem5/util/m5/build/x86/out/m5 => /home/gem5/
qemu: m5 2.40 MiB / 2.40 MiB [
---==]
100.00% 0s
==> qemu: Uploading shared/serial-getty(a).service => /home/gem5/
qemu: serial-getty(a).service 1.45 KiB / 1.45 KiB [================]
100.00% 0s
==> qemu: Uploading spec-2017/runscript.sh => /home/gem5/
qemu: runscript.sh 1.16 KiB / 1.16 KiB [=========================]
100.00% 0s
==> qemu: Uploading spec-2017/cpu2017-1.1.0.iso => /home/gem5/
qemu: cpu2017-1.1.0.iso 2.83 GiB / 2.83 GiB [=================] 100.00%
1m43s
==> qemu: Provisioning with shell script: spec-2017/post-installation.sh
qemu: Post Installation Started
qemu: Post Installation Done
==> qemu: [sudo] password for gem5:
==> qemu: Provisioning with shell script: spec-2017/install-spec2017.sh
qemu: Reading package lists...
qemu: Building dependency tree...
qemu: Reading state information...
qemu: build-essential is already the newest version (12.4ubuntu1).
qemu: The following additional packages will be installed:
qemu:  gfortran-7 libgfortran-7-dev libgfortran4
qemu: Suggested packages:
qemu:  gfortran-multilib gfortran-doc gfortran-7-multilib
gfortran-7-doc
qemu:  libgfortran4-dbg libcoarrays-dev
qemu: The following NEW packages will be installed:
qemu:  gfortran gfortran-7 libgfortran-7-dev libgfortran4
qemu: 0 upgraded, 4 newly installed, 0 to remove and 178 not upgraded.
qemu: Need to get 10.0 MB of archives.
qemu: After this operation, 31.4 MB of additional disk space will be
used.
qemu: Get:1 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64
libgfortran4 amd64 7.5.0-3ubuntu1~18.04 [492 kB]
qemu: Get:2 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64
libgfortran-7-dev amd64 7.5.0-3ubuntu1~18.04 [530 kB]
qemu: Get:3 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64
gfortran-7 amd64 7.5.0-3ubuntu1~18.04 [9,014 kB]
qemu: Get:4 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64
gfortran amd64 4:7.4.0-1ubuntu2.3 [1,356 B]
qemu: Fetched 10.0 MB in 6s (1,674 kB/s)
qemu: Selecting previously unselected package libgfortran4:amd64.
qemu: (Reading database ... 66502 files and directories currently
installed.)
qemu: Preparing to unpack
.../libgfortran4_7.5.0-3ubuntu1~18.04_amd64.deb ...
qemu: Unpacking libgfortran4:amd64 (7.5.0-3ubuntu1~18.04) ...
qemu: Selecting previously unselected package libgfortran-7-dev:amd64.
qemu: Preparing to unpack
.../libgfortran-7-dev_7.5.0-3ubuntu1~18.04_amd64.deb ...
qemu: Unpacking libgfortran-7-dev:amd64 (7.5.0-3ubuntu1~18.04) ...
qemu: Selecting previously unselected package gfortran-7.
qemu: Preparing to unpack .../gfortran-7_7.5.0-3ubuntu1~18.04_amd64.deb
...
qemu: Unpacking gfortran-7 (7.5.0-3ubuntu1~18.04) ...
qemu: Selecting previously unselected package gfortran.
qemu: Preparing to unpack .../gfortran_4%3a7.4.0-1ubuntu2.3_amd64.deb
...
qemu: Unpacking gfortran (4:7.4.0-1ubuntu2.3) ...
qemu: Setting up libgfortran4:amd64 (7.5.0-3ubuntu1~18.04) ...
qemu: Processing triggers for libc-bin (2.27-3ubuntu1) ...
qemu: Setting up libgfortran-7-dev:amd64 (7.5.0-3ubuntu1~18.04) ...
qemu: Processing triggers for man-db (2.8.3-2ubuntu0.1) ...
qemu: Setting up gfortran-7 (7.5.0-3ubuntu1~18.04) ...
qemu: Setting up gfortran (4:7.4.0-1ubuntu2.3) ...
qemu: update-alternatives: using /usr/bin/gfortran to provide
/usr/bin/f95 (f95) in auto mode
qemu: update-alternatives: using /usr/bin/gfortran to provide
/usr/bin/f77 (f77) in auto mode
==> qemu: [sudo] password for gem5: mount: /home/gem5/mnt: WARNING: device
write-protected, mounted read-only.
qemu: SPEC CPU2017 Installation
==> qemu: tput: unknown terminal "unknown"
qemu:
==> qemu: tput: unknown terminal "unknown"
qemu: Top of the CPU2017 tree is '/home/gem5/mnt'
qemu:
qemu: Installing FROM /home/gem5/mnt
qemu: Installing TO /home/gem5/spec2017
qemu:
qemu: Is this correct? (Please enter 'yes' or 'no')
qemu:
qemu:
---================================
qemu: Attempting to install the linux-x86_64 toolset...
qemu:
qemu:
qemu: Unpacking CPU2017 base files (46.4 MB)
qemu: Unpacking CPU2017 tools binary files (150.2 MB)
qemu: Unpacking 500.perlbench_r benchmark and data files (102 MB)
qemu: Unpacking 502.gcc_r benchmark and data files (240.3 MB)
qemu: Unpacking 503.bwaves_r benchmark and data files (0.2 MB)
qemu: Unpacking 505.mcf_r benchmark and data files (8.5 MB)
qemu: Unpacking 507.cactuBSSN_r benchmark and data files (12.5 MB)
qemu: Unpacking 508.namd_r benchmark and data files (8.3 MB)
qemu: Unpacking 510.parest_r benchmark and data files (25.6 MB)
qemu: Unpacking 511.povray_r benchmark and data files (23.3 MB)
qemu: Unpacking 519.lbm_r benchmark and data files (4.3 MB)
qemu: Unpacking 520.omnetpp_r benchmark and data files (56.6 MB)
qemu: Unpacking 521.wrf_r benchmark and data files (217.2 MB)
qemu: Unpacking 523.xalancbmk_r benchmark and data files (212 MB)
qemu: Unpacking 525.x264_r benchmark and data files (57.9 MB)
qemu: Unpacking 526.blender_r benchmark and data files (215.7 MB)
qemu: Unpacking 527.cam4_r benchmark and data files (348.6 MB)
==> qemu: Provisioning step had errors: Running the cleanup provisioner, if
present...
==> qemu: Deleting output directory...
Build 'qemu' errored after 25 minutes 1 second: Script disconnected
unexpectedly. If you expected your script to disconnect, i.e. from a
restart, you can try adding "expect_disconnect": true or
"valid_exit_codes": [0, 2300218] to the shell provisioner parameters.

==> Wait completed after 25 minutes 1 second

==> Some builds didn't complete successfully and had errors:
--> qemu: Script disconnected unexpectedly. If you expected your script to
disconnect, i.e. from a restart, you can try adding "expect_disconnect": true or "valid_exit_codes": [0, 2300218] to the shell provisioner
parameters.

==> Builds finished but no artifacts were created.

Hello, I'm getting the following error when trying to build the disk image as described here: https://www.gem5.org/documentation/gem5art/tutorials/spec-tutorial The final error is: ==> qemu: Provisioning step had errors: Running the cleanup provisioner, if present... ==> qemu: Deleting output directory... Build 'qemu' errored after 25 minutes 1 second: Script disconnected unexpectedly. If you expected your script to disconnect, i.e. from a restart, you can try adding `"expect_disconnect": true` or `"valid_exit_codes": [0, 2300218]` to the shell provisioner parameters. I've included the entire output below in case it's helpful. The host is Ubuntu 20.04 and I'm using gem5 21. Everything else is the same as the tutorial. Thanks for all you do! _______________________________________ $./packer build spec-2017/spec-2017.json qemu: output will be in this color. ==> qemu: Retrieving ISO ==> qemu: Trying http://old-releases.ubuntu.com/releases/18.04.2/ubuntu-18.04.2-server-amd64.iso ==> qemu: Trying http://old-releases.ubuntu.com/releases/18.04.2/ubuntu-18.04.2-server-amd64.iso?checksum=md5%3A34416ff83179728d54583bf3f18d42d2 ==> qemu: http://old-releases.ubuntu.com/releases/18.04.2/ubuntu-18.04.2-server-amd64.iso?checksum=md5%3A34416ff83179728d54583bf3f18d42d2 => /home/reiko/gem5-resources/src/spec-2017/disk-image/packer_cache/e94c06241a5e6ba0c4b9618ddcda39ba2ee27e9a.iso ==> qemu: Creating floppy disk... qemu: Copying files flatly from floppy_files qemu: Copying file: shared/preseed.cfg qemu: Done copying files from floppy_files qemu: Collecting paths from floppy_dirs qemu: Resulting paths from floppy_dirs : [] qemu: Done copying paths from floppy_dirs ==> qemu: Starting HTTP server on port 8610 ==> qemu: Found port for communicator (SSH, WinRM, etc): 4164. ==> qemu: Looking for available port between 5900 and 6000 on 127.0.0.1 ==> qemu: Starting VM, booting from CD-ROM qemu: The VM will be run headless, without a GUI. If you want to qemu: view the screen of the VM, connect via VNC without a password to qemu: vnc://127.0.0.1:82 ==> qemu: Overriding default Qemu arguments with qemuargs template option... ==> qemu: Waiting 10s for boot... ==> qemu: Connecting to VM via VNC (127.0.0.1:5982) ==> qemu: Typing the boot command over VNC... qemu: Not using a NetBridge -- skipping StepWaitGuestAddress ==> qemu: Using ssh communicator to connect: 127.0.0.1 ==> qemu: Waiting for SSH to become available... ==> qemu: Connected to SSH! ==> qemu: Uploading ../gem5/util/m5/build/x86/out/m5 => /home/gem5/ qemu: m5 2.40 MiB / 2.40 MiB [===================================] 100.00% 0s ==> qemu: Uploading shared/serial-getty(a).service => /home/gem5/ qemu: serial-getty(a).service 1.45 KiB / 1.45 KiB [================] 100.00% 0s ==> qemu: Uploading spec-2017/runscript.sh => /home/gem5/ qemu: runscript.sh 1.16 KiB / 1.16 KiB [=========================] 100.00% 0s ==> qemu: Uploading spec-2017/cpu2017-1.1.0.iso => /home/gem5/ qemu: cpu2017-1.1.0.iso 2.83 GiB / 2.83 GiB [=================] 100.00% 1m43s ==> qemu: Provisioning with shell script: spec-2017/post-installation.sh qemu: Post Installation Started qemu: Post Installation Done ==> qemu: [sudo] password for gem5: ==> qemu: Provisioning with shell script: spec-2017/install-spec2017.sh qemu: Reading package lists... qemu: Building dependency tree... qemu: Reading state information... qemu: build-essential is already the newest version (12.4ubuntu1). qemu: The following additional packages will be installed: qemu: gfortran-7 libgfortran-7-dev libgfortran4 qemu: Suggested packages: qemu: gfortran-multilib gfortran-doc gfortran-7-multilib gfortran-7-doc qemu: libgfortran4-dbg libcoarrays-dev qemu: The following NEW packages will be installed: qemu: gfortran gfortran-7 libgfortran-7-dev libgfortran4 qemu: 0 upgraded, 4 newly installed, 0 to remove and 178 not upgraded. qemu: Need to get 10.0 MB of archives. qemu: After this operation, 31.4 MB of additional disk space will be used. qemu: Get:1 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libgfortran4 amd64 7.5.0-3ubuntu1~18.04 [492 kB] qemu: Get:2 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libgfortran-7-dev amd64 7.5.0-3ubuntu1~18.04 [530 kB] qemu: Get:3 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 gfortran-7 amd64 7.5.0-3ubuntu1~18.04 [9,014 kB] qemu: Get:4 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 gfortran amd64 4:7.4.0-1ubuntu2.3 [1,356 B] qemu: Fetched 10.0 MB in 6s (1,674 kB/s) qemu: Selecting previously unselected package libgfortran4:amd64. qemu: (Reading database ... 66502 files and directories currently installed.) qemu: Preparing to unpack .../libgfortran4_7.5.0-3ubuntu1~18.04_amd64.deb ... qemu: Unpacking libgfortran4:amd64 (7.5.0-3ubuntu1~18.04) ... qemu: Selecting previously unselected package libgfortran-7-dev:amd64. qemu: Preparing to unpack .../libgfortran-7-dev_7.5.0-3ubuntu1~18.04_amd64.deb ... qemu: Unpacking libgfortran-7-dev:amd64 (7.5.0-3ubuntu1~18.04) ... qemu: Selecting previously unselected package gfortran-7. qemu: Preparing to unpack .../gfortran-7_7.5.0-3ubuntu1~18.04_amd64.deb ... qemu: Unpacking gfortran-7 (7.5.0-3ubuntu1~18.04) ... qemu: Selecting previously unselected package gfortran. qemu: Preparing to unpack .../gfortran_4%3a7.4.0-1ubuntu2.3_amd64.deb ... qemu: Unpacking gfortran (4:7.4.0-1ubuntu2.3) ... qemu: Setting up libgfortran4:amd64 (7.5.0-3ubuntu1~18.04) ... qemu: Processing triggers for libc-bin (2.27-3ubuntu1) ... qemu: Setting up libgfortran-7-dev:amd64 (7.5.0-3ubuntu1~18.04) ... qemu: Processing triggers for man-db (2.8.3-2ubuntu0.1) ... qemu: Setting up gfortran-7 (7.5.0-3ubuntu1~18.04) ... qemu: Setting up gfortran (4:7.4.0-1ubuntu2.3) ... qemu: update-alternatives: using /usr/bin/gfortran to provide /usr/bin/f95 (f95) in auto mode qemu: update-alternatives: using /usr/bin/gfortran to provide /usr/bin/f77 (f77) in auto mode ==> qemu: [sudo] password for gem5: mount: /home/gem5/mnt: WARNING: device write-protected, mounted read-only. qemu: SPEC CPU2017 Installation ==> qemu: tput: unknown terminal "unknown" qemu: ==> qemu: tput: unknown terminal "unknown" qemu: Top of the CPU2017 tree is '/home/gem5/mnt' qemu: qemu: Installing FROM /home/gem5/mnt qemu: Installing TO /home/gem5/spec2017 qemu: qemu: Is this correct? (Please enter 'yes' or 'no') qemu: qemu: ================================================================= qemu: Attempting to install the linux-x86_64 toolset... qemu: qemu: qemu: Unpacking CPU2017 base files (46.4 MB) qemu: Unpacking CPU2017 tools binary files (150.2 MB) qemu: Unpacking 500.perlbench_r benchmark and data files (102 MB) qemu: Unpacking 502.gcc_r benchmark and data files (240.3 MB) qemu: Unpacking 503.bwaves_r benchmark and data files (0.2 MB) qemu: Unpacking 505.mcf_r benchmark and data files (8.5 MB) qemu: Unpacking 507.cactuBSSN_r benchmark and data files (12.5 MB) qemu: Unpacking 508.namd_r benchmark and data files (8.3 MB) qemu: Unpacking 510.parest_r benchmark and data files (25.6 MB) qemu: Unpacking 511.povray_r benchmark and data files (23.3 MB) qemu: Unpacking 519.lbm_r benchmark and data files (4.3 MB) qemu: Unpacking 520.omnetpp_r benchmark and data files (56.6 MB) qemu: Unpacking 521.wrf_r benchmark and data files (217.2 MB) qemu: Unpacking 523.xalancbmk_r benchmark and data files (212 MB) qemu: Unpacking 525.x264_r benchmark and data files (57.9 MB) qemu: Unpacking 526.blender_r benchmark and data files (215.7 MB) qemu: Unpacking 527.cam4_r benchmark and data files (348.6 MB) ==> qemu: Provisioning step had errors: Running the cleanup provisioner, if present... ==> qemu: Deleting output directory... Build 'qemu' errored after 25 minutes 1 second: Script disconnected unexpectedly. If you expected your script to disconnect, i.e. from a restart, you can try adding `"expect_disconnect": true` or `"valid_exit_codes": [0, 2300218]` to the shell provisioner parameters. ==> Wait completed after 25 minutes 1 second ==> Some builds didn't complete successfully and had errors: --> qemu: Script disconnected unexpectedly. If you expected your script to disconnect, i.e. from a restart, you can try adding `"expect_disconnect": true` or `"valid_exit_codes": [0, 2300218]` to the shell provisioner parameters. ==> Builds finished but no artifacts were created.
HN
Hoa Nguyen
Sat, Sep 25, 2021 8:32 PM

Hi Reiko,

It's not immediately clear to me what caused the problem.

Though, I do think it was because the host was running out of memory.
I think you can resolve that by modifying the "vm_memory" parameter of
the disk-image/spec-2017/spec-2017.json file.

Regards,
Hoa Nguyen

On 9/24/21, Reiko Matsuda-dunn via gem5-users <gem5-users(a)gem5.org> wrote:

Hello,

I'm getting the following error when trying to build the disk image as
described here:
https://www.gem5.org/documentation/gem5art/tutorials/spec-tutorial

The final error is:
==> qemu: Provisioning step had errors: Running the cleanup provisioner, if
present...
==> qemu: Deleting output directory...
Build 'qemu' errored after 25 minutes 1 second: Script disconnected
unexpectedly. If you expected your script to disconnect, i.e. from a
restart, you can try adding "expect_disconnect": true or
"valid_exit_codes": [0, 2300218] to the shell provisioner parameters.

I've included the entire output below in case it's helpful. The host is
Ubuntu 20.04 and I'm using gem5 21. Everything else is the same as the
tutorial.

Thanks for all you do!


$./packer build spec-2017/spec-2017.json

qemu: output will be in this color.

==> qemu: Retrieving ISO
==> qemu: Trying
http://old-releases.ubuntu.com/releases/18.04.2/ubuntu-18.04.2-server-amd64.iso
==> qemu: Trying
http://old-releases.ubuntu.com/releases/18.04.2/ubuntu-18.04.2-server-amd64.iso?checksum=md5%3A34416ff83179728d54583bf3f18d42d2
==> qemu:
http://old-releases.ubuntu.com/releases/18.04.2/ubuntu-18.04.2-server-amd64.iso?checksum=md5%3A34416ff83179728d54583bf3f18d42d2
=>
/home/reiko/gem5-resources/src/spec-2017/disk-image/packer_cache/e94c06241a5e6ba0c4b9618ddcda39ba2ee27e9a.iso
==> qemu: Creating floppy disk...
qemu: Copying files flatly from floppy_files
qemu: Copying file: shared/preseed.cfg
qemu: Done copying files from floppy_files
qemu: Collecting paths from floppy_dirs
qemu: Resulting paths from floppy_dirs : []
qemu: Done copying paths from floppy_dirs
==> qemu: Starting HTTP server on port 8610
==> qemu: Found port for communicator (SSH, WinRM, etc): 4164.
==> qemu: Looking for available port between 5900 and 6000 on 127.0.0.1
==> qemu: Starting VM, booting from CD-ROM
qemu: The VM will be run headless, without a GUI. If you want to
qemu: view the screen of the VM, connect via VNC without a password to
qemu: vnc://127.0.0.1:82
==> qemu: Overriding default Qemu arguments with qemuargs template
option...
==> qemu: Waiting 10s for boot...
==> qemu: Connecting to VM via VNC (127.0.0.1:5982)
==> qemu: Typing the boot command over VNC...
qemu: Not using a NetBridge -- skipping StepWaitGuestAddress
==> qemu: Using ssh communicator to connect: 127.0.0.1
==> qemu: Waiting for SSH to become available...
==> qemu: Connected to SSH!
==> qemu: Uploading ../gem5/util/m5/build/x86/out/m5 => /home/gem5/
qemu: m5 2.40 MiB / 2.40 MiB [
---==]
100.00% 0s
==> qemu: Uploading shared/serial-getty(a).service => /home/gem5/
qemu: serial-getty(a).service 1.45 KiB / 1.45 KiB [================]
100.00% 0s
==> qemu: Uploading spec-2017/runscript.sh => /home/gem5/
qemu: runscript.sh 1.16 KiB / 1.16 KiB [=========================]
100.00% 0s
==> qemu: Uploading spec-2017/cpu2017-1.1.0.iso => /home/gem5/
qemu: cpu2017-1.1.0.iso 2.83 GiB / 2.83 GiB [=================] 100.00%
1m43s
==> qemu: Provisioning with shell script: spec-2017/post-installation.sh
qemu: Post Installation Started
qemu: Post Installation Done
==> qemu: [sudo] password for gem5:
==> qemu: Provisioning with shell script: spec-2017/install-spec2017.sh
qemu: Reading package lists...
qemu: Building dependency tree...
qemu: Reading state information...
qemu: build-essential is already the newest version (12.4ubuntu1).
qemu: The following additional packages will be installed:
qemu:  gfortran-7 libgfortran-7-dev libgfortran4
qemu: Suggested packages:
qemu:  gfortran-multilib gfortran-doc gfortran-7-multilib
gfortran-7-doc
qemu:  libgfortran4-dbg libcoarrays-dev
qemu: The following NEW packages will be installed:
qemu:  gfortran gfortran-7 libgfortran-7-dev libgfortran4
qemu: 0 upgraded, 4 newly installed, 0 to remove and 178 not upgraded.
qemu: Need to get 10.0 MB of archives.
qemu: After this operation, 31.4 MB of additional disk space will be
used.
qemu: Get:1 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64
libgfortran4 amd64 7.5.0-3ubuntu1~18.04 [492 kB]
qemu: Get:2 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64
libgfortran-7-dev amd64 7.5.0-3ubuntu1~18.04 [530 kB]
qemu: Get:3 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64
gfortran-7 amd64 7.5.0-3ubuntu1~18.04 [9,014 kB]
qemu: Get:4 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64
gfortran amd64 4:7.4.0-1ubuntu2.3 [1,356 B]
qemu: Fetched 10.0 MB in 6s (1,674 kB/s)
qemu: Selecting previously unselected package libgfortran4:amd64.
qemu: (Reading database ... 66502 files and directories currently
installed.)
qemu: Preparing to unpack
.../libgfortran4_7.5.0-3ubuntu1~18.04_amd64.deb ...
qemu: Unpacking libgfortran4:amd64 (7.5.0-3ubuntu1~18.04) ...
qemu: Selecting previously unselected package libgfortran-7-dev:amd64.
qemu: Preparing to unpack
.../libgfortran-7-dev_7.5.0-3ubuntu1~18.04_amd64.deb ...
qemu: Unpacking libgfortran-7-dev:amd64 (7.5.0-3ubuntu1~18.04) ...
qemu: Selecting previously unselected package gfortran-7.
qemu: Preparing to unpack .../gfortran-7_7.5.0-3ubuntu1~18.04_amd64.deb
...
qemu: Unpacking gfortran-7 (7.5.0-3ubuntu1~18.04) ...
qemu: Selecting previously unselected package gfortran.
qemu: Preparing to unpack .../gfortran_4%3a7.4.0-1ubuntu2.3_amd64.deb
...
qemu: Unpacking gfortran (4:7.4.0-1ubuntu2.3) ...
qemu: Setting up libgfortran4:amd64 (7.5.0-3ubuntu1~18.04) ...
qemu: Processing triggers for libc-bin (2.27-3ubuntu1) ...
qemu: Setting up libgfortran-7-dev:amd64 (7.5.0-3ubuntu1~18.04) ...
qemu: Processing triggers for man-db (2.8.3-2ubuntu0.1) ...
qemu: Setting up gfortran-7 (7.5.0-3ubuntu1~18.04) ...
qemu: Setting up gfortran (4:7.4.0-1ubuntu2.3) ...
qemu: update-alternatives: using /usr/bin/gfortran to provide
/usr/bin/f95 (f95) in auto mode
qemu: update-alternatives: using /usr/bin/gfortran to provide
/usr/bin/f77 (f77) in auto mode
==> qemu: [sudo] password for gem5: mount: /home/gem5/mnt: WARNING: device
write-protected, mounted read-only.
qemu: SPEC CPU2017 Installation
==> qemu: tput: unknown terminal "unknown"
qemu:
==> qemu: tput: unknown terminal "unknown"
qemu: Top of the CPU2017 tree is '/home/gem5/mnt'
qemu:
qemu: Installing FROM /home/gem5/mnt
qemu: Installing TO /home/gem5/spec2017
qemu:
qemu: Is this correct? (Please enter 'yes' or 'no')
qemu:
qemu:
---================================
qemu: Attempting to install the linux-x86_64 toolset...
qemu:
qemu:
qemu: Unpacking CPU2017 base files (46.4 MB)
qemu: Unpacking CPU2017 tools binary files (150.2 MB)
qemu: Unpacking 500.perlbench_r benchmark and data files (102 MB)
qemu: Unpacking 502.gcc_r benchmark and data files (240.3 MB)
qemu: Unpacking 503.bwaves_r benchmark and data files (0.2 MB)
qemu: Unpacking 505.mcf_r benchmark and data files (8.5 MB)
qemu: Unpacking 507.cactuBSSN_r benchmark and data files (12.5 MB)
qemu: Unpacking 508.namd_r benchmark and data files (8.3 MB)
qemu: Unpacking 510.parest_r benchmark and data files (25.6 MB)
qemu: Unpacking 511.povray_r benchmark and data files (23.3 MB)
qemu: Unpacking 519.lbm_r benchmark and data files (4.3 MB)
qemu: Unpacking 520.omnetpp_r benchmark and data files (56.6 MB)
qemu: Unpacking 521.wrf_r benchmark and data files (217.2 MB)
qemu: Unpacking 523.xalancbmk_r benchmark and data files (212 MB)
qemu: Unpacking 525.x264_r benchmark and data files (57.9 MB)
qemu: Unpacking 526.blender_r benchmark and data files (215.7 MB)
qemu: Unpacking 527.cam4_r benchmark and data files (348.6 MB)
==> qemu: Provisioning step had errors: Running the cleanup provisioner, if
present...
==> qemu: Deleting output directory...
Build 'qemu' errored after 25 minutes 1 second: Script disconnected
unexpectedly. If you expected your script to disconnect, i.e. from a
restart, you can try adding "expect_disconnect": true or
"valid_exit_codes": [0, 2300218] to the shell provisioner parameters.

==> Wait completed after 25 minutes 1 second

==> Some builds didn't complete successfully and had errors:
--> qemu: Script disconnected unexpectedly. If you expected your script to
disconnect, i.e. from a restart, you can try adding "expect_disconnect": true or "valid_exit_codes": [0, 2300218] to the shell provisioner
parameters.

==> Builds finished but no artifacts were created.

Hi Reiko, It's not immediately clear to me what caused the problem. Though, I do think it was because the host was running out of memory. I think you can resolve that by modifying the "vm_memory" parameter of the disk-image/spec-2017/spec-2017.json file. Regards, Hoa Nguyen On 9/24/21, Reiko Matsuda-dunn via gem5-users <gem5-users(a)gem5.org> wrote: > Hello, > > I'm getting the following error when trying to build the disk image as > described here: > https://www.gem5.org/documentation/gem5art/tutorials/spec-tutorial > > The final error is: > ==> qemu: Provisioning step had errors: Running the cleanup provisioner, if > present... > ==> qemu: Deleting output directory... > Build 'qemu' errored after 25 minutes 1 second: Script disconnected > unexpectedly. If you expected your script to disconnect, i.e. from a > restart, you can try adding `"expect_disconnect": true` or > `"valid_exit_codes": [0, 2300218]` to the shell provisioner parameters. > > I've included the entire output below in case it's helpful. The host is > Ubuntu 20.04 and I'm using gem5 21. Everything else is the same as the > tutorial. > > Thanks for all you do! > _______________________________________ > > $./packer build spec-2017/spec-2017.json > > qemu: output will be in this color. > > ==> qemu: Retrieving ISO > ==> qemu: Trying > http://old-releases.ubuntu.com/releases/18.04.2/ubuntu-18.04.2-server-amd64.iso > ==> qemu: Trying > http://old-releases.ubuntu.com/releases/18.04.2/ubuntu-18.04.2-server-amd64.iso?checksum=md5%3A34416ff83179728d54583bf3f18d42d2 > ==> qemu: > http://old-releases.ubuntu.com/releases/18.04.2/ubuntu-18.04.2-server-amd64.iso?checksum=md5%3A34416ff83179728d54583bf3f18d42d2 > => > /home/reiko/gem5-resources/src/spec-2017/disk-image/packer_cache/e94c06241a5e6ba0c4b9618ddcda39ba2ee27e9a.iso > ==> qemu: Creating floppy disk... > qemu: Copying files flatly from floppy_files > qemu: Copying file: shared/preseed.cfg > qemu: Done copying files from floppy_files > qemu: Collecting paths from floppy_dirs > qemu: Resulting paths from floppy_dirs : [] > qemu: Done copying paths from floppy_dirs > ==> qemu: Starting HTTP server on port 8610 > ==> qemu: Found port for communicator (SSH, WinRM, etc): 4164. > ==> qemu: Looking for available port between 5900 and 6000 on 127.0.0.1 > ==> qemu: Starting VM, booting from CD-ROM > qemu: The VM will be run headless, without a GUI. If you want to > qemu: view the screen of the VM, connect via VNC without a password to > qemu: vnc://127.0.0.1:82 > ==> qemu: Overriding default Qemu arguments with qemuargs template > option... > ==> qemu: Waiting 10s for boot... > ==> qemu: Connecting to VM via VNC (127.0.0.1:5982) > ==> qemu: Typing the boot command over VNC... > qemu: Not using a NetBridge -- skipping StepWaitGuestAddress > ==> qemu: Using ssh communicator to connect: 127.0.0.1 > ==> qemu: Waiting for SSH to become available... > ==> qemu: Connected to SSH! > ==> qemu: Uploading ../gem5/util/m5/build/x86/out/m5 => /home/gem5/ > qemu: m5 2.40 MiB / 2.40 MiB [===================================] > 100.00% 0s > ==> qemu: Uploading shared/serial-getty(a).service => /home/gem5/ > qemu: serial-getty(a).service 1.45 KiB / 1.45 KiB [================] > 100.00% 0s > ==> qemu: Uploading spec-2017/runscript.sh => /home/gem5/ > qemu: runscript.sh 1.16 KiB / 1.16 KiB [=========================] > 100.00% 0s > ==> qemu: Uploading spec-2017/cpu2017-1.1.0.iso => /home/gem5/ > qemu: cpu2017-1.1.0.iso 2.83 GiB / 2.83 GiB [=================] 100.00% > 1m43s > ==> qemu: Provisioning with shell script: spec-2017/post-installation.sh > qemu: Post Installation Started > qemu: Post Installation Done > ==> qemu: [sudo] password for gem5: > ==> qemu: Provisioning with shell script: spec-2017/install-spec2017.sh > qemu: Reading package lists... > qemu: Building dependency tree... > qemu: Reading state information... > qemu: build-essential is already the newest version (12.4ubuntu1). > qemu: The following additional packages will be installed: > qemu: gfortran-7 libgfortran-7-dev libgfortran4 > qemu: Suggested packages: > qemu: gfortran-multilib gfortran-doc gfortran-7-multilib > gfortran-7-doc > qemu: libgfortran4-dbg libcoarrays-dev > qemu: The following NEW packages will be installed: > qemu: gfortran gfortran-7 libgfortran-7-dev libgfortran4 > qemu: 0 upgraded, 4 newly installed, 0 to remove and 178 not upgraded. > qemu: Need to get 10.0 MB of archives. > qemu: After this operation, 31.4 MB of additional disk space will be > used. > qemu: Get:1 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 > libgfortran4 amd64 7.5.0-3ubuntu1~18.04 [492 kB] > qemu: Get:2 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 > libgfortran-7-dev amd64 7.5.0-3ubuntu1~18.04 [530 kB] > qemu: Get:3 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 > gfortran-7 amd64 7.5.0-3ubuntu1~18.04 [9,014 kB] > qemu: Get:4 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 > gfortran amd64 4:7.4.0-1ubuntu2.3 [1,356 B] > qemu: Fetched 10.0 MB in 6s (1,674 kB/s) > qemu: Selecting previously unselected package libgfortran4:amd64. > qemu: (Reading database ... 66502 files and directories currently > installed.) > qemu: Preparing to unpack > .../libgfortran4_7.5.0-3ubuntu1~18.04_amd64.deb ... > qemu: Unpacking libgfortran4:amd64 (7.5.0-3ubuntu1~18.04) ... > qemu: Selecting previously unselected package libgfortran-7-dev:amd64. > qemu: Preparing to unpack > .../libgfortran-7-dev_7.5.0-3ubuntu1~18.04_amd64.deb ... > qemu: Unpacking libgfortran-7-dev:amd64 (7.5.0-3ubuntu1~18.04) ... > qemu: Selecting previously unselected package gfortran-7. > qemu: Preparing to unpack .../gfortran-7_7.5.0-3ubuntu1~18.04_amd64.deb > ... > qemu: Unpacking gfortran-7 (7.5.0-3ubuntu1~18.04) ... > qemu: Selecting previously unselected package gfortran. > qemu: Preparing to unpack .../gfortran_4%3a7.4.0-1ubuntu2.3_amd64.deb > ... > qemu: Unpacking gfortran (4:7.4.0-1ubuntu2.3) ... > qemu: Setting up libgfortran4:amd64 (7.5.0-3ubuntu1~18.04) ... > qemu: Processing triggers for libc-bin (2.27-3ubuntu1) ... > qemu: Setting up libgfortran-7-dev:amd64 (7.5.0-3ubuntu1~18.04) ... > qemu: Processing triggers for man-db (2.8.3-2ubuntu0.1) ... > qemu: Setting up gfortran-7 (7.5.0-3ubuntu1~18.04) ... > qemu: Setting up gfortran (4:7.4.0-1ubuntu2.3) ... > qemu: update-alternatives: using /usr/bin/gfortran to provide > /usr/bin/f95 (f95) in auto mode > qemu: update-alternatives: using /usr/bin/gfortran to provide > /usr/bin/f77 (f77) in auto mode > ==> qemu: [sudo] password for gem5: mount: /home/gem5/mnt: WARNING: device > write-protected, mounted read-only. > qemu: SPEC CPU2017 Installation > ==> qemu: tput: unknown terminal "unknown" > qemu: > ==> qemu: tput: unknown terminal "unknown" > qemu: Top of the CPU2017 tree is '/home/gem5/mnt' > qemu: > qemu: Installing FROM /home/gem5/mnt > qemu: Installing TO /home/gem5/spec2017 > qemu: > qemu: Is this correct? (Please enter 'yes' or 'no') > qemu: > qemu: ================================================================= > qemu: Attempting to install the linux-x86_64 toolset... > qemu: > qemu: > qemu: Unpacking CPU2017 base files (46.4 MB) > qemu: Unpacking CPU2017 tools binary files (150.2 MB) > qemu: Unpacking 500.perlbench_r benchmark and data files (102 MB) > qemu: Unpacking 502.gcc_r benchmark and data files (240.3 MB) > qemu: Unpacking 503.bwaves_r benchmark and data files (0.2 MB) > qemu: Unpacking 505.mcf_r benchmark and data files (8.5 MB) > qemu: Unpacking 507.cactuBSSN_r benchmark and data files (12.5 MB) > qemu: Unpacking 508.namd_r benchmark and data files (8.3 MB) > qemu: Unpacking 510.parest_r benchmark and data files (25.6 MB) > qemu: Unpacking 511.povray_r benchmark and data files (23.3 MB) > qemu: Unpacking 519.lbm_r benchmark and data files (4.3 MB) > qemu: Unpacking 520.omnetpp_r benchmark and data files (56.6 MB) > qemu: Unpacking 521.wrf_r benchmark and data files (217.2 MB) > qemu: Unpacking 523.xalancbmk_r benchmark and data files (212 MB) > qemu: Unpacking 525.x264_r benchmark and data files (57.9 MB) > qemu: Unpacking 526.blender_r benchmark and data files (215.7 MB) > qemu: Unpacking 527.cam4_r benchmark and data files (348.6 MB) > ==> qemu: Provisioning step had errors: Running the cleanup provisioner, if > present... > ==> qemu: Deleting output directory... > Build 'qemu' errored after 25 minutes 1 second: Script disconnected > unexpectedly. If you expected your script to disconnect, i.e. from a > restart, you can try adding `"expect_disconnect": true` or > `"valid_exit_codes": [0, 2300218]` to the shell provisioner parameters. > > ==> Wait completed after 25 minutes 1 second > > ==> Some builds didn't complete successfully and had errors: > --> qemu: Script disconnected unexpectedly. If you expected your script to > disconnect, i.e. from a restart, you can try adding `"expect_disconnect": > true` or `"valid_exit_codes": [0, 2300218]` to the shell provisioner > parameters. > > ==> Builds finished but no artifacts were created. >