<div dir="ltr"><div><div>Thanks Richard. I followed your guide and it works for me.<br><br></div>Thanks,<br></div>Allen<br></div><div class="gmail_extra"><br><div class="gmail_quote">2016-07-13 17:04 GMT+08:00 Richard W.M. Jones <span dir="ltr"><<a href="mailto:rjones@redhat.com" target="_blank">rjones@redhat.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">[Let's keep the replies on the mailing list please]<br>
<span class=""><br>
On Wed, Jul 13, 2016 at 11:04:13AM +0800, Baochuan Wu wrote:<br>
> Thanks Richard.<br>
> I tried guestfs_set_network, and I think I can successfully use yum -y to<br>
> install software. It is a little slow.<br>
<br>
</span>Most of the time is taken running yum and downloading packages ...<br>
<span class=""><br>
> My program operates CentOS 6.4 VM virtual disks on CentOS 7, I installed<br>
> libguestfs into the CentOS 6.4. After installing, I reboot CentOS 6.4 but I<br>
> cannot log into it anymore.<br>
<br>
</span>You will need to relabel the filesystem after installing packages, see:<br>
<br>
  <a href="https://github.com/libguestfs/libguestfs/blob/master/customize/customize_run.ml#L415-L430" rel="noreferrer" target="_blank">https://github.com/libguestfs/libguestfs/blob/master/customize/customize_run.ml#L415-L430</a><br>
<span class=""><br>
Rich.<br>
<br>
--<br>
Richard Jones, Virtualization Group, Red Hat <a href="http://people.redhat.com/~rjones" rel="noreferrer" target="_blank">http://people.redhat.com/~rjones</a><br>
Read my programming and virtualization blog: <a href="http://rwmj.wordpress.com" rel="noreferrer" target="_blank">http://rwmj.wordpress.com</a><br>
</span>virt-builder quickly builds VMs from scratch<br>
<a href="http://libguestfs.org/virt-builder.1.html" rel="noreferrer" target="_blank">http://libguestfs.org/virt-builder.1.html</a><br>
</blockquote></div><br></div>