Linux – Access windows file system from linux shell script

linuxshell-scriptingwindows

I want to know, whether is it possible to access the Windows files from a shell script on Linux system ?
What i am trying to do is to run a shell script in my Linux system, that will access the files of a remote Windows system, read them and manipulate them.
Forget about the file and folder permissions.

Is it possible to do this using the Linux shell scripts (or perl scripts)?

Best Answer

Yes, you can mount a windows share into the linux filesystem using mount.cifs e.g.

mkdir /mnt/windowsfs
mount -t cifs //server/share -o username=user,password=P4ssw0rd /mnt/windowsfs

Once you've done that you can (with suitable permissions) access and manipulate the files in /mnt/windowsfs.