Skip to main content

Posts

Configure STAF to run as a Windows service

There are some advantages on running STAF as a Windows service. Common reason being that the STAF functionality is available even without user logged into the system. Configuring STAF to run as a service needs an auxiliary application, like srvany.exe. This file is part of Windows Resource Kit. Due to licensing restrictions I cannot attach the file here but it should not be big of a problem as you can download the resource kit from Microsoft for free. Do a google using the keywords "Windows Resource kit" and start from there. The filename of the installer normally is rktools.exe. Once downloaded, install the software look for srvany.exe and instsrv.exe.  You can copy this files somewhere so that you can use it other machines. See below for the steps for configuring STAF to run as a service: 1) Copy instsrv.exe and srvany.exe into C:\Windows\System32 (actually $windir\system32 ). 2) In Windows console ( Start->Run "cmd.exe"), change to directory C:\Windows\Syst

Configure Ubuntu to search hostnames across domains

I am not sure if I messed up my Ubuntu system or something but it does not search hostnames within our intranet on different domains. On Windows systems, this is automatically done for you through DNS Suffix Search List which I believe is being supplied by DHCP server, not really sure. Now to get my Ubuntu machine ping other hosts on another domain we have to do two things. First we need to do this . Then configure our Ubuntu box for the search order. This can be done in two ways. GUI via System->Administration->Network, it should show something like this: Or this can be done through the file /etc/resolv.conf. See below for an equivalent configuration. #: nano -w /etc/resolv.conf #<-- start here nameserver 142.176.1.82 nameserver 142.176.1.101 nameserver 142.176.1.102 domain asia.nothing.com search asia.nothing.com na.nothing.com ~ts

Manually configure networking in Debian under VBox

For some reason my Debian 4.0 box running under VBOX does not connect to the internet via NAT all the time, reason? I don't know. Anyway, I was able to get it up and running using the usual old, in the terminal configuration. First, since my first interface, eth0, is configured by default to get IP from DHCP, I have to bring it down, i.e. #: ifdown eth0 Now, let us bring it up manually with an IP that is probably not being used by other VMs running inside VBOX in this case we will try 10.0.2.3. #: ifconfig eth0 up 10.0.2.3 netmask 255.255.255.0 Note that by default, VBOX gateway is 10.0.2.2 or basically we can also say that this is the IP address of the host machine internally. Let us now add entry into the routing table to route traffic to the gateway. #: route add default gw 10.0.2.2 One last change we need to make is in the file /etc/resolv.conf. #: nano -w /etc/resolv.conf #<-- this line is not included, search for namesever nameserver 192.xxx.xxx.xxx Note that the IP addre

How to get Linux box ping a Windows machine via netbios/wins

Name resolution in Linux is controlled by System Databases and Name Switch Configuration file which is located in /etc/nsswitch.conf, at least for my Debian based system. Note this is only true I think with libc5 and newer with NYS support and the GNU C Library 2.x (libc.so.6). The most import section to get a Linux to ping a Windows machine is the hosts statement. # ~: nano /etc/nsswitch.conf # <----- several lines before this one hosts: files dns wins What this says is that the gethostbyname and similar functions will first check the local database (/etc/hosts). If the name cannot be found then do use dns and finally wins. But for wins lookup to work, winbind needs to be installed. Winbind provides 3 major functions for integrating with Windows network. But we are not really using anyone of those 3 major functions but rather we need the functionality provided by /lib/libnss_wins.so library. So to get this file installed, do: #: apt-get install winbind And as a side note, I have

Creating Windows icon using GIMP

Windows application icons normally used in an application is a multi-page icon. One is 16x16 at 4bpp and 32x32 that can be set as high as 32bpp. Creating an icon in GIMP is a easy a creating a new graphics document. Set the background to transparent and size to 32x32. On the first layer, add 16x16 and on the second layer add 32x32 picture. Save the file as .ico and select 4bpp for 16x16 image and 32bpp for 32x32. That should be it and off you go, you know have a nice looking Windows icon.