The FTP Publishing Service

[Previous] [Next]

Now let's look at concepts and tasks associated with the FTP Publishing Service (the FTP service). We'll begin by examining the Default FTP Site included as an example when you install Windows 2000 Server. Then we'll look at common tasks such as creating new FTP sites and virtual directories. We can move fairly quickly here because these tasks are similar to ones you just learned for the WWW Publishing Service.

The Default FTP Site

Like the WWW service, installing the FTP Publishing Service on a Windows 2000 Server creates a new default site called the Default FTP Site. (The WWW service and the FTP Publishing Service are both installed by default whenever you install the core Internet Information Services on Windows 2000 Server, but you can remove either of them by using Add/Remove Programs in Control Panel.) Unlike the Default Web Site, with its sample pages and numerous directories, however, the Default FTP Site is completely empty. This is singularly uninteresting, so let's move on!

Other FTP Sites

As with the WWW service, you can create as many different FTP sites as you want using IIS 5, and you can host the content (pages, images, and other files) for these sites in either local directories or network shares. Each FTP site acts as a separate entity, or virtual server, and acts as if it were running on its own Windows 2000 Server using the full resources available to it on that server. To illustrate this, we'll create a new FTP site on the server ws1, place a test file in its home directory, and then download the test file from another machine on the network.

Using the FTP Site Creation Wizard

As with Web sites, you can specify FTP sites on an internetwork in a variety of ways, including using the site's IP address, NetBIOS name, or fully qualified DNS name. For the present example, use the extra IP address that was bound to the network card on the server ws1 in the previous section. You must also create a home directory for the new FTP site, so you'll create the directory C:\ftphome on the local server. Then you'll copy a bitmap file like \Winnt\Greenstone.bmp to the C:\ftphome directory so you'll have something to download from the client. Follow these steps to create the new FTP site:

  1. Start the Internet Information Services console on server ws1 (or start it on a different server or workstation and connect to server ws1 by clicking the Action button on the toolbar and choosing Connect from the drop-down menu) and select the server's name in the console tree.
  2. Click Action on the toolbar, point to New, and choose FTP Site from the drop-down menu (or right-click the ws1 node in the console, point to New, and choose FTP Site from the shortcut menu). This starts the FTP Site Creation Wizard. Click Next.
  3. Type Scribes FTP Site as the name for the site. This name is displayed in the Internet Information Services console window and identifies the new site for the administrator. Click Next.
  4. Specify your second IP address as the one to be mapped to the site, leaving the port number at its default setting. Click Next.
  5. Specify the path to the home directory for the new FTP site as C:\ftphome. (Using the Browse button is easiest.) Note that the home directory for your site can be a local directory or a network share. Click Next.
  6. Make sure that both Read permissions and Write permissions are selected. This will allow you to both download files from and upload files to your new FTP site.
  7. Click Next and then click Finish to complete the Wizard. The new Scribes FTP Site should appear as a node under server ws1 in the Internet Information Services console window (Figure 27-12). Note that the Greenstone.bmp file within the home directory doesn't appear in the right pane of the console window. This is different from Web sites, where files in home directories and virtual directories are displayed in the console window.
  8. click to view at full size.

    Figure 27-12. The new Scribes FTP Site shown in the Internet Information Services console window.

Testing the New FTP Site

To test the new FTP site, go to a different machine on the network, start Internet Explorer 5, and open the URL, which specifies the new FTP site using its associated IP address. The file Greenstone.bmp should be displayed in the browser window, along with the IP address you're connecting to and the user name Anonymous (Figure 27-13).

click to view at full size.

Figure 27-13. Connecting to the new Scribes FTP Site using Internet Explorer 5.

Once you've connected to the FTP site, you can perform various actions in Internet Explorer, including the following:

  • Download the file to your machine by right-clicking its icon, choosing Copy To Folder, and specifying the destination folder on your machine (or anywhere else accessible on the network).
  • Drag and drop files from My Computer on your local machine into the browser window to upload them to the FTP site.
  • Right-click the file icon and choose Properties to display the type, location, size, and date modified of the original copy of the file on the FTP site.
  • Log on to the FTP site as a different user (if access is controlled by user names) by choosing the Login As command from the browser's File menu.
  • View the FTP welcome message (if there is one) using the Help menu.

Now isn't that more fun than using the old text-based FTP command from the command prompt?

Virtual Directories

You can create virtual directories for FTP sites the same as you can for Web sites. Let's look at this briefly now.

Using the Virtual Directory Creation Wizard

You've already seen the Virtual Directory Creation Wizard. It doesn't matter whether you create the virtual directory within a Web site or within an FTP site—the same wizard creates them. But just for variety, since you created a remote virtual directory for the Scribes Ltd. Web site last time, this time, create a local virtual directory for the Scribes FTP Site. (The following steps are compressed since you're already familiar with the wizard.)

  1. Create the directory C:\uploads on the server ws1. This directory will be used as an FTP drop box—a directory where users can upload files but can't view the contents of the directory or download files from it.
  2. Right-click the Scribes FTP Site node in the console tree of Internet Information Services, point to New, and choose Virtual Directory from the shortcut menu. Click Next.
  3. Type drop as the alias for the virtual directory. Click Next.
  4. Specify the path C:\uploads for the location of the content directory that maps to the virtual directory being created. Click Next.
  5. Change the access permissions to enable write access and disable read access on the directory.
  6. Click Next and then click Finish to complete the wizard.

The new local virtual directory /drop is now visible as the node underneath the Scribes FTP Site node in the console tree (Figure 27-14). Note that the icon used to represent FTP virtual directories is different from the ones used to represent Web virtual directories.

Testing the New Virtual Directory

Try accessing the new virtual directory from a remote machine by opening the URL virtual directory on the Scribes FTP Site using Internet Explorer. A message should appear in a dialog box saying, "An error occurred opening that folder on the FTP Server. Make sure you have permission to access that folder." Click OK to close the error message.

click to view at full size.

Figure 27-14. The /drop virtual directory within the Scribes FTP Site.

Now try dragging a file from My Computer into the browser window. Verify on the server ws1 that the file was indeed uploaded to the \uploads directory on the server. Now try refreshing the browser window. The same error message will appear as before. Click OK to close the error message, and the browser window—which is still open to the /drop virtual directory—should appear empty. This verifies that anonymous users can upload files to the virtual directory but can't view or download files from it.

Microsoft Windows 2000 Server Administrator's Companion, Vol. 1
Microsoft Windows 2000 Server Administrators Companion (IT-Administrators Companion)
ISBN: 1572318198
EAN: 2147483647
Year: 2000
Pages: 366 © 2008-2017.
If you may any questions please contact us: