Included in this file is the TOOLBOX.DLL example.
TOOLBOX.DLL (Demonstration DLL)
Version 2.00b (for NetWare 4 & 5)
Copyright (C) 1997,1998 Novell, Inc.
All Rights Reserved
________________________________________
I. ABSTRACT
________________________________________
TOOLBOX.DLL v2.00b is built from the same source as TOOLBOX.NLM v2.00, and was build as a demonstration of the robustness of the DLL loader (PELDR) for NetWare 4.11 and 5. The only code modification needed was a compiler specific pragma and a 64 bit integer data type; all other code worked as written.
TOOLBOX is a utility toolbox for NetWare 4 and 5 servers, providing various dos-like commands at the console.
________________________________________
II. INSTALLATION INSTRUCTIONS
________________________________________
Copy TOOLBOX.DLL into SYS:SYSTEM on the server.
________________________________________
III. USAGE
________________________________________
Loading PELDR: (need only be done once after reboot)
pmload LOADERXT (NetWare 4.11 only)
load PELDR
Loading TOOLBOX.DLL: (After PELDR is loaded)
load TOOLBOX.DLL
After loading TOOLBOX:
General Help:
TOOLBOX
A command listing is done with the command:
TOOLS
For help on the commands provided by Toolbox, type:
<CommandName> ? or /?
________________________________________
IV. PRODUCT DESCRIPTION
________________________________________
TOOLBOX is a collection of utilities that can be used at the server console, or executed from NCF files. All utilities, except where specified, allow operations on the local DOS partition, the local server's Volumes, and remote server's Volumes.
The utilities provided by Toolbox are:
auth - Manage authentication/connection information
beep - Ring the bell (no help available)
chdir (cd) - Set/View current directory or default path
copy (cp) - Copy utility
del (rm) - Delete utility
delay - Delay command
dir (ls) - Directory utility
echo - Echo a string to the console (no help available)
flag - Flag and attribute utility
map - Alias mapping
mkdir (md) - Make Directory utility
move (mv) - Move utility (alias for COPY /MS)
purge - Purge deleted files
rmdir (rd) - Remove Directory utility
shutdown - Shutdown and restart the server
startfile - Edit the Startup file (see help in newly created file)
Startfile Only Commands:
CDV4 - Allow the CD alias in NetWare 4.x. (See CD help)
NONS - Disable long name space support
NSV4 - Enable long name space on v4.x (with Support Pack 6)
tapplet - Start a Java applet
texp - Export (copy) Toolbox.DLL and all associated files
tjava - Start a Java application
tload - Load a NetWare module
tmodules - List loaded NetWare modules
trun - Execute an NCF file
tunload - Unload a NetWare module
toolbox - Toolbox main help
tools - Toolbox Command List (this screen)
type (cat) - Display file(s) on the screen
xtd,xtb,dtx - Hex, Decimal and Binary conversion
AUTH Help
---------
Authentication management utility - auth (v1.2)
USAGE: auth [BinderyServer | Tree [Username [Password]] [options]]
SAVE | LOAD [filename]
authset (alias)
Server = Server name (can include wildcards if listing)
Username = User object for authen. to Tree or Bindery server.
NDS users must be fully qualified from [Root]:
e.g. .bryan.devsup.provo.novell
Password = Password for above user (Enter "" for no password)
or omit to be prompted.
Options = preface option(s) with '-' or '/' (e.g. -bsa)
b - Entry specifies a Bindery connection
c - List connection table (all if no name specified)
d - delete one entry (if server/tree is specified)
or all entries (if not specified)
c - List connection table (all if no name specified)
m - Used only with LOAD which merges the current
entries with the ones being loaded.
Otherwise all current entries are removed.
o - logOut entry (or logout all if entry is omitted)
filename = A file to save/load an authentication profile
The directory must already exist. Even though
the file is encrypted, it is suggested to place
it in SYS:SYSTEM for security purposes.
Description:
- Authentication information is used by TOOLBOX utilities
when authentication is required. If the AUTH table doesn't
contain the auth info needed, it will be prompted for.
- If Username has no password, specify ""
- If password is omitted, it will be prompted for
- If adding an entry that already exists, the original
will be overwritten without warning.
- If no file is specified with SAVE or LOAD, the default profile
name is used: SYS:SYSTEM/TBOXAUTH.DAT
- All AUTH table entries are automatically saved upon exiting
TOOLBOX, and are restored upon loading TOOLBOX.
This is done before any startup commands are executed so it
can be overwritten with an AUTH LOAD command in the STARTFILE.
- AUTH LOAD without the /m (merge) switch, will logout
all current connections to prepare for the new table.
NDS Connections:
To specify an NDS connection you need only provide
authentication information for the tree. TOOLBOX will
automatically use those credentials when communication
with a server in that tree is requested.
Bindery Connections:
Bindery connections are specified with the /b option.
If the /b option is omitted, the entry is assumed to be a tree.
Auth Examples:
- AUTH mytree .bamund.devsup.novell (add a tree entry)
- AUTH mysrvr supervisor /b (add a bindery server entry)
- AUTH (list all entries in the auth table)
- AUTH mytree (list a single entry)
- AUTH my* (list all matching entries)
- AUTH mytree /d (delete all 'mytree' entries)
- AUTH /d (delete all auth entries)
- AUTH /c (list the current active connections)
- AUTH mytree /o (logout of mytree and all its servers)
- AUTH /o (logout of all trees and servers)
BEEP Help:
----------
USAGE: beep
Rings the beell
CD Help:
--------
Change/View Current Directory utility - chdir (v1.4)
USAGE: chdir [Path]
c
cd (NetWare 5 only. See Known Issues below)
pwd
Path = [servername/]VolOrDrive:[path]
= ..[/][...]
= may include spaces and wildcards
Description:
- When set, "Path" will be prepended to all filespec and path
arguments that do not include a colon
- cd with no parameters will display the current path
- Set the default path to LocalServer/SYS: by doing: cd ""
- Any number of dots can be used to go back n - 1 directories
- Wildcards (*) may be specified for directory completion
- Supports LONG name space on NetWare 5 local server only.
- Quotes are allowed but not required in the path for
directories with spaces
- AUTH information is used for all authen. (See AUTH)
Known Issues:
- CD is a reserved command on NetWare 4 (CDROM.NLM)
so the CD alias is not active by default. If CDROM.NLM
is not used, you may use CD on NetWare 4 by specifying
in the startup file: CDV4 (See STARTFILE)
COPY Help:
----------
Copy/Move utility - copy (v1.5)
USAGE: copy SourceSpec [DestPath] [options]
move (same as: copy /ms)
cp (same as: copy)
mv (save as: move)
SourceSpec = [servername/]VolOrDrive:["]path["]/filespec
DestPath = [servername/]VolOrDrive:["]path["][/file]
Options = preface option(s) with '-' or '/' (ie. -bsa)
a - do not copy DOS & NetWare Attributes
d - copy empty subDirectories
e - do not remove Empty dirs during a move
l - Log activity summary to the file:
TBOX$ACT.LOG in the destination directory
m - Move file/dirs (delete original after copy)
r - overwrite Read-only files (on NetWare partitions)
s - copy filespec in current dir and all subdirs
v - Verbose mode
q - Quiet mode
Features/Description:
- Works with DOS partition on local server
- Keeps activity log for auditing purposes
- Interrupt copy with Ctl-C
- Supports Long name space copying between two local
volumes on NetWare 5 only
- Quotes are required in the path for directories with spaces
- AUTH information is used for all authen. (See AUTH)
Limitations/Known Issues:
- No wildcards are allowed in destination filespec
- Trustees and extended attributes are not copied
- Files copied to the DOS partition will not preserve attributes
- Overwrite Read-only files is not supported on any DOS Partitions
- Max recursive depth for subdirectory copies is 15
- DestPath may only be omitted if both are true below:
* No username and password are specified
* A current directory is set with CHDIR
- Empty subdirs are always copied from the DOS partition. (See /e)
- With Move, the /s switch is active only when Moving a directory.
This conforms to the typical move specification.
Warnings:
- If the destination file exists,
it will be overwritten without warning.
DEL Help:
---------
Delete utility - del (v1.5)
USAGE: del FileSpec [options]
rm
FileSpec = [servername/]VolOrDrive:path[/filespec]
Options = preface option(s) with '-' or '/' (ie. -bsa)
s - delete filespec in current and all subdirs and
remove any empty subdirectories when completed
e - will not remove Empty subdirs (used with /s)
q - Quiet mode
r - Do not delete Read-only files
v - Verbose mode
y - Suppress delete confirmation
Description:
- Deletes the files specified with filespec
- If a directory is specified with the /s option, it will be removed
as well as all files and subdirs beneath it unless /e is used
- Removes read-only files by default (use /r to preserve them)
Features:
- Supports LONG name space on NetWare 5 local server only
- Works with DOS partition on local server
- Quotes are required in the path for directories with spaces
- AUTH information is used for all authen. (See AUTH)
Limitations/Known Issues:
- Max recursive depth for /s option is 15
- Cannot delete Read-only files from DOS Partitions
DELAY HELP:
-----------
Delay/Pause the command prompt - delay (v1.1)
USAGE: delay [mseconds]
mseconds = number of milliseconds to delay
Description:
- To hold the command prompt from executing any other commands
for a specified delay time
- Useful in NCF files to pseudo-synchronize commands
- If mseconds is not specified, delay the default of 1000ms (1 sec)
Warning:
- You cannot break out of delay once it has started
DIR Help:
---------
Dir utility - dir (v1.5)
USAGE: dir [FileSpec] [options]
ls
FileSpec = [servername/]VolOrDrive:[path/filespec]
Options = preface option(s) with '-' or '/' (ie. -bsa)
c - Continuous listing
d - list Directories only
n - list DOS Name space names
s - search Subdirectories for filespec
t - list Totals only
v - Verbose mode
w - Wide listing
Description:
- If no filespec is specified, a directory of the
path specified by Chdir is listed.
Chdir path is set to the root of SYS: by default.
- AUTH information is used for all authen. (See AUTH)
- Supports LONG name space on NetWare 5 local server only
- Quotes are required in the path for directories with spaces
Features:
- Works with DOS partition on local server
Limitations/Known Issues:
- Will not report available space on the DOS partition
- Max recursive depth for subdirectory listings is 15
ECHO Help:
----------
USAGE: echo [["]string["]]
string = Any string to echo to the console
Quotes are optional.
FLAG Help:
----------
Flag utility - flag (v1.0)
USAGE: flag [[FileSpec] [[+|-]attribs] [/options]]
ls
FileSpec = [servername/]VolOrDrive:[path/filespec]
Attribs = + sets (default), - clears
DOS Attributes
N - Normal (clear all attributes)
R - Read only
H - Hidden
Y - sYstem
A - Archive
NetWare Attributes
T - Transaction
P - immediate Purge
S - Sharable
D - Delete inhibit
C - Copy inhibit
E - rEname inhibit
O - don't cOmpress
I - Immediately compress
B - don't suBallocate
Options = preface option(s) with '/' (ie. /sv)
c - Continuous listing
s - search Subdirectories for filespec
v - Verbose mode
Description:
- Provides limited capabilities for setting file attributes
- If no filespec is specified, a directory of the
path specified by Chdir is listed.
Chdir path is set to the root of SYS: by default.
- AUTH information is used for all authen. (See AUTH)
- Supports LONG name space on NetWare 5 local server only
- Quotes are required in the path for directories with spaces
- If a directory name is specified, all files in the directory
will be listed/modified
Limitations/Known Issues:
- Max recursive depth for subdirectories is 15
- Will not set attributes on DOS partitions
- Will not set directory attributes
MAP Help:
---------
Map utility - map (v1.0)
USAGE: map [Alias:[=[Server/]Vol|Drive:[path]] [options]]
SAVE | LOAD [filename]
Alias = Alias name used to refer to resource.
Can be up to 15 characters in length.
Server = Server name
Vol = Volume name or DOS drive letter
Path = Directory Path or File (. for current dir.)
Options = preface option(s) with '-' or '/' (e.g. -bsa)
c - Continuous listing
d - delete one entry (if alias is specified)
or all entries (if none specified)
m - Used only with LOAD which merges the current
entries with the ones being loaded.
Otherwise all current entries are removed.
s - Do not append a / to the end of the path.
This is used for aliases to files.
filename = A file to save/load a map profile
The directory must already exist.
Description:
- If adding an entry that already exists, the original
will be overwritten without warning.
- If no file is specified with SAVE or LOAD, the default profile
name is used: SYS:SYSTEM/TBOXMAP.DAT
- All MAP table entries are automatically saved upon exiting
TOOLBOX, and are restored upon loading TOOLBOX.
This is done before any startup commands are executed so it
can be overwritten with a MAP LOAD command in the STARTFILE.
- Supports LONG name space on NetWare 5 local server only
- Quotes are required in the path for directories with spaces
- Mappings are not verified for validity. This prevents
connections from being established merely because a map
entry exists to a server. TOOLBOX establishes connections
only when operations are performed on that server.
- The alias value automatically has a / appended to it
unless the /s option is specified, allowing file aliases.
Examples:
- map mydir:=edward_ii/vol1:users/bamund
- map silauto:=silicon/sys:system/autoexec.ncf /s
- map mydir: /d
MD Help:
--------
Make Directory utility - mkdir (v1.3)
USAGE: mkdir Directory
md
Directory = [servername/]VolOrDrive:path
Features:
- Will create all non-existant directories in the path
- Supports LONG name space on NetWare 5 local server only
- Quotes are accepted but not required in the path
for directories with spaces.
- AUTH information is used for all authen. (See AUTH)
MOVE Help:
----------
See COPY Help.
PURGE Help:
-----------
Purge utility - purge (v1.7)
USAGE: purge [Path] [options]
Path = [servername/]Volume:[path[/filespec]]
Options = preface option(s) with '-' or '/' (ie. -bsa)
a - purge files in directory and all subdirs
d=nn - don't purge files deleted less than nn days
q - Quiet mode
v - Verbose mode
Description:
- Purges (permanently removes) all files in Path
- If Path is omitted, all files in the current directory
from Chdir are purged
Features:
- AUTH information is used for all authen. (See AUTH)
Limitations/Known Issues:
- Max recursive depth for /a option is 15
- Support only DOS name space names
RD Help:
--------
Remove Directory utility - rmdir (v1.4)
USAGE: rmdir Directory
rd
Directory = [servername/]VolOrDrive:path
Features:
- Supports LONG name space on NetWare 5 local server only
- Quotes are accepted but not required in the path
for directories with spaces.
- AUTH information is used for all authen. (See AUTH)
Limitations:
- Will only remove the directory if it is empty. See "DEL /S"
SHUTDOWN Help:
--------------
Down Server utility - ShutDown (v1.3)
USAGE: ShutDown [Server] [options]
Server = Servername of server to down (local if none)
Options = preface option(s) with '-' or '/' (ie. -bsa)
f - Force Server Down even if there are
open files
q - Do not prompt for confirmation.
LOCAL SERVER ONLY OPTIONS:
r - Restart the server after it is down
s - reSet server (NetWare 5 only)
Description:
- ShutDown allows you to force the server DOWN, even if files
are open, without having to be at the console to confirm it.
- If the Force option is not specified and files are open,
ShutDown will print an error and return to the prompt.
- Restart (/r) is the default behavior on NetWare 5
- Reset server reboots the machine (NetWare 5 only)
STARTFILE Help:
---------------
USAGE: Startfile
Description:
- Edits the startup file which is executed when toolbox loads
- Only certain commands are valid for the startup file,
execute the TOOLS command for that list.
If an invalid command is placed in the file,
Toolbox will report the error upon startup.
- Load TOOLBOX with the /NS switch to not execute the startup file
- Comments for the startup file include: # ; REM
- This documentation is also found in the startfile file itself.
- The startfile name is: sys:system/tbox.cfg
- Special Startfile only commands are:
NONS - Disables long name space support
CDV4 - Allows the CD command to be registered on 4.x
which is not registered by default so it doesn't
conflict with the CDROM NLM.
NSV4 - Enables long name space support on 4.x. It is
disabled by default on 4.x because of CLIB bugs
but should be corrected in Support Pack 6.
- Startfile documentation is placed in a newly created file.
If you want the above docs in your startfile, remove it,
and reload Toolbox.
T[exec]... Help:
--------------
Load/Unload/Execute Server Modules - (v1.0)
USAGE: TLoad [Server/vol:path/]Module [Parameters]
TUnload [Server:]Module
TModules [Server:][ModuleSpec]
TRun [Server:]NCFFile [Parameters]
TJava [-options] Class [Class Options]
TApplet [-debug] [-J<runtime flag>] URL|File
TLoad - Same parameters as the LOAD command
TUnload - A loaded module
TModules - A module name or module spec may be specified
TRun - Any parameters for executing an NCF file
TJava - For parameters see: java -help | java -nwhelp
TApplet - For parameters see: help applet
Options:
-cp<path to append to classpath> (TJava only)
This option allows you to easily append
a path (or paths separated by ;)
to the existing classpath in ENVSET.
This should not be used with -classpath.
Description:
- Texec commands use the current directory (set by CD)
to provide path information for executing modules
or Java applications/applets.
Texec commands do NOT use the OS search paths.
- TLoad allows you to load a server module from the
current directory without the need to specify a path
to the module. A full path may be specified if desired.
- TUnload will unload a server module on a specified server,
or the server in the current directory.
- TModules will list modules on a specified server,
or the server in the current directory.
- TRun allows you to run an NCF file from the
current directory without the need to specify a path
to the file. A full path may be specified if desired.
- TJava works the same as executing a Java application
using the JAVA command, except that TJava automatically
inserts the current directory into the classpath.
One custom option: -cp<classpath> is available to
easily append a path (or paths separated by ;) to the
existing classpath variable in ENVSET. Basically
this option is the same as specifying:
-classpath $CLASSPATH;<classpath>.
The -cp option cannot be used with -classpath.
Requires JAVA.NLM to be loaded.
- TApplet works the same as executing a Java applet
using the APPLET command, except that TApplet uses the
current directory as the path to the HTML file, if
a URL is not specified.
Requires JAVA.NLM to be loaded.
Limitations:
- TJava and TApplet do not work for remote servers
Examples:
- TLOAD:
cd vol1:mynlms
tload test
tload joeserver/sys:mynlms/test
- TUNLOAD:
cd jimserver/sys:
tunload monitor
tunload joeserver:monitor
- TRUN:
cd vol1:myncfs
trun doit
trun joeserver/sys:myncfs/test
- TMODULES:
cd joeserver/sys:
tmodules mo*
tmodules joeserver:mo*
- TJAVA:
cd sys:java/demos
tjava mydemo
tjava -cp<append to classpath> <classname>
tjava -classpath <a custom classpath> <classname>
- TAPPLET:
cd sys:java/applets
tapplet myapplet
TEXP Help:
----------
Toolbox Environment Export Utility - texp (v1.0)
USAGE: texp destDir
DestDir = Directory to copy Toolbox.DLL and related files
Description:
- Toolbox.DLL uses various files to store and retrieve
necessary information such as Authentication, Map,
and Startup data.
This utility provides a quick way to copy all current
files that toolbox needs for its current environment
to a specified location, such as another Server.
- IMPORTANT: In order for Toolbox to work properly, all exported
files must be placed in SYS:SYSTEM on the destination server.
Also be sure that TOOLBOX is not loaded on the destination
server or the new Authentation and Map data files will be
overwritten when Toolbox unloads. (See TUNLOAD)
TOOLBOX Help:
-------------
USAGE: toolbox [?][/?]
Displays the main toolbox help screen and copyright
EXAMPLE:
toolbox
TOOLS Help:
-----------
USAGE: tools [?][/?]
Displays the command list screen.
EXAMPLE:
tools
TYPE Help:
----------
Type utility - type (v1.4)
USAGE: type FileSpec [options]
cat
FileSpec = [servername/]VolOrDrive:path/filespec
Options = preface option(s) with '-' or '/' (ie. -bsa)
c - Continuous display
Description:
- View the contents of text files on the screen
Features:
- Accepts wildcards for viewing multiple files
- Works with DOS partition on local server
- Supports LONG name space on NetWare 5 local server only
- Quotes are required in the path for directories with spaces
- AUTH information is used for all authen. (See AUTH)
XTD, XTB, DTX Help:
-------------------
Hex, Decimal and Binary conversion
USAGE: XTD <hex number> (convert hex to decimal)
XTB <hex number> (convert hex to binary)
DTX <decimal num> (convert decimal to hex)
|