LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-15-2004, 04:27 PM   #1
adriaanbw
Member
 
Registered: May 2003
Location: Brisbane, Australia
Distribution: Fedora Core 4 with XFCE
Posts: 128

Rep: Reputation: 16
smbmount in script not working


Hi all,

I have placed two smbmount commands in a script so i can quickly mount two networked windows shares, so yes i have created the /mnt points. However, the script doesnt seem to run properly.

when i run the two commands individually in a terminal they work fine. I realise that i must be root to smbmount, but even when i execute the script in a term as su, still doesnt work.

script is pasted below.
thanks
------

#!/bin/bash

smbmount //aaa.bbb.ccc.ddd/windocs /mnt/windocs -o username=XXXX,password=YYYY
smbmount //aaa.bbb.ccc.ddd/Scratch /mnt/scratch -o username=XXXX,password=YYYY
 
Old 12-15-2004, 04:32 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Error-messages, any output at all?

Best of copy & paste the output of your terminal
session (remove critical info again).


Cheers,
Tink
 
Old 12-15-2004, 04:34 PM   #3
sigsegv
Senior Member
 
Registered: Nov 2004
Location: Third rock from the Sun
Distribution: NetBSD-2, FreeBSD-5.4, OpenBSD-3.[67], RHEL[34], OSX 10.4.1
Posts: 1,197

Rep: Reputation: 47
What does your shell output when you run the script? "still doesn't work" isn't much to go on.
 
Old 12-15-2004, 04:43 PM   #4
adriaanbw
Member
 
Registered: May 2003
Location: Brisbane, Australia
Distribution: Fedora Core 4 with XFCE
Posts: 128

Original Poster
Rep: Reputation: 16
right you are. sorry folks, but to be honest there is no output. the only evidence i have that its not running the command properly is that when i type:

ls /mnt/windocs (and likewise for other share)

i get nothing. no files listed. after running each command individually, i get a full listing.
 
Old 12-15-2004, 04:47 PM   #5
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
Mate!

Just give us the transcript of the session :}


Cheers,
Tink
 
Old 12-15-2004, 05:30 PM   #6
sigsegv
Senior Member
 
Registered: Nov 2004
Location: Third rock from the Sun
Distribution: NetBSD-2, FreeBSD-5.4, OpenBSD-3.[67], RHEL[34], OSX 10.4.1
Posts: 1,197

Rep: Reputation: 47
Ok, let's assume there are really no errors...

Run your script and post the output of mount
 
Old 12-15-2004, 06:47 PM   #7
adriaanbw
Member
 
Registered: May 2003
Location: Brisbane, Australia
Distribution: Fedora Core 4 with XFCE
Posts: 128

Original Poster
Rep: Reputation: 16
hi all,

so i have been playing around with it some more and i am not sure what i did but i believe it now works

i had an su command in the script ahead of the smbmount commands. so after running that in the terminal i was of course still as 'root'. running mount at that point showed no network shares mounted. when i exited back to my user account, and then ran mount again it showed the shares.


it seems very odd but as i said earlier, there was never any errors so i guess it was always working, just i wasnt able to see them immediately.

thanks for your time though. i appreciate your efforts
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
SH Script not working PEACEYALL Linux - General 3 03-21-2005 08:58 AM
smbmount stopped working (operation already in progress) jeffbarish Linux - Networking 2 10-22-2004 04:46 AM
Help get this script working please rickenbacherus Linux - General 2 03-24-2004 06:25 PM
smbmount not working sikandar Linux - Software 4 08-22-2003 12:48 PM
Smbclient is working fine but smbmount is not.. sandy Linux - Networking 1 07-31-2003 05:58 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:11 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration