Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Debian User (http://www.linux-archive.org/debian-user/)
-   -   installing virtual guest via ssh on console based remote host (http://www.linux-archive.org/debian-user/692005-installing-virtual-guest-via-ssh-console-based-remote-host.html)

Nelson Green 08-08-2012 08:54 PM

installing virtual guest via ssh on console based remote host
 
----------------------------------------
> From: chris-usenet@roaima.co.uk
> Subject: Re: installing virtual guest via ssh on console based remote host
> Date: Wed, 8 Aug 2012 20:54:28 +0100
> To: debian-user@lists.debian.org
>
> Nelson Green <nelsongreen84@hotmail.com> wrote:
> > Installing qemu-kvm and a guest on a remote system is turning into an
> > absolute nightmare, so I'm once again turning to this list for help.
>
> > The host OS is a Centos 6.3 server, without X installed.
>
> If it was Debian I could advise you to install the libvirt-bin,
> bridge-utils, and qemu-kvm packages on the server, with virt-manager as
> a GUI for the client.
>
> Chris

Thanks Chris, and you have no idea how much I wish I was on Debian as I've been a long time (12+ years) user. In fact my local machine is Debian Wheezy, which is why I started this thread here.

I've got some more progress to report if you'll bear with me. First of all, I did install the libvirt-bin and qemu-kvm packages. A bit of history as to why I say this has been a nightmare is because the basic problem has been a lack of straight-forward documentation, but that could be my inability to find it. That being said, every step in this process has involved an error, followed by much time troubleshooting. I don't necessarily mind because finding an answer to a problem involves a learning process, and that is never bad. But in this case I have people depending on me to get them some development boxes.

The first error I got was "Failed to connect socket to '/var/run/libvirt/libvirt-sock': No such file or directory" which was accompanied by "error : virNetServerMDNSStart:460 : internal error Failed to create mDNS client: Daemon not running" in the log file. A bit of searching led me to the need to install the avahi package. That then led to an inability to create VMs because of no virtual network. I eventually figured out that I needed to define a network, and to start it. That led to the empty screen problem. I know that the empty screen is the installer output not mapping to the console properly (if that is the correct terminology). I have now solved that issue as well, but not quite the way I thought needed to be done. I was figuring that I could correct the output on the console I started, but apparently I needed to install the virt-viewer package, which creates a window on my local machine and redirects the console to that.

So, I am now installing an OS on my VM. That leaves one final item, but this is really low on the priority list. How do I clean up after those failed initial attempts? I bet I now know enough to restart them, connect to them, and continue the installs there as well, so I will take it from here.

Regards,
Nelson


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: BAY160-W158E82C08D611B29AAC870ADCD0@phx.gbl">http://lists.debian.org/BAY160-W158E82C08D611B29AAC870ADCD0@phx.gbl

Nelson Green 08-08-2012 10:06 PM

installing virtual guest via ssh on console based remote host
 
OK, another quick question, completely off subject, but hardly worth a new
thread.

When I look at my previous post through a browser, there are no line breaks,
and one has to scroll across the screen to read it. I don't imagine this is desirable
for most users. Is that a result of my mail client (hotmail)? This message won't
suffer the same issue because I'm manually breaking the lines.

Thanks

----------------------------------------
> From: nelsongreen84@hotmail.com
> To: chris@roaima.co.uk; debian-user@lists.debian.org
> Subject: RE: installing virtual guest via ssh on console based remote host
> Date: Wed, 8 Aug 2012 15:54:45 -0500
>
>
>
>
> ----------------------------------------
> > From: chris-usenet@roaima.co.uk
> > Subject: Re: installing virtual guest via ssh on console based remote host
> > Date: Wed, 8 Aug 2012 20:54:28 +0100
> > To: debian-user@lists.debian.org
> >
> > Nelson Green <nelsongreen84@hotmail.com> wrote:
> > > Installing qemu-kvm and a guest on a remote system is turning into an
> > > absolute nightmare, so I'm once again turning to this list for help.
> >
> > > The host OS is a Centos 6.3 server, without X installed.
> >
> > If it was Debian I could advise you to install the libvirt-bin,
> > bridge-utils, and qemu-kvm packages on the server, with virt-manager as
> > a GUI for the client.
> >
> > Chris
>
> Thanks Chris, and you have no idea how much I wish I was on Debian as I've been a long time (12+ years) user. In fact my local machine is Debian Wheezy, which is why I started this thread here.
>
> I've got some more progress to report if you'll bear with me. First of all, I did install the libvirt-bin and qemu-kvm packages. A bit of history as to why I say this has been a nightmare is because the basic problem has been a lack of straight-forward documentation, but that could be my inability to find it. That being said, every step in this process has involved an error, followed by much time troubleshooting. I don't necessarily mind because finding an answer to a problem involves a learning process, and that is never bad. But in this case I have people depending on me to get them some development boxes.
>
> The first error I got was "Failed to connect socket to '/var/run/libvirt/libvirt-sock': No such file or directory" which was accompanied by "error : virNetServerMDNSStart:460 : internal error Failed to create mDNS client: Daemon not running" in the log file. A bit of searching led me to the need to install the avahi package. That then led to an inability to create VMs because of no virtual network. I eventually figured out that I needed to define a network, and to start it. That led to the empty screen problem. I know that the empty screen is the installer output not mapping to the console properly (if that is the correct terminology). I have now solved that issue as well, but not quite the way I thought needed to be done. I was figuring that I could correct the output on the console I started, but apparently I needed to install the virt-viewer package, which creates a window on my local machine and redirects the console to that.
>
> So, I am now installing an OS on my VM. That leaves one final item, but this is really low on the priority list. How do I clean up after those failed initial attempts? I bet I now know enough to restart them, connect to them, and continue the installs there as well, so I will take it from here.
>
> Regards,
> Nelson
>
>
> --
> To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
> with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
> Archive: http://lists.debian.org/BAY160-W158E82C08D611B29AAC870ADCD0@phx.gbl
>


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: BAY160-W1DC10750DA8AF986DF2AAADCD0@phx.gbl">http://lists.debian.org/BAY160-W1DC10750DA8AF986DF2AAADCD0@phx.gbl

Chris Davies 08-08-2012 10:42 PM

installing virtual guest via ssh on console based remote host
 
Nelson Green <nelsongreen84@hotmail.com> wrote:
> I've got some more progress to report if you'll bear with me. First
> of all, I did install the libvirt-bin and qemu-kvm packages. A bit of
> history as to why I say this has been a nightmare is because the basic
> problem has been a lack of straight-forward documentation, but that
> could be my inability to find it

To be honest it's an absolute nightmare. I forgot until I saw your reply
that I've also needed to perform the following tweaks when using libvirt
in a true client/server model:

EITHER
1. Carry the libvirt/qemu protocol across an ssh tunnel to the
server. This requires you to have a login account on the server
2. Add the user account from #1 to the libvirt group on the server
3. In the client GUI, create a connection to "nelson@server" (or
whatever) rather than just to "server"

OR
4. Edit /etc/libvirt/qemu.conf and /etc/libvirt/libvirtd.conf on the
server to allow non-local connections to the daemon. Ideally with
authentication (but this isn't essential if you are on a controlled
and/or restricted network).

I've never found SASL an enjoyable experience, so I would recommend that
you go for the first option. However, you have have a policy dictating
otherwise.


> The first error I got was "Failed to connect socket to
> '/var/run/libvirt/libvirt-sock': No such file or directory"

I think this may be a consequence of omitting #2


> So, I am now installing an OS on my VM. That leaves one final item,
> but this is really low on the priority list. How do I clean up after
> those failed initial attempts?

The nasty but effective way is to shut down the libvirt daemon and delete
the relevant xml files from /etc/libvirtd/qemu/.

Chris


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: ek6bf9xn6n.ln2@news.roaima.co.uk">http://lists.debian.org/ek6bf9xn6n.ln2@news.roaima.co.uk

Nelson Green 08-09-2012 12:46 PM

installing virtual guest via ssh on console based remote host
 
> From: chris-usenet@roaima.co.uk
> Subject: Re: installing virtual guest via ssh on console based remote host
> Date: Wed, 8 Aug 2012 23:42:54 +0100
> To: debian-user@lists.debian.org
>
> Nelson Green <nelsongreen84@hotmail.com> wrote:
> > I've got some more progress to report if you'll bear with me. First
> > of all, I did install the libvirt-bin and qemu-kvm packages. A bit of
> > history as to why I say this has been a nightmare is because the basic
> > problem has been a lack of straight-forward documentation, but that
> > could be my inability to find it
>
> To be honest it's an absolute nightmare. I forgot until I saw your reply
> that I've also needed to perform the following tweaks when using libvirt
> in a true client/server model:
>
> EITHER
> 1. Carry the libvirt/qemu protocol across an ssh tunnel to the
> server. This requires you to have a login account on the server
> 2. Add the user account from #1 to the libvirt group on the server
> 3. In the client GUI, create a connection to "nelson@server" (or
> whatever) rather than just to "server"
>
> OR
> 4. Edit /etc/libvirt/qemu.conf and /etc/libvirt/libvirtd.conf on the
> server to allow non-local connections to the daemon. Ideally with
> authentication (but this isn't essential if you are on a controlled
> and/or restricted network).
>
> I've never found SASL an enjoyable experience, so I would recommend that
> you go for the first option. However, you have have a policy dictating
> otherwise.
>
>
> > The first error I got was "Failed to connect socket to
> > '/var/run/libvirt/libvirt-sock': No such file or directory"
>
> I think this may be a consequence of omitting #2
>
>
> > So, I am now installing an OS on my VM. That leaves one final item,
> > but this is really low on the priority list. How do I clean up after
> > those failed initial attempts?
>
> The nasty but effective way is to shut down the libvirt daemon and delete
> the relevant xml files from /etc/libvirtd/qemu/.
>
> Chris

Thank you Chris. This is good info, based on experience. Not sure if you saw
my post saying I got it working, but not in the manner you describe. I will have
to do more of this in near future, so I will give your method a try. I will try to
put together a list of the steps for working methods and post it somewhere. I
do have good notes on what I've done so far, and I have added your
information to them.

And thank you for the xml file location info. I figured it was something like
that, since Virtual Box is similar, but wasn't sure where to find the files.

Back to work. Thanks again,
Nelson


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: BAY160-W3F132FEF618973F23C9BFADCC0@phx.gbl">http://lists.debian.org/BAY160-W3F132FEF618973F23C9BFADCC0@phx.gbl

Nelson Green 08-09-2012 12:51 PM

installing virtual guest via ssh on console based remote host
 
*> Not sure if you saw my post saying I got it working,
>

Sheesh, of course you saw my post, you were replying to it. That was a
consequence of too little sleep, and typing while carrying on a conversation
at the same time.


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: BAY160-W63878EDE56863A42F6740CADCC0@phx.gbl">http://lists.debian.org/BAY160-W63878EDE56863A42F6740CADCC0@phx.gbl

Bob Proulx 08-09-2012 10:16 PM

installing virtual guest via ssh on console based remote host
 
Nelson Green wrote:
> OK, another quick question, completely off subject, but hardly worth a new
> thread.

That's debatable. :-)

> When I look at my previous post through a browser, there are no line breaks,

Yes. Very annoying. And unfortunately not uncommon when using
Microsoft mail user agents. When doing so they should set
"format=flowed" and then the mail reader would know that it needs to
flow the text. But MS in particular doesn't do this and it is quite
annoying.

> and one has to scroll across the screen to read it.

Yes. Very annoying.

In my mail user agent (mutt in a terminal) it wraps hard at 80 columns
without regard to words. That is, it doesn't truncate the line. It
just keeps printing and when that runs off the end of the line it does
the traditional terminal thing and continues on the next line. But it
is also quite hard to read that way. Also very annoying. I often
need to manually word wrap a copy of the text in order to make it
readable.

> I don't imagine this is desirable for most users.

It is not. But most of us have probably gotten tired of griping about
it. MS hasn't fixed half of their bugs yet and this one doesn't seem
to be getting traction for a fix either. Email predates MS using it.
Many of us remember MS opposing being connected to the Internet and
them trying to cloister their subscribers off on their own private
side of things. Unfortunately that didn't work. When they decided to
play with others on the Internet they didn't ever decide to play by
the previously established rules and standards. We have been
suffering through it ever since.

> Is that a result of my mail client (hotmail)?

Microsoft bought Hotmail and converted it to MS systems some time ago.
Prior to the conversion away from Sun servers I believe their web
interface was function and word wrapping was applied by default. But
then everything was rewritten to use MS servers.

> This message won't suffer the same issue because I'm manually
> breaking the lines.

Thank you for doing that. There is very likely a setting that you can
set to have it automatically word wrap your paragraphs at 72
characters. Although searching now I see a lot of complaints from
users about that mis-feature. The best suggestion I see from the web
is to cut the previous text into an editor for composing and word
wrapping and then pasting the result back for mailing. That seems
very painful.

Perhaps you should consider using a different free email platform?

I learned long ago, never to wrestle with a pig. You get dirty, and
besides, the pig likes it. --George Bernard Shaw

Bob

Nelson Green 08-16-2012 06:43 PM

installing virtual guest via ssh on console based remote host
 
> Date: Thu, 9 Aug 2012 16:16:45 -0600
> From: bob@proulx.com
> To: debian-user@lists.debian.org
> Subject: Re: installing virtual guest via ssh on console based remote host
>
> Nelson Green wrote:
> > OK, another quick question, completely off subject, but hardly worth a new
> > thread.
>
> That's debatable. :-)
>

Bob, thanks for the reply. And as a MCSE, I can tell you that the visible problems
with microsoft products are only the tip of the iceberg. I used to think that their
products were bad. Then I got certified, and my suspicions were confirmed. That
is one reason all subsequent certifications had nothing to do with them.

I will go with a different email platform, as I suspected.

Nelson Green 08-16-2012 06:45 PM

installing virtual guest via ssh on console based remote host
 
> From: chris-usenet@roaima.co.uk
> Subject: Re: installing virtual guest via ssh on console based remote host
> Date: Wed, 8 Aug 2012 23:42:54 +0100
> To: debian-user@lists.debian.org
>
> Nelson Green <nelsongreen84@hotmail.com> wrote:
> > I've got some more progress to report if you'll bear with me. First
> > of all, I did install the libvirt-bin and qemu-kvm packages. A bit of
> > history as to why I say this has been a nightmare is because the basic
> > problem has been a lack of straight-forward documentation, but that
> > could be my inability to find it
>
> To be honest it's an absolute nightmare. I forgot until I saw your reply
> that I've also needed to perform the following tweaks when using libvirt
> in a true client/server model:
>
> EITHER
> 1. Carry the libvirt/qemu protocol across an ssh tunnel to the
> server. This requires you to have a login account on the server

I ended up using ssh tunneling. In the end it was much easier, and in line
with our goals for the VMs. Thanks so much for the help.


All times are GMT. The time now is 09:46 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.