Return to: U of M Home

Gold University of Minnesota M. Skip to main content.University of Minnesota. Home page.
 
Academics.

Mechanical Engineering Home >Info: Useful Links > ProE > Unix Hints

The Silicon Graphics (SGIs) in ME 308 use the UNIX operating system. On top of this, to make them more user-friendly, they use the X Windowing system, commonly called X Windows or just X. X works somewhat like the Mac OS or Microsoft Windows, so you'll be able to pick it up fairly quickly. If you've ever used MS-DOS, you'll learn UNIX fairly easily.

When you first log into an SGI, you'll see a screen with several things on it:

  • Toolchest

    The toolchest, in the upper left corner. This is where you access most of the shortcuts on the SGI. From here you can open windows, reconfigure the look of your system, and many more things. Don't worry that you don't have an Apps item - we'll show you how to customize your menu later so that you can set this up too.

  • Winterm

    This is what you get when you select the Desktop : Unix Shell option. It is basically like the MS-DOS prompt option in Windows. It allows you to see your files, and interact with the computer in a command-line format. This means that the computer executes whatever commands you type into this window. Most accounts are initialized to automatically bring up two of these windows.

Getting Help

To get a good overview of the windowing system, select Help : Desktop Help. Double-click on the Basic System Setup option under the Getting Started index item. Run through this tutorial until you feel comfortable with the system.

Using Unix

Now, you're ready for some Unix Commands. There are many good tutorials out there:

http://hep.uchicago.edu/%7Ecovault/Unix_help/unix_help.html

http://www.eecs.nwu.edu/Unixhelp/TOP_.html

These are just two that looked promising. Try them, and send feedback if you don't like them. To find your own, just do a search (you can use the 'net search' button on the Netscape browser) for 'unix tutorial.'

Commands That You Will find Useful:
  • Purge:

    Pro/Engineer keeps old versions of your part. For instance, if I create a part called widget, it will be saved as widget.prt.1 when I first save it. If I then change the part and save it, it will be saved as widget.prt.2. As you can see, this quickly eats up disk space. With a limit of 10 megabytes and part files that (if you're really doing something complicated) can pass 2 megabytes, space soon runs out. Pro/Engineer has included a feature to get rid of the old versions of a part, and only save the version with the highest number. To execute the command, type:

    purge
    from the Unix prompt. This will remove all the old versions of your parts, assemblies, and drawings.


    Note: make sure you don't want these files before you do this!
  • rm:

    rm stands for remove. It is very powerful, and very dangerous. Be very careful using this command, as you could conceivably lose all your files.

    To use rm, type

    rm file
    . rm will remove the file you want to delete. If you type part of the file, then follow it with a star (*), it will match everything that begins with what you typed, and remove it. For instance, in order to remove all of your plot files (once they are printed, it's best to remove them, as they take up a lot of space and aren't that hard to redo from Pro/E):
    rm -i *.plt
    This will remove everything in the current directory that ends in .plt. Use the -i option whenever you use a star in the file argument. This forces rm to operate interactively, which means that it asks for confirmation before it removes the file. This is very good, because it forces you to look at each file you want to delete before you delete it.


  • ls:

    ls simply lists all the files in your directory. ls -alF lists the files in a format similar to MS-DOS' DIR command. In addition to this, the -alF option shows all the 'hidden' files that begin with a dot (.). You may need to see these at some point in your career, but for now just ignore them, or use ls -lF.

  • cd:

    cd stands for change directory. It is almost identical to the MS-DOS CD command. Some examples are:

    • cd temp -change to the /temp directory (note that UNIX uses forward slashes, not backslashes.)
    • cd .. -change to the parent directory (move 'up' one directory.)
    • cd -change to your home directory.
    • cd temp/usr/foo/bar/ -change to the temp/usr/foo/bar/ directory
  • mkdir:

    Makes a directory, under the directory you're currently in, with the name you specify. For instance, if I wanted to create a directory called 'proe' then go into that directory and see what was there, I would do:

          mkdir proe
          cd proe
          ls -alF
          

    Of course, nothing would be in the directory, but that's because it only just got created.

  • cp:

    cp stands for copy. It's format is cp from to. For instance, if I wanted to copy the file foo from the current directory to one called proe, I would type:

    cp foo proe
          
    If I wanted to rename it to foo2, I would type
    cp foo proe/foo2
    . If I wanted to copy all the part files from my current directory, I would type:
    cp *.prt.* proe
          
    (we need two stars here, one to match the beginning of the filename, one to match the revision, so that foo.prt.1 and bar.prt.2 both get copied.)


  • mv:

    mv works exactly like cp, except it doesn't leave a copy behind. mv stands for move.


Back to the Index
 
The University of Minnesota is an equal opportunity educator and employer.