a crash course in njit’s afs afs quick tips - kashif qazi
TRANSCRIPT
A CRASH COURSE IN NJIT’S AFS
AFS Quick Tips
- Kashif Qazi
What is AFS
AFS stands for Andrew File SystemA way to have storage spaceDistributed file system lets you access your
data virtually anywhere, anytime
Distributed Computing
Defn: Users won’t know that the process or data is in some
other computer in the network
Advantages Availability Efficiency
What is AFS for ME in NJIT?
A way to have storage space on the college network
A place to store Web pages Course Material Research Material Course Assignments
Client/Server
• Server provides data and services to the client
• Client is accessed by the user and gets services and data from the server
AFS
File Server File Server File Server
Authentication Server
Client
(username, password)
Tokens
E.g. afsconnect1.njit.edu
Laptop
Remotely
Where is AFS
File Servers: In NJIT
Clients: afsconnect1.njit.edu and afsconnect2.njit.edu Any NJIT maintained MS Windows Workstation
(Library, Student Mall PC Labs, GITC 2302) Your own PC with OpenAFS Client installed
Each student has 125 MB of AFS disk space
Services Available by NJIT on AFS
Web Services (Apache Tomcat)Variety of open source and commercial
software (compilers like javac and gcc)MySQL Database
How to Use AFS
Three ways of accessing your 125 MB AFS space Secure Shell (Remote Login) OpenAFS Client for Windows, Mac, Linux, Solaris One of the AFS client machines in the labs
You need your UCID and AFS password
How to Use AFS – Secure Shell
Download and install the SSH Secure Shell from http://ist.njit.edu
If downloading remotely, you need VPNRun SSHClick ‘Quick Connect
How to Use AFS – Secure Shell
Enter afsconnect1.njit.edu or afsconnect2.njit.edu in ‘Host Name’
Enter UCID in User NameClick ‘Connect’
Step 1Step 2
How to Use AFS – Secure Shell
Enter your AFS PasswordClick ‘OK’
Step 3
How to Use AFS – Secure Shell
You are connected!!
How to Use AFS – Secure Shell
Unix commands work in this environmentType in ls and press return to see the list of
files and directories in your root
How to Use AFS – Secure Shell
Unix commands work in this environmentType in cd directory_name to go to particular
directory
How to Use AFS – OpenAFS Client
Install and setup OpenAFS Client as per instructions at http://web.njit.edu/all_topics/AFS/windows.client/
After this, you should have a drive in ‘My Computer’ called H:
This is your AFS ‘drive’ which means your AFS space is directly accessible from ‘My Computer’
How to Setup Web Page
Your web-page’s address is: http://web.njit.edu/~ucid
The index.html file is located in public_html directory under root in your AFS space
For SSH you can type in cd public_html from root
For OpenAFS you can double click H: in ‘My Computer’ and then double click public_html directory
Modifying index.html modifies the web-page at the above address
How to Setup Web Page
You can now build your website in the public_html directory
Additionally NJIT’s AFS also provides for an Apache TomCat Web Server
You can also install CMSs like Drupal or CodeIgnitor
Backup
Backup is taken every day
Last backup of home directory will be in the home directory itself
Older backups up to one year available from tape
Backups of research directories are backed up every week in a tape and kept for 1 year!
Some Help with Unix Commands
cd <path/directory_name> : changed current directory to path/directory. E.g. cd public_html
ls : Lists all files and directories in current directory
cp <path1/file> <path2/file> : copies file from path1 to path2
cat file_name : displays the file on the screen. Useful for reading small files
Some Help with Unix Commands
rm file_name : removes the filemkdir dir_name : creates a new directoryrmdir dir_name : removes directoryfs sa ~/<path> ucid rl : gives ucid access to
path directory on your AFS
Killing a process?
If an application hangs?
Find the process id ps –u <username> | grep <processname>
Kill the process kill -9 <processid>
Moving Files from your Computer
SSH Includes SSH Secure File Transfer Run and connect same way as Secure Shell Client Drag and drop
OpenAFS Client H: is like any other drive Copy-Paste as usual
Connecting via Linux - I
Open up a terminal window in LinuxExecute the command
ssh –l ucid afsX.njit.edu
The first time you will see: The authenticity of host afsX.njit.edu' can't be
established.RSA key fingerprint is a long string of charactersAre you sure you want to continue connecting (yes/no)?
Type in ‘yes’ and press return
Type in password and press return
Connecting via Linux - II
Install OpenAFS Client apt-get install openafs-client
Set “CELL” to cad.njit.eduOther values use defaultklog ucidcd /afs/cad.njit.edu/u/k/m/kmq2
Further References
For further information on NJIT’s AFS, visit http://ist.njit.edu http://web.njit.edu http://web.njit.edu/all_topics/one.stop/
The last link is useful to check your AFS Quota, Usage, Reset Password, etc.