How to boot and install the Ubuntu server image on QEMU -nographic without the GUI?












0















At How to run Ubuntu 16.04 Desktop on QEMU? I have described in detail how to boot and install the desktop Ubuntu image on QEMU.



Now I wanted to do a similar setup for the server image to try keep things more minimal:



wget http://releases.ubuntu.com/18.04/ubuntu-18.04.1.0-live-server-amd64.iso


I have installed the server image with the GUI previously, and the setup seems to be text based, so I thought it might work.



But then, if I just add the usual:



-nographic -serial mon:stdio


as in:



qemu-system-x86_64 -cdrom ubuntu-18.04.1.0-live-server-amd64.iso 
-drive file=ubuntu-18.04.1.0-live-server-amd64.img.qcow2,format=qcow2
-enable-kvm -m 2G -smp 2 -vga virtio -nographic -serial mon:stdio


I just never get anything on the terminal serial.



I also tried to mount the image to see what was inside:



mkdir mydir
sudo mount ubuntu-18.04.1.0-live-server-amd64.iso mydir


to see what was inside, and:



cat mydir/boot/grub/grub.cfg


indicates that there is no console=ttyS0 option on the command line, which might explain why the terminal is empty.



I can't edit the ISO file however without first going into a GUI session, as it is mounted readonly.



I have already used the Cloud image previously, and it is great: Is there any prebuilt QEMU Ubuntu image(32bit) online? but I can't use it this time because I need GRUB for something (edit: nevermind, the cloud image does have GRUB, just it is hidden by default, see: How to get to the GRUB menu at boot-time using serial console? )



Related: How to get to the GRUB menu at boot-time using serial console? I managed to get GRUB to show on the terminal after changing the GRUB configuration with the GUI as shown in that thread.



Tested on an Ubuntu 16.04 host.










share|improve this question





























    0















    At How to run Ubuntu 16.04 Desktop on QEMU? I have described in detail how to boot and install the desktop Ubuntu image on QEMU.



    Now I wanted to do a similar setup for the server image to try keep things more minimal:



    wget http://releases.ubuntu.com/18.04/ubuntu-18.04.1.0-live-server-amd64.iso


    I have installed the server image with the GUI previously, and the setup seems to be text based, so I thought it might work.



    But then, if I just add the usual:



    -nographic -serial mon:stdio


    as in:



    qemu-system-x86_64 -cdrom ubuntu-18.04.1.0-live-server-amd64.iso 
    -drive file=ubuntu-18.04.1.0-live-server-amd64.img.qcow2,format=qcow2
    -enable-kvm -m 2G -smp 2 -vga virtio -nographic -serial mon:stdio


    I just never get anything on the terminal serial.



    I also tried to mount the image to see what was inside:



    mkdir mydir
    sudo mount ubuntu-18.04.1.0-live-server-amd64.iso mydir


    to see what was inside, and:



    cat mydir/boot/grub/grub.cfg


    indicates that there is no console=ttyS0 option on the command line, which might explain why the terminal is empty.



    I can't edit the ISO file however without first going into a GUI session, as it is mounted readonly.



    I have already used the Cloud image previously, and it is great: Is there any prebuilt QEMU Ubuntu image(32bit) online? but I can't use it this time because I need GRUB for something (edit: nevermind, the cloud image does have GRUB, just it is hidden by default, see: How to get to the GRUB menu at boot-time using serial console? )



    Related: How to get to the GRUB menu at boot-time using serial console? I managed to get GRUB to show on the terminal after changing the GRUB configuration with the GUI as shown in that thread.



    Tested on an Ubuntu 16.04 host.










    share|improve this question



























      0












      0








      0








      At How to run Ubuntu 16.04 Desktop on QEMU? I have described in detail how to boot and install the desktop Ubuntu image on QEMU.



      Now I wanted to do a similar setup for the server image to try keep things more minimal:



      wget http://releases.ubuntu.com/18.04/ubuntu-18.04.1.0-live-server-amd64.iso


      I have installed the server image with the GUI previously, and the setup seems to be text based, so I thought it might work.



      But then, if I just add the usual:



      -nographic -serial mon:stdio


      as in:



      qemu-system-x86_64 -cdrom ubuntu-18.04.1.0-live-server-amd64.iso 
      -drive file=ubuntu-18.04.1.0-live-server-amd64.img.qcow2,format=qcow2
      -enable-kvm -m 2G -smp 2 -vga virtio -nographic -serial mon:stdio


      I just never get anything on the terminal serial.



      I also tried to mount the image to see what was inside:



      mkdir mydir
      sudo mount ubuntu-18.04.1.0-live-server-amd64.iso mydir


      to see what was inside, and:



      cat mydir/boot/grub/grub.cfg


      indicates that there is no console=ttyS0 option on the command line, which might explain why the terminal is empty.



      I can't edit the ISO file however without first going into a GUI session, as it is mounted readonly.



      I have already used the Cloud image previously, and it is great: Is there any prebuilt QEMU Ubuntu image(32bit) online? but I can't use it this time because I need GRUB for something (edit: nevermind, the cloud image does have GRUB, just it is hidden by default, see: How to get to the GRUB menu at boot-time using serial console? )



      Related: How to get to the GRUB menu at boot-time using serial console? I managed to get GRUB to show on the terminal after changing the GRUB configuration with the GUI as shown in that thread.



      Tested on an Ubuntu 16.04 host.










      share|improve this question
















      At How to run Ubuntu 16.04 Desktop on QEMU? I have described in detail how to boot and install the desktop Ubuntu image on QEMU.



      Now I wanted to do a similar setup for the server image to try keep things more minimal:



      wget http://releases.ubuntu.com/18.04/ubuntu-18.04.1.0-live-server-amd64.iso


      I have installed the server image with the GUI previously, and the setup seems to be text based, so I thought it might work.



      But then, if I just add the usual:



      -nographic -serial mon:stdio


      as in:



      qemu-system-x86_64 -cdrom ubuntu-18.04.1.0-live-server-amd64.iso 
      -drive file=ubuntu-18.04.1.0-live-server-amd64.img.qcow2,format=qcow2
      -enable-kvm -m 2G -smp 2 -vga virtio -nographic -serial mon:stdio


      I just never get anything on the terminal serial.



      I also tried to mount the image to see what was inside:



      mkdir mydir
      sudo mount ubuntu-18.04.1.0-live-server-amd64.iso mydir


      to see what was inside, and:



      cat mydir/boot/grub/grub.cfg


      indicates that there is no console=ttyS0 option on the command line, which might explain why the terminal is empty.



      I can't edit the ISO file however without first going into a GUI session, as it is mounted readonly.



      I have already used the Cloud image previously, and it is great: Is there any prebuilt QEMU Ubuntu image(32bit) online? but I can't use it this time because I need GRUB for something (edit: nevermind, the cloud image does have GRUB, just it is hidden by default, see: How to get to the GRUB menu at boot-time using serial console? )



      Related: How to get to the GRUB menu at boot-time using serial console? I managed to get GRUB to show on the terminal after changing the GRUB configuration with the GUI as shown in that thread.



      Tested on an Ubuntu 16.04 host.







      qemu






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited 8 hours ago







      Ciro Santilli 新疆改造中心 六四事件 法轮功

















      asked Jan 9 at 16:13









      Ciro Santilli 新疆改造中心 六四事件 法轮功Ciro Santilli 新疆改造中心 六四事件 法轮功

      9,37944347




      9,37944347






















          0






          active

          oldest

          votes











          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "89"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });














          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1108334%2fhow-to-boot-and-install-the-ubuntu-server-image-on-qemu-nographic-without-the-g%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes
















          draft saved

          draft discarded




















































          Thanks for contributing an answer to Ask Ubuntu!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1108334%2fhow-to-boot-and-install-the-ubuntu-server-image-on-qemu-nographic-without-the-g%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          GameSpot

          日野市

          Tu-95轟炸機