Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Fri 18 Apr 2014, 22:03
All times are UTC - 4
 Forum index » House Training » Beginners Help ( Start Here)
automate "scan as user" and "mount" in L
Moderators: Flash, Ian, JohnMurga
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [4 Posts]  
Author Message
carbking

Joined: 11 Mar 2006
Posts: 5
Location: Pennsylvania, USA

PostPosted: Tue 14 Mar 2006, 20:42    Post subject:  automate "scan as user" and "mount" in L  

Following HOWTO : Share files and folders between Computers, I've put the following line in /etc/rc.d/rc.local:

smbmount //192.168.1.46/HPmp3 mnt/HPmp3

This gets me thru steps 1-7 of the LinNeighborhood portion of the HOWTO, but I still have to do steps 8 and 10 manually every time I boot up before I can access the folder over the LAN from a Windows XP machine.

Is there a way to automate these two steps:

8. Right click on the computer name/address and select "scan as user"

10. Right click in the share you want to use and click "mount" ?

Thanks!

_________________
Al
Back to top
View user's profile Send private message 
Adrian Fischer


Joined: 29 Jan 2006
Posts: 4

PostPosted: Tue 14 Mar 2006, 23:25    Post subject:  

Hello Carbking,

I could be wrong but...

create the share manually using the utility (cant think what its called ..) but after you have done the whole scan as user and mount thingy...in the menu across the top there is an option to export the mount script. Save that somehwere you can remember then go to etc/rc.local Work with me here as I am not a my puppy pc ...but in that file cut an copy the text from the mountscrip you save previoulsy. Then when next you boot the share is created automatically.

Did that answer the question? Sorry if it was vague but I have done it several times now on various machines and it does the trick.

_________________
Adrian Fischer
Brisbane, Australia
Back to top
View user's profile Send private message 
jmarsden


Joined: 31 Dec 2005
Posts: 263
Location: California, USA

PostPosted: Wed 15 Mar 2006, 02:25    Post subject: Re: automate "scan as user" and "mount"  

carbking wrote:
Following HOWTO : Share files and folders between Computers, I've put the following line in /etc/rc.d/rc.local:

smbmount //192.168.1.46/HPmp3 mnt/HPmp3
You may be missing a leading / in the path to the mount point: Try
Code:
/mnt/HPmp3


Quote:
8. Right click on the computer name/address and select "scan as user"
I have no idea why you need to scan anything as anybody, since you already know the computer IP address and share name that you intended to use...and hard coded them into rc.local!?
Quote:
10. Right click in the share you want to use and click "mount" ?
mounting the SMB share is exactly what smbmount does. So you already did that in rc.local -- if your smbmount command actually worked OK. So, my suspicion is that in fact it did not!

After booting (and so running your smbmount command in rc.local), but without using LinNeighbourhood at all, what does typing
Code:
mount
in a terminal (console) window show you? Do you see the mounted SMB share on /mnt/HPmp3 listed in its output? If not, then your smbmount command is not working the way you think it is. Maybe in that case you can type in in by hand at the shell prompt in a terminal window, and note any error messages it displays?

If you need to specify a user to connect as, try adding -o username=whoever,password=whatever to the end of your smbmount command. Replace whoever and whatever with the desired username and password, of course.

Testing the exit status of the smbmount command and displaying a message if it is non-zero (a failure) might also be helpful?

PS. I am assuming you are running smbmount directly because the Busybox mount in Puppy isn't smart enough to invoke it for you, or has some other issue that gets in the way?? If mount will use it, then you should probably use a more generic and Unix-like mount -t smbfs command, instead. Or better yet, put a line into /etc/fstab so the share is automounted at boot along with your other fileystems -- with no need for kludged extra commands in rc.local Smile If you could explain why you are using smbmount instead, it might be useful.

Jonathan
Back to top
View user's profile Send private message 
carbking

Joined: 11 Mar 2006
Posts: 5
Location: Pennsylvania, USA

PostPosted: Wed 15 Mar 2006, 09:36    Post subject:  

Adrian: thanks for your reply. Yes, that worked. In LinNeighborhood under Options there is "Export Mountscript." Thank you!

Jonathan: thanks for your reply. You mentioned:

>You may be missing a leading / in the path to the mount point

My apologies; the / was actually in there; I mis-typed in my post. From looking at the mountscript I saved using Adrian's suggestion, it appears that the problem was that it needed /root in front of what I had in rc.local.

smbmount //192.168.1.46/HPmp3 /mnt/HPmp3

should have been

smbmount //192.168.1.46/HPmp3 /root/mnt/HPmp3


Your suspicion that my smbmount command did not work was correct, and verified when I typed "mount" in a terminal window.

> If you could explain why you are using smbmount instead, it might be useful.

That's easy; I don't know what the heck I'm doing and was blindly following the example in the referenced HOWTO. Very Happy I freely, if not proudly, confess my ignorance. Are these commands/topics specific to Puppy, or would reading any general book on Linux be useful?

Thanks again for your help.

_________________
Al
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [4 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » House Training » Beginners Help ( Start Here)
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0473s ][ Queries: 12 (0.0033s) ][ GZIP on ]