This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
tutorials:node5.html [2011/04/30 19:59] – [4.7 Surf the Web] georg | tutorials:node5.html [2011/04/30 20:04] – [4.8.2 scp] georg | ||
---|---|---|---|
Line 149: | Line 149: | ||
===== 4.7 Surf the Web ===== | ===== 4.7 Surf the Web ===== | ||
- | A good web browser to use on a text-only command line is lynx. You can give it an URL to read on the command line, like this: '' | + | A good web browser to use on a text-only command line is lynx. You can give it an URL to read on the command line, like this: '' |
Unless the unix system where you have an account is very trusting, you probably cannot run a graphical web browser on it. Technically it can be done using the graphical system called X (which is common on unices), setting permissions with the xhost program, & setting your DISPLAY environment variable, but it usually is not allowed on a public access unix. | Unless the unix system where you have an account is very trusting, you probably cannot run a graphical web browser on it. Technically it can be done using the graphical system called X (which is common on unices), setting permissions with the xhost program, & setting your DISPLAY environment variable, but it usually is not allowed on a public access unix. | ||
Line 160: | Line 160: | ||
To transfer files between your home computer & a remote unix, use the program called ftp. Your home computer almost certainly has a copy, even if you run Microthought Winders at home. | To transfer files between your home computer & a remote unix, use the program called ftp. Your home computer almost certainly has a copy, even if you run Microthought Winders at home. | ||
- | To run ftp, first go to a command line. Then type < | + | To run ftp, first go to a command line. Then type '' |
The ftp client has a command line interface. Here are some of the commands it understands: | The ftp client has a command line interface. Here are some of the commands it understands: | ||
- | cd directory | + | '' |
- | Change directory on the remote FTP server. | + | |
- | dir | + | Change directory on the remote FTP server. |
- | Print a lsit of the files in the current directory on the remote FTP server. | + | |
- | ascii | + | '' |
- | Tell FTP to assume that files you transfer are text files. | + | |
- | binary | + | Print a lsit of the files in the current directory on the remote FTP server. |
- | Tell FTP to assume that files you trnasfer are binary files. | + | |
- | hash | + | '' |
- | Tell FTP to print an octothorpe character (#) for each block it sends or receives. It helps you see the progress of the file transfer. | + | |
- | put filename | + | Tell FTP to assume that files you transfer are text files. |
- | Upload a file. | + | |
- | get filename | + | '' |
- | Download a file. | + | |
+ | Tell FTP to assume that files you trnasfer are binary files. | ||
+ | |||
+ | '' | ||
+ | |||
+ | Tell FTP to print an octothorpe character (#) for each block it sends or receives. It helps you see the progress of the file transfer. | ||
+ | |||
+ | '' | ||
+ | |||
+ | Upload a file. | ||
+ | |||
+ | '' | ||
+ | |||
+ | Download a file. | ||
In general, use the cd command to enter the correct directory on the remote FTP server. Then set the correct mode (ascii or binary). Then use get to download a file or put to upload one. | In general, use the cd command to enter the correct directory on the remote FTP server. Then set the correct mode (ascii or binary). Then use get to download a file or put to upload one. | ||
- | The ftp client program supports many more commands. Use < | + | The ftp client program supports many more commands. Use "man ftp" for more information about FTP. |
In case you are interested: FTP refers to the File Transfer Protocol; it was one of the three requirements that created the Arpa Net which became the Internet. Ftp is also the name of the File Transfer Program which implements FTP. | In case you are interested: FTP refers to the File Transfer Protocol; it was one of the three requirements that created the Arpa Net which became the Internet. Ftp is also the name of the File Transfer Program which implements FTP. | ||
Line 192: | Line 205: | ||
Use scp like you would use cp, but it can copy from one computer to another. | Use scp like you would use cp, but it can copy from one computer to another. | ||
- | For example, if I want to copy myfile.cpio.bz2 on my computer into the tmp directory in my account on SDF, I would run this: < | + | For example, if I want to copy myfile.cpio.bz2 on my computer into the tmp directory in my account on SDF, I would run this: '' |
- | Run < | + | Run '' |
In my experience, scp takes longer than ftp to transfer files, & it gives up easily. If either computer or the network is slow, scp gives up quickly. So I prefer ftp. | In my experience, scp takes longer than ftp to transfer files, & it gives up easily. If either computer or the network is slow, scp gives up quickly. So I prefer ftp. |