Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,730,761 Members 42,205 Now Online
XDA Developers Android and Mobile Development Forum

[Q] mounting a windows shared folder to android fs

Tip us?
 
liran corleone
Old
#1  
Junior Member - OP
Thanks Meter 0
Posts: 19
Join Date: Nov 2013
Default [Q] mounting a windows shared folder to android fs

i looked at these forums and solutions for doing this and none of them worked for me so i'm posting this in case someone knows how to solve this:

I am using nexus 7 2013 with cyanogenmod 10.2.1. i tried both "cifsmanager" and "mount manager" applications to mount my shares (with the right credentials). i also used the following command:

busybox mount -t cifs -o username=[user],password=[password] //192.168.1.91/T /mnt/sdcard/users

all these produce the same error - "mount: invalid argument" when trying to connect to the shared folder.
 
peterk-1
Old
#2  
Senior Member
Thanks Meter 42
Posts: 209
Join Date: Jan 2012
Have you seen if smbfs rather than cifs works? ( I know smbfs is "old"). There is some relevant info here http://www.netzgewitter.com/2013/10/...fs-on-android/ on the problems with cifs and Sony Xperia
The Following User Says Thank You to peterk-1 For This Useful Post: [ Click to Expand ]
 
liran corleone
Old
#3  
Junior Member - OP
Thanks Meter 0
Posts: 19
Join Date: Nov 2013
Quote:
Originally Posted by peterk-1 View Post
Have you seen if smbfs rather than cifs works? ( I know smbfs is "old"). There is some relevant info here http://www.netzgewitter.com/2013/10/...fs-on-android/ on the problems with cifs and Sony Xperia
Thanks man!!!!! the "-o unc=" thing soved the issue!
 
liran corleone
Old
#4  
Junior Member - OP
Thanks Meter 0
Posts: 19
Join Date: Nov 2013
Quote:
Originally Posted by liran corleone View Post
Thanks man!!!!! the "-o unc=" thing soved the issue!
I guess i was happy too soon - the mount now does work, but i cannot access it with other users. this is how i did the mount:

mount -o unc=\\\\192.168.1.91\\d$,username=developer,passwo rd=pass -t cifs none /mnt/cifs/arcade/d

this is the "mount" command output afterwards:

none /mnt/cifs/arcade/d cifs rw,relatime,sec=ntlm,unc=\\192.168.1.91\d$,usernam e=developer,uid=0,noforceuid,gid=0,noforcegid,addr =192.168.1.91,file_mode=0755,dir_mode=0755,nounix, serverino,rsize=61440,wsize=65536,actimeo=1 0 0

Any idea why/how to solve this?
 
spiked_mistborn
Old
#5  
spiked_mistborn's Avatar
Member
Thanks Meter 37
Posts: 93
Join Date: Nov 2012
Location: Michigan
I've had good luck using the cifs module in the ElementalX kernel along with cifsmanager. You don't need to configure anything other than your shares, and maybe set mount point prefix to /mnt/cifs
If you want to mount shares remotely through ssh port forwarding you can specify the port number that you are forwarding to using port= in options. I'm getting ready for work, so I don't have time right now to get the output showing the mount command that it generates, but I can when I get home.
The Following User Says Thank You to spiked_mistborn For This Useful Post: [ Click to Expand ]
 
liran corleone
Old
#6  
Junior Member - OP
Thanks Meter 0
Posts: 19
Join Date: Nov 2013
Quote:
Originally Posted by spiked_mistborn View Post
I've had good luck using the cifs module in the ElementalX kernel along with cifsmanager. You don't need to configure anything other than your shares, and maybe set mount point prefix to /mnt/cifs
If you want to mount shares remotely through ssh port forwarding you can specify the port number that you are forwarding to using port= in options. I'm getting ready for work, so I don't have time right now to get the output showing the mount command that it generates, but I can when I get home.
i cannot use this kernel since i am using cyanogenmod 10.2.1 (i need the wireless ad-hoc connection mode support) so i will need another solution for this...
 
spiked_mistborn
Old
#7  
spiked_mistborn's Avatar
Member
Thanks Meter 37
Posts: 93
Join Date: Nov 2012
Location: Michigan
Well, I checked in /system/lib/modules to see if cifs.ko was there, but it's not. I was thinking maybe extracting the cifs modules from the ElementalX kernel might be possible, but it must be part of the kernel source and not a separate file. Seems like more people would find cifs support useful, so maybe somebody with development skills will make a kernel module file that's compatible with the N7 2013.

Here's what shows up when I run mount:
//192.168.0.100/Music /mnt/cifs/Music cifs rw,relatime,sec=ntlm,unc=\\192.168.0.100\Music,use rname=username,uid=0,noforceuid,gid=0,noforcegid,a ddr=192.168.0.100,file_mode=0755,dir_mode=0755,nou nix,serverino,rsize=16384,wsize=131007,actimeo=1 0 0
 
mdamaged
Old
(Last edited by mdamaged; 22nd April 2014 at 01:57 AM.)
#8  
mdamaged's Avatar
Senior Member
Thanks Meter 844
Posts: 1,351
Join Date: Oct 2013
Location: South of Heaven

 
DONATE TO ME
Nevermind.
Kenneth, what is the frequency? Set a fire for a man, and he will stay warm for a night. Set a man on fire, and he will stay warm for the rest of his life.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
liran corleone
Old
#9  
Junior Member - OP
Thanks Meter 0
Posts: 19
Join Date: Nov 2013
Quote:
Originally Posted by mdamaged View Post
Nevermind.
cifs seems to be supported well by cyanogenmod - the mount process is working fine, but the mounted folders are only visible with root priviledges - not to device's applications like poweramp, pdf reader etc.
 
mdamaged
Old
#10  
mdamaged's Avatar
Senior Member
Thanks Meter 844
Posts: 1,351
Join Date: Oct 2013
Location: South of Heaven

 
DONATE TO ME
Quote:
Originally Posted by liran corleone View Post
cifs seems to be supported well by cyanogenmod - the mount process is working fine, but the mounted folders are only visible with root priviledges - not to device's applications like poweramp, pdf reader etc.
It's private namespaces that's the issue.
Kenneth, what is the frequency? Set a fire for a man, and he will stay warm for a night. Set a man on fire, and he will stay warm for the rest of his life.
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


XDA PORTAL POSTS

Blast Those Flags with Knock the Flags

Lately, we have seen a rather drastic shift in the world of mobile device gaming. The infamous Angry … more

Hide Numbers on Your SMS and Call Logs with Reflection

How many times have you given your device to someone else in order to show them a … more

Implement Split View in Your LG G2 KitKat Rom with Automated Installer

Some of you may have remembered a story on the Portal a few weeks back … more

Cast Your Device Screen the Way it Was Meant to be with Second Screen

Not too long ago here on the XDA Portal, we covered how Google had made … more