[an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] Skip to the content of the web site.

Copying Files To And From Unix

Contents Previous Topic Next Topic

All testing for ECE 250 will be performed under Unix, and thus, even if you develop your code in Windows using Dev-C++, you must test your code on Unix.

The first step is to transfer the files to your Unix account. For this, you have two options:

If you are copying your files from Windows to Unix, you should read the next topic (dos2unix) to correctly deal with some of the differences between the way Windows and Unix store text files.

Map Network Drive (P:)

This only works, to the best of my knowledge, from a University campus computer. If you determine that it can be used to connect from home, please let the author know.

In Windows Explorer, select Tools → Map Network Drive... . This will bring up a dialog which prompts you for a drive and a folder. For the drive, select P: (having a common drive makes life easier for all persons concerned) and under the folder, enter \\eceserv\homes\. Make sure the Reconnect at logon is checked (it should, by default, be checked), and click Finish.

Now, you will be able to copy files to and from your Unix account by copying to and from P:.

SFTP

To use sftp, or secure file-transfer protocol from, for example, Nexus, you can access sftp through the Start menu as shown in Figure 1.

Figure 1. Launching sftp on Nexus.

If you have installed sftp at home, you will also find an appropriate entry under your Start menu under SSH Secure Shell.

Once you launch sftp, you may use the Quick Connect button to make a connection by using ecelinux.uwaterloo.ca as the Host Name and your UW User ID as the User Name. Click Connect and you will be prompted for your password.

Once you have connected, you will be prompted to give the current Host-Name—User-Name pair a Profile name which you will be able to access under Profiles (as opposed to always using Quick Connect). Pick a name like ECE Unix ftp.

Once a connection has been made, you will see two file systems: your local file system on the left panel, and the remote (Unix) file system on the right panel, as is shown in Figure 2.

Figure 2. A connection to ecelinux.

With the connection, you can now move files using by copying them to the right-hand file system. As necessary, you may navigate the right-hand file system like any Windows file system. You may copy files the files by dragging them between the two panels, or you can also drag files between the Desktop or Windows Explorer to the right-hand panel.

To practice, you can down-load the two files SingleList.h and SingleNode.h. Both of these files were created using Notepad in Windows XP. Copy these onto your desktop and transfer them to your account on ecelinux as described above. Subsequent topics will assume these files exist, and the next (dos2unix) discusses how to modify the format of the text file.

Summary

This topic described how to copy files from another computer onto your Unix account on ecelinux. The next step will be to change the format of the text files into one which Unix expects (thus, dealing with the differences between Windows and Unix).

Contents Previous Topic Next Topic

Copyright ©2005-2012 by Douglas Wilhelm Harder. All rights reserved.

[an error occurred while processing this directive]