kNetmon Documentation
Intro
kNetmon is free software according to the GNU General Public License.
kNetmon provides you an easy to use interface to your local network.
It is a bit similar to the "network neighbourhood" in the M$ Explorer, but
additonally transparently supports Samba, NFS and Novell netware and many
other network related tools (ping, talk, rlogin and so on).
Latest versions you can get from
http://www.rz.tu-ilmenau.de/~lekus/netmon.html
Features:
kNetmon supports Samba, version 1.x and 2.x
(smbclient, smbmount, smbumount)
-NFS
(mount, showmount)
-Novell Netware, almost untested
(slist, ncpmount, ncpumount)
-many network utilities:
talk, ping, rlogin, nslookup, nmblookup, telnet, finger
Requirements:
You need the following stuff:
-the KDE-libraries (http://www.kde.org), at least libkdecore.so and libkdeui.so,
both version 2.0 or newer
-the Qt-library 1.4 or newer (http://www.troll.no)
I compile it with the following stuff:
libqt 1.44
libkdecore 2.0
libkdeui 2.0
libc 5.4.33
libg++ 27.2.8
libstdc++ 27.2.8
g++ 2.7.2.1
Please tell me if you manage to compile kNetmon on another system than linux/pc.
Bug reports, comments, patches, suggestions ... to
alexander.neundorf@rz.tu-ilmenau.de
Installing:
Unpack knetmon-0.##.tgz (tar -zxvf knetmon-0.##.tgz), enter the new directory,
then run configure, make and make install (in this order).
This should compile and install kNetmon on your system.
After make install you have to restart KPanel if you are using it.
Then you should find kNetmon in the start menu under "Internet".
If you want to install kNetmon manually:
-copy the binary knetmon/knetmon and knetmon/netmonwrapper in your KDE binary directory ($KDEDIR/bin)
-copy knetmon/knetmon.kdelnk in the location where your other *.kdelnk files are and restart kpanel
-create a directory $KDEDIR/share/doc/html/en/knetmon and copy the file index.html in this directory
-copy the files *.xpm to the directory $KDEDIR/share/icons/mini/
If kNetmon runs, you have to configure it (File->Configure). For more information about
the configuration look under Configuration.
If you are connected to a Windows network, make sure that you have the right to execute smbmount,
this means, that smbmount and smbumount must be installed suid root
(the root of your system must set the "set user id on execution"-flag
of both files).
Compiling:
Change to the directory knetmon-#.## and execute configure.
After this execute make, then it should compile.
If you uncomment #define PING kNetmon will offer you a further method
for retrieving a list of active hosts in your network,
but this is not recommended, since this works not very stable and reliable.
If you uncomment #define DEBUG_ON in defines.h, you will
get a lot of ugly debugging output from kNetmon.
If you are not able to compile it, please mail me:
alexander.neundorf@rz.tu-ilmenau.de
Configuration:
If kNetmon runs you can configure it, you will find the configuration dialog
under ->File->Configure .
kNetmon reads its configuration usually from the file ($KDEDIR)/share/config/knetmonrc
and if this one doesn't exist from ($HOME)/.kde/share/config/knetmonrc.
Some tips for configuration
You are connected to a Windows network
Activate "Enable samba support" in the configuration dialog.
You must have installed the samba package
on your system. Make sure that your samba is configured correctly.
For using samba you must have a kernel with support for the SMB-filesystem
and "Network block device support" enabled.
Is there a Windows NT primary domain controller in your network ?
In this case, you must have installed at least samba 2.0.
In the configuration dialog you have to activate
"Ask always for password and username" and
"Samba is 2.0 or newer".
To mount/explore shares, you always have to use
"Explore using password" or "Mount using password" as long as they are
enabled, otherwise kNetmon may crash.
In smb.conf, the configuration file for samba, you have to adjust the following:
security = domain
password server = name_of_your_NT_domain_controller
Under Network-Settings:
Active workgroup:
This is the name of the current workgroup in the configuration dialog.
Here you can switch between the workgroups you have configured.
To add a workgroup, you have to press "Add workgroup" and then enter the name for the new workgroup.
To change the identifier of the current workgroup you have to press
"Change Name". There is also a button "Delete workgroup", I think you know what it does.
If you have enabled "Use workgroupname" you must enter the correct
name of this workgroup, if you haven't enabled "Use workgroupname" the workgroupname
actually doesn't really matter.
possible values: any_name
default value: default
knetmonrc: wg_name
Your user name:
This is the name kNetmon suggests to use if usernames
are required, but you have always the chance to enter another one.
possible values: any_name
default value: tux
knetmonrc: std_user
Use NSLookup:
Here you decide, wether kNetmon will use nslookup for some actions,
e.g. if you check this one, the IP-address of the hosts will be displayed
in the statusline and you have to enable this option, if you need to supply
the IP-address to smbclient/smbmount to work.
If you check this option, then you must enter the IP address of your
nameserver in the edit line, if your LAN is working well you should
also be able to enter the name of your nameserver.
If you are not sure, don't check this option.
possible values: don't select (no) or the IP address or name of your nameserver
default value: no
knetmonrc: use_nslookup
Use nmblookup:
Instead of nslookup you can also use nmblookup, in most configurations both works.
You've got to use nmblookup, if the hosts of your LAN have different DNS- and WINS-names.
possible values: yes, no
default value: no
knetmonrc: use_nmblookup
Enable Samba support
If you want to have access to a windows-/samba-LAN you have to enable
this option. To work properly you must have the following binaries on your system
included in the path:
smbclient
smbmount
smbumount
smbmnt (Samba 2.0 or newer)
Ensure that smbmount, smbumount and smbmnt are installed suid root.
The smb-filesystem and "network block device support" must be supported by your kernel.
possible values: yes, no
default value: yes
knetmonrc: enable_samba
Enable NFS support
With this option enabled you will also see the NFS-exports of other (UNIX-)hosts
and you will be able to mount and explore them (if you are a user who is allowed to).
Your kernel must support the NFS-filesystem and network-block-devices. Additionally you
must have the binary showmount in your path. If you want to make directories
accessible to others via NFS, you have to edit the file /etc/exports, it's easy.
possible values: yes, no
default value: yes
knetmonrc: enable_nfs
Enable Novell support
If you are connected to a Novell-Netware LAN, you should enable this option.
Then you will also see the Netware servers and there volume. Since I am not
connected to such a LAN, this feature is not much tested. It uses the following binaries:
possible values: yes, no
default value: no
knetmonrc: enable_novell
Get browselist from:
kNetmon will try to get a browsing list using "smbclient -L ..."
from the host you enter here.
Maybe you can keep it "localhost", but it should work better with the nameserver,
a router or a primary domain controller or something like that, just try it.
I recommend that you experiment with smbclient -L and its options from the
shell, until you found a host which provides a complete list of running hosts
and you found the combination of parameters where you don't need a password or need
to press enter. Sometimes therefor you need the parameter -W or -U guest,
you've got to try.
possible values: name of a samba or windows machine
default value: localhost
knetmonrc: browselist_server
Ask always for password and username
If you say yes, then everytime you take a look at the shares
of a host, you will be asked for your logon name and password.
This will call smbclient like: smbclient //hostname/IPC$ yourpassword -L hostname -U mylogonname
Set it only to Yes, if you know what you are doing.
possible values: yes, no
default value: no
knetmonrc: use_pw_allways
Samba is 2.0 or newer
Due to the changes in the syntax of smbmount in Samba 2.0 it is necessary to adjust
the version here.
possible values: yes, no
default value: no
knetmonrc: use_samba2
Use workgroupname
You should enable this option, if you need the parameter -W if you run smbclient
manually, usually this should only be the case if you have more than one workgroups.
As name for the workgroup the name of the Active workgroup will be used. If you're unsure,
don't enable this option.
possible values: yes, no
default value: no
knetmonrc: use_wgname_for_samba
Use guest login
In some network configurations it is required, to use the option -U guest for smbclient
to have access to this host.
possible values: yes, no
default value: no
knetmonrc: use_guest_for_samba
Use IP address
If yes, kNetmon will call smbclient like: smbclient -L hostname -I 192.11.200.10
else, if no, it will work like: smbclient -L hostname
so decide, if you need it.
If you select it, then you must select "Use NSLookup" too.
If you are not sure, don't select this option.
possible values: yes, no
default value: no
knetmonrc: use_ip_for_samba
Under GUI-Settings:
Use special talk program:
If you want to use the standard unix-talk in a xterm, then
don't check this, else if you want to use a Xwindows talk program
(which doesn't run in a xterm) enter the name in the edit line.
It is important that this talk is started with
"yourXtalk username@hostname" to talk to user "username" on host "hostname".
Since this is kNetmon, you may want to enter "ktalk".
possible values: any working X talk program
default value: not selected (standard)
knetmonrc: xtalk
Use following xterm:
This xterm will be used to execute ping, rlogin and so on in.
Kvt might not work, I think you should keep it "xterm".
possible values: any xterms with options equal to the standard xterm
default value: xterm
knetmonrc: xterm
Start xterm with options:
Every xterm selected above will be started with this options, set them as you like,
for instance "-fn 7x14" to have the 7x14 font in a standard xterm.
possible values: valid options for the selected xterm
default:
knetmonrc: xterm_options
Explore with:
This is the filemanager which will be started if you choose "explore host".
If you want to start your filemanager "xyz-fm" showing the directory "dontknow"
for instance with "xyz-fm -d dontknow", then you would have to set
"xyz-fm -d %dir", then it should work.
If it is a console-filemanager, for instance "mc" in color with the 7x14 font, then you would have to enter:
"color_xterm -fn 7x14 -e mc -c %dir".
possible values: any working filemanager
default value: kfmclient openURL %dir
knetmonrc: filemanager
Under More Settings:
Mount shares under:
Enter here the directory where you want to mount the shares and exports of other host.
To access the shares of other hosts they must be mounted first.
E.g. if you enter "~/network", and a host with the name "anyhost" has a public share "anyname",
this share will be mounted under ~/network/ANYHOST/anyname, where ~ stands for your home
directory.
It is very important that you have write permission in this directory, so
I think you should keep it as is. Another possibility would be /tmp/network,
there also everybody has write-permission.
possible values: any directory, where you have permission to write
default value: ~/network/
knetmonrc: mount_point
Update period:
Here you enter the number of seconds, after which kNetmon updates its
list of hosts.
If you enter "manual", kNetmon will only update after selecting "Update"
from the menu under "File".
possible values: 5 to 3600, or "manual"
default value: 180
knetmonrc: refresh
Patience time:
Here you enter the number of seconds, for which kNetmon will wait for
answers from hosts in the network, e.g. the time it will wait for smbclient or nslookup.
Depending on your network a time of 5 seconds should be enough.
possible values: 1 to 600
default value: 15
knetmonrc: killing_time
Check for binaries on startup
If this option is enabled, knetmon will check for all possibly used binaries on startup.
Once you know wether you have the used binaries, you can disable this option.
possible values: yes, no
default value: yes
knetmonrc: check_for_binaries
Unmount on exit
This decides, wether all the shares which were mounted by kNetmon and
all the created directories will be unmounted or removed if you exit
or kill kNetmon.
You should check this option, otherwise you may have problems on multi user systems.
possible values: yes, no
default value: yes
knetmonrc: unmount_on_exit
Known problems
In the case kNetmon didn't exit correctly, e.g. if you killed it using kill -9,
all directories that were mounted by kNetmon are still mounted. If you want to
unmount them all, run the script knetmon_cleanup. It is created automatically
by kNetmon in your home directory.
If kNetmon exits normally, this script will be empty.
If you are member of a NT-domain, you have to to enable the option
Ask always for password and username, you version of Samba must be 2.0 or
newer and you always have to use Mount/Explore using password, if you try without
password, you might run into problems.
While kNetmon is updating its display and the tree is disabled, don't select
anything from the menu, this might lead to problems.
If you mounted/unmounted something, kNetmon checks after some seconds (Patience time in
the configuration dialog), if it was successful. If you unmount/mount this share before
kNetmon did this check, it may also crash.
If it seems like mounting was successful (just enter "mount" to see what is mounted), but you are not able to look
at the contents of the mounted directory, and your harddisk is working all the time, the
reason could be that "Network block device support" isn't supported by your kernel.
In this case you have to compile a new kernel or install the module nbd.
If kNetmon isn't able to mount Samba shares, at first take a look at the configuration
dialog and try a bit. If this doesn't help, ensure that smbmount, smbmnt (for Samba 2.x) and smbumount
are installed suid root. This means that the root must set the "set user id on execution" flag of these files.