Part 1 Share files from windows to Linux
1. Installed windows 2003 active directory in VMware, share c:\share and put one file text under this folder, the whole network is using
VMnet3. IP address is 192.168.0.99.  The DHCP is disabled to save memory.
 
2. Under Linux go to terminal, use su login root account, go to /etc/sysconfig/network-scripts/
Change ifcfg-th1 ( I used two network cards, the eth0 is bridged with real network card, the eth1 is using VMnet3) into

DEVICE=eth1
ONBOOT=yes
BOOTPROTO=static
BROADCAST=192.168.0.255
IPADDR=192.168.0.138
NETMASK=255.255.255.0
NETWORK=192.168.0.0
TYPE=Ethernet
HWADDR=xx:xx:xx:xx:xx:xx à(KEEP THIS AS ORIGINAL!!!)

3. run "ifdown eth1" and "ifup eth1" to restart eth1

4. mkdir /mnt/test2/
5. mount –t cifs –o username=xxx,password=xxx //192.168.0.99/share /mnt/test
6. now goes to /mnt/test, you will see the shared resources from windows 2003
Part 2 share files from linux to Windows

1. Install samba on linux server, go to linux installation disk\server, rpm –ivh  ./Server/samba-3.0.23c-2.i386.rpm

2. Rpm –ivh ./Server/samba-client-3.0.23c-2.i386.rpm

3. After installed samba, configure /etc/samba/smb.conf

Change smb.conf into

[global]

workgroup = mygroup

netbios name=LinuxServername

server string = Linux Smaba Server

Security = share

guest account = administrator

[linuxShare]

Description= First share folder  

path=/home/share

public= yes

writeable = yes

browseable = yes

guest ok =yes

visible = yes

4.#makedir /home/share

5.#setup turn off firewall and selinux

6.# ./sbin/service smb start

6. go to windows server 2003, run \\192.168.0.138 you will see the shared folder

 
Advertisements