Sunday, July 31, 2011

Mounting windows share on android Froyo

Recently i bought my first android based mobile (Samsung Galaxy Pro) and since then i was looking for something to access my windows shared folder via wifi. So i started exploring and found that on a rooted device it is possible to mount a window share using using cifs (Common Internet File Sharing Protocol) kernel module (cifs.ko) and mount command. I looked over net and found many builds of cifs.ko but didn't found a build for my kernel version 2.6.23.9-perf PREEMPT so i decided to build my own cifs. To make the kernel module i downloaded firmware source code from samsung's open source code distribution website https://opensource.samsung.com/. During the build i found that cifs module depends on slow-work and for that i build another module slow-work.ko and then i used terminal emulator to exeute mount command for inserting kernel modules and mounting the share.

         insmod /mnt/system/lib/slow-work.ko
         insmod /mnt/system/lib/cifs.ko
         mount -o username=,password= -t cifs anil-pc/d$ /mnt/cifs/d

and wollla now i can access any shared file from laptop on mobile via wifi like any other local file on mobile.

If you are not good at linux commands then you can download Cifs manager https://market.android.com/details?id=ws.plattner.cifsmanager&hl=en to do the same for you.

You can download my build of kernel modules here http://dl.dropbox.com/u/48560079/cifs_and_slow_work_modules_2.6.32.9-perf_PREEMPT.zip (Specific to kernel version: 2.6.23.9-perf PREEMPT, use uname -a command to find your kernel version or goto Settings>About phone>Kernel Version)

2 comments:

Anonymous said...

Thanks for the kernel modules, I will try them out on my device and let you know the working status

Piotr LA said...

It's good to read such articles. Good information. Thanks for such a great post.
Find deals with hotels