Tuesday, June 10, 2014

vmware tools and NetBSD

Message for all NetBSD lovers, who needed vmware-tools:


     The vmt driver is a kernel level implementation of VMware Tools.  VMware
     Tools are intended to provide better support for operating systems run-
     ning inside virtual machines.

     vmt handles shutdown, reboot, resume requests from the host by sending
     events using sysmon_pswitch(9) of type PSWITCH_TYPE_POWER,
     PSWITCH_TYPE_RESET, and PSWITCH_TYPE_SLEEP that can be handled by
     powerd(8)vmt will log notifications that the guest has been suspended
     or resumed by the host.

     vmt reports the guest's hostname and first non-loopback IP address to the
     host.

it means from NetBSD 6.0:

sh# modload vmt

and you have NetBSD VM with ability to shutdown/reboot from vmware infrastructure. Also you will see IP address of first non-loopback network interface within virtual machine. Great job!

Also another great news: Hikaru Abe  imported vmxnet3 driver from OpenBSD to NetBSD on Tue Jun 10 01:42:39 UTC 2014.

Labels: , , , ,

Monday, May 27, 2013

jailkit + ispconfig + ubuntu 12.04 SFTP problem

Hi,

with the jailkit on ubuntu 12.04 and installed ispconfig, by default chrooted SFTP not working. Here is a workaround:

we need to edit /etc/jailkit/jk.init.ini

change section from:

---- snip ----
comment = common files for all jails that need user/group information
libraries = /lib/libnsl.so.1, /lib64/libnsl.so.1, /lib/libnss*.so.2, /lib64/libnss*.so.2
regularfiles = /etc/nsswitch.conf, /etc/ld.so.conf
---- snip ----

to:

comment = common files for all jails that need user/group information
libraries = /lib/libnsl.so.1, /lib64/libnsl.so.1, /lib/libnss*.so.2, /lib64/libnss*.so.2, /lib/x86_64-linux-gnu/libnsl.so.1, /lib/x86_64-linux-gnu/libnss*.so.2
regularfiles = /etc/nsswitch.conf, /etc/ld.so.conf

and this section also:

---- snip ----
[netbasics]
comment = common files for all jails that need any internet connectivity
libraries = /lib/libnss_dns.so.2, /lib64/libnss_dns.so.2
regularfiles = /etc/resolv.conf, /etc/host.conf, /etc/hosts, /etc/protocols
---- snip ----


to:

[netbasics]
comment = common files for all jails that need any internet connectivity
libraries = /lib/libnss_dns.so.2, /lib64/libnss_dns.so.2, /lib/x86_64-linux-gnu/libnss_dns.so.2
regularfiles = /etc/resolv.conf, /etc/host.conf, /etc/hosts, /etc/protocols

add new chrooted user, and everything will work from now on.

Labels: , , ,

Wednesday, May 22, 2013

HP Proliant ML150 G6 won't boot from CDROM

If your HP Proliant ML150 G6 won't boot from CDROM but BIOS sees it, change SATA mode from AHCI to Compatible.

Labels: , , ,

Wednesday, February 01, 2012

free vm disk clone/backup howto

Some of us, using free version of vmware esxi want to clone/backup vm with free tools, yes? :)
There a lot of products which are expensive, big, and they somehow work, but if you are some sort of g33k, here is a way to make backup of runing virtual machine. Lets look how it can be done:

Let's assume that we have virtual machine by name: testvm, it is runing from some sort of datastore named datastore (strange, yes?), so - you have already sitting, logged in via SSH to vmware esxi host, looking to the black screen and...

First of all we need to create snapshot of runing VM, we need this to remove lock of main vmdk file:

vmware-cmd /vmfs/volumes/datastore/testvm/testvm.vmx \
createsnapshot "test" "Backup of testvm on 2012-02-01" 1 1

after that, in some minutes, depending of the size of vm disk, we should see something like that:

createsnapshot(test, Backup of testvm on 2012-02-01, 1, 1) = 1

Then we create copy of the disk:

vmkfstools -i /vmfs/volumes/datastore/testvm/testvm.vmdk \
/path/to/backup/place/testvm_clone.vmdk

you should see some sort of text:

Destination disk format: VMFS zeroedthick
Cloning disk: /vmfs/volumes/datastore/testvm/testvm.vmdk 
Clone: 5% done.

yeah! now we have copy of a runing live VM!! But first we need to delete snapshot, we have created to unlock our vmdk file:

vmware-cmd /vmfs/volumes/datastore/testvm/testvm.vmx removesnapshots

That's all. We have vmdk file (the disk (with all the files:) of the virtual machine), the machine is runing fine. A little shell scripting, nfs or physical backup disks, gzip, crontab and we have free backup software :)

P.S. if the disks of virtual machines are persistent, then we can't create snapshots, and of course, can't backup with this scheme those machines.

Labels: , , , ,

Thursday, July 21, 2011

Black explorer menu bar after clean install

On some fresh installed windows xp laptops, there is a strange behavior - black menu bar apears on top. One hint to fix that - change windows xp theme to another, and then change back to prefered one. After this trick - black menu bar will be fixed.

Friday, July 01, 2011

Reveal your password hidden in browser password field

One nice day, I was very sad, because I forgot one my passwords to important router management. Password was saved in my IE, but how to reveal it? As you may know - router does'nt have capability to "remind your password" :) After some googling I found one script, that I'll share with you below. You just need to go to a site, where your password masked with asterisks, paste code to address bar, and press enter! Thats it!

The script is here:



As far as I have tested, this method works on Internet Explorer, Firefox, Netscape and Opera.

Labels: , , ,