What is Telnet?
Connecting
to Youthofamerica.Net through Telnet.
Connecting to the
server.
Basic Telnet
commands for beginners.
Using PICO (editor
client) in Telnet.
Talking to other users
on Telnet.
Testing your CGI scripts
through Telnet.
/usr/bin/dos2unix
/usr/bin/date
/usr/bin/egrep
/usr/bin/touch
/usr/bin/kill
/usr/bin/ln
/usr/bin/zip
/usr/bin/unzip
/usr/sbin/htpasswd
/usr/bin/whois
/usr/sbin/nslookup
/usr/bin/perl
/usr/bin/ls
/usr/bin/pico
/usr/bin/vi
/usr/local/bin/emacs
/usr/bin/pine
/usr/bin/cat
/usr/bin/tac
/usr/local/bin/less
/usr/bin/clear
/usr/bin/grep
/usr/local/bin/joe
/usr/sbin/sendmail
/usr/bin/chmod
/usr/bin/man
/usr/bin/mv
/usr/bin/cp
/usr/bin/find
/usr/bin/rm
/usr/bin/rmdir
/usr/bin/tar
/usr/bin/gunzip
/usr/bin/mkdir
/usr/bin/awk
/usr/bin/dirname
/usr/bin/du
/usr/bin/echo
/usr/bin/edit
/usr/bin/hash
/usr/bin/head
/usr/bin/hostname
/usr/bin/id
/usr/bin/jobs
/usr/bin/last
/usr/bin/more
/usr/bin/mysql
/usr/bin/mysql2mysql
/usr/bin/mysqlaccess
/usr/bin/mysqlbug
/usr/bin/mysqladmin
/usr/bin/mysqldump
/usr/bin/mysqlshow
/usr/bin/pagesize
/usr/bin/printf
/usr/local/bin/emacsclient
/usr/bin/gzip
/usr/local/bin/pgp
/usr/bin/sort
/usr/local/bin/emacs-20.3
/usr/bin/pwd
/usr/bin/spell
/usr/bin/tail
/usr/bin/time
/usr/bin/nice
/usr/bin/renice
/usr/bin/compress
/usr/bin/uncompress
/usr/bin/zcat
/usr/local/bin/perldoc
/usr/ucb/whereis
/usr/ccs/bin/help
/usr/bin/crontab
What is Telnet?
Telnet is a protocol most often used to connect to a UNIX system because of its command
line interface. Telnet is a very useful protocol when properly used but lacks graphical
user interface.
Telnet has a number of advantages over FTP including the avility to chat with users,
pinpoint problems in CGI scripts, delete directories if it is not empty, and editing of
files without downloading them from the server.
Telnet clients we recommend for use.
We recommend a program called CRT Telnet by VanDyke
Technologies. You can download CRT Telnet from our FTP site or from VanDyke
Technologies. Below is a FTP download site :
Windows 95 comes with a telnet program, Windows Telnet. This program can be accessed by
pressing the Start button on the menu bar of the desktop, then Run... Now type in
"telnet" in the textbox and Windows Telnet should appear as a plain white
window.
Connecting to the Youthofamerica.Net
server.
Connect via telnet is simple. Use your domain name or your IP address as the hostname. In
the telnet window of CRT or Windows telnet, you will then be prompted for your login and
password. Once you enter this information and the server verifies this information, you
will be logged into the root (/home/your_login) of your acco unt.
Basic Telnet commands for beginners.
Telnet comes with a large number of commands that cannot all be discussed in this brief
tutorial. Below we attempt to address basic telnet commands.
Command
|
What this command does....
|
| ls |
This command will list all of the
files and directories within the current directory.
|
| cd <directory> |
This command will change your
current directory to the directroy you specify. An example would be that "cd
public_html" would take you into your public_html directory.
|
| mv <filename>
<location> |
This command will move a file
from its current location within the current directory to the directory you specify. For
example, lets say you are in your public_html directory and you want to move the file
"links.cgi" into your "cgi-local" directory. At the prompt type
"mv links.cgi cgi-local.
|
| chmod XXX <filename or
directory> |
This command will set the
permissions on a file or directory to whatever you specify. The "XXX" would be
replaced by actual numbers, such as 644. For example, if we wanted to set the permissions
on our links.cgi file in our cgi-local directory, we would first go into that directory
then type "chmod 755 links.cgi" at the prompt.
|
| rm <filename or directory> |
This command will delete the
filename or directory you specify in the current directory. If we wanted to remove the
directory named "user", we would type "rm user" at the prompt.
|
| man <command> |
This is one of the most helpful
commands for new users. It allows you to see all of the different options for a particular
command. For example, if were were to type "man ls", we would then see all of
the different options available for the list (ls) com mand.
|
| traceroute <domain> |
This command will perform a
traceroute on a particular virtual domain to see how many hops it takes to get from your
location to the domain specified. An example would be "traceroute yahoo.com",
which would show us how long it takes for packets to get to yahoo.com and how they get
there.
|
| whois <domain> |
This command will display the
current InterNIC record including administrative, technical, and billing contact for a
particular domain if it is already owned.
|
Using PICO in Telnet.
Pico is a very basic editor used it Telnet. Although basic, it is very useful in that you
can edit your HTML files, CGI scripts, and any other ASCII files without downloading them
from the server, making the changes, then uploading them once again.
Pico is used in the following manner: type in "pico <filename>" at the
prompt. For example, lets say we wanted to edit a line in our links.cgi file. We would
need to get into the directory where that file resides and type in "pico
links.cgi" at the prompt. Now a screen would appear with our links.cgi file.
Once you are finished making the changes to a file, press <Ctrl><X> at the
same time. Pico will ask you if you wish to "Save modified buffer" (in plain
English, save the changes). Type "y" if you want the changes saved or
"n" if you want the c hanges ignored. If you typed in "y" it will then
ask you "File name to write:", which means the file name to save the changes to;
the default value is the file we originally edited (in this case, links.cgi). So you can
save the changed file to a different name.
For more information on Pico, visit the following URL:
http://ellars.com/whatever/pico.shtml
Talking to other users on Telnet.
To talk to any user on the system, just type "talk login" where login is the
acutal login of the user you want to talk to. If the user accepts you chat request, a
divided screen will appear and you two will be able to chat.
Testing your CGI scripts through Telnet.
One of the most powerful features of Telnet is that you can pinpoint problems in your CGI
scripts. Unlike the HTTPD protocol which displays the infamous "Internal Server
Error" message, telnet will tell you what is the real problem!
To test your script, you must execute it on the server which means your permissions must
allow you (the user) to execute the script. Otherwise, a permission denied message will
occur.
Go into the directory where the script you wish to test resides. Lets say that the CGI
script named "links.cgi" is giving us problems! To find the problem, type in
"./links.cgi". The server will then execute the script and tell you what, if any
problems occur. The syntax for this command is "./script_name".
After you have found the problem, you can edit your CGI script using PICO in Telnet, then
test it again. Eventually you will get your script working, and much faster than trying to
pinpoint the problem yourself!
Back to the top.
Back to the top.
What is the function of the "cgi-local" directory?
This directory allows you to execute a CGI script written in Perl, Unix Shell, or C.
Perl and shell programs are self-compiling and can be utilized immediately after transfer
to this directory/folder. C programs must first be compiled by YouthofAmerica.Net before
they will function. Remember, you can always run your perl scripts anywhere within your
account except for a directory named "cgi-bin" because this directory is
reserved for the server. In other words, Perl scripts are not restricted to your cgi-local
directory.
Back to the top.
How do I create sub-directories?
We recommend using the "make directory" feature, (MkDir
button in WS_FTP) in our recommended FTP client software, WS_FTP.
In Telnet, type in "mkdir directory_name" at the prompt and a directory will be
created.
Back to the top.
How can I simulate sub-websites within my
account?
To simulate a sub-web site
(www.yourdomain.com/anothersite), you have to create a new directory (or folder to MAC
users) and then upload the main loading page (index.html). You can setup as many sub-web
sites as you wish. YouthofAmerica.Net only charges additional fees if you go over the
allotted disk space limit of 350MB.
Back to the top.
When will I be able to reach my site using the domain
name?
Once the InterNIC announces that your domain name has been registered
(or transferred, if applicable), it usually takes about 72-hours before it is active. All
internet providers must update their records (DNS tables) to reflect new site locations.
This is called propagation.
Back to the top.
How can I monitor web usage statistics?
A program called MK-Stats is installed for each new account. This is
probably the best statistical software for websites currently available. MK-Stats can be
found in your /stats directory.
All accounts are provided with MK-Stats as a standard feature with no additional charge.
Back to the top.
Can custom reports be generated from raw log files?
The MK-Stats website statistics program is a system-wide program which
cannot be custom configured for one customer. However, feel free to use any web statistics
program you would like.
Back to the top.
C
Back to the top. |