понеделник, 11 април 2016 г.

My fight with qemu, part 2: ssh from host to guest

Ok, my next step is to install the planned guest OS and to run ssh on it. So this is my log of it.

1. Find an .iso.
For some reasons, the network install wasn't that glorious, though I tried only once.
So let's do it with the iso.
Note to self: don't xkill qemu while trying to install new OS, because it falls asleep, gets in d state and needs a restart to fix.
Second note to self: Don't install new guest OS from ISO while doing calculations on the PC which will prevent you to restart. Facepalm and go to sleep.
The iso I chose:
http://ubuntu.ipacct.com/xubuntu/14.04/release/
the x64 desktop version. I need something light and stable for the perversions I planned. So we start with XUBUNTU.
2. Install it on the virtual machine.
I made a new virtual machine with a 20GB raw partition and then mounted the iso as a cdrom from Machine->Details->Cdrom.
After that I started the machine and installed Xubuntu. Not much surprise there.
3. Try not to ruin your new install in the first 5 minutes.
A little surprise was that a software update crashed and I had to do:
$sudo dpkg --configure -a
once or twice and to restart to fix it.
4. Install ssh
To install ssh I followed this ubuntu tutorial.
Basically I did:
$sudo asudo apt-get install openssh-server 
then
$sudo cp /etc/ssh/sshd_config /etc/ssh/sshd_config.factory-defaults
$sudo chmod a-w /etc/ssh/sshd_config.factory-defaults
 and
$sudo gedit /etc/ssh/sshd_config
 where I didn't change much, maybe just disabled password-less authentication and allowd X-forwarding (as stupid as it sounds for a virtual machine). 
Then:
$sudo restart ssh
to apply the changes. 
5. Connect to your ssh-server :) 
From your host machine do
$ssh user@home-ip
and from my host machine I could ssh to the virtual machine.
Now that's awesome! And quite easy! Still can't get ssh-server to work on my Sabayon. Oh, well, that's why I chose Ubuntu for the virtual machine.
 


  

Няма коментари:

Публикуване на коментар