A Heterogeneous Linux/Windows 95 Home Network
To enable file and print sharing between Linux and Windows 95 machines, you need the Samba suite, which is installed as part of the Red Hat installation.
I wanted to use serrano as a file server so I can install all my Windows 95 software on serrano. Under my home directory on serrano, I created a directory called samba, which will be used to install all my Windows 95 software. I will make this directory (/home/easwaran/samba) visible from ancho as its D: drive. In addition I have a DeskJet 540 printer, attached to serrano, that I want to use to print from ancho. I also want to access the CD-ROM drive on serrano from ancho. My CD-ROM mount point on serrano is /mnt/cdrom, and I would like ancho to see this as the E: drive.
Samba is configured via the file /etc/smb.conf. Read the Samba documentation available at http://www.samba.org/ for more details. My smb.conf file is shown in Listing 3. Samba gives many other options: the original /etc/smb.conf file has many good examples. Also check the Samba documentation (/usr/doc/HOWTO/SMB-HOWTO or http://www.samba.org/).
Using the smb.conf file, I have made my serrano home directory (/home/easwaran) and the /tmp directory on serrano visible to the Windows 95 machine. The names in square brackets, [easdir] and [cdrom], are the names under which /home/easwaran/samba and /mnt/cdrom will be available to ancho and seen under “Network Neighborhood”. The line
log file = /var/log/samba-log.%m
toward the beginning of smb.conf file directs Samba to log in to /var/log/samba-log.serrano. In case of trouble, this will be quite useful.
Once you have modified /etc/smb.conf, stop and restart Samba:
/etc/rc.d/init.d/smb stop /etc/rc.d/init.d/smb start
In the following instructions, I assume your Windows 95 logon password is the same as your login password for serrano. If they are not the same, you will get a password prompt when you try to mount a directory from serrano on ancho. I make the passwords the same to avoid the hassle, but this may not be a good idea in other situations.
At this point, if you click on “Network Neighborhood” on the Windows 95 machine ancho, you should see serrano listed. Double-click on serrano, and you should see the directories cdrom, easdir, tmp, easwaran, lp and others you may have shared. Open a DOS window and type
net use d: \\serrano\easdir
You should then see “command completed successfully”, which means that /home/easwaran/samba is available to you on ancho as your D: drive. You can install software and do whatever you want in this directory.
net use e: \\serrano\cdrom
will mount the CD-ROM on serrano as your E: drive on ancho. Make sure your CD is mounted on serrano as /mnt/cdrom—you may have to do this manually. When I installed Red Hat 5.0, initially only root had mount permission for the CD-ROM drive, so that had to be changed.
To have these drives automatically mounted each time you boot your Windows 95 machine, you can put the net use commands in your Startup folder. To do this, look for Windows 95 help under Startup. Alternatively, you could open the “Network Neighborhood”, select the machine and the directory and click the right mouse button. This will give you an option to “Map Network Drive”. Here, you can specify the drive letter for that directory to be mounted under, and whether this drive is to be mapped at logon time.
Installing the printer correctly on the Linux machine is easy to do from the Red Hat control panel. We need to make this printer the default printer for ancho. Go to ancho's Control Panel, click “Printers”, then “Add Printer”. Choose “Remote Printer, Browse”. At this point, you should see your printer on serrano listed as lp. Select it, click “OK” and follow the instructions. You will have to load the driver for your printer. (Check the Windows 95 CD or the printer manufacturer's disks or find it on the Web.) Print a test page, and make this your default printer.
The next task is to make the C: drive on ancho visible to serrano and other machines on the network. Click on “Network” in the Control Panel and make sure you have “Client for Microsoft Networks” installed (if not, install it). Under “File and Print Sharing”, click on “want to be able to give others access to my files” and “OK”. This may install some more files from the Windows 95 CD. If you now go to “My Computer”, click on “C:” and pull down “Properties”, you should see “Sharing” in the menu; click on it. Then click on “Shared as” and give a share name, “C-Ancho” with Access Type: Full. Type in an access password; I use the same one as my Windows login password. Click “OK”. Now your C: drive on ancho is available to any machine on the network under the name C-Ancho. The icon for the C: drive under “My Computer” will have a blue hand holding the drive.
There is an FTP-like interface that allows you to mount the C: drive from ancho on serrano. If you type smbclient -L ancho on serrano, you should get a listing of shared resources on ancho similar to the one shown in Listing 4.
If you type smbclient \\ancho\C-ANCHO on serrano, you will be prompted for the password (the one you gave ancho to share its C: drive) and you will get an smb> prompt. If you type ls, you will see the files and directories on ancho's C: drive. Read the SMB-HOWTO documentation in /usr/doc/HOWTO for more information.
|PostgreSQL, the NoSQL Database||Jan 29, 2015|
|HPC Cluster Grant Accepting Applications!||Jan 28, 2015|
|Sharing Admin Privileges for Many Hosts Securely||Jan 28, 2015|
|Red Hat Enterprise Linux 7.1 beta available on IBM Power Platform||Jan 23, 2015|
|Designing with Linux||Jan 22, 2015|
|Wondershaper—QOS in a Pinch||Jan 21, 2015|
- PostgreSQL, the NoSQL Database
- Sharing Admin Privileges for Many Hosts Securely
- HPC Cluster Grant Accepting Applications!
- Internet of Things Blows Away CES, and it May Be Hunting for YOU Next
- Ideal Backups with zbackup
- Wondershaper—QOS in a Pinch
- January 2015 Issue of Linux Journal: Security
- Slow System? iotop Is Your Friend
- Red Hat Enterprise Linux 7.1 beta available on IBM Power Platform
- Designing with Linux
Editorial Advisory Panel
Thank you to our 2014 Editorial Advisors!
- Jeff Parent
- Brad Baillio
- Nick Baronian
- Steve Case
- Chadalavada Kalyana
- Caleb Cullen
- Keir Davis
- Michael Eager
- Nick Faltys
- Dennis Frey
- Philip Jacob
- Jay Kruizenga
- Steve Marquez
- Dave McAllister
- Craig Oda
- Mike Roberts
- Chris Stark
- Patrick Swartz
- David Lynch
- Alicia Gibb
- Thomas Quinlan
- Carson McDonald
- Kristen Shoemaker
- Charnell Luchich
- James Walker
- Victor Gregorio
- Hari Boukis
- Brian Conner
- David Lane