Web Programming Essentials:

Slides:



Advertisements
Similar presentations
LIS651 lecture 5 direct use of wotan Thomas Krichel
Advertisements

Learning Unix/Linux Bioinformatics Orientation 2008 Eric Bishop.
1 Introduction to UNIX Ke Liu
ECT 250: Survey of e-commerce technology Publishing pages on a Unix system.
Linux+ Guide to Linux Certification, Second Edition
UNIX Chapter 00 A “ Quick Start ” into UNIX Operating System Mr. Mohammad Smirat.
UNIX Files and Security Software Tools. Slide 2 File Systems l What is a file system? A means of organizing information on the computer. A file system.
A Mini UNIX Tutorial. What’s UNIX?  An operating system run on many servers/workstations  Invented by AT&T Bell Labs in late 60’s  Currently there.
L INUX C OMMAND L INE I NTERFACE G UNAANBAN.G
Using Macs and Unix Nancy Griffeth January 6, 2014 Funding for this workshop was provided by the program “Computational Modeling and Analysis of Complex.
Telnet/SSH: Connecting to Hosts Internet Technology1.
Overview of Linux CS3530 Spring 2014 Dr. José M. Garrido Department of Computer Science.
Help session: Unix basics Keith 9/9/2011. Login in Unix lab  User name: ug0xx Password: ece321 (initial)  The password will not be displayed on the.
Chapter 9 Part II Linux Command Line Access to Linux Authenticated login using a Linux account is required to access a Linux system. The Linux prompt will.
Linux Directory Navigation. File & Directory Commands This is a minimal list of Unix commands that you must know for file management: ls (list) mkdir.
Essential Unix at ACEnet Joey Bernard, Computational Research Consultant.
Unix Basics Chapter 4.
Linux+ Guide to Linux Certification, Second Edition
PROGRAMMING PROJECT POLICIES AND UNIX INTRO Sal LaMarca CSCI 1302, Fall 2009.
ACCESS IC LAB Graduate Institute of Electronics Engineering, NTU Usage of Workstation Lecturer: Yu-Hao( 陳郁豪 ) Date:
UNIX Workshop Freshmen Orientation UNIX workshop Before we begin…  Does everybody have a computer?  Does everybody have your account slips?
1 Operating Systems and Using Linux Topics What is an Operating System? Linux Overview Frequently Used Linux Commands Reading None.
1May 16, 2005 Week 2 Lab Agenda Command Line FTP Commands Review More UNIX commands to learn File name expansion - * Introduction of vi.
E X C E E D I N G E X P E C T A T I O N S Basic LINUX Linux System Administration Dr. Hoganson Kennesaw State University Operating Systems Directory structure:
Introduction to Programming Using C An Introduction to Operating Systems.
Λειτουργικά Συστήματα – Lab2 Γιάννης Πετράκης. Directory Navigation and Control  The Unix file system is set up like a tree branching out from the root.
Linux Commands C151 Multi-User Operating Systems.
Unix Servers Used in This Class  Two Unix servers set up in CS department will be used for some programming projects  Machine name: eustis.eecs.ucf.edu.
1 Introduction to Unix. 2 What is UNIX?  UNIX is an Operating System (OS).  An operating system is a control program that helps the user communicate.
 Last lesson, the Windows Operating System was discussed along with the Windows command shell  Unix is a computer operating system, that similarly manages.
1 CS3695 – Network Vulnerability Assessment & Risk Mitigation – Introduction to Unix & Linux.
Learning basic Unix command It 325 operating system.
CMSC 104, Version 8/061L03OperatingSystems.ppt Operating Systems and Using Linux Topics What is an Operating System? Linux Overview Frequently Used Linux.
CS 120 Extra: The CS1 Server Tarik Booker CS 120.
CMSC 104, Version 9/011 Operating Systems and Using Linux Topics What is an Operating System? Linux Overview Frequently Used Linux Commands Reading None.
UNIX Basics Matt Hayward October 18, 2016 LS560 – Information Technology for information professionals.
Overview of Linux Fall 2016 Dr. Donghyun Kim
UNIX To do work for the class, you will be using the Unix operating system. Once connected to the system, you will be presented with a login screen. Once.
Tutorial of Unix Command & shell scriptS 5027
CS1010: Intro Workshop.
Getting started with CentOS Linux
Commands Basic syntax of shell commands UNIX or shell commands have a basic structure command -options target command comes first (such as cd or ls) any.
Web Programming Essentials:
Andy Wang Object Oriented Programming in C++ COP 3330
FTP Lecture supp.
Lecture 2 Working with Files and Directories
Some Linux Commands.
C151 Multi-User Operating Systems
Introduction to Linux Dr Karina Kubiak - Ossowska
Part 3 – Remote Connection, File Transfer, Remote Environments
UNIX Basics Internet Technology.
Tutorial of Unix Command & shell scriptS 5027
Tutorial of Unix Command & shell scriptS 5027
Operating Systems and Using Linux
Telnet/SSH Connecting to Hosts Internet Technology.
Operating Systems and Using Linux
Operating Systems and Using Linux
Operating Systems and Using Linux
Tutorial of Unix Command & shell scriptS 5027
Operating Systems and Using Linux
Getting started with CentOS Linux
Andy Wang Object Oriented Programming in C++ COP 3330
UNIX/LINUX Commands Using BASH Copyright © 2017 – Curt Hill.
Operating Systems and Using Linux
Operating Systems and Using Linux
Operating Systems and Using Linux
Module 6 Working with Files and Directories
Lab 2: Terminal Basics.
January 26th, 2004 Class Meeting 2
Presentation transcript:

Web Programming Essentials: Connecting to Server Transferring Files Unix Basics Web Programming

Publishing Web Content 11/30/2018 Publishing Web Content Edit Web Server PC Edit Publish Display Display upload to Web Server Display Publish WCC Mode #1 WCC Mode #2 Web Content Creation Mode #1 (easy) Create HTML & CGI files on the PC using Notepad. Upload the files to the Web server using SFTP. Secure File Transfer Protocol (SFTP)  Method for transferring data on the Internet Web Content Creation Mode #2 (preferred) Login to the Web server using SSH. Secure SHell (SSH)  Method for connecting to computers on the Internet Create HTML & CGI files using a Unix editor (e.g., pico, vi) Web Programming

Connecting to Server Secure SHell (SSH) SSH Client Software Method for connecting to computers on the Internet Like Window’s Remote Desktop (without the GUI) SSH Client Software SSH Client PuTTY Web Programming

SSH Client: PuTTY PuTTY configuration Download and double click PuTTY Type in the Host Name (e.g. widit.knu.ac.kr) and click Open Login Web Programming

SSH Client: PuTTY PuTTY configuration (continued) Right-click the top blue bar of the PuTTY window Select “Change Settings” Select “Translation” under Window Category Set Character set translation to “UTF-8” Web Programming

SSH Client: PuTTY PuTTY configuration (continued) Select “Appearance” under Window Category Set Font settings to desired font if needed Select “Colors” under Window Category Set Default Foreground and Default Background to desired colors if needed Click Apply to apply the current settings. Web Programming

SSH Client: PuTTY PuTTY configuration (continued) Click the “Session” category Type in a name for the current configuration (e.g., widit) in the “Saved Sessions” box Click Save to save the current settings Next time, you can right-Click the top blue bar and select Saved Sessions to choose the appropriate session (e.g. widit) Web Programming

Transferring Files Secure File Transfer Protocol (SFTP) SFTP Clients Method for transferring data on the Internet SFTP Clients GUI Interactive file transfer programs SSH Secure File Transfer (includes SSH client: SSH Secure Shell) Web Programming

SFTP Client: SSH Secure File Transfer SSH Secure File Transfer (includes SSH client) Click File, and select Connect Type in the Remote Host Name (e.g. widit.knu.ac.kr), User Name, and click Connect Type in Password Web Programming

SFTP Client: SSH SFTP SSH Secure File Transfer (continued) Click Profiles, and select Add Profile Type in the profile name (e.g. widit-ftp) and click Add to Profiles Next time, Click Profiles and select the saved profile name to connect Web Programming

Unix: OS for Internet Servers Web Programming

Unix Basics Unix is an Operating System 11/30/2018 Unix Basics Unix is an Operating System An operating system (OS) is software that enable the computer to function Developed in 1960’s at Bell Laboratories to run multiple concurrent processes for many users Ideal OS for Web servers Unix Differences (from Windows) No GUI No “Undo” feature It is CASE SENSITIVE Unix Fundamentals Know the difference between a directory and a file Know what directory you are in When in directory doubt, type ‘pwd‘ Web Programming

Unix: File System ~ Home directory shorthand 11/30/2018 Unix: File System File and directory paths use the forward slash “/” / "root" directory /home/kiyang subdirectory “home” → subdirectory “kiyang” root ~ Home directory shorthand ~kiyang = /home/kiyang ~topzoo = /home/stud/topzoo ~/ = user’s home directory home usr kiyang stud topzoo freeghsd public_html public_html WP WP /home/stud/freeghsd/public_html/WP/ Web Programming

Unix Basics: Command Syntax 11/30/2018 Unix Basics: Command Syntax Unix command syntax: command [space] option switches [space] arguments Options can be combined To get help on a command Type ‘man command’ e.g., man ls man pages can be difficult to read (example) ls -al /home/kiyang/public_html Web Programming

Unix Basics: Basic Command 11/30/2018 Unix Basics: Basic Command ls filename Lists files in a directory Default argument = current directory Common options: -a → list all files including dot files -l → display detailed info pwd  Lists the current working directory cd dir_name  Move to the directory named dir_name cp file1 file2  Copy file1 to file2 mv file1 file2  Rename file1 to file2 rm file1  delete file1 cat filename  display the content of filename more filename  display the content of filename one screen at a time less filename  same as more plus scrolling backwards Web Programming

Unix Basics: Working with Directories 11/30/2018 Unix Basics: Working with Directories Directories are special types of files Unix file system is hierarchical use "cd" and "ls" to get around ~/  your home directory ~/public_html = /home/kiyang/public_html drwxr-xr-x 2 kiyang kiyang 4096 2011-03-16 11:45 TT -rw------- 1 kiyang kiyang 92 2010-12-14 19:17 hw1.txt "cd" to change directory cd  change to home directory cd ..  change to parent directory "pwd" to print current working directory "mkdir dir_name" to create a directory named dir_name "rmdir dir_name" to remove the directory named dir_name "cd" alone brings you home (RUBY slippers!) "cd ~" and "cd ~username" brings you home (or to "username's" home) "cd.." brings you down a directory Web Programming

Unix Basics: Working with Files 11/30/2018 Unix Basics: Working with Files Files have owners and permissions Owner = person who created the file Permission read, write, execute by owner, group, everyone Cannot "more" all files read permission needed Special files Dot files: ls –a to list Symbolic links: ls –I to list the original file "ls" to list "cp" to copy "mv" to rename. "rm" to delete "more" (less, cat) to view the content Try: ls -l /etc/motd Try "cp" to copy: cp /etc/motd ~/motd.my.copy Try "mv" to rename: mv motd.my.copy blah Try "rm" to delete (forever): rm blah Directories are special types of files mkdir blahdir ("rmdir" to remove) cp /etc/motd ~/blahdir ("ls blahdir" to view) Web Programming

Unix Permissions rwx r-x r-- 111 101 100 7 5 4 file type permission 11/30/2018 Unix Permissions file type permission owner group size last modified time file name owner group world 000 = 0 = --- 001 = 1 = --x 010 = 2 = -w- 011 = 3 = -wx 100 = 4 = r-- 101 = 5 = r-x 110 = 6 = rw- 111 = 7 = rwx rwx r-x r-- 1=Allowed 0=Not Allowed 111 101 100 In decimal number 7 5 4 Web Programming

Changing Unix File Permissions 11/30/2018 Changing Unix File Permissions Use the chmod command Syntax: chmod permissions filename e.g., chmod 644 hw1.txt This would change the permissions to? (Hint: 6 = 110, 4 = 100 in binary) Important in web authoring Web pages Must be world readable → chmod 644 index.htm Server-side Programs Must be executable → chmod 755 roster.cgi User group depending on web server configuration Directories Must be world executable → chmod 711 public_html Web Programming

UNIX Shortcuts Up arrow Tab key after partial filename Alias 11/30/2018 UNIX Shortcuts Up arrow Cycles through previous commands Tab key after partial filename Completes the filename if enough has been typed (like auto-complete) Alias Designates a shorter command to be used in place of a longer one. Stored in ~/.aliases Syntax: alias short_cmd=‘long command’ e.g., alias dir='ls -al |more' alias cdhwp='cd ~/public_html/WP‘ alias chmo='chmod 755 ~/public_html/WP/*' Web Programming

UNIX Editor: Pico pico file1  edit file1 11/30/2018 UNIX Editor: Pico pico file1  edit file1 Ctrl-o  save the current file Ctrl-x  save & exit Ctrl-e  delete to the end of current line Ctrl-k  delete the current line Ctrl-u  restore the last line that was deleted Ctrl-w  find/search Going to a specific line number Ctrl-w  Ctrl-t  line number Web Programming