This is a discussion on reading usbstick across a network within the Linux Networking forums, part of the Linux Forums category; I cant get at my usb ports on my desktop, but can on my laptop ( next to it & networked) ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
I cant get at my usb ports on my desktop, but can on my laptop ( next to it
& networked) 1) i can mount the pendrive from the laptop from laptop - /etc/fstab /dev/sda /mnt/pendrive auto moauto,user,exec,umask=000 0 0 I can read and write to the pendrive as laptop user from the desktop: bash-2.05b# mount -t nfs 192.168.1.9:/mnt/pendrive /mnt/pendrive bash-2.05b# ls /mnt/pendrive Blank10.xls Differential Equations.sxw Music Coursework.sxw change to user and I can still see the files: from the desktop bash-2.05b$ cp /mnt/pendrive/Music\ Coursework.sxw /tmp cp: cannot stat `/mnt/pendrive/Music Coursework.sxw': Input/output error bash-2.05b$ ls -la /mnt/pendrive ls: /mnt/pendrive/Music Coursework.sxw: Input/output error ls: /mnt/pendrive/Differential Equations.sxw: Input/output error ls: /mnt/pendrive/Blank10.xls: Input/output error ls: /mnt/pendrive/.directory: Input/output error and in Konqueror (as user) desktop(/mnt/pendrive ) appears empty this is linux - there must be a solution :-)) |
|
|||
|
Hi,
> I cant get at my usb ports on my desktop, but can on my laptop ( next to it > & networked) > 1) i can mount the pendrive from the laptop > from laptop - /etc/fstab > /dev/sda /mnt/pendrive auto moauto,user,exec,umask=000 0 0 > I can read and write to the pendrive as laptop user > > from the desktop: > bash-2.05b# mount -t nfs 192.168.1.9:/mnt/pendrive /mnt/pendrive > bash-2.05b# ls /mnt/pendrive > Blank10.xls Differential Equations.sxw Music Coursework.sxw > change to user and I can still see the files: > > from the desktop > > bash-2.05b$ cp /mnt/pendrive/Music\ Coursework.sxw /tmp > cp: cannot stat `/mnt/pendrive/Music Coursework.sxw': Input/output error Hust a guess: do you (or the user sent by nfs) have read permissions on the files you wanted to copy? I had a similar problem with samba. Some files on my shares were listable, but i could not open them in any way. The Dir had browse permission to anyone, but the files were only accessible by it's owner..... HTH Ralf |
|
|||
|
plaptop root # cd /mnt/pendrive/
plaptop pendrive # ls -la total 773 drwxrwxrwx 2 root root 512 Jan 1 1970 . drwxr-xr-x 7 root root 216 May 8 21:45 .. -rwxrwxrwx 1 root root 44 May 9 19:04 .directory -rwxrwxrwx 1 root root 505856 May 8 22:16 Blank10.xls -rwxrwxrwx 1 root root 125729 May 8 21:52 Differential Equations.sxw -rwxrwxrwx 1 root root 157597 May 8 21:52 Music Coursework.sxw everything is 777 ! |
|
|||
|
the pen is vfat - mounted from the laptop
/dev/sda*/mnt/pendrive*auto*moauto,user,exec,umask=000*0*0* works as well sith -t vfat accesing laptop:/mnt/pendrive from the desktop has to be nfs vfat here gives a device not accessible error message mount*-t*nfs*192.168.1.9:/mnt/pendrive*/mnt/pendrive* Steve Wolfe wrote: > > How are you exporting it - Samba, or NFS? Most pendrives have a VFAT > file > system, and if I recall, you can't reliably export VFAT via NFS. > > steve > > |
|
|||
|
> the pen is vfat - mounted from the laptop
> /dev/sda /mnt/pendrive auto moauto,user,exec,umask=000 0 0 > > works as well sith -t vfat > > accesing laptop:/mnt/pendrive from the desktop has to be nfs > vfat here gives a device not accessible error message So, you are trying to export a vfat file system via NFS. I looked into it a bit further, and while vfat via NFS used to be a "it just won't work", that's not *necessarily* the case any more. However, you have to be running the right kernel versions, nfs-utils, etc.. As an example, a message on LKML indicates that some versions (such as 2.4.24) worked, while some (like 2.4.25) did not. And, some of RedHat's nfs-utils will let you do it, some won't. You have three options here: 1. Format the pendrive with ext2. It'll work great with Linux, and will export nicely via NFS. Unfortunately, it won't work with Windows. 2. You can export the vfat file system with samba instead of NFS. 3. You can do a lot of googling and version comparisons until you find the combination that works. steve |
|
|||
|
been having a go with samba server running on the laptop
from the laptop running samba dadslaptop root # tail -n 7 /etc/samba/smb.conf [pendrive] comment =PenDrive in Pauls Laptop path=/mnt/pendrive public=yes writeable=yes from the desktop bash-2.05b# smbclient -I 192.168.1.9 //dadslaptop/pendrive Password: Domain=[DADSLAPTOP] OS=[Unix] Server=[Samba 3.0.2a] smb: \> ls . D 0 Thu Jan .. D 0 Sat May Music Coursework.sxw A 157597 Sat May Differential Equations.sxw A 125729 Sat May Blank10.xls A 505856 Sat May .directory AH 44 Sun May smb: \> q bash-2.05b# whoami root bash-2.05b# ls -la /mnt/pendrive total 1 drwxrwxrwx 2 paul users 48 May 9 16:19 . drwxr-xr-x 13 root root 336 May 9 16:19 .. bash-2.05b# can get to it with smbclient but cant browse or copy from /to |
|
|||
|
sorry -missed a bit
bash-2.05b# mount -t smbfs -o username=paul,password=sackbutt //dadslaptop/pendrive /mnt/pendrive 22860: Connection to dadslaptop failed SMB connection failed bash-2.05b# mount -t smbfs -o username=paul,password=sackbutt 192.168.1.9//dadslaptop/pendrive /mnt/pendrive Usage: mount.smbfs service mountpoint [-o options,...] Version 3.0.2a Options: username=<arg> SMB username password=<arg> SMB password credentials=<filename> file with username/password etc etc also from fstab //dadslaptop/pendrive or 192.168.1.9//dadslaptop/pendrive mnt/pendrive smbfs noauto,password=sackbutt 0 0 and it fails to mount ( with the smbfs error message) |