| Prev |   3     4   5 |
maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   Samba? (https://talk.maemo.org/showthread.php?t=2487)

wiredless 2006-07-22 15:56

mount -t cifs at my address keeps returning (cant find in fstab) error. Any idea why?

Hedgecore 2006-07-23 01:28

I had the same problem (read back in the thread... you must have root enabled in the same shell you ran the other steps in)

BanditRider 2006-07-24 15:36

Here is my setup:
I have a Linksys WRTSL54GS wireless router which has a USB port to which I've connected a 120GB drive in an external enclosure. The router firmware allows me to create a "windows share" which I've named NAS and has read/write access for user "joe" with password "passw0rd". This is the same thing, really, as having a shared folder on a Windows machine.

I created a directory called NAS in /media to be the mount point. You could create it in /media/mmc1 to make it easier to browse to. This was just my choice.

I don't mind having the cifs kernel module loaded all the time so I've added a line near the top of /etc/init.d/minircS to load the module at boottime.

Here's an excerpt of my minircS file:
Code:

#!/bin/sh

umask 022
PATH=/sbin:/bin:/usr/sbin:/usr/bin
insmod /mnt/initfs/lib/modules/2.6.16-omap1/ext2.ko
insmod /lib/modules/cifs.ko

mount -t proc proc /proc
mount -t sysfs sysfs /sys
mount -t usbfs usbfs /proc/bus/usb

...
I cut out alot of stuff here...
then at the bottom of the file
...

#osso hotfix #24145
chmod a+w /sys/devices/platform/audio-i2c/mic_enable
swapon -a
mount /media/mmc2
exit 0

You'll notice I also load the ext2 kernel module and mount my ext2 partition on my mmc card here. I also activate my swap partition here.

This is my /etc/fstab file:
Code:

rootfs  /              rootfs  defaults,errors=remount-ro,noatime      0 0
/dev/mmcblk0p1  /media/mmc1 vfat rw,noauto,nodev,noexec,nosuid,utf8,uid=29999 0 0
/dev/mmcblk0p2  /media/mmc2 ext2 rw,noauto      0 0
/dev/mmcblk0p3  swap    swap    defaults        0 0
//192.168.1.1/NAS      /media/NAS      cifs    rw,user=joe,password=passw0rd 0 0

Now I can mount the share with the command

mount /media/NAS

But since you need to be root to mount a filesystem, I modified fanouch's slick gainroot script and called it mountNAS and umountNAS as follows:

mountNAS
Code:

#!/bin/sh
# mount cifs shared folder from the router
# use gainroot to become root and relaunch itself
if [ `id -u` != 0 ] ; then
#if not already root, call itself as root
sudo gainroot <<EOF
$0 $*
EOF
exit
fi
mount /media/NAS

and umountNAS
Code:

#!/bin/sh
# un-mount cifs shared folder from the router
# use gainroot to become root and relaunch itself
if [ `id -u` != 0 ] ; then
#if not already root, call itself as root
sudo gainroot <<EOF
$0 $*
EOF
exit
fi
umount /media/NAS

I made them executable with chmod +x mountNAS umountNAS
Then I coppied them to /usr/bin (which is in both user's and root's PATH)

I can now mount the share by ebtering the command mountNAS
and unmount it with umountNAS

I've added them to gnuite's cpu/load w/ run applet and it works great.

BruceL 2006-10-27 02:46

In the first post it was asked if Samba would allow printing from the 770. Abiword has a menu item for printing. Other programs don't have a print menu item, but since Abiword does, could it print to a shared printer through Samba?

Bruce


| Prev |   3     4   5 |
All times are GMT. The time now is 06:50.

vBulletin® Version 3.8.8