:: Re: [Dng] Document on using Qemu fo…
Página Principal
Delete this message
Reply to this message
Autor: Svante Signell
Data:  
Para: Steve Litt
CC: dng
Assunto: Re: [Dng] Document on using Qemu for Linux DIY
On Thu, 2015-05-14 at 19:18 -0400, Steve Litt wrote:
> Hi all,
>
> I just finished a very basic document on using Qemu for Linux DIY,
> which I tech-edited using Valentines Devuan:
>
> http://www.troubleshooters.com/linux/diy/qemu.htm
>
> It's based on three shellscripts, and also contains instructions for
> sharing host and guest /tmp/xfer directory via sshfs. As you know, Qemu
> currently has no copy and paste between host and guest, so a shared
> directory's a great way to transfer copied text or screenshots.
>
> The shellscripts in this doc, perhaps modified by you, might be a
> timesaver for some of you who are repeatedly testing Devuan.
>
> Hope you like it.


Hi Steve, nice writeup and scripts. For communication between your
host/externally and guest you can also use ssh and scp:

Add to qemu-system-x86_64 commandline:
-net user,hostfwd=tcp::5556-:22

Install ssh server on both host and guest.

ssh access to guest:
>From host: ssh -p 5556 localhost
>From external: ssh -p 5556 <your_host_ip_address>


File copy to guest:
>From host:

scp -p -P5556 path/file_on_host localhost:path/file_on_guest
>From external:

scp -p -P5556 path/file <your_host_ip_address>:path/file_on_guest

ssh access from guest:
To host: ssh <your_host_ip_address>
To external: ssh <external_ip_address>

File copy from guest:
To host:
scp path/file_on_guest <your_host_ip_address>:path/file_on_guest
To external:
scp path/file_on_guest <external_ip_address>:path/file_on_guest

>From one guest (guest1:port 5556) to another (guest2:port 5557)

ssh access from guest1 to guest2:
ssh -p5557 <your_host_ip_address>

gateway: 10.0.2.2
File copy from guest2 to guest1:
scp -p -P5567 10.0.2.2:path/file_on_guest2 path/file_on_guest1