Sun Microsystems, Inc.
spacerspacer
spacer www.sun.com docs.sun.com |
spacer
black dot
 
 
18.  Accessing Removable Media (Tasks) Accessing Removable Media on a Remote System (Task Map) How to Make Local Media Available to Other Systems Example--Making Local CDs Available to Other Systems  Previous   Contents   Next 
   
 

Example--Making Local Diskettes Available to Other Systems

The following example shows how to make any local diskette available to other systems on the network.

# ps -ef | grep nfsd
    root 10127  9986  0 08:25:01 pts/2    0:00 grep nfsd
    root 10118     1  0 08:24:39 ?        0:00 /usr/lib/nfs/nfsd -a
# mkdir /dummy
# vi /etc/dfs/dfstab
(Add the following line:)
share -F nfs -o ro  /dummy
# eject floppy0
# chmod 644 /etc/rmmount.conf
# vi /etc/rmmount
(Add the following line to the File System Sharing section.)
share floppy*
# chmod 444 /etc/rmmount.conf
(Load a diskette.)
# volcheck -v
media was found
# share
-               /dummy   ro   ""  
-               /floppy/myfiles   rw   ""  

Example--Making Local PCMCIA Memory Cards Available to Other Systems

The following example shows how to make any local PCMCIA memory card available to other systems on the network.

# ps -ef | grep nfsd
    root 10127  9986  0 08:25:01 pts/2    0:00 grep nfsd
    root 10118     1  0 08:24:39 ?        0:00 /usr/lib/nfs/nfsd -a
# mkdir /dummy
# vi /etc/dfs/dfstab
(Add the following line:)
share -F nfs -o ro  /dummy
# eject pcmem0
# chmod 644 /etc/rmmount.conf
# vi /etc/rmmount
(Add the following line to the File System Sharing section:)
share floppy*
# chmod 444 /etc/rmmount.conf
(Load a PCMCIA memory card.)
# volcheck -v
media was found
# share
-               /dummy   ro   ""  
-               /pcmem/myfiles   rw   ""  

How to Access Removable Media on Remote Systems

You can access media on a remote system by mounting it manually into your file system, provided the other system has shared its media according to the instructions in "How to Make Local Media Available to Other Systems".

  1. Select an existing directory to serve as the mount point or create one.

    $ mkdir directory

    directory is the name of the directory that you create to serve as a mount point for the other system's CD.

  2. Find the name of the media you want to mount.

    $ showmount -e system-name
    export list for system-name:
    /cdrom/sol_9_sparc (everyone)
  3. As superuser, mount the media.

    # mount -F nfs -o ro system-name:/media/media-name local-mount-point

    system-name

    The name of the system whose media you will mount.

    media-name

    The name of the media you want to mount.

    local-mount-point

    The local directory onto which you will mount the remote media.

  4. Log out as superuser.

  5. Verify that the media is mounted.

    $ ls /media

Example--Accessing CDs on Other Systems

The following example shows how to mount the CD named sol_9_sparc from the remote system starbug onto the /cdrom directory of the local system.

$ showmount -e starbug
export list for starbug:
/cdrom/sol_9_sparc (everyone)
$ su
Password: password
# mount -F nfs -o ro starbug:/cdrom/sol_9_sparc /cdrom
# exit
$ ls /cdrom
cdrom0     sol_9_sparc

Example--Accessing Diskettes on Other Systems

The following example shows how to mount the diskette named myfiles from the remote system mars onto the /floppy directory of the local system.

$ cd /net/mars
$ ls /floppy
floppy0     myfiles
$ su
Password: password
# mount -F nfs mars:/floppy/myfiles /floppy
# exit
$ ls /floppy
myfiles

Example--Accessing PCMCIA Memory Cards on Other Systems

The following example shows how to mount the PCMCIA memory card named myfiles from the remote system mars onto the /pcmem directory of the local system.

$ cd /net/mars
$ ls /pcmem
pcmem0     myfiles
$ su
Password: password
# mount -F nfs mars:/pcmem/myfiles /pcmem
# exit
$ ls /pcmem
myfiles
 
 
 
  Previous   Contents   Next