Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from shelob.surriel.com (shelob.surriel.com [96.67.55.147]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id B2F2CC433EF for ; Thu, 7 Jul 2022 23:47:59 +0000 (UTC) Received: from localhost ([::1] helo=shelob.surriel.com) by shelob.surriel.com with esmtp (Exim 4.95) (envelope-from ) id 1o9bDy-0005h0-GV for kernelnewbies@archiver.kernel.org; Thu, 07 Jul 2022 19:47:58 -0400 Received: from mail1.systemli.org ([93.190.126.36]) by shelob.surriel.com with esmtps (TLS1.2) tls TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384 (Exim 4.95) (envelope-from ) id 1o9bBz-0002qQ-Sw for kernelnewbies@kernelnewbies.org; Thu, 07 Jul 2022 19:45:56 -0400 Message-ID: <316b7e35-58c4-48fe-4b1b-0351fb17bc1a@systemli.org> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=systemli.org; s=default; t=1657237551; bh=6olwPdWY93r1NShZ9+oEEwgPygXpFnuq6OJwrcGkmEE=; h=Date:Subject:To:References:From:In-Reply-To:From; b=CVfJpDv73dcgDMCYZAFWlr7GK4Q5lMWBAzrIc/u5OqJ58fsMVwem+JZeydq/3eAps Ri6RS55cqvmslH2a4LJ+GwwlzTHIj33SzT6pG4uuoTq/+dzft3wikk31V+fA+DgwD6 kG5sxFrtAqBL0dHYkTreVV9oOCtJ48s0Cyxhw8k0xmwAvOAHo57xuYOTQzWF0Bid1x dQwLyDP7WltC8Zf56GRqi2wmEQtG2Riedh19Rpv6mMpyoE5Fu9tOy/26zaR8mXK/3B tvnoBotSSlLr1nueVOu/e7oWss7PFB/QqGI+aqdhyziEwFYsDc3h775nmxee0XhrOi o9oEK9JSRzl9A== Date: Fri, 8 Jul 2022 01:45:50 +0200 MIME-Version: 1.0 Subject: Re: Can I debug busybox program running on a qemu virtual machine using gdb? Content-Language: en-US To: kernelnewbies@kernelnewbies.org References: <03d101d891e3$ccfe9630$66fbc290$@etri.re.kr> From: Richard In-Reply-To: <03d101d891e3$ccfe9630$66fbc290$@etri.re.kr> X-BeenThere: kernelnewbies@kernelnewbies.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Learn about the Linux kernel List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: kernelnewbies-bounces+kernelnewbies=archiver.kernel.org@kernelnewbies.org Hi, If the goal is only to understand tftp and it's not something hardware dependend I would debug it on my normal desktop system/notebook. My distro (debian) has a busybox package. It does not provide the symlinks to change the ARGV[0] but you can create them manually and then debug locally as usually with your prefered tool (emacs recommended :) ). If it has to be in quemu, I see no reason against it, the normal rules for remote debugging apply. -- Richard Sailer On 07/07/2022 11:27, Chan Kim wrote: > Hi all, > > I'm trying to track how tftp program runs when I run tftp provided by > busybox on qemu virtual machine. > I can debug the linux source but I cannot debug tftp (busybox) program. > Can I debug busybox program using gdb in this case? > Any hint or advice will be very appreciated. > Thank you! > > Chan Kim > > > > > > _______________________________________________ > Kernelnewbies mailing list > Kernelnewbies@kernelnewbies.org > https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies _______________________________________________ Kernelnewbies mailing list Kernelnewbies@kernelnewbies.org https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies