This tutorial assumes that your PC is running Microsoft Windows 95 and is connected to the College Internet backbone network or to the Internet via an Internet Service Provider (ISP). With other operating systems, the procedure will be similar.
Typically, usernames are all lower-case, begin with your first initial, followed by up to seven letters of your surname. (Unix being what it is, usernames are limited to 8 characters.) For example, Mike Boldin's username is mboldin; Arnold Schwarzenegger's would be aschwarz.
Your username and password are also used to transfer files to the server via FTP. Consult the FTP tutorial for more information.
telnet> open www.technology.niagarac.on.ca
On success, the server will respond with the following output in the
main Telnet window. Enter your assigned username and password when
prompted. (For security reasons, your password will not be
displayed on the screen; in this example, we use "jrperson"
[J.
FreeBSD (www.technology.niagarac.on.ca) (ttyp0)
login: jrperson
Password:
Last login: Wed Aug 27 12:57:21 from 192.197.62.10
Copyright (c) 1980, 1983, 1986, 1988, 1990, 1991, 1993, 1994
The Regents of the University
of California. All rights reserved.
FreeBSD 2.2.2-RELEASE (GENERIC) #0: Tue May 20 10:45:24 GMT 1997
Welcome to the Niagara College Technology WWW Server, now powered by FreeBSD!
The FreeBSD Handbook is in /usr/share/doc/handbook and the FAQ in
/usr/share/doc/FAQ.
/home/jrperson>
The "greater-than" sign (>) is called the prompt; it means that the server is waiting for you to enter Unix commands. The prompt also displays the current working directory. (This is equivalent to the the pwd ["print working directory"] command, which tells you in which directory you are currently working.)
When you first log in, you are placed in your home directory (which matches your username). To return to your home directory at any time, enter the cd command without any parameters. Under DOS, this command is equivalent to pwd. Otherwise, cd is equivalent to its DOS counterpart, with two exceptions:
/home/jrperson> passwd
Changing local password for jrperson.
Old password:
New password:
Retype new password:
passwd: rebuilding the database...
passwd: done
/home/jrperson>
As with logging in, your passwords are not displayed as you type them (for obvious security reasons). To further enhance security, FreeBSD insists that you use mixed case or digits in your passwords. If you enter all lower-case letters, the following message is displayed, and you are re-prompted for a password:
Please don't use an all-lower case password.
Unusual capitalization, control characters or digits are suggested.
| DOS Command | Unix Equivalent | Description |
| dir | ls -lF | List files |
| copy | cp | Copy a file or files |
| move | mv | Move files or directories |
| ren | mv | Rename a file or directory |
| del | rm | Delete (remove) files |
| type | cat | Display (concatenate) a file or files |
| md | mkdir | Create (make) a directory or directories |
| rd | rmdir | Remove an empty directory or directories |
| help | man | Obtain help (read manual pages) on commands |
| deltree | rm -r | Remove a subdirectory and its contents |
| find | grep | Find a string (or regular expression) in a file |
| qbasic | perl | Interpreted general-purpose programming language |
| xcopy | cp -r | Copy a subdirectory and its contents |
| cls | clear | Clear the screen (terminal window). |
/home/jrperson>alias
copy (cp -i -p)
del (/bin/rm -i)
deltree (/bin/rm -r -i)
dir (/bin/ls -lF)
la (/bin/ls -a)
lf (/bin/ls -FA)
list more
ll (/bin/ls -lA)
lm /bin/ls -lA !* | more
ls (/bin/ls -F)
md mkdir
move (mv -i)
path echo $path
rd rmdir
type cat
up (cd ..)
/home/jrperson>
Note that the ls command is widely-represented. By itself, The ls command lists only filenames.
/home/jrperson> ls
public_html
/home/jrperson>
When you log in for the first time, only public_html is shown. This file is actually a link to your personal World Wide Web directory, and behaves like a directory. Your WWW directory is in the /usr/wwwhome/people directory, and is spelled with your full last name. If you type cd public_html, you will go there, and can manage your HTML pages.
Output from the dir alias (actually ls -lF) displays the following information,
/home/jrperson>dir
total 0
lrwxrwxrwx 1 root wwwusers 27 Aug 22 16:25 public_html@
-> /usr/wwwhome/people/jrperson
/home/jrperson>
The "total" line displays the number of blocks (1 block = 512 bytes) used by files in the directory, and for each file, from left to right:
/home/jrperson>man man
MAN(1) FreeBSD General Commands Manual MAN(1)
NAME
man - format and display
the on-line manual pages
SYNOPSIS
man [-adfhktw] [-m system]
[-p string] [-M path] [-P pager] [-S list]
[section] name ...
DESCRIPTION
Man formats and displays
the on-line manual pages. This version knows
about the MANPATH and PAGER
environment variables, so you can have your
own set(s) of personal man
pages and choose whatever program you like to
display the formatted pages.
If section is specified, man only looks in
that section of the manual.
You may also specify the order to search the
sections for entries and
which preprocessors to run on the source files
via command line options
or environment variables. If enabled by the
system administrator, formatted
man pages will also be compressed with
the `/usr/bin/gzip -c' command
to save space.
etc.
/home/jrperson> man intro
INTRO(1) FreeBSD General Commands Manual INTRO(1)
NAME
intro - introduction to
general commands (tools and utilities)
DESCRIPTION
Section one of the manual
contains most of the commands which comprise
the BSD UNIX user environment.
Some of the commands included in section
one are text editors, command
shell interpreters, searching and sorting
tools, file manipulation
commands system status commands, remote file
copy commands, mail commands,
compilers and compiler tools, formatted
output tools, and line printer
commands.
All commands set a status
value upon exit which may be tested to see if
the command completed normally.
The exit values and their meanings are
explained in the individual
manuals. Traditionally, the value 0 signi-
fies successful completion
of the command.
SEE ALSO
apropos(1), man(1),
intro(2), intro(3), intro(4), intro(5),
intro(6), intro(7),
intro(8), intro(9)
etc.
Also useful are the three keyword search commands (which are essentially equivalent), apropos, man -k and whatis:
/home/jrperson> whatis ls
ls(1) - list directory contents
/home/jrperson> apropos directory
Tcl_TranslateFileName(3) - convert file name to native
form and replace tilde with home directory
VOP_ABORTOP(9)
- abort a directory operation
VOP_CREATE(9), VOP_MKNOD(9), VOP_MKDIR(9), VOP_SYMLINK(9)
- create a file, socket, fifo, device, directory or symlink
VOP_GETATTR(9), VOP_SETATTR(9) - get and set attributes
on a file or directory
VOP_READDIR(9)
- read contents of a directory
VOP_REMOVE(9), VOP_RMDIR(9) - remove a file or directory
basename(1), dirname(1) - return filename or
directory portion of pathname
cd(1)
- change working directory
cd(n)
- Change working directory
chdir(2), fchdir(2)
- change current working directory
chroot(2)
- change root directory
chroot(8)
- change root directory
dir(5), dirent(5)
- directory file format
getcwd(3), getwd(3)
- get working directory pathname
getdirentries(2)
- get directory entries in a filesystem independent format
ls(1)
- list directory contents
mkdir(2)
- make a directory file
mtree(8)
- map a directory hierarchy
opendir(3), readdir(3), telldir(3), seekdir(3), rewinddir(3),
closedir(3), dirfd(3) - directory operations
etc.
The number is parentheses after each manual entry is its section number. Sections are numbered from 1 to 9. Most useful commands are in section 1. If you need to look at another section, enter the section number followed by the topic (for example, man 2 mkdir).
/home/jrperson>apropos editor
ed(1) - text editor
ee(1)
- easy editor
ex(1), vi(1), view(1) - text editors
[non-text editor entries deleted]
joe(1)
- Joe's Own Editor
jove(1)
- an interactive display-oriented text editor
teachjove(1)
- learn how to use the JOVE editor
/home/jrperson>whatis emacs
xemacs(1)
- Emacs: The Next Generation
/home/jrperson>
The reason is that MS-DOS-derived operating systems (MS-DOS, OS/2, Windows) use both a carriage return (ASCII 13) and a line feed (ASCII 10) character at the end of a text line. Unix only uses line feeds.
Fear not, for you can use vi to remove those pesky carriage returns with its global search-and-replace feature.
This is a "living" document. Additions and updates will be made from
time to time, when the author
has a chance. Thanks for your patience.